[GE users] SGE in shell script problem

Craig Tierney ctierney at hypermall.net
Wed Dec 14 16:22:14 GMT 2005


    [ The following text is in the "ISO-8859-1" character set. ]
    [ Your display is set for the "ISO-8859-10" character set.  ]
    [ Some special characters may be displayed incorrectly. ]

Jon Savian wrote:

>Hi Every1
>
>I am trying to write a bash shell script (not an sge submit script)
>and am trying to get some output from "/path/to/bin/qstat -f" to
>parse.  When i run I run the script myself it has no problem getting
>output.  If I set it up to use cron it will not execute and gives the
>error "please define SGE_ROOT".  Exporting the variable or just
>defining it in the script again,ie. SGE_ROOT=/path/to/gridengine, do
>not work.
>
>Any suggestions?
>
>Jon (the funky homosapien)
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: users-unsubscribe at gridengine.sunsource.net
>For additional commands, e-mail: users-help at gridengine.sunsource.net
>
>
>  
>
When starting Bash from cron, the environment isn't loaded.  You should 
either
source the settings.sh file in the SGE_ROOT directory, or change the 
first line
of your script to be "#!/bin/bash --login".  Adding --login will make 
bash think
it is a login shell, and source the environment.

Craig

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe at gridengine.sunsource.net
For additional commands, e-mail: users-help at gridengine.sunsource.net




More information about the gridengine-users mailing list