[Swift-user] Is there a way to set env variables in swift
Michael Wilde
wilde at mcs.anl.gov
Tue Aug 30 16:22:26 CDT 2011
Lorenzo,
You can set env vars for an application in the tc.data file. Use the "env namespace profile" as described at:
http://www.ci.uchicago.edu/swift/guides/trunk/userguide/userguide.html#_env_namespace
Like this:
beagle myapp /home/joe/bin/myapp INSTALLED INTEL32::LINUX ENV::TMP="/lustre/beagle/joe/tmp"
If you need "joe" substituted into the "TMP" env var in the tc file dynamically (as with your example below), you need to do that with your own wrapper script on the client host (before you run the swift command).
Alternatively, if you are running locally on Beagle, there may also be an option you can specify in your sites file that will get passed down to the PBS qsub command, to pass the environment vars of the submitting job down to the submitted job, in which case you dont need the ENV::TMP profile in your tc.data file. David or Justin may be able to clarify whats possible there. (And this should go into the new 0.93 Site Configuration Guide).
- Mike
----- Original Message -----
> From: "Lorenzo Pesce" <lpesce at uchicago.edu>
> To: swift-user at ci.uchicago.edu
> Sent: Tuesday, August 30, 2011 2:59:57 PM
> Subject: [Swift-user] Is there a way to set env variables in swift
> Specifically something like
>
> export TMP=/lustre/beagle/`whoami`/tmp
>
> Thanks
>
> Lorenzo
> _______________________________________________
> Swift-user mailing list
> Swift-user at ci.uchicago.edu
> https://lists.ci.uchicago.edu/cgi-bin/mailman/listinfo/swift-user
--
Michael Wilde
Computation Institute, University of Chicago
Mathematics and Computer Science Division
Argonne National Laboratory
More information about the Swift-user
mailing list