scp with openssh on the server side and $PATH.

Damien Miller djm at
Sat Dec 25 08:58:33 EST 1999

Hash: SHA1

On Fri, 24 Dec 1999, Marc Haber wrote:

> On Fri, 10 Dec 1999 16:32:28 GMT, you wrote:
> >When I try to use scp from or to a machine that runs
> >openssh-1.2pre16 on Debian Linux, I keep getting the error message
> >"scp: command not found". Executing "ssh this-host echo \$PATH"
> >yields "/usr/bin:/bin:/usr/sbin:/sbin:" which might be set in
> >config.h.
> This issue still hasn't been addressed. I don't have a clue what
> where to search.

This is a little tricky. When you execute scp, your local copy of
scp executes another instance of scp on the server end.

The remote copy of scp could have been installed anywhere, and 
there is little the client could do to the path (it could be 

A possible solution would be to hardcode an explicit path at 
configure time, but this would only work if the client and the
server were configured the same. I am not keen to include this 
kludge. (a more elegant solution would be welcomed, though).

Have you tried editing your /etc/profile (or similar) and simply
including the path to scp in there?

Damien Miller

- --
| "Bombay is 250ms from New York in the new world order" - Alan Cox
| Damien Miller -
| Email: djm at (home) -or- djm at (work)

Version: GnuPG v1.0.0 (GNU/Linux)
Comment: For info see


More information about the openssh-unix-dev mailing list