View previous topic :: View next topic |
Author |
Message |
maurs Tux's lil' helper
Joined: 16 Oct 2005 Posts: 85
|
Posted: Mon Mar 19, 2007 6:45 pm Post subject: Crontab e /var/log/message |
|
|
Volevo chiedere se c'è un modo per evitare che Vixie-Cron mi riempia il mio (già incasinato) /var/log/messages con queste rige!
Code: | Mar 19 19:00:01 maurs cron[8127]: (root) CMD (test -x /usr/sbin/run-crons && /usr/sbin/run-crons )
Mar 19 19:00:01 maurs cron[8128]: (root) CMD (rm -f /var/spool/cron/lastrun/cron.hourly)
Mar 19 19:10:01 maurs cron[8194]: (root) CMD (test -x /usr/sbin/run-crons && /usr/sbin/run-crons )
Mar 19 19:20:01 maurs cron[8315]: (root) CMD (test -x /usr/sbin/run-crons && /usr/sbin/run-crons ) |
Più precisamente, che cosa fa questa riga nel dettaglio (che si trova in /etc/crontab)?
Code: | test -x /usr/sbin/run-crons && /usr/sbin/run-crons |
_________________ MaUrS
[HOW-TO] Gentoo su PC datati (aka Portatile Felice)
Maurs' Blog
VDD Project |
|
Back to top |
|
|
Kernel78 Moderator
Joined: 24 Jun 2005 Posts: 3654
|
Posted: Mon Mar 19, 2007 7:21 pm Post subject: Re: Crontab e /var/log/message |
|
|
maurs wrote: | Più precisamente, che cosa fa questa riga nel dettaglio (che si trova in /etc/crontab)?
Code: | test -x /usr/sbin/run-crons && /usr/sbin/run-crons |
|
man test wrote: | -x file
Vero se file esiste ed e eseguibile.
|
_________________ Le tre grandi virtù di un programmatore: pigrizia, impazienza e arroganza. (Larry Wall).
Prima di postare un file togli i commenti con Code: | grep -vE '(^[[:space:]]*($|(#|!|;|//)))' |
|
|
Back to top |
|
|
maurs Tux's lil' helper
Joined: 16 Oct 2005 Posts: 85
|
|
Back to top |
|
|
lavish Bodhisattva
Joined: 13 Sep 2004 Posts: 4296
|
|
Back to top |
|
|
Kernel78 Moderator
Joined: 24 Jun 2005 Posts: 3654
|
Posted: Tue Mar 20, 2007 7:24 pm Post subject: |
|
|
maurs wrote: | Grazie per avermi risposto al quesito n. 2.
Ma tornando al quesito n.1...
per far in modo che contrab nn faccia il storage di quella riga in /var/log/messages ogni volta che l'esegue? |
Non posso che concordare con lavish, meglio che la riga sia presente, più che altro se non pasticci di frequente con cron puoi dilazionare il lancio di run-crons modificando la riga Code: | */10 * * * * root test -x /usr/sbin/run-crons && /usr/sbin/run-crons | tale riga fa si che ogni 10 minuti venga lanciato (se esiste ed è eseguibile) run-crons che si occupa di run-crons wrote: | # this script looks into /etc/cron.[hourly|daily|weekly|monthly]
# for scripts to be executed. The info about last run is stored in
# /var/spool/cron/lastrun
| se lo porti a ogni 30 minuti riduci a un terzo la verbosità ... _________________ Le tre grandi virtù di un programmatore: pigrizia, impazienza e arroganza. (Larry Wall).
Prima di postare un file togli i commenti con Code: | grep -vE '(^[[:space:]]*($|(#|!|;|//)))' |
|
|
Back to top |
|
|
maurs Tux's lil' helper
Joined: 16 Oct 2005 Posts: 85
|
|
Back to top |
|
|
|