The output of crontab -l
and crontab
are different.
root@ce:~# crontab -l
0-59 * * * * curl http://ce.scu.ac.ir/courses/admin/cron.php?password=mypass
* * * * * ntpdate –s ir.pool.ntp.org
* * * * * php /var/www/html/shub/ow_cron/run.php
root@ce:~# cat /etc/crontab
SHELL=/bin/sh
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
# m h dom mon dow user command
*/01 * * * * www-data /var/www/html/shub/ow_cron/run.php
*/1 * * * * www-data /usr/bin/php7.0 /var/www/html/courses/admin/cli/cron.php > /var/log/moodle/cron.log
17 * * * * root cd / && run-parts --report /etc/cron.hourly
25 6 * * * root test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.daily )
47 6 * * 7 root test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.weekly )
52 6 1 * * root test -x /usr/sbin/anacron || ( cd / && run-parts --report /etc/cron.monthly )
#
I ask that because some documents say to use crontab -e
to define cron jobs. Should I use crontab -e
or vim /etc/crontab
?