[mpich-devel] mpirun fails if there is a void environment variable

Balaji, Pavan balaji at anl.gov
Thu Feb 18 11:05:52 CST 2016


Does your environment not have anything in it?  What's the output of "env"?

  -- Pavan

> On Feb 18, 2016, at 9:08 AM, Дмитрий <dmitrodem at gmail.com> wrote:
> 
> Hello,
> 
> i've found that on my system mpirun /bin/hostname causes segmentation
> fault. Inspecting it in gdb, i've seen the following stack trace:
> 
> (gdb) run /bin/hostname
> Starting program: /usr/bin/mpirun /bin/hostname
> [Thread debugging using libthread_db enabled]
> Using host libthread_db library "/lib64/libthread_db.so.1".
> 
> Program received signal SIGSEGV, Segmentation fault.
> 0x00007ffff69c484a in ?? () from /lib64/libc.so.6
> (gdb) bt
> #0  0x00007ffff69c484a in ?? () from /lib64/libc.so.6
> #1  0x0000000000430455 in HYDTI_bscd_in_env_list (env_name=0x0,
> env_list=env_list at entry=0x7fffffffd890) at
> tools/bootstrap/external/external_common.c:27
> #2  0x0000000000425ae4 in HYDT_bscd_ssh_query_env_inherit
> (env_name=<optimized out>, ret=0x7fffffffd8e4) at
> tools/bootstrap/external/ssh_env.c:17
> #3  0x000000000042557c in HYDT_bsci_query_env_inherit
> (env_name=<optimized out>, ret=ret at entry=0x7fffffffd8e4) at
> tools/bootstrap/src/bsci_env.c:18
> #4  0x00000000004208d3 in HYDU_list_inherited_env
> (env_list=env_list at entry=0x66c680 <HYD_server_info+128>) at
> utils/env/env.c:55
> #5  0x000000000040404c in main (argc=<optimized out>, argv=<optimized
> out>) at ui/mpich/mpiexec.c:258
> 
> The problem seems to be in strcmp call, which compares NULL (empty
> named environment variable) with something. env command shows string
> "=" for me.
> 
> So, I guess it would be nice to check env_name variable before passing
> it to strcmp?
> 
> -- 
> Regards,
>    Dmitriy
> _______________________________________________
> To manage subscription options or unsubscribe:
> https://lists.mpich.org/mailman/listinfo/devel



More information about the devel mailing list