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

crontab e redirect del comando in un file di log con data e ora



Ciao a tutti,
vorrei salvare l'output di un comando in un file con nome data / ora; ho provato così ma non funziona:

# m h  dom mon dow   command
00 12 	* * * /home/fabio/scripts/automated/sync_all.sh > /home/fabio/scripts/logs/`date +'%Y%m%d_%H%M%S'`-sync_all.log

mentre senza il comando date funziona
# m h  dom mon dow   command
00 12 	* * * /home/fabio/scripts/automated/sync_all.sh > /home/fabio/scripts/logs/test-sync_all.log

Dove sbaglio?

grazie,
f

--
--
<Fabio Mora> - Consulenza nel settore delle tecnologie informatiche
Via Buozzi, 5 - 28066 Galliate (NO) - P.IVA: 02227320039
Cel.: 340-1504097 - eMail: fabio.mm@gmail.com
-
Libera il pianeta! Usa Linux!
http://www.gallug.it - http://www.ubuntu-it.org/

Attachment: signature.asc
Description: OpenPGP digital signature


Reply to: