Fabian, I have tripped over this before myself.
I don't know why or how, but globus-job-run starts bash in such a way that it doesn't read its initialization files. You can force bash to load those with the -login flag (See man bash). $ globus-job-run cashmere /bin/bash -login -c '/usr/bin/printenv' Note that this is a good way to set up variables that have something specific to do with the machine. However, if you want to set an environment variable specific to your job, it would be better to specify it in a job description file. Consider using the more modern globusrun-ws for this. Cheers! On 23.05.08, Fabian Lueghausen wrote: > Hey Steve, > > thanks for this hint! You are right... But I will better try to specify > my question concerning globus-job-run: > > *Is there a way to use the (remote) environment variables set up in the > .bashrc profile file?* > > If I run > > globus-job-run ingrid /usr/bin/printenv > > or > > globus-job-run ingrid /bin/bash -c '/usr/bin/printenv' > > it doesn't work.. :-| > > Thanks! > Fabian > > > > Steve White schrieb: > > >Fabian, > > > >I think you are misinterpreting your example. > >The shell replaces "$VARIABLE" before globus-job-run is called. > > > >To find out the environment available for job executables, try this: > > > > $ globus-job-run machine_name /usr/bin/printenv > > > >You will find the default environment is very limited. There are > >provisions for setting the environment, either from the command line > >or in a job description file. > > > >Cheers! > > > > > >On 21.05.08, Fabian Lueghausen wrote: > > > > > >>Hey list ! > >> > >>I've got a question concerning the environment variables used when > >>executing the globus-job-run command. > >> > >>When submitting a job from my local machine "mertens" to a remote > >>machine "ingrid", the remote machine is always using my local > >>environment variables (wherefore...) > >> > >>For example: > >> > >> [EMAIL PROTECTED] ~]$ *globus-job-run ingrid /bin/echo $VARIABLE* > >> VARIABLE: Undefined variable. > >> [EMAIL PROTECTED] ~]$ setenv VARIABLE "hello world!" > >> [EMAIL PROTECTED] ~]$ globus-job-run ingrid /bin/echo $VARIABLE > >> hello world! > >> [EMAIL PROTECTED] ~]$ > >> > >>This becomes a problem while a want to start a programm whose runtime > >>environment variables should be defined on the remote machine because > >>they differ from the ones which should be used on my local machine... > >> > >>So my question: Is there any way to set some variables on the remote > >>machine? > >> > >>Great *thanks* for all your answers! > >>Fabian > >> > >> > > > >- - - - - - - - - - - - - - - - - - - - - - - - - > >Steve White +49(331)7499-202 > >e-Science / AstroGrid-D Zi. 35 Bg. 20 > >- - - - - - - - - - - - - - - - - - - - - - - - - > >Astrophysikalisches Institut Potsdam (AIP) > >An der Sternwarte 16, D-14482 Potsdam > > > >Vorstand: Prof. Dr. Matthias Steinmetz, Peter A. Stolz > > > >Stiftung privaten Rechts, Stiftungsverzeichnis Brandenburg: III/7-71-026 > >- - - - - - - - - - - - - - - - - - - - - - - - - > > > > > -- - - - - - - - - - - - - - - - - - - - - - - - - - Steve White +49(331)7499-202 e-Science / AstroGrid-D Zi. 35 Bg. 20 - - - - - - - - - - - - - - - - - - - - - - - - - Astrophysikalisches Institut Potsdam (AIP) An der Sternwarte 16, D-14482 Potsdam Vorstand: Prof. Dr. Matthias Steinmetz, Peter A. Stolz Stiftung privaten Rechts, Stiftungsverzeichnis Brandenburg: III/7-71-026 - - - - - - - - - - - - - - - - - - - - - - - - -
