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

Notices


Reply
  Search this Thread
Old 10-19-2005, 04:47 PM   #1
Josh328
Member
 
Registered: Jan 2004
Location: Louisiana
Posts: 106

Rep: Reputation: 15
dhcpd setup


I'm seting up a basic DHCP server, and I have a few questions...
I want infinite lease times to "known" clients and short lease times to "unknown clients".
Here's what I've got, basically pulled straight from the man pages. I have some questions throughout... Any help would be appreciated. Thanks..


Code:
       subnet 192.168.3.0 netmask 255.255.255.0 {
         option routers 127.0.0.1;  #THE ROUTER/FIREWALL IS RUNNING LOCALLY

         # Unknown clients get this pool.
         pool {
           option domain-name-servers 127.0.0.1; #BIND WILL ALSO RUN LOCALLY
           max-lease-time 300;
           range 192.168.3.200 192.168.3.253;
           allow unknown-clients;  #HOW ARE 'unknown-clients' DEFINED? AS A GROUP?
         }

         # Known clients get this pool.
         pool {
           option domain-name-servers 127.0.0.1;
           max-lease-time 28800;   #HOW BIG CAN THIS BE?
           range 192.168.3.5 192.168.3.199;
           deny unknown-clients;
         }
       }

Last edited by Josh328; 10-19-2005 at 04:49 PM.
 
Old 10-19-2005, 06:29 PM   #2
SirGertrude
Member
 
Registered: May 2004
Location: Missouri
Distribution: Gentoo
Posts: 59

Rep: Reputation: 15
Known clients are simply clients that have been defined using the "host" parameter.
Code:
host Todd { hardware ethernet 00:E0:18:9B:B3:2C; }
host Bill { hardware ethernet 00:11:d8:70:6b:04; }
host Don { hardware ethernet 00:50:8D:AE:07:27; }

You can have the host defined in a group if you want.

Code:
group {
	next-server 192.168.0.129;
	host Todd { hardware ethernet 00:E0:18:9B:B3:2C; }
	host Bill { hardware ethernet 00:11:d8:70:6b:04; }
	host Don { hardware ethernet 00:50:8D:AE:07:27; }
}
This is the same as above except parameters here affect all group members.

If you were to incorporate either of the two above examples in your configuration the �unknown-clients� would be any machines with mac addresses not set in a �host� parameter. Hope this helps.
 
Old 10-19-2005, 06:33 PM   #3
Josh328
Member
 
Registered: Jan 2004
Location: Louisiana
Posts: 106

Original Poster
Rep: Reputation: 15
ok, that makes sense. so this should be fine...

Code:
       host one { hardware ethernet 00:E0:18:9B:B3:2C; }
       host two { hardware ethernet 00:11:d8:70:6b:04; }
       host three { hardware ethernet 00:50:8D:AE:07:27; }

       subnet 192.168.3.0 netmask 255.255.255.0 {
         option routers 127.0.0.1;  #THE ROUTER/FIREWALL IS RUNNING LOCALLY

         # Unknown clients get this pool.
         pool {
           option domain-name-servers 127.0.0.1; #BIND WILL ALSO RUN LOCALLY
           max-lease-time 300;
           range 192.168.3.200 192.168.3.253;
           allow unknown-clients;
         }

         # Known clients get this pool.
         pool {
           option domain-name-servers 127.0.0.1;
           max-lease-time 28800;   #HOW BIG CAN THIS BE?
           range 192.168.3.2 192.168.3.199;
           deny unknown-clients;
         }
       }
how large can the max and default lease times be? I'd like known host lease times to be infinite.

Thanks,
Josh
 
Old 10-21-2005, 08:51 PM   #4
SirGertrude
Member
 
Registered: May 2004
Location: Missouri
Distribution: Gentoo
Posts: 59

Rep: Reputation: 15
Quote:
how large can the max and default lease times be? I'd like known host lease times to be infinite.
I'm not sure how long the lease can be, but I am pretty sure it cannot be infinite. It is not wise to have an infinite lease because you may fill your DHCP pool (especially if you pass many computers through your network) and run into problems. I have always set static DHCP leases to overcome the problem of infinite leases.
Code:
host Jack {
	hardware ethernet 00:04:61:98:E9:EC;
	fixed-address 192.168.1.2;
	}
Using the above example, the DHCP server will read the host statement and assign the specified fixed address to the host. It is a good idea to leave any fixed addresses out of the DHCP range so the IP addresses are always available for the hosts to which they belong.
 
  


Reply


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
dhcpd subnet declaration problems in dhcpd.conf vcrispo Linux - Networking 6 07-15-2005 10:32 AM
dhcpd dotcafe Linux - Software 2 03-23-2004 08:47 AM
DHCPD startup failure, mdk 9.2, dhcpd v3.0.1rc11 fuzzyworm Linux - Networking 1 02-14-2004 03:58 AM
DHCPD setup peok Linux - Networking 13 11-09-2003 02:10 PM
dhcpd.master or dhcpd.conf rickg Linux - Networking 0 04-11-2002 03:34 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 08:39 PM.

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