multi-hop ssh port forwards?
Paul Lussier
p.lussier at comcast.net
Mon Oct 18 21:39:01 EDT 2004
In a message dated: Mon, 18 Oct 2004 11:34:08 EDT
Bill McGonigle said:
>On Oct 18, 2004, at 10:41, Matt Brodeur wrote:
>
>> I think you're looking for something like this:
>>
>> $ ssh -L 8000:localhost:8000 myserver ssh -L 8000:insideserver:80
>> bastion
>
>Yeah, that's what I thought would work, but empirically doesn't. ssh
>tells me something like:
>
> channel 2: open failed: connect failed: Connection refused
>
>BTW, throw in a -t on the first ssh to get the multi-hop terminal
>working. I've also tried "AllowTCPForwarding yes" and "GatewayPorts
>yes". I have a vague suspicion about TCP source ports but I haven't
>formulated any theories.
This
ssh -t -L 8080:localhost:8080 bastion.host.com \
'ssh -L 8080:localhost:80 internal_desktop'
works just fine for me.
More information about the gnhlug-discuss
mailing list