Use sshtunnel to connect to a LAN Machine

Source: Internet
Author: User

Use sshtunnel to connect to a LAN Machine

When you need a browser to open an intranet IP address, you can use putty to create a tunnel. As mentioned in my previous blog post;

You can also install the vnc viewer locally, log on to the login node, and use the browser of the login node to open the Intranet IP address;

Using ssh tunnel is the simplest method;

Example:

Node1 has a public ip address; node2 only has an intranet ip address; node1 and node2 communicate over the network;

We can only open the service of node1 in the browser; we can establish an ssh tunnel on node1 to obtain the service of node2 through the public ip address and port of node1 in the browser;

1. The intranet ip address of node2 is 10.0.0.189. We want to use the ip address of node1 to obtain the service with port 80 of node2;

Log on to node1 and run the following command. Enter the username and password as prompted to keep the current terminal window open:

# Ssh-L 80: 10.0.0.189: 80 10.0.0.189

2. Open node2_ip: 80/in the browser to see the service under port 80 of node1;

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.