By xshell local windows ubuntu computer remote computer operation

1 Preparations 

See their host IP address:
Windows
. 1 CWD
2 input ipconfig / all
inside an IPv4 address, the right side is their IP

Ubuntu
open terminal performs: the ifconfig -a command can, as shown in FIG white background information that is.
enp0s3 represents the first NIC, which HWaddr represent the physical address of the network card, you can see the current physical address of the network card (MAC address) is 08: 00: 27: 4E: E0: ae
inet addr IP address of the network card used to represent, IP address of this card is 10.0.2.15, broadcast address, Bcast: 10.0.2.255, mask address mask: 255.255.255.0 
LO is a bad return address of the host, which generally is used to test a web application, but do not want user LAN or outside the network to view, and the view can only run on which network interfaces on this host. For example, to specify HTTPD server back to the bad address, will be able to see what you stand WEB site in browser and enter 127.0.0.1. But only you can see, the host or other LAN users do not know.

First line: connection type: Ethernet (Ethernet) HWaddr (mac address hardware)
the second row: the IP address, subnet mask card
Third row: the UP (NIC on state on behalf of) the RUNNING (NIC cable is representative of connected to) the mULTICAST (supports multicast) the MTU: 1500 (maximum transmission unit): 1500 bytes
fourth, the five elements: receive and send data packets statistics
seventh row:Receiving, transmitting data bytes statistics.
,

2.1 Option One: to ubuntu install ssh server

xshell ubuntu remote connection protocol through ssh, it is necessary to install the ssh server ubuntu
 

1) ubuntu ssh server installed
sudo apt-get install openssh-server

2) When a problem occurs, you can restart the ssh service ( https://blog.csdn.net/qq_36827957/article/details/78929534 )
sudo ssh restart Service

3) Use the following command to view the process :( https://blog.csdn.net/qq_40606798/article/details/82622376 )

 ps -e | grep ssh

4) If only sshd-agent represents not start, you need:

/etc/init.d/ssh start

5) If the display is illustrated sshd start successfully.

or

2.2 Option Two: to ubuntu install ssh server

https://blog.csdn.net/u014465934/article/details/81290215

# 1 updates the list
sudo apt-get update

# 2.安装openssh-server
sudo apt-get install openssh-server

# 3. Check whether to start ssh service
sudo ps -e | grep ssh

# 4. If it does not, start ssh service
sudo service ssh start

# 5. Check the IP address
sudo ifconfig
inet addr: 192.168.252.128
 

Check IP

1) ubuntu see its ip: ifconfig


2) win its view ip: ipconfig

3.1 can detect whether a link tips

Local cmd inside    the ping 10.XXXX    (the ping + other gateways)
to see if there Reply

3.2 encountered problems and solutions

https://blog.csdn.net/wu_cai_/article/details/78162119

Problem Description: Could notconnect to '192.168.18.121' (Port 22 is): Connection failed.

Solution: must have root privileges, enter the following command:
sudo su
sudo Service SSH restart
PS -e | grep SSH restart  (to see if open)

 

4 formal settings

Instruction requires input on ubuntu machine
/etc/init.d/ssh Start
the sudo SU

0 Download xshell, a local official website to download windows, leave your name E-mail address to receive download

1 to establish a connection

2 to establish a connection, typing

名称:就是起个名,哪个机器控制哪个机器
协议:SSH
主机: (这里便是准备工作里面说的IP)被控制机器(服务器)的IP,比如:193.112.9.183
端口号: 不改变

3 点击用户身份验证
输入用户名,密码(我理解就是Ubuntu服务器的哪个用户名和密码

4 输入用户名,记住用户名

5 输入密码

 

 

 

发布了458 篇原创文章 · 获赞 138 · 访问量 24万+

Guess you like

Origin blog.csdn.net/zjc910997316/article/details/103961539