what part of dhcpd.leases file is moved (or copied) to dhcpd.leases~?

Simon Hobson dhcp1 at thehobsons.co.uk
Mon Jan 22 16:24:12 UTC 2007


Luc T. wrote:

>   It seems to me that the isc dhcp server very much relies on the system time.

Yes, it's pretty fundamental to the system - not just to dhcpd.

>If I change the machine time backward for a couple days (e.g. change 
>the time of today to Jan 1st, 2007), will those expired records be 
>treated as a still assigned ip ? ( the expiration time is still 
>later than the "current" machine time) Will this cause a shortage of 
>ip address?

I don't know what the server will do, I would GUESS that it will 
still count them as expired because that is what they'll be labelled 
as. David may have a better answer than that, but I would guess that 
it's a case not considered since time going backwards is not a normal 
event.

I have to say that changing the system time like that is a very bad 
idea - it may cause you all sorts of problems elsewhere in the 
system. Log files are going to be mightily messed up, various 
time-dependent functions (like cron) may get confused (think any 
process that uses a "is the current time past the due time for the 
next <something>" type function), and anything producing time-stamped 
files may overwrite important data.

On one system I've used in the past (Apollo Aegis), the manufacturer 
warned that the time must NEVER EVER go backwards - it used a 
combination of the machines network id and clock as the internal 
file-id when creating new files, setting the clock back (even by a 
few seconds) could result in a clash with unpredictable results. 
Fortunately, to change the clock also meant shutting down the OS, so 
setting it back a few seconds/minutes to correct for clock drift was 
OK as long as you waited at least an equivalent length of time before 
starting it all up again - no time sync it would seem in those 
days/on that network.

So, I strongly recommend that you keep the clock set correctly at all 
times to avoid any such problems. ntpdate will step-sync you clock to 
a time source, ntpd is far better and will determine and correct for 
your clock drift. You ISP will most likely provide an NTP server you 
can use, if not then take a look at http://www.pool.ntp.org/



More information about the dhcp-users mailing list