Home  >  Article  >  Operation and Maintenance  >  Root user cannot connect via ssh under linux

Root user cannot connect via ssh under linux

王林
王林Original
2020-02-15 17:17:043904browse

Root user cannot connect via ssh under linux

Problem:

After installing Ubuntu on the virtual machine, when connecting remotely through ordinary ssh, I have clearly entered the correct root user name and password but I keep being prompted to enter the password. Unable to log in remotely, but normal users are fine.

(Recommended video tutorial: linux video tutorial)

Solution:

1. Confirm that the ssh service has been installed and the connection is successful through an ordinary user;

2. Confirm whether the ssh configuration has special settings for root, modify the /etc/ssh/sshd_config file

Find PermitRootLogin without-password

Change without-password to yes ;

3. Restart the ssh service /etc/init.d/ssh restart;

4. Use ssh to connect again. This time there is no prompt and the connection is successful.

Related recommendations: linux tutorial

The above is the detailed content of Root user cannot connect via ssh under linux. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn