[CentOS] cron.hourly runs twice

m.roth at 5-cent.us m.roth at 5-cent.us
Wed Mar 17 15:27:04 UTC 2010


Timothy wrote:
> Michael Schumacher wrote:
>
>>> I just wonder if anyone has come across this curiosity?
>>> Or can suggest any possible cause.
>>
>> Did you edit one of the jobs? Some Editors (joe) create a file with an
>> "~" at the end as a backup. If you edit one of your cronjob-scripts
>> in /etc/cron.hourly/ , you may create a second file that will be run
>> by cron too.
>> This happened here some time ago and it took some time to figure out
>> the reason.
>
> Thanks for the suggestion.
> I haven't edited any of the scripts in /etc/cron.hourly .
> Also, I checked and found that cron.hourly starts twice
> before any of the scripts starts.
> Each of the scripts then runs twice.

This finally hit: under no circumstances should you be editing your
crontab with vi in the directory. ALWAYS use crontab -e.

Another thing, and this constantly irritates me: ll, in CentOS, seems to
be ls -l,*not* ls -la, and so doesn't show .files; have you looked for
those?

          mark



More information about the CentOS mailing list