Mohamed Haidar wrote:
Hello guys, I have a problem with cron. I got a program for updating my ip to a internet dns host and i set it up correctly. The program works. Now with the program came a file that i putt in the /etc/cron.d dir because the program instructed me to do that. Basically what I want to do is to let the program run once a minute. The file I putt in the cron.d dir contains these entries :
* * * * * root /usr/bin/ipdetect.sh */15 * * * * root /usr/bin/ipdetect.sh -p host -r browser -c
Now cron doesn't run the ipdetect script, never. I did some investigation and I found out that cron doesn't have any log files or conf files on my system, which I thought was a bit strange.
cron logs via syslog; there should be log records about the start of each job in /var/log/messages. The exception is when your crontab line starts with "-" (a hyphen), then job start logging is turned off. (In fact, when your ipdetect cron job really works, you might want to turn off job start logging that way.) If there are no respective log entries, execute "touch /etc/cron.d" to be on the save side. cron detects changes in files in cron.d only if the timestamp of the directory /etc/cron.d changes as well. Alternatively, call "rccron restart". After touching cron.d, there must be log entry that cron re-read the crontab files, maybe one or two minutes later. Your crontab syntax itself is OK, that's not the cause. Joachim -- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- Joachim Schrod Email: jschrod@acm.org Roedermark, Germany -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Joachim Schrod wrote:
Mohamed Haidar wrote:
cron logs via syslog; there should be log records about the start of each job in /var/log/messages. The exception is when your crontab line starts with "-" (a hyphen), then job start logging is turned off. (In
Oddly this is not happening on my system, the hyphen is there but job start logging is still being performed. The run-crons script explicitly sends information to the syslog daemon overriding the above setting, but successful job reporting is controlled by the $SYSLOG_ON_NO_ERROR variable. However, I have never explicitly set this myself. It looks as if the majority of the standard SuSE scripts explicitly log their status.
-----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.5 (GNU/Linux) Comment: Using GnuPG with SUSE - http://enigmail.mozdev.org iD8DBQFGQYx9asN0sSnLmgIRAqBMAKDeUtYNXlaSiGfgLWb+++KyLW8CUgCeMPNP n/YVTz1BMIxdE2FS8kypgDo= =BoSO -----END PGP SIGNATURE----- -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org
participants (2)
-
G T Smith
-
Joachim Schrod