[rabbitmq-discuss] getting started, broker runs; can't get status

Doug Barth dougbarth at gmail.com
Tue Feb 3 19:44:03 GMT 2009

On Feb 3, 1:19 pm, Dmitriy Samovskiy
<dmitriy.samovs... at cohesiveft.com> wrote:
> We did net_adm:localhost() to see the local host name that erlang sees. It was an FQDN
> (a.example.com). In /etc/hosts however, a.example.com resolved to an Internet-facing IP on
> ISP's frontend, not to a private IP of the local box. With tcpdump, we observed SYN
> packets in response to net_adm:names() call going out to the network to ISP's IP address,
> instead of going locally to our epmd.
> Once we changed /etc/hosts and put something like " a.example.com" there,
> net_adm:names() started working and erlang is happy now.

Hey Dmitriy,

Thanks again for the help.

Once we had a working configuration, we did a bit more digging to
fully understand how this issue was caused. I thought it would be
worth sharing what we believe was the root cause.

Our new machines have two NICs with separate IP addresses for each.
One one NIC has a publicly addressable IP, the other has a private IP
meant for server management traffic. When the erlang process was
attempting to contact the epmd process, it was using the private IP
interface to connect to the public IP interface. It did this because
the hostname for that box resolved to the public IP. The epmd-bound
traffic was stopped by the firewall for the public IP interface.
Modifying the hosts file to resolve the machine's hostname to avoided the firewall and fixed the issue. Alternatively,
changing the hosts file to use the private IP address also fixed the
issue, since that traffic avoids the firewall as well because the
originating and destination addresses are identical.

In theory, I think another fix for this issue would be to instruct
Erlang to use the public IP address when generating outbound traffic.
Unfortunately, I do not know how to control that setting to test this
theory. Is there are startup flag that could be set?

Doug Barth

More information about the rabbitmq-discuss mailing list