Problem with dhcpctl.

Glenn Satchell Glenn.Satchell at
Thu Apr 23 15:27:20 UTC 2009

>Date: Thu, 23 Apr 2009 09:59:15 -0400
>Subject: Re: Problem with dhcpctl.
>From: phil lemelin <phil.lemelin at>
>To: Users of ISC DHCP <dhcp-users at>
>X-BeenThere: dhcp-users at
> More on my dhcpctl adventure.
> I just realized, follwing the example, that the value for the leases ends
> and starts time seems to be the inverse of what they should.
> The value in "value->value" is 0x1366f049 wich gives us 325513289 in epoch (
> something in the year 1980 ).
> The real value should be 0x49f06613. Any idea why it is like that ? Right
> now I have function that inverts it.

Looks to me like a "big/little endian" problem. You probably need to
convert the data from Network Byte Order to host order.

htonl() and nltoh() are the functions you should use if you want them
to be portable across big and little endian systems.


More information about the dhcp-users mailing list