[Wien] passing env variables to lapw1 and 2

Peter Blaha pblaha at theochem.tuwien.ac.at
Wed Nov 11 08:59:14 CET 2015


I'm not sure, why you would not set this permanently in .bashrc.

Anyway, if ssh does not allow it on your system, you could modify your 
lapw1/2para_lapw script and "source" a file in your directory which 
contains the desired settings.

The lines to modify are:

		  ($remote $machine[$p] "cd $PWD;$t $taskset0 $exe ${def}_$loop.def 
;fixerror_lapw ${def}_$loop";rm -f .lock_$lockfile[$p]) >& 
.stdout1_$loop; sortoutput 1_$loop &


where you could put some sourcing between cd $PWD;source ...;$t ...

(must be csh commands, not bash).

On 11/10/2015 03:25 PM, Pavel Ondracka wrote:
> Dear Wien2k mailing list,
>
> I'm having some troubles passing environmental variables (eg.
> OMP_NUM_THREADS or similar) to lapw1 and lapw2. This works in serial
> mode where the lapw* programs are called directly, however in parallel
> mode they are run through remote shell and all environmental info is
> lost.
> I can declare them in my .bashrc and then it works (since the .bashrc
> is reloaded when remote shell is spawned) however i would  like to
> specify them per task.
> One solution I had in mind was to go through AcceptEnv in sshd however
> this is considered insecure according to cluster admins an is disabled.
> Another option is to modify the wien scripts to include the required
> variables when calling the remote shell, however at the moment I'm
> wondering if there is more universal and elegant solution?
> Any ideas?
>
> Best regards
> Pavel Ondračka
> _______________________________________________
> Wien mailing list
> Wien at zeus.theochem.tuwien.ac.at
> http://zeus.theochem.tuwien.ac.at/mailman/listinfo/wien
> SEARCH the MAILING-LIST at:  http://www.mail-archive.com/wien@zeus.theochem.tuwien.ac.at/index.html
>

-- 

                                       P.Blaha
--------------------------------------------------------------------------
Peter BLAHA, Inst.f. Materials Chemistry, TU Vienna, A-1060 Vienna
Phone: +43-1-58801-165300             FAX: +43-1-58801-165982
Email: blaha at theochem.tuwien.ac.at    WIEN2k: http://www.wien2k.at
WWW:   http://www.imc.tuwien.ac.at/staff/tc_group_e.php
--------------------------------------------------------------------------


More information about the Wien mailing list