next up previous contents index
Next: Appendix Up: DHCP Server Previous: Leases   Contents   Index


Static DHCP

Static DHCP gives a network a little bit more security and stability. When I say a little bit more security I am only referring to security from people who only know how to use DHCP. Those people will not get an IP address so they will not be able to use the network. If they instead just give themselves an IP address this will not do anything. This is what the above DHCP configuration file would look like if you also added two static DHCP entries for dns and dns2:

server-identifier 1.2.3.4;
default-lease-time 86400;
max-lease-time 172800;
option domain-name	"bob.org";
option domain-name-servers	1.2.3.2,
	1.2.3.3;
option host-name	"bob.org";
option routers	1.2.3.1;
option subnet-mask	255.255.255.0;
subnet 1.2.3.0 netmask 255.255.255.0{
	range  1.2.3.200 1.2.3.250;
	default-lease-time 86400;
	max-lease-time 172800;
	option domain-name		"bob.org";
	option domain-name-servers		1.2.3.2,
		1.2.3.3;
	option host-name		"bob.org";
	option routers		1.2.3.1;
	option subnet-mask		255.255.255.0;

        host dns      { hardware ethernet 00:11:22:33:44:55; fixed-address 1.2.3.2; }
        host dns2     { hardware ethernet 11:22:33:44:55:66; fixed-address 1.2.3.3; }

}

If you only wanted static DHCP for your network you would remove the lines that refer to the DHCP lease range and lease times. These are the three lines you would remove:

	range  1.2.3.200 1.2.3.250;
	default-lease-time 86400;
	max-lease-time 172800;

It these were gone then the DHCP server would only give out IP addresses to dns and dns2.



Joseph Colton 2002-09-24