The ssh daemon output an error "Bind to port 22 on xxxx:xxxx:xxxx:xxxx::xxx failed: Address already in use" on starting it
Issue
- The ssh daemon output the following error into /var/log/secure on starting it.
Dec 10 14:32:27 testmachine sshd[2638]: error: Bind to port 22 on xxxx:xxxx:xxxx:xxxx::xxx failed: Address already in use.
- We have a ListenAddress configuration in /etc/ssh/sshd_config as below.
ListenAddress testmachine
ListenAddress testmachine.ipv6
- Also, we have the following entries in /etc/hosts
192.168.100.1 testmachine testmachine.ipv4
xxxx:xxxx:xxxx:xxxx::xxx testmachine testmachine.ipv6
Environment
Red Hat Enterprise Linux 6
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.