LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 04-01-2010, 10:13 PM   #1
j-me
Member
 
Registered: Jan 2003
Location: des moines, ia
Distribution: suse RH
Posts: 123

Rep: Reputation: 16
Crontab path when execute a job


I have and entry in a crontab for my user (appadmin) that when it executes it does not start with the proper path. It needs to start as the appadmin user as appadmin owns all the directories for glassfish.

00 01 * * * appadmin /home/appadmin/scripts/restartProdSubDomainandNode.sh

However, once glassfish restarts, the hudson application cannot find the default JDK. I get an error.
If I initiate the restart via command line, all works as it should.

I believe it has something to do with PATH in the crontab but am not sure what I need to set the PATH to in crontab. Here is what I think ... you guy can weigh in on this ...

PATH=/usr/local/bin:/usr/bin:/usr/X11R6/bin:/bin:/usr/games:/opt/bin:/opt/gnome/bin:/opt/kde3/bin:/usr/sbin:/sbin:/opt/SUN/jdk1.6.0_04/bin
As always, appreciate your input ...
 
Old 04-01-2010, 10:33 PM   #2
troop
Member
 
Registered: Feb 2010
Distribution: gentoo, arch, fedora, freebsd
Posts: 379

Rep: Reputation: 96
http://www.linuxquestions.org/questi...d-cron-796412/
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
crontab job not executing.... mia_tech Linux - Newbie 6 08-31-2009 03:42 PM
the crontab job is not run ust Linux - Software 1 03-24-2008 08:03 PM
Run crontab job sunhui Linux - Software 2 05-16-2007 09:35 PM
crontab job Thulemanden Linux - Software 2 07-09-2006 07:57 AM
crontab job entry notolerance Linux - Software 2 02-20-2005 03:40 PM


All times are GMT -5. The time now is 01:00 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration