Skip to content

Root Password Login Fails Post-Cloud-init #6

@krakenhavoc

Description

@krakenhavoc

Issue:
After running cloud-init, root login via password does not work with the default /etc/ssh/sshd_config settings.

Details:
The SSH configuration prevents root password login due to the following lines:

#PermitRootLogin prohibit-password
KbdInteractiveAuthentication no

Resolution:
Update /etc/ssh/sshd_config as follows:

  • Change #PermitRootLogin prohibit-password to PermitRootLogin yes
  • Change KbdInteractiveAuthentication no to KbdInteractiveAuthentication yes

Steps to reproduce:

  1. Provision system with cloud-init and default sshd_config.
  2. Attempt to login as root using a password (should fail).
  3. Apply above changes in sshd_config, restart SSH, and verify root password login works.

Expected outcome:
Root password login should succeed after updating these configuration values.


Security Note:
Enabling root password login can increase risk; ensure strong passwords and consider additional security controls.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions