Re: Expect prog. doesn't work in background !

2004-07-15 Thread Andrew Gaffney
Ravinder Arepally wrote: It works from command line. Problem is when we run it as a cron job. Yes, because you have a good PATH set at the command line. Not all cron daemons will set a sensible PATH environment variable. Use full paths to executables in your perl program. For example, use '/usr/

RE: Expect prog. doesn't work in background !

2004-07-15 Thread Ravinder Arepally
It works from command line. Problem is when we run it as a cron job. -Original Message- From: Andrew Gaffney [mailto:[EMAIL PROTECTED] Sent: Thursday, July 15, 2004 12:57 PM To: beginners Subject: Re: Expect prog. doesn't work in background ! Ravinder Arepally wrote: > All.

Re: Expect prog. doesn't work in background !

2004-07-15 Thread Andrew Gaffney
Ravinder Arepally wrote: All. I wrote this perl program using Expect.pm and this program also works fine in foreground but does NOT work in background (cron job). Any help is greatly appreciated. Try using full paths to external programs. Cron doesn't always set a usable PATH when it runs script

Expect prog. doesn't work in background !

2004-07-15 Thread Ravinder Arepally
All. I wrote this perl program using Expect.pm and this program also works fine in foreground but does NOT work in background (cron job). Any help is greatly appreciated. Thanks #!/usr/local/bin/perl -w use File::Basename; our $debug; use Expect; @ARGV == 1 or die "usage: $0 rem_host rem_u