Cron Job Error!!!! A newbee Request
From: Ibrahim Shaik (ibrahim@mediasoft-inc.com)
Date: 03/11/03
- Previous message: Adam Luchjenbroers: "Re: Web bug"
- Next in thread: Brian Hatch: "Re: Cron Job Error!!!! A newbee Request"
- Reply: Brian Hatch: "Re: Cron Job Error!!!! A newbee Request"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
From: "Ibrahim Shaik" <ibrahim@mediasoft-inc.com> To: <security-discuss@linuxsecurity.com> Date: Mon, 10 Mar 2003 16:51:45 -0800
HI all,
I am new to linux administration. I am facing a strange problem.
I have a simple cron job which has the following script
SHELL=/bin/bash
PATH=/sbin:/bin:/usr/sbin:/usr/bin
MAILTO=root
HOME=/
13 * * * * sh /home/projectdata/Accuweather/Parsers/currentParser.sh {
which runs a Java Program to parse XML file } .
I editied this file from /var/spool/cron/root ..
When I manually run the command
sh /<path>/currentParser.sh , it executes perfectly . But the same command
doesn't work from the cron job. It fails to load the classes. It gives the
following exception
java.lang.NoClassDefFoundError: org/xml/sax/helpers/DefaultHandler
at java.lang.Class.forName(Class.java:native)
at java.lang.Class.forName(Class.java:52)
I made sure that the jar files are added to the classpath variable defined
in /root/.bash_profile ..
How do we define X-Cron-Env: <SHELL=/bin/bash> variable and how to make the
classpath available to X-Cron-Env ..
I appreciate your help to this newbee. I have been trying a lot to solve
this , but in vain .
Thanks
Ibrahim
--- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.459 / Virus Database: 258 - Release Date: 2/25/2003 ------------------------------------------------------------------------ To unsubscribe email security-discuss-request@linuxsecurity.com with "unsubscribe" in the subject of the message.
- Previous message: Adam Luchjenbroers: "Re: Web bug"
- Next in thread: Brian Hatch: "Re: Cron Job Error!!!! A newbee Request"
- Reply: Brian Hatch: "Re: Cron Job Error!!!! A newbee Request"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]