Problem with cron

Reindl Harald h.reindl at
Sat Mar 23 22:09:59 UTC 2013

Am 23.03.2013 23:00, schrieb Joe Zeff:
> On 03/23/2013 02:47 PM, Reindl Harald wrote:
>> why do you not simply place your cronjobs in/etc/cron.d/?
>> i maintain a lot of servers with tons of cronjobs running as
>> different users and never in my life called the contab-command
> Because crontab is specifically written for this, and I saw no reason not to use it

who cares - cronobs are one-liners
*/10 * * * * apache nice -n 19 ionice -c 3 bash /scripts/cleanup-uploadtemp.cron

also take a look at anacrontab
normally you have there a line for daily jobs

touch /etc/cron.daily/
chmod 700 /etc/cron.daily/

and in this file place a shebang and
su -c 'whatever' user

there are millions of ways for cronjobs and all of them
can be done by any ordinary text-editor

[root at srv-rhsoft:~]$ cat /etc/anacrontab
# /etc/anacrontab: configuration file for anacron
# See anacron(8) and anacrontab(5) for details.


# the maximal random delay added to the base delay of the jobs

# the jobs will be started during the following hours only

#period in days   delay in minutes   job-identifier   command
1                 5                  cron.daily       nice -n 19 run-parts /etc/cron.daily
7                 25                 cron.weekly      nice -n 19 run-parts /etc/cron.weekly
@monthly          45                 cron.monthly     nice -n 19 run-parts /etc/cron.monthly

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 263 bytes
Desc: OpenPGP digital signature
URL: <>

More information about the users mailing list