Linux Tutorial
Keep asking password for root user even when provide correct password and not established ssh connection for localhost using root user.
[ramyadevi@fedora ~]$ ssh root@localhost root@localhost's password: Permission denied, please try again. root@localhost's password: Permission denied, please try again. root@localhost's password:
Need to check PermitRootLogin option in /etc/ssh/sshd_config file,
[ramyadevi@fedora ~]$ sudo cat /etc/ssh/sshd_config | grep PermitRootLogin PermitRootLogin prohibit-password
set prohibit-password value for option PermitRootLogin, that’s why ssh connection is not established using root user login.
Update PermitRootLogin option as yes in /etc/ssh/sshd_config file,
$ sudo vi /etc/ssh/sshd_config # change PermitRootLogin to yes PermitRootLogin yes
[ramyadevi@fedora ~]$ sudo cat /etc/ssh/sshd_config | grep PermitRootLogin PermitRootLogin yes
Also ensure PasswordAuthentication option is set as yes, otherwuse ssh connection refused again.
PasswordAuthentication yes
Let’s try ssh connection now,
[ramyadevi@fedora ~]$ ssh root@localhost 1 device has a firmware upgrade available. Run `fwupdmgr get-upgrades` for more information. Last login: Mon Mar 20 01:48:54 2023 from ::1
Linux Tutorial
Privacy Policy | Copyright2020 - All Rights Reserved. | Contact us | Report website issues in Github | Facebook page | Google+ page