Date: Fri, 15 Nov 2002 17:30:59 +0000 From: Matthew Seaman <m.seaman@infracaninophile.co.uk> To: freebsd-questions@FreeBSD.ORG Subject: Re: FTP and cron Message-ID: <20021115173059.GA48777@happy-idiot-talk.infracaninophi> In-Reply-To: <20021115103931.A82781@starfire.mn.org> References: <20021115103931.A82781@starfire.mn.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, Nov 15, 2002 at 10:39:31AM -0600, John wrote: > No, it's not something simple like cron not running expect, or ftp > being in "non-interactive mode". The prework all runs correctly, > I even set the hash byte count and get the feedback from that... > when the put command starts, though, things get different! I get > different progress messages, no hash marks, and apparently, no > data transferred. The file NAME appears on the remote side, but is > 0 length regardless of how long I wait. When I run the scripts > from the terminal, it works fine. When you're running from cron(8) you get a very limited environment. You won't get a tty assigned to you, and the $TERM environment variable won't be set. That makes it difficult for ftp(1) to do any of the screen control things you may be expecting. Stuff like $FTP_PASSIVE_MODE, which is often set out of /etc/login.conf, won't be configured either. Actually, on reflection the symptoms you describe sound like ftp(1) active mode breakage to me --- you tend to get that if you're running a firewall on the client end of the ftp connection. Try using pftp(1) or equivalently, supplying the '-p' flag on the ftp command line. Cheers, Matthew -- Dr Matthew J Seaman MA, D.Phil. 26 The Paddocks Savill Way Marlow Tel: +44 1628 476614 Bucks., SL7 1TH UK To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20021115173059.GA48777>