[TriLUG] Cron weirdness

Igor Partola igor at igorpartola.com
Thu Jun 19 10:05:50 EDT 2014


TriLUG,

I have a strange cron issue that I don't exactly know how to even
describe/Google. Here's what's happening:

 - I spin up CentOS 6.4 instances on EC2 and provision them all using the
same puppet manifests.
 - One of the puppet modules I wrote contains two files that get copied
(with the same owner and permissions) to /etc/cron.d/. The filenames are in
the form of `example` and `example-foo-bar`.

The problem I have is that only the file `example-foo-bar` is seen by cron
right away. The `example` file is not UNTIL I `touch /etc/cron.d/example`.
Then I see a message in the /var/log/cron that cron noticed it, and it
start executing normally. When the file is touched, the following shows up
in /var/log/cron:

Jun 18 01:37:01 ip-XX-XX-XX-XX crond[895]: (system) RELOAD
(/etc/cron.d/example)

I know that you cannot have the "." character in the names, etc. but this
name matches [a-z]+. I could have puppet `/usr/bin/touch` the file, but I
am trying to understand why this is happening.

Thanks in advance,
Igor


More information about the TriLUG mailing list