[Dovecot] trouble setting up director, "invalid argument" for connect() call [SOLVED]

Jim Lawson jtl+dovecot at uvm.edu
Wed Oct 5 23:31:15 EEST 2011


On 10/4/11 13:31 , Jim Lawson wrote:
> Hi Timo & everyone,
>
> I'm trying out a 2-node director setup, but I keep getting the following
> error:
>
> Oct  3 16:11:29 imapdir1 dovecot: master: Dovecot v2.0.15 starting up
> (core dumps disabled)
> Oct  3 16:11:34 imapdir1 dovecot: director: Error:
> connect(132.198.100.150:9090) failed: Invalid argument
> Oct  3 16:11:41 imapdir1 last message repeated 3 times

I was specifying DNS names in director_servers (imapdir1.uvm.edu,
imapdir2.uvm.edu).  /etc/hosts listed 127.0.0.1 as the address for the
local host name (in addition to "localhost").  This can happen on some
RHEL installs that begin their life as DHCP clients.

So when the director tried to figure out its self_ip, it always picked
127.0.0.1.  Calling connect() using a localhost socket with a non-local
address as destination just doesn't work so well, I guess.  Seeing
127.0.0.1 as "self" in "doveadm director ring status" should have been a
clue, but I hadn't seen the output before to have anything to compare it to.

2 easy fixes:  specify real IP addresses in the director_servers config,
or don't list 127.0.0.1 as your local hostname in /etc/hosts.

Jim


More information about the dovecot mailing list