[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: crontab -e et vi



Quoting pascal@linuxorable.net:

J'avais quelque peu oublié #!/bin/bash mais je l'ai oublié aussi sur mon PC sur lequel tout marche quand même très bien.

Sur mon PC dans syslog je trouve:

Aug 14 23:25:01 euphorie /USR/SBIN/CRON[16580]: (root) CMD (/usr/local/www/ez_publish/ezpublish.cron)

toutes les 5 minutes. Ce qui est normal.

Sur le serveur j'ai des choses comme ça:

Aug 14 22:17:01 sd-2570 /USR/SBIN/CRON[20424]: (root) CMD ( run-parts --report /etc/cron.hourly)
Aug 14 22:29:04 sd-2570 /usr/sbin/cron[2513]: (CRON) INFO (pidfile fd = 3)
Aug 14 22:29:04 sd-2570 /usr/sbin/cron[13051]: (CRON) STARTUP (fork ok)
Aug 14 22:29:04 sd-2570 /usr/sbin/cron[13051]: (CRON) INFO (Skipping @reboot jobs -- not system startup)
Aug 14 22:31:22 sd-2570 /usr/sbin/cron[20366]: (CRON) INFO (pidfile fd = 3)
Aug 14 22:31:22 sd-2570 /usr/sbin/cron[19973]: (CRON) STARTUP (fork ok)
Aug 14 22:31:22 sd-2570 /usr/sbin/cron[19973]: (CRON) INFO (Skipping @reboot jobs -- not system startup) Aug 14 22:39:01 sd-2570 /USR/SBIN/CRON[7769]: (root) CMD ( [ -d /var/lib/php4 ] && find /var/lib/php4/ -type f -cmin +$(/usr/lib/php4/maxlifetime) -print0 | xargs -r -0 rm) Aug 14 23:09:01 sd-2570 /USR/SBIN/CRON[31377]: (root) CMD ( [ -d /var/lib/php4 ] && find /var/lib/php4/ -type f -cmin +$(/usr/lib/php4/maxlifetime) -print0 | xargs -r -0 rm) Aug 14 23:17:01 sd-2570 /USR/SBIN/CRON[8895]: (root) CMD ( run-parts --report /etc/cron.hourly)

ce qui ne me parle guerre.

Pascal


Quoting rixed <rixed@happyleptic.org>:

j'ai mis

MAILTO=root@localhost

au tout début de la crontab mais pas de mail reçu.

Mais comment ça marche ce MAILTO ?
Parce que sur mon PC (debian sid avec cron qui marche) j'ai fait aussi le test et je ne reçois pas non plus de mail alors que le fichier est bien créé toutes les 5 minutes.

J'ai raté un truc ?

Pascal

-[ Mon, Aug 14, 2006 at 10:12:17PM +0200, pascal@linuxorable.net ]----
0,5,10,15,20,25,30,35,40,45,50,55 * * * *  /usr/local/www/ezpascal.cron

D'abord, tu peut écrire :

*/5 * * * * /usr/local/www/espascal.com

qui signifie aussi "toutes les 5 minutes".

Ensuite, regardes ce qui est écrit dans /var/log/syslog ?

grep CRON /var/log/syslog

en root.

Cela donnera peut etre une indication interressante.

Sinon, ajoutes au debut de ta crontab :

MAILTO=machin@truc

pour recevoir stdout par email.

Sinon, à priori, je ne vois pas.







----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.



----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.




Reply to: