in reply to (OT) Path Trouble

We use absolute paths in cron scripts. This is sort of for security and mostly to avoid environment issues like the one you seem to be hitting.

Phil

Replies are listed 'Best First'.
Re^2: (OT) Path Trouble
by tc1364 (Beadle) on Mar 02, 2006 at 18:57 UTC
    Yes and it is there. Please see below. # CSCANS Automation 45 12 * * 0-6 /ossd/tc1364/cscans/bin/start_cscans.pl
      I don't mean just in the cron entry. I also mean inside that script, whenever it refers to other scripts, the paths used are all absolute.

      Phil

        yes they are. Please see below. $bin = "/ossd/tc1364/cscans/bin"; $dms_start = "$bin/dms_start.exp"; $ess_start = "$bin/ess_start.exp"; $dms_pb = "/sys/extract/menu/west.pl";

        Part of my job is to babysit cron jobs and I totally agree. The secret to environmental harmony is to be independent of it to the extent possible.

        foo($path)
        needs to act on a
        /full/path
        .

        Since you're sure you're doing that I agree $ENV{LD_LIBRARY_PATH} is a place where you can still get hit by this.