Linux SSH Access denied (access denied) solution

The newly installed CentOS 7 uses SSH to connect to Access denied, record this pit.
The detailed questions are as follows (see picture):
insert image description here

Solution
After checking the information, the Linux system prohibits remote login by default. Then just open the permissions.

Because the system settings need to be modified, ordinary users will not have permission, so operate under the super administrator, enter su root and enter the password (as shown in the figure):
insert image description here

Install openssh-server
yum -y install openssh-server
1
Check the SSH version
ps -e |grep ssh
1
See the figure below: ssh-server has been installed successfully.
insert image description here

insert image description here

Edit the configuration file:
vim /etc/ssh/sshd_config
1
modify PermitRootLogin to yes
insert image description here

Exit editing:
Press the 'Esc' key, enter ":wq", and press Enter.
1
Restart SSH:
systemctl restart sshd
1
You're done, you can use ssh to link

Guess you like

Origin blog.csdn.net/baiyifei2016/article/details/124914561
Recommended