Rodney Green wrote: > My web server runs as the user 'apache.' (...)
> (...)the script successfully from the command line as root but when I run it in the browser the shell script executes but fails.
I've set the permissions of the script to be executable for anyone.
Shell side:
- must be readable and executable by user (apache or perhaps everyone)
- suid bit work only for programs, not scripts I think
- shell can only execute cmds for which it's effective user has sufficient permissions
Try this (as root on webserver), if you can login as apache. If you can't login as apache, log as a normal user (not root) # su - apache $ cd /path/to/script $ ./myscript.sh You will probably see errors here.
If not, it probably is a safemode restriction. See http://www.php.net/manual/en/features.safe-mode.php#ini.safe-mode and set the safe_mode_* variables in php.ini or in a .htaccess, in particular safe_mode_exec_dir ...
Hope it helps
-- Christophe Chisogne http://www.publicityweb.com
-- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php