SSH can't do menage a trois?

William Stearns wstearns at pobox.com
Tue Sep 10 14:29:12 EDT 2002


Good day, Michael,

On Tue, 10 Sep 2002, Michael O'Donnell wrote:

> I have three machines:
> 
>  - system C(entral) is connected to two LANs.
>  - system L(eft) is on one LAN connected to C.
>  - system R(ight) is on the other LAN connected to C.
> 
> L and R have no knowledge of each other.  I can
> easily establish SSH sessions and scp files (inbound
> or outbound) between C and L, or between C and R,
> but it seems that I can't, while operating from C,
> say something like:
> 
>    scp L:someFile R:someDirectory
> 
> ...because scp doesn't act as a go-between (as I had
> originally expected it to do) but instead constructs
> and transmits another scp command line for execution
> on L, and that command fails because it refers to R
> which, as I said, L doesn't recognize.
> 
> I can hack around this in a number of ways (like
> issuing two separate scp commands with the files
> temporarily residing on C's disk, or by spawning a
> tar on L and one on R and pushing the data from one to
> the other via two pipelined ssh's on C, etc, etc) but
> I wonder if there is some more elegant approach...?

	I think you'll find the answer you need in:

http://www.stearns.org/doc/ssh-techniques-two.current.html

	Cheers,
	- Bill

---------------------------------------------------------------------------
	"Outside of a dog, a book is a man's best friend.  Inside a dog
it's too dark to read."
	-- Groucho Marx
--------------------------------------------------------------------------
William Stearns (wstearns at pobox.com).  Mason, Buildkernel, named2hosts, 
and ipfwadm2ipchains are at:                        http://www.stearns.org
--------------------------------------------------------------------------




More information about the gnhlug-discuss mailing list