What can be causes that script in /etc/cron.monthly/weekly/daily/hourly folder does not do its job/not executed/not run?
I think this may help:
check that script has right permission (-rw------- root root)
# stat /path/to/script
now change to proper permission for Linux cron
chmod 600 /path/to/script
check that there is new line at the end of script
check that cron service is running (pid exist)command on the last line
# this is the end
# pgrep cron
try to add this line to the beginning of the script:
#!/bin/sh
try to use full pathes for commands in the script
like not "find parametershere", but "/usr/bin/find parametershere" to discover full path, do example. "which find" command or "which grep" etc.
check that user that should run the script is defined
if the script is launched from an file in /etc/cron.d/ directory, then try to add "root" into the file, ie.:
0 */1 * * * root /usr/sbin/tmpwatch -am 1 /tmp/nginx_client
Bookmarks