webgui icon indicating copy to clipboard operation
webgui copied to clipboard

Parity Check does not include a day of month

Open masterwishx opened this issue 10 months ago • 5 comments

how i can setup check parity in Unraid - '0 0 1 */3 *' every 3 month on 1 day 0:00?

if i set custom i can select months , but no day of month select , only weeks :

i can manually add (0 0 1 */3 *) to parity-check.cron , but not shure it will work it not shown right in webGUI ...

image

masterwishx avatar Sep 09 '23 17:09 masterwishx

You can specify the day and the which week in the month.

This runs on the 4th Sunday in the month.

image

SimonFair avatar Sep 09 '23 17:09 SimonFair

Yes, but can't set 1day of month every 3 months.

If I set Sunday of first week, but in first week no Sunday this month? For example month starting at Friday at 1day... Can I set manually (0 0 1 */3 *) in parity-check. cron? Strange that this option not available in WebGUI.

masterwishx avatar Sep 10 '23 06:09 masterwishx

You should be able to edit.

root@computenode:~# cat /boot/config/plugins/dynamix/parity-check.cron

Generated parity check schedule:

0 0 * 1,4,7,10 0 [[ $(date +%e) -le 7 ]] && /usr/local/sbin/mdcmd check NOCORRECT &> /dev/null || :

and then run update_cron. But not sure how it will show in gui.

SimonFair avatar Sep 10 '23 06:09 SimonFair

I tryed (0 0 1 */3 *) it shows like every 1day of every month... you think (0 0 1 */3 *) this will not work? If it use cron at all. I need use your example?

masterwishx avatar Sep 10 '23 07:09 masterwishx

No it was just a example of the format.

So you could create /boot/config/plugins/dynamix/custom-parity-check.cron

0 0 1 */3 * /usr/local/sbin/mdcmd check &> /dev/null

once created run update_cron

It should put this entry into /etc/cron.d/root

SimonFair avatar Sep 10 '23 18:09 SimonFair