Sei sulla pagina 1di 32

DHCP

Managed Configuration of
TCP/IP Hosts
Purpose of DHCP
From RFC2131: The Dynamic Host Configuration
Protocol (DHCP) provides a framework for passing
configuration information to hosts on a TCP/IP
network. DHCP consists of two components: a
protocol for delivering host-specific configuration
parameters from a DHCP server to a host and a
mechanism for allocation of network addresses to
hosts.
DHCP functional goals
 A host without a valid IP address locates and
communicates with a DHCP server.
 A DHCP server passes configuration
parameters, including an IP address, to the host.
 The DHCP server may dynamically allocate
addresses to hosts and reuse addresses.
 Hosts can detect when they require a new IP
address.
 Unavailability of DHCP server has minimal effect
on operation of hosts.
What can you do with DHCP
 Plug-and-play.
 Move desktop PCs between offices.
 Other restructuring - change subnet
masks.
 Mobile IP – laptops.
What DHCP doesn’t do

 Support multiple addresses per interface.


 Inform running host that parameters have
changed.
 Support inter-server communication.
 Provide authenticated message delivery.
What DHCP doesn’t do

 Configure routers and other network


equipment.
 Design network addressing plan.
 Determine other configuration parameters.
 Locate other servers.
DHCP
Overview
Dynamic Host Configuration Protocol.
 Centralized distribution and management.
 Clients obtains IP addresses from the server.
– Automates TCP/IP configuration.
– Administrators don’t have to manually configure each client.
– Centralizes IP address management.
– TCP/IP property changes are configured at the DHCP server.

DHCP Operation
DHCP Client
00:a0:24:71:e4:44 DHCP Server

DHCPDISCOVER
Sent to 255.255.255.255
 DHCP DISCOVER

DHCP Server
DHCP Client
00:a0:24:71:e4:44 DHCPOFFER DHCP Server

 DHCP OFFER
DHCPOFFER

DHCP Server
DHCP Operation
DHCP Client
00:a0:24:71:e4:44 DHCP Server

 DCHP REQUEST DHCPREQUEST

At this time, the DHCP client can DHCPACK


start to use the IP address

DHCP Client DHCP Server


00:a0:24:71:e4:44 DHCP Server

 Renewing a Lease DHCPREQUEST

(sent when 50% of lease has DHCPACK

expired)
If DHCP server sends DHCP Server
DHCPNACK, then address
is released.
DHCP Operation
DHCP Client
00:a0:24:71:e4:44 DHCP Server
DHCPRELEASE

 DCHP RELEASE

At this time, the DHCP client has released the IP address

DHCP Server
DHCP
Configuring Reliability and Redundancy
LON-DC-01 NY-DC-01
DHCP Server DHCP Server
Scope 1 Leasing Scope 1
Leasing
192.168.16.2/20 192.168.80.2/20
192.168.16.1 to 192.168.16.3 to 192.168.29.1 192.168.80.1 to

X
192.168.28.254 (80%) WRK-LON-001
192.168.16.1 to WRK-LON-
192.168.80.1 192.168.92.254 (80%)
Wide Area 003
Scope 2 Routers
Network Scope 2
192.168.93.1 to 192.168.29.1 to
192.168.95.254 (20%) 192.168.31.254 (20%)

Hubs

WRK-LON-001
needs WRK-LON-003
an IP
needs an IP
address
address
WRK-LON-003
WRK-LON-001

Workstations
192.168.16.3 192.168.29.1
Setting up a DHCP server in
Windows 2003
 Dynamic Host Configuration Protocol (DHCP)
– IP standard designed to reduce the complexity of
administering IP address configurations."
– Microsoft's definition. A DHCP server would be set up
with the appropriate settings for a given network.
– Settings would include a set of fundamental parameters
gateway, DNS, subnet masks, and a range of IP
addresses.
– Using DHCP on a network means administrators don't
need to configure these settings individually for each
client on the network. The DHCP would automatically
distribute them to the clients itself.
Setting up a DHCP server in
Windows 2003
 The DHCP server assigns a client an IP address taken
from a predefined scope for a given amount of time.
 If the client has not requested an extension on the lease
time, the IP address will be considered free and can be
assigned to another client .
 If the user wishes to change IP address then they can do
so by typing "ipconfig /release", followed by "ipconfig
/renew" in the command prompt.
 Addresses can be reserved for a MAC address or a host
name so these clients will have a fixed IP address that is
configured automatically.
Most Internet Service Providers use DHCP to assign new IP addresses to client
computers when a customer connects to the internet - this simplifies things at user

level.
Setting up a DHCP Server
 Installing the DHCP server is made quite easy in Windows 2003. By using the
"Manage your server" wizard,
Setting up a DHCP Server
Setting up a DHCP Server
Scope: A scope is a collection of IP addresses for computers on a subnet that use
DHCP
The next window will ask you to define the range of addresses that the scope will
distribute across the network and the subnet mask for the IP address. Enter the
appropriate details and click next
You are shown a window in which you must add any exclusions to the range of IP
addresses you specified in the previous window. If for example, the IP address
10.0.0.150 is that of the company router then you won't want the DHCP server to
be able to distribute that address as well. In this example I have excluded a range
of IP addresses, 10.0.0.100 to 10.0.0.110, and a single address, 10.0.0.150. In this
case, eleven IP's will be reserved and not distributed amongst the network clients.
It is now time to set the lease duration for how long a client can use an IP address
assigned to it from this scope. It is recommended to add longer leases for a fixed
network (in the office for example) and shorter leases for remote connections or
laptop computers. In this example I have set a lease duration of twelve hours
since the network clients would be a fixed desktop computer in a local office and
the usual working time is eight hours.
You are given a choice of whether or not you wish to configure the DHCP options
for the scope now or later. If you choose Yes then the upcoming screenshots will
be of use to you. Choosing No will allow you to configure these options at a later
stage.
The router, or gateway, IP address may be entered in next. The client computers
will then know which router to use
In the following window, the DNS and domain name settings can be entered. The
DNS server IP address will be distributed by the DHCP server and given to the
client.
If you have WINS setup then here is where to enter the IP Address of the WINS
server. You can just input the server name into the appropriate box and press
"Resolve" to allow it to find the IP address itself.
The last step is to activate the scope - just press next when you see the window
below. The DHCP server will not work unless you do this.
The DHCP server has now been installed with the basic settings
in place. The next stage is to configure it to the needs of your
network structure.
The address pool displays a list of IP ranges assigned for distribution and
IP address exclusions.
You are able to add an exclusion by right clicking the address pool text
on the left hand side of the mmc window and selecting "new exclusion
range".
This will bring up a window (as seen below) which will allow you to enter
an address range to be added.
Entering only the start IP will add a single IP address.
DHCP servers permit you to reserve an IP address for a
client. This means that the specific network client will
have the same IP for as long as you wanted it to.

To do this you will have to know the physical address


(MAC) of each network card. Enter the reservation name,
desired IP address, MAC address and description -
choose whether you want to support DHCP or BOOTP
and press add.
The new reservation will be added to the list. As an
example, I have reserved an IP address (10.0.0.115) for a
client computer called Andrew.
If you right click scope options and press "configure
options" you will be taken to a window in which you can
configure more servers and their parameters. These
settings will be distributed by the DHCP server along
with the IP address. Server options act as a default for
all the scopes in the DHCP server. However, scope
options take preference over server options.

Potrebbero piacerti anche