From owner-freebsd-questions@FreeBSD.ORG Fri Sep 12 11:26:30 2003 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 42E2B16A4BF for ; Fri, 12 Sep 2003 11:26:30 -0700 (PDT) Received: from sccrmhc13.comcast.net (sccrmhc13.comcast.net [204.127.202.64]) by mx1.FreeBSD.org (Postfix) with ESMTP id 52B7043FDF for ; Fri, 12 Sep 2003 11:26:29 -0700 (PDT) (envelope-from gsam@trini0.org) Received: from hivemind.trini0.org (trini0.org[68.39.114.118]) by comcast.net (sccrmhc13) with ESMTP id <2003091218262801600rjk00e>; Fri, 12 Sep 2003 18:26:28 +0000 Received: from trini0.org (gladiator.trini0.org [192.168.0.3]) by hivemind.trini0.org (Postfix) with ESMTP id 233CE1C4 for ; Fri, 12 Sep 2003 14:26:28 -0400 (EDT) Message-ID: <3F620FD4.1090207@trini0.org> Date: Fri, 12 Sep 2003 14:26:28 -0400 From: Gerard Samuel User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.4) Gecko/20030701 X-Accept-Language: en, nl, ar, th, en-us MIME-Version: 1.0 To: FreeBSD Questions Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Script doesn't complete via Cron X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 12 Sep 2003 18:26:30 -0000 Script -> -------- #!/bin/sh # # To roll up a zip file of source code # date=`date '+%Y-%m-%d'` cd ~/temp rm -rf foo_dev foo.zip export CVS_RSH=ssh export CVSROOT=:ext:xxx@xxx.xxx.xxx:/xxx/yyy/zzz cvs -Q export -D $date -d foo_dev foo zip -q -r foo foo_dev scp -q foo.zip server_name: rm -rf foo_dev foo.zip ------ Cron job -> ------ # export, zip up and scp foo source to server_name 17 14 * * * /home/bar/bin/export-foo 2> /dev/null > /dev/null ------ When I execute the script by hand, it completes without any problems. When I let a cronjob handle it, it doesn't scp the zip file to the remote server. I don't get any errors in /var/log/auth.log or /var/log/messages Anyone has any ideas on how to fix this up? Thanks