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

RE: Cron Problem



Have you tried running the script from an interactive shell?


Have you redirected stdout to stdin in your cron invocation? 

    root@p166d302:~# crontab -l
    0 2 * * *       /root/bin/cron-backup   2>&1


Does your script dump all it's messages into a log file and redirect stdout to
stdin when it calls other scripts?

    root@p166d302:~# cat bin/cron-backup
    #! /bin/sh

    LOG=/backup/rsync-out/cron-backup.log

    echo    ===== `date` ===== begin: '$Id: cron-backup,v 1.9 2004/12/08
 05:59:11 dpchrist Exp $' =====                     2>&1 | tee -a $LOG

    /root/bin/backup-cvs                            2>&1 | tee -a $LOG
    /root/bin/md5sums-rsync-out                     2>&1 | tee -a $LOG

    echo    ===== `date` ===== end: '$Id: cron-backup,v 1.9 2004/12/08 0
5:59:11 dpchrist Exp $' =====                       2>&1 | tee -a $LOG


David



Reply to: