A system administrator notices that the SSH service on a Linux server is failing to start. The log shows: 'sshd: error: Could not load host key: /etc/ssh/ssh_host_rsa_key'. What is the most likely cause and solution?
Trap 1: The sshd_config file has a syntax error
The error message does not indicate a syntax error.
Trap 2: The SSH service is managed by xinetd and the configuration is…
SSH is typically not managed by xinetd.
Trap 3: The /etc/ssh/sshd_config file has incorrect permissions
The error is about a missing key, not permissions.
- A
The sshd_config file has a syntax error. Run 'sshd -t' to check it.
Why wrong: The error message does not indicate a syntax error.
- B
The SSH service is managed by xinetd and the configuration is missing. Edit /etc/xinetd.d/ssh.
Why wrong: SSH is typically not managed by xinetd.
- C
The /etc/ssh/sshd_config file has incorrect permissions. Change them to 600.
Why wrong: The error is about a missing key, not permissions.
- D
The host key file is missing or corrupt. Run 'ssh-keygen -A' to regenerate all missing host keys.
This regenerates default host keys.