pmodels / mpich

Official MPICH Repository
http://www.mpich.org
Other
538 stars 280 forks source link

Hydra does not handle spaces in path names correctly #1160

Closed mpichbot closed 7 years ago

mpichbot commented 7 years ago

Originally by ddifilippo@lumerical.com on 2011-01-08 13:05:26 -0600


I am deploying mpich2-1.3.1 on the Mac. I am coming up against a problem that may require modifying the mpich source to resolve: if there are spaces in the path to hydra_pmi_proxy and -host is not the default, the constructed launch arguments to ssh are not correctly handling spaces. Spaces in the path are correctly handled if the default host is used.

Excerpted command lines below. The machine name is microburst and its address on our network is 192.168.0.174.

-* Success with localhost **

microburst:MacOS ddifilippo$ pwd
/Applications/Lumerical/FDTD Solutions/FDTD Solutions.app/Contents/MacOS
microburst:MacOS ddifilippo$ ./mpiexec -host localhost ./cpi ...
[mpiexec@microburst] Launch arguments: /Applications/Lumerical/FDTD
Solutions/FDTD Solutions.app/Contents/MacOS/./hydra_pmi_proxy --control-port
microburst:49465 --debug --demux poll --pgid 0 --enable-stdin 1 --proxy-id 0
...
Process 0 on microburst
pi is approximately 3.1416009869231254, Error is 0.0000083333333323 wall
clock time = 0.000060

-* Not success... with -host 192.168.0.174, alias to localhost **

microburst:MacOS ddifilippo$ ./mpiexec -host 192.168.0.174 ./cpi ...
[mpiexec@microburst] Launch arguments: /usr/bin/ssh -x 192.168.0.174
/Applications/Lumerical/FDTD Solutions/FDTD
Solutions.app/Contents/MacOS/./hydra_pmi_proxy --control-port
microburst:49367 --debug --demux poll --pgid 0 --enable-stdin 1 --proxy-id 0
...

bash: /Applications/Lumerical/FDTD: No such file or directory

If I replace both instances of "FDTD Solutions" with "FDTD_Solutions" the second call using -host 192.168.0.174 succeeds. If anyone has a suggestion or patch that would allow me to keep spaces in our path, it would be warmly received.

mpichbot commented 7 years ago

Originally by ddifiilippo@lumerical.com on 2011-01-10 16:37:38 -0600


Attachment added: mpich2_1160.diff (0.6 KiB) Adding double quotes in building path to hydra_pmi_proxy

mpichbot commented 7 years ago

Originally by ddifilippo@lumerical.com on 2011-01-10 16:44:45 -0600


I have found a patch that works for me. It allows me to keep spaces in the path to hydra_pmi_proxy by wrapping HYD_handle.base_path and hydra_pmi_proxy with double quotes. I attached the patch file to this ticket.

mpichbot commented 7 years ago

Originally by balaji on 2011-01-11 07:42:39 -0600


No, this patch doesn't work when the local node is one of the nodes on which the MPI processes is launched.

mpichbot commented 7 years ago

Originally by ddifilippo@lumerical.com on 2011-01-11 12:30:11 -0600


Yes, I discovered that myself last night and was about to comment & hopefully remove the patch. Apologies for the noise, it was hubris to think I could step in and play with mpich fire.

mpichbot commented 7 years ago

Originally by balaji on 2011-01-12 06:22:51 -0600


Fixed in c4a553b1f41f41538a157ddf64976caaef41cb70 and [7697](1.3.x branch). Resolving.