Unable to login with username and password in Redhat Machine created in aws

0

Hi Team,

I am unable to login with username and password in the Redhat machine ..even after making PasswordAuthentication yes in sshd_config.

However the same is working fine aws linux.

Pankaj
gefragt vor 5 Monaten460 Aufrufe
4 Antworten
1
Akzeptierte Antwort

Changing PasswordAuthentication to yes in sshd_config is enough on Amazon Linux, but on RHEL PasswordAuthentication also appears in /etc/ssh/sshd_config.d/50-cloud-init.conf

[root@ip-172-31-13-116 ~]# cat /etc/ssh/sshd_config.d/50-cloud-init.conf
PasswordAuthentication no
[root@ip-172-31-13-116 ~]# 

Either set it to yes again in here, or just comment it out sed -i 's/^PasswordAuthentication/#PasswordAuthentication/' /etc/ssh/sshd_config.d/50-cloud-init.conf and then systemctl reload sshd and now users with a password set should be able to login using their password.

profile picture
EXPERTE
Steve_M
beantwortet vor 5 Monaten
profile picture
EXPERTE
überprüft vor 2 Monaten
0

Hello.

Have you checked the SSH logs?
Also, have you set a password for the user?

var/log/secure
profile picture
EXPERTE
beantwortet vor 5 Monaten
0

Let me try

Pankaj
beantwortet vor 5 Monaten
0

Thanks Steve .. your Solution worked

Pankaj
beantwortet vor 5 Monaten

Du bist nicht angemeldet. Anmelden um eine Antwort zu veröffentlichen.

Eine gute Antwort beantwortet die Frage klar, gibt konstruktives Feedback und fördert die berufliche Weiterentwicklung des Fragenstellers.

Richtlinien für die Beantwortung von Fragen