<div dir="ltr">Hi Phil, <div><br></div><div>Here's how OpenMPI 3.1.5 was configured/built:</div><div><br></div><div>'--enable-mpi-cxx' '--enable-static' '--enable-shared' '--with-verbs' '--with-libltdl' '--with-slurm' '--enable-orterun-prefix-by-default' '--enable-mpirun-prefix-by-default' '--enable-openib-rdmacm-ibaddr' '--with-pmi=/usr' '--without-cuda' '--with-knem=/opt/knem-1.1.3.90mlnx1' '--with-lustre=/usr' '--with-io-romio-flags=--with-file-system=ufs+nfs+lustre CFLAGS=-I/usr/include/lustre CPPFLAGS=-I/usr/include/lustre' '--with-ucx=/usr' '--with-ucx-libdir=/usr/lib64' '--without-mxm<br></div><div><br></div><div><br></div><div>I repeated the experiment, using OMPIO from OpenMPI (export OMPI_MCA_io=ompio), instead of ROMIO. With this scenario I'm unable to write the darshan log file on lustre, with or without the configuration of "export DARSHAN_LOGHINTS=", with the error being slightly different: </div><div><br></div><div>---------------------</div><div>Program received signal SIGSEGV: Segmentation fault - invalid memory reference.<br><br>Backtrace for this error:<br>error opening file /PATH/TO/FILE.darshan_partial<br>....<br>#0  0x7f204bc7f27f in ???<br>#1  0x7f204d89f4fd in darshan_core_lookup_record_name<br>        at lib/darshan-core.c:2125<br>#2  0x7f204d8bb844 in darshan_stdio_lookup_record_name<br>        at lib/darshan-stdio.c:1456<br>#3  0x7f204d8a6f87 in fileno<br>        at lib/darshan-posix.c:590<br>#4  0x7f204a22a504 in ???<br>#5  0x7f204a22b920 in ???<br>#6  0x7f204ce79817 in ???<br>#7  0x7f204ce1bf1a in ???<br>#8  0x7f204cec1361 in ???<br>#9  0x7f204ce7b5c8 in ???<br>#10  0x7f204cdc7feb in ???<br>#11  0x7f204cdf5903 in ???<br>#12  0x7f204d8aef9b in MPI_File_open<br>        at lib/darshan-mpiio.c:316<br>#13  0x7f204d8a0b98 in darshan_log_open_all<br>        at lib/darshan-core.c:1574<br>#14  0x7f204d8a0b98 in darshan_core_shutdown<br>        at lib/darshan-core.c:477<br>#15  0x7f204d89e402 in MPI_Finalize<br>        at lib/darshan-core-init-finalize.c:82<br>#16  0x7f204d24a798 in ???<br>#17  0x4023bb in ???<br>#18  0x401ae6 in ???<br>#19  0x7f204bc6b3d4 in ???<br>#20  0x401b16 in ???<br>#21  0xffffffffffffffff in ???<br>--------------------------------------------------------------------------<br></div><div><br></div><div><br></div><div>We also have at our disposal the OpenMPI 2.4 (which came as the default MPI on the system) and I'm still unable to write the log file on Lustre filesystem, even with  "export DARSHAN_LOGHINTS=".</div><div><br></div><div><br></div><div>I would also like to point out that with an older version of the Lustre Client (2.4.3),  both OMPIO and ROMIO worked out fine, with no problems to write the darshan log file.</div><div><br></div><div><br></div><div>Once again, thank you very much the help and attention. I'll try to do some digging on this issue about the hints and the lustre filesystem. I'll give the feedback as soon as I find out anything. </div><div><br></div><div>Best regards.</div><div><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Apr 2, 2020 at 5:58 PM Carns, Philip H. <<a href="mailto:carns@mcs.anl.gov">carns@mcs.anl.gov</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">




<div dir="ltr">
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0);background-color:rgb(255,255,255)">
It's my day for lucky guesses <span id="gmail-m_4161513575882770260🙂">🙂  Thank you for testing that.</span></div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0);background-color:rgb(255,255,255)">
<span><br>
</span></div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0);background-color:rgb(255,255,255)">
<span>Those MPI hints (obviously) shouldn't make the MPI library crash.  Do you have a record of how OpenMPI 3.1.5 was built?  If there is some permutation of build options / mpi versions / lustre versions causing a problem then we might have to detect that
 somehow in Darshan's build configuration.</span></div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0);background-color:rgb(255,255,255)">
