sshd_config strange behavior

winproof

Well-Known Member
Oct 18, 2017
33
10
48
50
france
hi all

i've find something strange in my test cluster when playing with ssh settings.
if i change sshd_config "permitrootlogin" from "yes" to "without-password" and do a "systemctl restart sshd.service & systemctl restart ssh", it's work.

but after rebooting, "permitrootlogin" is set to "yes"!

same thing on a stand-alone server.

why?
 
Hi,

this is somewhat by design, when creating a cluster (pvecm create) adding a node (pvecm add) or updating certs (pvecm updatecerts) we parse sshd_config and enforce that root may login, for management reasons (we need to be able to login at least once to setup certs).

And currently we call updatecerts on startup of the cluster filesystem to ensure we got the "correct" (from POV of PVE) settings here, that's why the reboot reverts the change.

But I agree with you that also "without-password" is a valid setting here.
Could you please open a request @ https://bugzilla.proxmox.com/ so we can track this issue, else they may get lost more easily.
Just also refer to this thread.