Thanks Jeff.

“:nojobid” worked well for me and helps me remove 1 extra level of hierarchy 
for log files.

Regards
Vipul


From: Jeff Squyres (jsquyres) [mailto:jsquy...@cisco.com]
Sent: Thursday, October 31, 2019 6:21 PM
To: Kulshrestha, Vipul <vipul_kulshres...@mentor.com>
Cc: Open MPI User's List <users@lists.open-mpi.org>
Subject: Re: [OMPI users] mpirun --output-filename behavior

On Oct 30, 2019, at 2:16 PM, Kulshrestha, Vipul 
<vipul_kulshres...@mentor.com<mailto:vipul_kulshres...@mentor.com>> wrote:

Given that this is an intended behavior, I have a couple of follow up questions:

1.       What is the purpose of the directory “1” that gets created currently? 
(in <log directory>/app.log/1/rank.<i>/stdout ) Is this hard-coded to “1” or 
could be something else?

The "1" is actually the internal Open MPI (PMIx) job ID.  In most cases it will 
be 1, but it can be larger numbers, too.

FWIW: It looks like when this feature was added, you can add an optional 
":nojobid" to the filename to suppress this level of directories.  For example:

    mpirun --output-file foo:nojobid ...

Will result in:

    foo/rank.0/...
    foo/rank.1/...

As opposed to:

    foo/1/rank.0/...
    foo/1/rank.1/...

This ":nojobid" suffix needs to go in the documentation for this option, too...

2.       Mpirun also has an option “—merge-stderr-to-stdout”, that allows us to 
merge the stderr into stdout, so we are left with only 1 file (‘stdout’). Are 
there any future change that we need to worry about in using this option to 
merge the 2 streams?

There is nothing planned at the present.

FWIW, it doesn't look like this area of the code has changed substantially 
since 2016.  It's not an area of active development.

--
Jeff Squyres
jsquy...@cisco.com<mailto:jsquy...@cisco.com>

Reply via email to