By default, mdadm checks arrays at 01:00:00 every Sunday. For me this is terrible, because the heaviest load on the array starts on Saturday and ends on Monday. Naturally, the mdadm check caused additional problems, and several times it even stopped the array completely. So I decided to look for information on "How to change the mdadm check schedule?"
It is not difficult. FIrst, check the current schedule, then change "OnCalendar" parameter in the timer configuration file and reload the daemon. Check the result
user@vrem:~$ systemctl list-timers --all | grep -i md
Wed 2026-02-04 05:07:30 UTC 5h 59min left Tue 2026-02-03 08:15:51 UTC 14h ago mdcheck_continue.timer mdcheck_continue.service
Wed 2026-02-04 18:25:43 UTC 19h left Tue 2026-02-03 01:06:20 UTC 22h ago mdmonitor-oneshot.timer mdmonitor-oneshot.service
Sun 2026-03-01 02:18:57 UTC 3 weeks 4 days left Sun 2026-02-01 22:57:41 UTC 2 days ago mdcheck_start.timer mdcheck_start.service
user@vrem:~$ sudo nano /lib/systemd/system/mdcheck_start.timer
user@vrem:~$ sudo systemd-analyze verify /lib/systemd/system/mdcheck_start.*
user@vrem:~$ sudo systemctl daemon-reload
user@vrem:~$ systemctl list-timers --all | grep -i md
Wed 2026-02-04 05:07:30 UTC 5h 59min left Tue 2026-02-03 08:15:51 UTC 14h ago mdcheck_continue.timer mdcheck_continue.service
Wed 2026-02-04 18:25:43 UTC 19h left Tue 2026-02-03 01:06:20 UTC 22h ago mdmonitor-oneshot.timer mdmonitor-oneshot.service
Wed 2026-02-04 14:45:22 UTC 15h left Sun 2026-02-01 22:57:41 UTC 2 days ago mdcheck_start.timer mdcheck_start.service
Комментариев нет:
Отправить комментарий