We often encounter various problems: putty cannot connect to various Linux servers, especially in virtual machines. In Windows, Putty can be used to remotely log on to management or log on to a Linux server, putty connection timeout, putty connection rejected ...... In windows, putty cannot connect to the virtual machine. Common Linux troubleshooting
Command: Rpm-qa | grep openssh
It indicates that you have installed
For example
Then check whether the network is smooth: ping the IP address
Check the SSH service status: stysemctl status sshd. service
It can be found that the status is dead, indicating that the SSH service is not started.
Start the SSH service: systemctl start sshd. service
Then check the service status: stysemctl status sshd. service
The SSH service is ACTIVE, indicating that the service has been started.
Use PIETTY to log on to linux
Successful
Putty cannot connect to the VM Ubuntu in windows
1. Make sure that you can ping a remote Ubuntu or virtual machine.
2. If you still cannot log on, most of the reasons are that you have not enabled the ssh-server service. The final success method is as follows:
Sudo apt-get install openssh-server
Openssh-client is installed by default in Ubuntu, so it is not installed here. If your system is not installed, use apt-get to install it.
Then confirm whether the sshserver is started:
Ps-e | grep ssh
If only ssh-agent is available, the ssh-server has not been started./etc/init. d/ssh start is required. If you see sshd, the ssh-server has been started.
The ssh-server configuration file is located in/etc/ssh/sshd_config. Here, you can define the SSH service port. The default port is 22. You can define other port numbers, such as 222. Then restart the SSH service:
Sudo/etc/init. d/ssh resart
Use Putty on win7 to connect to a local Virtual Machine (Fedora)
1. error message: network error: connection time out
Yes, the connection to the VM does not respond. If the ping is successful, it is probably because of the firewall.
2. You can try to open the linux Firewall and then use putty to connect to the firewall. If not, it indicates a firewall problem. You can view the firewall rules for confirmation.
Aside from the question, it may also be a problem with your virtual machine, or a problem with the network connection method (bridging, host mode, etc.). All the problems are changing. We must learn to be flexible.