Enable password login along with private key authentication – Linux

I came across a scenario where I had to enable plain password login on a Linux server which is configured for private key authentication.

Normally when you create VM on cloud with SSH authentication, password login is by default disabled.

To enable password login, file you should be looking at is.


Following options are available:

To enable/disable the password authentication, set:

>> PasswordAuthentication <yes/no>

To enable/disable the Public/private key authentication, set”:

>> PubkeyAuthentication <yes/no>

For any changes to this file to be active, restart the sshd service with below command:

>> sudo service sshd restart


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s