CRON got me a beauty this week
Why don’t I have a simpler hobby like gardening or matchbook collecting? Computers can drive me insane some days.
I have this script on my Debian server which is supposed to run every day but every morning when I check my logs, I find it has failed to run. The script works fine when I run it manually. I have put it in the /etc/cron.daily directory with the correct permissions, but CRON just ignores it – what is going on ?
I was determined to find the problem today. And I did. You see CRON uses another program called run-parts to handle the process of scanning the directory and running each file contained within. After reading up a little and doing some tests, I found that run-parts will ignore any file which has a dot in it’s name. Coming from a DOS/Windows background, naturally I had named my file adam-daily.sh because it is a shell script. Removing the “.sh” fixed the problem.
This is the price I pay for not sufficiently dedicating my life to the UNIX way.

Hey Adam,
As a Unix sysadmin, I can say that this is a Linux problem _not_ a UNIX problem ;-)
Hey Robert, thanks for the correction. I’ve done a little SCO and a little Solaris over the years but my UNIX experience has been mostly on Linux.