bind is failing, returning EADDRNOTAVAIL

July 3, 2014 2.2k views

I have been moving from another CentOS server to DigitalOcean. I had a software package working on the other server, and it fails on a socket bind: bind() is returning EADDRNOTAVAIL for the machine's ip address, 91.237.88.XXX ( x'd out the last subnet for security ).

I have been talking to the software package vendor and they did detailed error analysis to find this socket failure. As I mentioned, another server with CentOS 6.4 works. My droplet CentOS is 6.5, and that is the only difference. The software builds on CentOS 6.5 without error, but fails to open the socket. Tech support thinks it is the VPS environment at Digital Ocean.

2 Answers

Seeing that the software works fine on a CentOS 6.4 server, I would recommend installing it on a CentOS 6.4 droplet instead.

Sorry, but that is not an answer! It turned out I had a wrong digit in the /etc/hosts file that mismatched the "ifconfig -a" inet address. Tech support asked me to check the /etc/hosts file and I found the problem.

Have another answer? Share your knowledge.