<span><br>
</span></div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0);background-color:rgb(255,255,255)">
<span>If you are willing to spend some time on it you should be able to isolate whether it's romio_no_indep_rw=true or cb_nodes=4 (or both) triggering the problem.  That's probably a bug that should be opened somewhere; any user app could set those hints, not
 just Darshan.</span></div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0);background-color:rgb(255,255,255)">
<span><br>
</span></div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0);background-color:rgb(255,255,255)">
<span>That combination of hints is a performance optimization from Darshan's perspective.  In particular, it makes it such that regardless of how large your application is, no more than 4 of it's processes will actually open the Darshan log file and aggregate
 data for the other ranks.  This keeps overhead down at scale.  If there are many ranks and only a little bit of Darshan data to write (a typical scenario) then the cost of having all ranks call open() and close() will be far higher than the cost of relaying
 through a small number of aggregators. </span></div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0);background-color:rgb(255,255,255)">
<span><br>
</span></div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0);background-color:rgb(255,255,255)">
<span>thanks,</span></div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0);background-color:rgb(255,255,255)">
<span>-Phil</span></div>
<div id="gmail-m_4161513575882770260appendonsend"></div>
<hr style="display:inline-block;width:98%">
<div id="gmail-m_4161513575882770260divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> André R. Carneiro <<a href="mailto:andre.es@gmail.com" target="_blank">andre.es@gmail.com</a>><br>
<b>Sent:</b> Thursday, April 2, 2020 4:44 PM<br>
<b>To:</b> Carns, Philip H. <<a href="mailto:carns@mcs.anl.gov" target="_blank">carns@mcs.anl.gov</a>><br>
<b>Cc:</b> <a href="mailto:darshan-users@lists.mcs.anl.gov" target="_blank">darshan-users@lists.mcs.anl.gov</a> <<a href="mailto:darshan-users@lists.mcs.anl.gov" target="_blank">darshan-users@lists.mcs.anl.gov</a>><br>
<b>Subject:</b> Re: [Darshan-users] Darshan crashing compute node</font>
<div> </div>
</div>
<div>
<div dir="ltr">Hi Phil.
<div><br>
</div>
<div>First of all, thank you very much for the attention and the information.</div>
<div><br>
</div>
<div>The "export DARSHAN_LOGHINTS=" solved the problem! </div>
<div><br>
</div>
<div>Now the darshan log file is written without problem. </div>
<div><br>
</div>
<div>I would like to point out that before the "configuration" of DARSHAN_LOGHINTS, when I used the darshan-parser to extract some info from the log file, I got the following:<br>
</div>
<div><br>
</div>
<div># metadata: lib_ver = 3.1.8<br>
# metadata: h = romio_no_indep_rw=true;cb_nodes=4<br>
</div>
<div><br>
</div>
<div>With the configuration of "DARSHAN_LOGHINTS=" there's no info about metadata or the hints used.</div>
<div><br>
</div>
<div>Thank you very much for the valuable help!</div>
<div><br>
</div>
<div>Best regards.</div>
<div><br>
</div>
</div>
<br>
<div>
<div dir="ltr">On Thu, Apr 2, 2020 at 12:27 PM Carns, Philip H. <<a href="mailto:carns@mcs.anl.gov" target="_blank">carns@mcs.anl.gov</a>> wrote:<br>
</div>
<blockquote style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<div dir="ltr">
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0);background-color:rgb(255,255,255)">
Thanks for the bug reports André!  You are describing two different problems:</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0);background-color:rgb(255,255,255)">
<br>
</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0);background-color:rgb(255,255,255)">
1) incompatibility between the Darshan Lustre instrumentation and recent Lustre releases: we'll definitely look into this.  As you found in the mailing list archives there has been a known problem here, but this is a new permutation that it causes a node crash
 now.  That's disappointing, to say the least.  If anyone happens to have a pointer to how to stand up a Lustre 2.11 instance in docker or a VM they can share, that would be greatly appreciated and would help us track compatibility better.  The Lustre systems
 we have access to are not new enough. In the mean time you are correct to disable that component at build time.</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0);background-color:rgb(255,255,255)">
