Access with Password Authentication
Before changing the password authentication switch the root user
sudo su 
Navigate to the /etc/ssh/sshd_config
Use the vi editor to edit the file

Change PermitRootLogin prohibited_password > PermitRootLogin yes
PasswordAuthentication yes

Now again Navigate to the /etc/ssh/sshd_config.d/60-cloudimg-settings.conf
Change PasswordAuthentication no > yes

Restart the SSHd service
Now set the password for the root user:
set the password

Now log in to the server with the root user
ssh root@Your_server_IP_add

Last updated