I definitely sure that the syntax I am using in the crontab file is correct because I installed the same job on another host and it is working fine. The syntax is:

05 10 * * mon,wed,fri /app/aban/scripts/remove_log.sh >> /app/aban/scripts/remove.log 2>&1

Also, I tried this one:

* * * * * /app/aban/scripts/remove_log.sh

the error is :

crontab: installing new crontabempty one
"/tmp/crontab.fuqF5D":0: bad minute
errors in crontab file, can't install.
Do you want to retry the same edit? n
crontab: edits left in /tmp/crontab.fuqF5D

Please note that I have logged in as 'aban' user. I can install cronjobs on other hosts with the same user logged in.

Any advice?

  • 6
    The particular cron daemon that you are using on the host may dislike the zero in 05. Try changing it to just 5. What cron daemon variant does your two hosts run? – Kusalananda Apr 4 '19 at 5:40
  • if I get your mean right, its crond.service deamon – MJ taleghani Apr 4 '19 at 7:56
  • Is that the only line in the crontab ? Could the error be referring to another line? – user103944 Apr 4 '19 at 12:13

Your Answer

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

Browse other questions tagged or ask your own question.