cronjob in cron.d appears not to run
Posted: 15. Nov 2010, 11:48
I'm experimenting with lockout, which worked fine under Ubuntu:
http://www.linux.com/archive/feature/116324
Basically it temporarily scrambles your root password and then obeys your settings to block various time wasting activities. As the author points out, in principle this is risky, but I was careful. After the time you set expires, all returns to normal when the program executes this in /etc/cron.d
However, it doesn't work. Googling threw up a number of reports from people using various distros about things they put in cron.d not running as expected.
Any ideas as to why this might be and how to fix it?
Needless to say, I haven't tested the second active line beginning @reboot.
http://www.linux.com/archive/feature/116324
Basically it temporarily scrambles your root password and then obeys your settings to block various time wasting activities. As the author points out, in principle this is risky, but I was careful. After the time you set expires, all returns to normal when the program executes this in /etc/cron.d
Code: Select all
# lockout needs to check every minute whether it's time to unlock
*/1 * * * * root /usr/bin/lockout unlock >/dev/null 2>&1
# rebooting *MUST* restore the root password
@reboot root /usr/bin/lockout unlock force >/dev/null 2>&1
Any ideas as to why this might be and how to fix it?
Needless to say, I haven't tested the second active line beginning @reboot.