<br>
</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0);background-color:rgb(255,255,255)">
2) floating point or divide by zero when writing log to Lustre: This one is odd because at the point of the problem, Darshan is not instrumenting anything: it is simply an application writing data to Lustre.  We don't generally see problems here.  Darshan is
 doing a collective write here as the last step of aggregating instrumentation from all ranks into a single log file.  The only slightly unusual things that Darshan could be doing are a) setting MPI-IO hints or b) using particular datatypes to organize the
 writes.  Neither should be a problem, but it looks like they might have triggered a bug somewhere.</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0);background-color:rgb(255,255,255)">
<br>
</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0);background-color:rgb(255,255,255)">
If you don't mind trying another test case, could you repeat one of the experiments that crashes with a floating point or divide by zero bug down in MPI_File_write_at_all() with the following environment variable set?  (please keep disabling the Lustre module
 at build time, we have no other fix for that ready yet) </div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0);background-color:rgb(255,255,255)">
<br>
</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0);background-color:rgb(255,255,255)">
export DARSHAN_LOGHINTS=</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0);background-color:rgb(255,255,255)">
<br>
</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0);background-color:rgb(255,255,255)">
(in other words, set the DARSHAN_LOGHINTS environment variable to an empty string)</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0);background-color:rgb(255,255,255)">
<br>
</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0);background-color:rgb(255,255,255)">
I believe that this will clear the MPI-IO hints that Darshan would normally specify when opening the output log file.  If that makes your example work cleanly, then we can narrow down which hint is the problem and maybe get some help outside of Darshan for
 the root cause.  If it still fails, then we need to look elsewhere for the problem.</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0);background-color:rgb(255,255,255)">
<br>
</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0);background-color:rgb(255,255,255)">
thanks,</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0);background-color:rgb(255,255,255)">
-Phil</div>
<div id="gmail-m_4161513575882770260x_gmail-m_-3919595619548292505appendonsend"></div>
<hr style="display:inline-block;width:98%">
<div id="gmail-m_4161513575882770260x_gmail-m_-3919595619548292505divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" color="#000000" style="font-size:11pt"><b>From:</b> Darshan-users <<a href="mailto:darshan-users-bounces@lists.mcs.anl.gov" target="_blank">darshan-users-bounces@lists.mcs.anl.gov</a>>
 on behalf of André R. Carneiro <<a href="mailto:andre.es@gmail.com" target="_blank">andre.es@gmail.com</a>><br>
<b>Sent:</b> Wednesday, April 1, 2020 1:39 PM<br>
<b>To:</b> <a href="mailto:darshan-users@lists.mcs.anl.gov" target="_blank">darshan-users@lists.mcs.anl.gov</a> <<a href="mailto:darshan-users@lists.mcs.anl.gov" target="_blank">darshan-users@lists.mcs.anl.gov</a>><br>
<b>Subject:</b> [Darshan-users] Darshan crashing compute node</font>
<div> </div>
</div>
<div>
<div dir="ltr">
<div>Hi,</div>
<div><br>
</div>
<div>I'm traying to use darshan (tested all 3.1.X versions) on a HPC cluster running with Red Hat 7.6 (kernel 3.10.0-957.el7.x86_64) and using Lustre Filesystem version 2.11.0.300_cray_102_g3dbace1, but when the application starts, the compute node crashes
 with a kernel panic message on the console. </div>
<div><br>
</div>
<div>While searching on the Darshan mailing list I came across this message: <a href="https://lists.mcs.anl.gov/mailman/htdig/darshan-users/2019-October/000542.html" target="_blank">https://lists.mcs.anl.gov/mailman/htdig/darshan-users/2019-October/000542.html</a></div>
<div><br>
</div>
<div>I disabled the Lustre module and recompiled darshan. The crash isn't happening anymore, but now it's unable to write the darshan log file on the lustre filesystem, with the following error:</div>
<div><br>
</div>
<div>
<div>*Using OpenMPI 3.1.5 and GCC 7</div>
<div></div>
</div>
<div><br>
</div>
<div>Program received signal SIGFPE: Floating-point exception - erroneous arithmetic operation.<br>
Backtrace for this error:<br>
#0  0x7f4f6759f27f in ???<br>
#1  0x7f4f687ababe in ???<br>
#2  0x7f4f687add06 in ???<br>
#3  0x7f4f687db6c0 in ???<br>
#4  0x7f4f687dbddb in ???<br>
#5  0x7f4f6879d6f1 in ???<br>
#6  0x7f4f6871892b in ???<br>
#7  0x7f4f691d0ae1 in MPI_File_write_at_all<br>
at lib/darshan-mpiio.c:536<br>
#8  0x7f4f691bea7f in darshan_log_append_all<br>
at lib/darshan-core.c:1800<br>
#9  0x7f4f691c1907 in darshan_log_write_name_record_hash<br>
at lib/darshan-core.c:1761<br>
#10  0x7f4f691c1907 in darshan_core_shutdown<br>
at lib/darshan-core.c:546<br>
#11  0x7f4f691be402 in MPI_Finalize<br>
at lib/darshan-core-init-finalize.c:82<br>
#12  0x7f4f68b6a798 in ???<br>
#13  0x4023bb in ???<br>
#14  0x401ae6 in ???<br>
#15  0x7f4f6758b3d4 in ???<br>
#16  0x401b16 in ???<br>
#17  0xffffffffffffffff in ???<br>
--------------------------------------------------------------------------<br>
</div>
<div><br>
</div>
<div>*Using Intel PSXE 2018 with Intel MPI</div>
<div><br>
</div>
<div>forrtl: severe (71): integer divide by zero<br>
Image              PC                Routine            Line        Source            
<br>
exec.exe           000000000045282E  Unknown               Unknown  Unknown<br>
libpthread-2.17.s  00002B8B5A5FE5D0  Unknown               Unknown  Unknown<br>
libmpi_lustre.so.  00002B8B659D4FDF  ADIOI_LUSTRE_Get_     Unknown  Unknown<br>
libmpi_lustre.so.  00002B8B659CFFD9  ADIOI_LUSTRE_Writ     Unknown  Unknown<br>
libmpi.so.12.0     00002B8B59A4C15C  Unknown               Unknown  Unknown<br>
libmpi.so.12       00002B8B59A4D1D5  PMPI_File_write_a     Unknown  Unknown<br>
libdarshan.so      00002B8B58F90312  MPI_File_write_at     Unknown  Unknown<br>
libdarshan.so      00002B8B58F7E63A  Unknown               Unknown  Unknown<br>
libdarshan.so      00002B8B58F815B0  darshan_core_shut     Unknown  Unknown<br>
libdarshan.so      00002B8B58F7DFF3  MPI_Finalize          Unknown  Unknown<br>
libmpifort.so.12.  00002B8B592414DA  pmpi_finalize__       Unknown  Unknown<br>
exec.exe           00000000004490A5  Unknown               Unknown  Unknown<br>
exec.exe           00000000004032DE  Unknown               Unknown  Unknown<br>
<a href="http://libc-2.17.so" target="_blank">libc-2.17.so</a>       00002B8B5AB2F3D5  __libc_start_main     Unknown  Unknown<br>
exec.exe           00000000004031E9  Unknown               Unknown  Unknown<br>
</div>
<div><br>
</div>
<div><br>
</div>
<div>If I configure darshan to write on a different filesystem (local /tmp of the first compute node), it works out fine, but then I'm restricted to use only one compute node, since the output dir have to be shared among all nodes (MPI tasks). <br>
</div>
<div><br>
</div>
<div>Is there a workaround for this? At the moment, my cluster only have the lustre filesystem as a shared filesystem among all compute nodes.</div>
<div><br>
</div>
Best regards.<br clear="all">
<div><br>
</div>
-- <br>
<div dir="ltr">Abraços³, <br>
André Ramos Carneiro.</div>
</div>
</div>
</div>
</blockquote>
</div>
<br clear="all">
<div><br>
</div>
-- <br>
<div dir="ltr">Abraços³, <br>
André Ramos Carneiro.</div>
</div>
</div>

</blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr" class="gmail_signature">Abraços³, <br>André Ramos Carneiro.</div>