scp with different users

Alex Bligh alex at alex.org.uk
Tue Oct 11 08:59:42 EST 2011


Peter,

--On 10 October 2011 23:27:44 +0200 Peter Stuge <peter at stuge.se> wrote:

> Alex Bligh wrote:
>> why
>>  scp a at b:c d:
>> fails, where
>>  scp a at b:c .
>>  scp c d:
>> succeeds?
>
> The former copies from c to d while the latter first copies from c to .
> and then from . to d.

The former copies file 'c' from user 'a' at host 'b' to the current
user at host 'd'.

The latter does the same, but via a file c in the current directory
on the current host.

What I am asking is why the former can succeed but the latter fail if
the local machine can log into both hosts. IE authenticating to
each of them individually works, but not when they are both on the
same scp command line.

-- 
Alex Bligh


More information about the openssh-unix-dev mailing list