imclient broken on Solaris 9

Stephen Grier s.e.grier at
Wed Mar 16 06:33:50 EST 2005

Dear all,

We've got Cyrus-imapd-2.2.10 running on on a Solaris 9 box, and
everything is fine, except for the cyradm utility, which fails with:

cyradm --user admin imap-test
imclient_connect: unknown host "imap-test" at /usr/local/lib/perl5/site_perl/5.8.5/sun4-solaris/Cyrus/IMAP/ line 71.

Having done some debugging, the problem appears to be the getaddrinfo()
call of the imclient_connect() function of lib/imclient.c. It does not
appear to like the AI_CANONNAME flag as defined in netdb.h, and returns
EAI_BADFLAGS "invalid ai_flags". If I change line 238 to:

    hints.ai_flags = 2;

(which is how AI_CANONNAME is defined in lib/gai.h) cyradm works as

So the getaddrinfo() call in imclient_connect seems to expect
AI_CANONNAME to be as defined in lib/gai.h rather than as defined in
netdb.h. And this only seems to happen on Solaris 9, not Solaris 7/8.

Does anyone know why this is happening? I have found a couple of
references on this issue in the info-cyrus archives, but nothing
conclusive. We can work with the above fix for now, but I'd rather know
exactly what's going on here.



Stephen Grier
Systems Developer
Computing Services
Queen Mary, University of London

Cyrus Home Page:
Cyrus Wiki/FAQ:
List Archives/Info:

More information about the Info-cyrus mailing list