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

Re: Cron and perl scripts



The esteemed Tomas Tikovsky so eloquently scribed:
> 
> hi
> 
> I wrote a perl script that work fine being run from the command line.
> When i have cron run the script it, it doesn't delete files that i wont.
> i tried to use unlink command and `rm`.
> Than i deleted aliases from all rc's in /root directory like "alias
> rm=rm -i"
> 
> What i'm  doing wrong?
> 
> Thanks Tom
> 
Tom,

The problem is that cron fires off a shell that doesn't source your environment,
like your PATH variable.  Use the full path name to executables, e.g., /bin/rm
and it should work like a champ.

Bruce

> 
> -- 
> To unsubscribe: mail redhat-list-request redhat com with "unsubscribe"
> as the Subject.
> 
> 



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