[Pw_forum] Corrupting "input_tmp.in" when starting jobs at once

Paolo Giannozzi giannozz at democritos.it
Mon Feb 6 13:47:46 CET 2012


On Feb 6, 2012, at 13:26 , Layla Martin-Samos wrote:

> Dear Silvia, we moved to this intermediate input_tmp.in for  
> preparing pw
> to the automatic detection of xml input format. There is no simple way
> to overcome this step.

there are a few possibilities to prevent overwriting by other processes:
- add a unique identifier, e.g. the process ID, to the file name;
- add a random number to the file name;
- rename the file to input_tmp_N.in, with N= smallest number such that
   no input_tmp_N.in is detected;
but none  is trivial to implement in a portable and safe way.

I don't think however that the input file is copied to input_tmp.in,  
when
it is read using the -in option (as opposed to " < file"). So everything
should work if the -in (or -inp, or -input) option is used.

Paolo
---
Paolo Giannozzi, Dept of Chemistry&Physics&Environment,
Univ. Udine, via delle Scienze 208, 33100 Udine, Italy
Phone +39-0432-558216, fax +39-0432-558222






More information about the Pw_forum mailing list