View previous topic :: View next topic |
Author |
Message |
pubecon Guru
Joined: 03 Mar 2003 Posts: 342 Location: Glasgow, Scotland
|
Posted: Fri Mar 19, 2004 12:58 pm Post subject: "mt not found in $PATH" - via cron |
|
|
I have the flexbackup script running via cron as root
(and my mt exists as /usr/sbin/mt)
all is well when I run flexbackup from a terminal but all I get in my cron emails to root is
Code: | Errors:
mt not found in $PATH |
but it should be!!!
/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/opt/bin:/usr/i486-pc-linux-gnu/gcc-bin/3.3:/usr/X11R6/bin:
/opt/blackdown-jdk-1.4.1/bin:/opt/blackdown-jdk-1.4.1/jre/bin:/usr/qt/3/bin:/usr/kde/3.2/sbin:/usr/kde/3.2/bin:
/usr/qt/2/bin
any ideas?
Last edited by pubecon on Fri Mar 19, 2004 1:27 pm; edited 1 time in total |
|
Back to top |
|
|
Cocker68 Apprentice
Joined: 16 Jan 2003 Posts: 227 Location: Germany
|
Posted: Fri Mar 19, 2004 1:26 pm Post subject: |
|
|
In the cron environment the PATH variable is not set.
So in Your crontab specify all commands with their full paths.
This further implies, that scripts called by cron have also no idea about PATH. Either specify all commands in those scripts with full path name, or specify once at the beginning of the script a standard PATH.
- Cocker :wq
Last edited by Cocker68 on Tue Oct 05, 2004 4:40 pm; edited 1 time in total |
|
Back to top |
|
|
pubecon Guru
Joined: 03 Mar 2003 Posts: 342 Location: Glasgow, Scotland
|
Posted: Fri Mar 19, 2004 1:30 pm Post subject: |
|
|
excellent!
I find it mighty strange that there was no posts in the flexbackup mailing list nor a mention of this in the readme or faq...
many thanks |
|
Back to top |
|
|
|