I am new to Linux. I put a file in cron.daily to test, but it never got execute, access mod is 755 for the test file.

crontab file has the default entry of: -*/15 * * * * root test -x /usr/lib/cron/run-crons && /usr/lib/cron/run-crons >/dev/null 2>&1

cron daemon is there. I can start a "at" job.

What do I miss ?

  • This file that you've placed is a bash script? And what does the logs say? Jun 8, 2011 at 17:05
  • What does the actual cron script look like?
    – slashdot
    Jun 9, 2011 at 14:06

1 Answer 1


Your script has .sh suffix doesn't it? ;)

run-parts doesn't run anything with any suffix. Files with suffix are silently ignored.

This is a documented but utterly stupid "feature":

If neither the --lsbsysinit option nor the --regex option is given then the names must consist entirely of upper and lower case letters, dig‐ its, underscores, and hyphens.

  • Actually no. The file name is test-it and it has one line in there just say "touch /tmp/x "
    – Ed Kwan
    Jun 9, 2011 at 14:44
  • Try running run-crons manually and look in it's man page. See if it has a verbose flag or strace it.
    – jkj
    Jun 11, 2011 at 0:06

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.