Download your favorite Linux distribution at LQ ISO.
Go Back > Forums > Linux Forums > Linux - Networking
User Name
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.


  Search this Thread
Old 06-10-2010, 11:29 AM   #1
Registered: Feb 2010
Location: North of Boston, Mass (North Shore/Cape Ann)
Distribution: CentOS 7.0 (and kvm/qemu)
Posts: 31

Rep: Reputation: 0
DHCP lease time anomaly

SuSE 11.1 dhcpd -- server (eth0)
SuSE 11.2 dhclient -- client (eth0)
Setting up, testing, set default lease, maximum lease to 240 seconds when testing, change to default outside of test mode.

It seems to be working, but looking at
/var/lib/dhcp/db/dhcpd.leases #on the server
/var/lib/dhcp/dhcp.leases #on the client

the hour of the lease if off by four hours in the future, the minutes seem OK.
(Being East Coast, I always suspect hidden California time stuff, but that would be three hours in the PAST <.grin>)

on server and client give the correct EDT time (I'm just north of Boston)

The server uses a NTP-server for its time-setting, the client has nothing (one of the experiments is to set that when I set the DHCP-address. But in any event, they both are the same time.

Do I have a problem ?
Which I fix by ... ?


Old 06-11-2010, 03:42 PM   #2
Registered: Mar 2010
Posts: 58

Rep: Reputation: 5
Are the timstamps in the leases files stampted for GMT/UTC?
1 members found this post helpful.
Old 06-11-2010, 04:07 PM   #3
Registered: Mar 2008
Posts: 16,676

Rep: Reputation: 2455Reputation: 2455Reputation: 2455Reputation: 2455Reputation: 2455Reputation: 2455Reputation: 2455Reputation: 2455Reputation: 2455Reputation: 2455Reputation: 2455
Set hardware clock to realtime clock if dafydd2277's suggestion isn't the fix.??? I think he is right though.
1 members found this post helpful.
Old 06-17-2010, 08:19 PM   #4
Registered: Feb 2010
Location: North of Boston, Mass (North Shore/Cape Ann)
Distribution: CentOS 7.0 (and kvm/qemu)
Posts: 31

Original Poster
Rep: Reputation: 0
Thumbs up UTC, date -u

The problem is/was there was no marks, EDT or GMT or UTC.
The hardware time and the system time were OK, and within seconds of each other on both machines.

It should have been obvious but I was having a brain-fart.
Thank you for the responses, which lead me to what I should have done
man dhcpd.leases
which explained in detail the line in the file, explained that dating format used and told me about
$ date -u
so as to verify my 'current time' and the one just entered in the lease table were indeed the same.

(I'm trying to evoke ddns, and then ddhcp, and I read that if the time difference was greater than 5 minutes the zone file would not update with that data. I'm not updating, so I suspected this my culprit -- it's obviously not, so I'll look elsewhere. I've probably got a setting or two in error that is my nemesis.)

Anyhow, thanks for your help.

(Am I suppose to click a check-box or radio-button to say thanks to all and/or case-closed ?)



Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
DHCP Server - No lease time? piercey Linux - Server 2 07-21-2008 11:15 AM
Force DHCP To Refuse Clients A DHCP Lease Depending On Client MAC Address blackfish Linux - Server 3 08-17-2007 12:54 AM
Slackware 11.0 DHCP no detection anomaly FYI coldbeer Slackware 3 11-16-2006 06:30 AM
Lost DHCP Lease when putting computer in "Standby" mode for a "long" time pnellesen Linux - Networking 1 01-06-2005 11:44 PM
Invalid DHCP server lease time CloudBuilder Linux - Wireless Networking 3 04-30-2004 08:41 PM > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 10:19 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration