open-mpi / ompi

Open MPI main development repository
https://www.open-mpi.org
Other
2.17k stars 860 forks source link

Segfault with Openmpi-4.0.3 + ucx-1.8.1 when running IMB-MPI1 #8032

Open dsharma283 opened 4 years ago

dsharma283 commented 4 years ago

We are running IMB-MPI1 on Broadcom's 100G adaptor on a 2 nodes setup connected back to back and configured a basi QOS scheme between the two nodes. The hosts has been installed with OpenMPI-4.0.4 with UCX-1.8.1 and the OS in used is RHEL-8.2.

following is the command used: /usr/local/mpi/openmpi/bin/mpirun -np 36 --allow-run-as-root --hostfile hostfile --mca btl ^openib,vader,self,uct --bind-to none --map-by node --mca pml ucx -x UCX_NET_DEVICES=bnxt_re0:1 -x UCX_IB_GID_INDEX=3 /usr/local/imb/IMB-MPI1

the test fails with segfault:

#----------------------------------------------------------------
 Benchmarking Alltoall
 processes = 36
#----------------------------------------------------------------
       #bytes #repetitions  t_min[usec]  t_max[usec]  t_avg[usec]
            0         1000         0.04         0.08         0.04
            1         1000        17.36        18.54        17.90
            2         1000        17.65        19.76        18.66
            4         1000        19.26        20.62        19.86
            8         1000        17.99        22.27        20.04
           16         1000        18.73        23.00        20.79
           32         1000        20.21        24.65        22.38
           64         1000        20.65        23.51        22.04
          128         1000        23.85        27.06        25.48
          256         1000        32.18        38.44        35.62
          512         1000        36.79        42.38        40.00
         1024         1000        47.85        56.19        51.74
         2048         1000        65.51        72.60        68.51
         4096         1000       212.69       218.02       215.53
         8192         1000       346.13       355.91       350.93
        16384         1000       530.76       544.94       536.91
        32768         1000      1051.43      1073.43      1061.61
        65536          640      2176.55      2212.60      2195.62
       131072          320      4360.10      4430.24      4394.18
       262144          160     10081.54     10177.10     10147.08
[thor1:13825:0:13825] rc_verbs_ep.c:31   Assertion `ep->qp->state == IBV_QPS_RTS' failed: QP 0x4a061c62 state is 1241914470
/home/MPI/ucx/src/uct/ib/rc/verbs/rc_verbs_ep.c: [ uct_rc_verbs_ep_post_send() ]
      ...
       27     int ret;
       28
       29     ucs_assertv(ep->qp->state == IBV_QPS_RTS, "QP 0x%x state is %d",
==>    30                 ep->qp->qp_num, ep->qp->state);
       31
       32     if (!(send_flags & IBV_SEND_SIGNALED)) {
       33         send_flags |= uct_rc_iface_tx_moderation(&iface->super, &ep->super.txqp,

  backtrace (tid:  13825)
 0 0x0000000000057603 ucs_debug_print_backtrace()  /home/MPI/ucx/src/ucs/debug/debug.c:653
 1 0x0000000000026349 uct_rc_verbs_ep_post_send()  /home/MPI/ucx/src/uct/ib/rc/verbs/rc_verbs_ep.c:30
 2 0x0000000000026349 uct_rc_verbs_ep_am_short()  /home/MPI/ucx/src/uct/ib/rc/verbs/rc_verbs_ep.c:243
 3 0x000000000002c002 uct_ep_am_short()  /home/MPI/ucx/src/uct/api/uct.h:2424
 4 0x0000000000051234 ucp_request_try_send()  /home/MPI/ucx/src/ucp/core/ucp_request.inl:171
 5 0x0000000000051234 ucp_request_send()  /home/MPI/ucx/src/ucp/core/ucp_request.inl:206
 6 0x0000000000051234 ucp_tag_send_req()  /home/MPI/ucx/src/ucp/tag/tag_send.c:109
 7 0x0000000000051234 ucp_tag_send_nbr()  /home/MPI/ucx/src/ucp/tag/tag_send.c:258
 8 0x00000000001bfed2 mca_pml_ucx_send()  ???:0
 9 0x00000000000d824b ompi_coll_base_sendrecv_actual()  ???:0
10 0x00000000000db8d0 ompi_coll_base_alltoall_intra_pairwise()  ???:0
11 0x000000000008c6d2 MPI_Alltoall()  ???:0
12 0x000000000044962a IMB_alltoall()  ???:0
13 0x000000000042dea8 Bmark_descr::IMB_init_buffers_iter()  ???:0
14 0x00000000004405df OriginalBenchmark<BenchmarkSuite<(benchmark_suite_t)0>, &IMB_alltoall>::run()  ???:0
15 0x0000000000405ad4 main()  ???:0
16 0x00000000000236a3 __libc_start_main()  ???:0
17 0x000000000040448e _start()  ???:0

[thor1:13825] *** Process received signal ***
[thor1:13825] Signal: Aborted (6)
[thor1:13825] Signal code:  (-6)
[thor1:13825] [ 0] /lib64/libpthread.so.0(+0x12dd0)[0x7f3d0a08ddd0]
[thor1:13825] [ 1] /lib64/libc.so.6(gsignal+0x10f)[0x7f3d09cf070f]
[thor1:13825] [ 2] /lib64/libc.so.6(abort+0x127)[0x7f3d09cdab25]
[thor1:13825] [ 3] /usr/local/ucx/lib/libucs.so.0(+0x564e5)[0x7f3d08c494e5]
[thor1:13825] [ 4] /usr/local/ucx/lib/libucs.so.0(ucs_fatal_error_format+0xd6)[0x7f3d08c495c6]
[thor1:13825] [ 5] /usr/local/ucx/lib/ucx/libuct_ib.so.0(uct_rc_verbs_ep_am_short+0x269)[0x7f3d05c51349]
[thor1:13825] [ 6] /usr/local/ucx/lib/libucp.so.0(ucp_do_am_single+0xb2)[0x7f3d091e4002]
[thor1:13825] [ 7] /usr/local/ucx/lib/libucp.so.0(ucp_tag_send_nbr+0x4e4)[0x7f3d09209234]
[thor1:13825] [ 8] /usr/local/mpi/openmpi/lib/libmpi.so.40(mca_pml_ucx_send+0xb2)[0x7f3d0ad89ed2]
[thor1:13825] [ 9] /usr/local/mpi/openmpi/lib/libmpi.so.40(ompi_coll_base_sendrecv_actual+0x8b)[0x7f3d0aca224b]
[thor1:13825] [10] /usr/local/mpi/openmpi/lib/libmpi.so.40(ompi_coll_base_alltoall_intra_pairwise+0x130)[0x7f3d0aca58d0]
[thor1:13825] [11] /usr/local/mpi/openmpi/lib/libmpi.so.40(PMPI_Alltoall+0x162)[0x7f3d0ac566d2]
[thor1:13825] [12] /usr/local/imb/IMB-MPI1[0x44962a]
[thor1:13825] [13] /usr/local/imb/IMB-MPI1[0x42dea8]
[thor1:13825] [14] /usr/local/imb/IMB-MPI1[0x4405df]
[thor1:13825] [15] /usr/local/imb/IMB-MPI1[0x405ad4]
[thor1:13825] [16] /lib64/libc.so.6(__libc_start_main+0xf3)[0x7f3d09cdc6a3]
[thor1:13825] [17] /usr/local/imb/IMB-MPI1[0x40448e]
[thor1:13825] *** End of error message ***
Broadcast message from systemd-journald@thor1 (Wed 2020-08-19 22:33:38 PDT):

systemd[1]: Caught <ABRT>, dumped core as pid 17531.

Broadcast message from systemd-journald@thor1 (Wed 2020-08-19 22:33:38 PDT):

systemd[1]: Freezing execution.

Primary job  terminated normally, but 1 process returned
a non-zero exit code. Per user-direction, the job has been aborted.

Message from syslogd@thor1 at Aug 19 22:33:38 ...
 systemd[1]:Caught <ABRT>, dumped core as pid 17531.

Message from syslogd@thor1 at Aug 19 22:33:38 ...
 systemd[1]:Freezing execution

mpirun noticed that process rank 26 with PID 0 on node thor1 exited on signal 6 (Aborted).

CPU info: lscpu Architecture: x86_64 CPU op-mode(s): 32-bit, 64-bit Byte Order: Little Endian CPU(s): 36 On-line CPU(s) list: 0-35 Thread(s) per core: 1 Core(s) per socket: 18 Socket(s): 2 NUMA node(s): 2 Vendor ID: GenuineIntel CPU family: 6 Model: 85 Model name: Intel(R) Xeon(R) Gold 6254 CPU @ 3.10GHz Stepping: 7 CPU MHz: 1201.014 BogoMIPS: 6200.00 Virtualization: VT-x L1d cache: 32K L1i cache: 32K L2 cache: 1024K L3 cache: 25344K NUMA node0 CPU(s): 0,2,4,6,8,10,12,14,16,18,20,22,24,26,28,30,32,34 NUMA node1 CPU(s): 1,3,5,7,9,11,13,15,17,19,21,23,25,27,29,31,33,35 Flags: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx pdpe1gb rdtscp lm constant_tsc art arch_perfmon pebs bts rep_good nopl xtopology nonstop_tsc cpuid aperfmperf pni pclmulqdq dtes64 monitor ds_cpl vmx smx est tm2 ssse3 sdbg fma cx16 xtpr pdcm pcid dca sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave avx f16c rdrand lahf_lm abm 3dnowprefetch cpuid_fault epb cat_l3 cdp_l3 invpcid_single intel_ppin ssbd mba ibrs ibpb stibp ibrs_enhanced tpr_shadow vnmi flexpriority ept vpid fsgsbase tsc_adjust bmi1 hle avx2 smep bmi2 erms invpcid rtm cqm mpx rdt_a avx512f avx512dq rdseed adx smap clflushopt clwb intel_pt avx512cd avx512bw avx512vl xsaveopt xsavec xgetbv1 xsaves cqm_llc cqm_occup_llc cqm_mbm_total cqm_mbm_local dtherm ida arat pln pts pku ospke avx512_vnni md_clear flush_l1d arch_capabilities

jsquyres commented 4 years ago

I see that there's an assertion failure, assumedly in UCX itself:

Assertion `ep->qp->state == IBV_QPS_RTS' failed: QP 0x4a061c62 state is 1241914470

Do you know what state your QP is in when this happens? I think it's kinda poor form to throw an assertion failure at this point (because that drops a corefile -- that's not scalable!), but I think the underlying issue is probably correct: the QP somehow went into a bad state.

You should probably check what state it went into, and why.