I'm trying to configure patch management with Spacewalk of all GNU/Linux machines in my organization, but I'm struggling a bit with the scheduling. Change Management has decided, that the dev/test environments should be patched every Tuesday at 5-7 in the morning, and production environments should be patched Thursday morning in the same time frame. Besides checking for, downloading and applying patches, I've added a script to reboot the server on kernel update, and a script to clean yum. I've placed those scripts in /etc/cron.weekly/ and configured anacrontab as such:
1 5 cron.daily nice run-parts /etc/cron.daily
7 5 cron.weekly nice run-parts /etc/cron.weekly
My problem is that everything gets executed every day, and I think the problem is caused by the configuration file for yum-cron /etc/yum-cron.conf. I've tried to find information about how to configure this file, and the setting DAYS_OF_WEEK / days_of_week is obviously where the magic happens. The man page isn't really of any help either. My question is, how the F*** do I set the day of week to tuesday (2) or thursday (4)??? I've tried different variations like:
DAYS_OF_WEEK=2
DAYS_OF_WEKK="2"
days_of_week = 2
days_of_week = "2"
And yet nothing seems to work the way I want it to. I have hunch that for CentOS 7 I have to use the lowercase days_of_week, and the uppercase for CentOS 6, but I'm not sure.
Any inputs or ideas will be appreciated, and thanks in advance!