0

I have the following problem. From machine A I connect to machine B over the internet via ssh and port forwarding. Machine B is part of my local network and has connection to machine C which acts as a server inside the LAN.

A --------- | ---- B ---- C
  INTERNET GW        LAN      

Now I want to start a program on A that needs access to C without using a vpn connection. I tried ssh tunneling:

#user@A: ssh -N user@B -L 9999:B:9999

But when I start the program on A it cant connect to C. I guess it has something to do with A not having a route to C because it has only a local address (192.168.something) . How can I find out whats going wrong?

1 Answer 1

3

This is what you need.

#user@A: ssh -N user@B -L 9999:C:9999

When you connect from A with telnet

#user@A: telnet localhost 9999
3
  • Still i get a No route to host error when i try to telnet C 9999 Commented Mar 1, 2014 at 10:52
  • Updated with telnet command Commented Mar 1, 2014 at 11:19
  • @greole of course. From A you should telnet A 9999 or localhost 9999 Commented Mar 1, 2014 at 12:18

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.