robskillington / pdsh

Automatically exported from code.google.com/p/pdsh
GNU General Public License v2.0
0 stars 1 forks source link

pdcp uses local absolute path to pdcp on remotes #62

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
If the path to pdcp on the remote hosts is not the same as the path on the 
local host, pdcp fails. E.g.
"/bin/bash: /usr/bin/pdcp: No such file or directory".

pdcp should allow the remote shell to use its PATH to find the required binary 
and not assume that it will be installed at the same location on all machines. 
For example, on my laptop I have it installed at '/usr/local/bin' but on remote 
machines it might be installed at '/usr/bin'.

Original issue reported on code.google.com by sdev...@gmail.com on 22 Feb 2014 at 5:24

GoogleCodeExporter commented 9 years ago
There is the option '-e' which can be used to specify the remote path to pdcp.
This option can also be set via an environment variable:

       -e PATH
              Explicitly  specify  path to remote pdcp binary instead of using
              the locally executed path. Can also be set via  the  environment
              variable PDSH_REMOTE_PDCP_PATH.

I realize this isn't going to work if you are using pdcp to multiple machines,
each of which has the binary in a different path, but IIRC there were security
reasons for not trusting the PATH on remote hosts. However, you might just try

 pdcp -e pdcp ...

for now and see if that works (I don't have a place to test it right now)

Meanwhile, let me look back at why remote PATH can't be trusted.

Original comment by mark.gro...@gmail.com on 24 Feb 2014 at 2:45

GoogleCodeExporter commented 9 years ago
I did not see that option. Thanks, that works for me.

Original comment by sdev...@gmail.com on 26 Feb 2014 at 5:57

GoogleCodeExporter commented 9 years ago
Thanks! If it becomes a problem just reopen this ticket

Original comment by mark.gro...@gmail.com on 27 Feb 2014 at 3:04