Strange Error message SIOCGIFCONF Invalid argument

Glenn Satchell Glenn.Satchell at
Fri Sep 21 12:55:06 UTC 2007

>X-Virus-Scanned: amavisd-new at
>X-Spam-Flag: NO
>X-Spam-Score: -2.589
>Date: Fri, 21 Sep 2007 13:24:56 +0200
>From: Richard Smits <R.Smits at>
>To: dhcp-users at
>Subject: Re: Strange Error message SIOCGIFCONF Invalid argument
>X-archive-position: 4659
>X-ecartis-version: Ecartis v1.0.0
>X-original-sender: R.Smits at
>List-software: Ecartis version 1.0.0
>X-List-ID: <>
>X-list: dhcp-users
>Glenn Satchell wrote:
>>> Date: Thu, 20 Sep 2007 12:45:20 +0200
>>> From: "R.Smits" <R.Smits at>
>>> To: dhcp-users at
>>> Subject: Strange Error message SIOCGIFCONF Invalid argument
>>> Hello,
>>> We have a Solaris 9 box running ISC 3.03
>>> We have 64 trunked virtual network interfaces. When we try to make
>>> another one, and start the dhcp server, the messages file says :
>>> ioctl: SIOCGIFCONF: Invalid argument
>>> The dhcp server exits with this error message. What does this mean ?
>>> Greetings... Richard Smits
>>> TU-Delft
>> A quick google with that error message shows that Solaris returns
>> invalid argument if the size of the buffer passed in the ioctl() call
>> is not big enough to hold the data for all the interfaces.
>> The string SIOCGIFCONF occurs in only one source file,
>> common/discover.c. In this file this string is used several times in
>> the subroutine discover_interfaces(). It starts with a 2048 byte
>> buffer, but if it gets an error it increases the size and tries again.
>> At least this is the way it is supposed to work in 3.0.4 and 3.0.5. I
>> don't have a copy of the 3.0.3 source code handy to see if this
>> behaviour is in that version. I know it was added somewhere along the
>> years.
>> First step would be to try a newer release to see if the behaviour changes.
>> Otherwise you could increase the size of the buffer until it works.
>> regards,
>> -glenn
>Ah ok.... this is a good explanation.
>> Otherwise you could increase the size of the buffer until it works.
>Ok, but how do you do this ? We will try a newer version, but a quick
>fix would be better :-)

Edit the source and recompile.

In common/discover.c find the discover_interfaces subroutine. There is
a line in the first few lines there that defines the original buffer:

        char buf [2048];

The 204 might be different in the older version. Make that something like

        char buf [4096];

then recompile and re-install.

The other option is not to trunk all the VLANs to the Sun box, but
rather do the multiple VLANs on a router and enable ip-helper (or
equivalent) on that router with only a single VLAN connected to the Sun
box. I suspect this may be harder to do.


>Greetings, and thank you for your help...

More information about the dhcp-users mailing list