From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: fa528,10ddfca7ae5a50be X-Google-Attributes: gidfa528,public X-Google-ArrivalTime: 2003-08-10 19:37:25 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!logbridge.uoregon.edu!snoopy.risq.qc.ca!chi1.webusenet.com!news.webusenet.com!cyclone1.gnilink.net!spamkiller2.gnilink.net!nwrdny01.gnilink.net.POSTED!53ab2750!not-for-mail From: Nico Kadel-Garcia User-Agent: Mozilla/5.0 (Windows; U; Win 9x 4.90; en-US; rv:1.5a) Gecko/20030718 X-Accept-Language: en-us, en MIME-Version: 1.0 Newsgroups: comp.unix.tru64 Subject: Re: cron job PATH problem? References: In-Reply-To: Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Message-ID: Date: Mon, 11 Aug 2003 02:37:23 GMT NNTP-Posting-Host: 151.203.22.73 X-Complaints-To: abuse@verizon.net X-Trace: nwrdny01.gnilink.net 1060569443 151.203.22.73 (Sun, 10 Aug 2003 22:37:23 EDT) NNTP-Posting-Date: Sun, 10 Aug 2003 22:37:23 EDT Xref: archiver1.google.com comp.unix.tru64:10625 Zhiliang Hu wrote: > On a True64 system (UNIX4.0), I have a perl program to query Ingress > database through DBI/DBD and it works fine on command line. However when I > use cron job to run the program it complains: > > install_driver(Ingres) failed: Can't load > '/usr/local/lib/perl5/site_perl/5.8.0/alpha- > dec_osf/auto/DBD/Ingres/Ingres.so' for > module DBD::Ingres: dlopen: cannot load > /usr/local/lib/perl5/site_perl/5.8.0/alpha- > dec_osf/auto/DBD/Ingres/Ingres.so at > /usr/local/lib/perl5/5.8.0/alpha-dec_osf/DynaLoader.pm line 229. > at (eval 1) line 3 > Compilation failed in require at (eval 1) line 3. > Perhaps a required shared library or dll isn't installed where expected > at /WWW/apache/share/cgi-bin/cgi-perl/array_list.pl line 27 > > > I tried to fix it by adding more to the PATH in this program but didn't > help at all. Wonder what could be the problem? First, I think you would want to set LD_LIBRARY_PATH, not PATH. Is this cron job running as root or as a user? In some OS's, root is not *allowed* to set a LD_LIBRARY_PATH, it gets ignored for security raasons. Can you preload the library path at compilation time for your Perl modules, instead of expecting it to be found by the cron job? Alternatively, can you symbolically link the appropriate libraries into /usr/lib/. so they get found at run time by default? Lastly, why in ghu's name are you still running the 4.0 release? There are a whole stack of patches and updates between 4.0 and 5.1b that yo umay find useful.