We have a problem on a centos 6 server. normally, PasswordAuthentication is off.
When I get connected using rescue mode, I execute these commands :
mount -o remount,rw /
chroot / /bin/bash
passwd root
It says password reset successfully.
And I also try to edit /etc/ssh/sshd_config
and/etc/ssh/ssh_config
to enable password authentication, but the problem is that none of the modifications is saved after reboot. And when I try the new password with ssh, it does not work.
Do you have any idea?