O'Reilly logo

Cisco IOS Cookbook, 2nd Edition by Ian Brown, Kevin Dooley

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Defining DHCP Configuration Options

Problem

You want to dynamically deliver configuration parameters to client workstations.

Solution

You can configure a wide variety of DHCP parameters for configuring client workstations:

Router1#configure terminal 
Enter configuration commands, one per line.  End with CNTL/Z.
Router1(config)#ip dhcp pool ORAserver
Router1(dhcp-config)#host 172.25.1.34 255.255.255.0
Router1(dhcp-config)#client-name bigserver
Router1(dhcp-config)#default-router 172.25.1.1 172.25.1.3
Router1(dhcp-config)#domain-name oreilly.com
Router1(dhcp-config)#dns-server 172.25.1.1 10.1.2.3
Router1(dhcp-config)#netbios-name-server 172.25.1.1 
Router1(dhcp-config)#netbios-node-type h-node
Router1(dhcp-config)#option 66 ip 10.1.1.1 
Router1(dhcp-config)#option 33 ip 192.0.2.1 172.25.1.3 
Router1(dhcp-config)#option 31 hex 01
Router1(dhcp-config)#lease 2
Router1(dhcp-config)#exit
Router1(config)#end
Router1#

Discussion

The strength of DHCP is its ability to configure client workstations from a centralized location using DHCP options. It greatly reduces costs if workstations can dynamically learn all of their configuration options instead of having to send a technician to every desk.

DHCP can assign default routes, domain names, name server addresses, and WINS server addresses, to name just a few. RFC 2132 defines a large number of standard configurable options, and includes provisions for further vendor-specific options. However, in reality most networks only use a small subset of these ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required