DHCP的基本配置

 

1、  实验目的:

通过本次的实验,我们可以掌握如下技能

1)        DHCP的工作原理和工作过程

2)        DHCP服务器的基本配置

3)        客户端的配置

2、  实验拓扑图:

DHCP的基本配置

3、  实验步骤:

(1)       配置路由器R1提供DHCP服务

R1config#server dhcp   //开启DHCP服务

R1config#no ip dhcp conflict logging    //关闭DHCP冲突日志

R1config# ip dhcp pool ccie  //定义地址池

R1config#network 192.168.1.0/24   //DHCP分配的网络和掩码

R1dhcp-config#domain-name benet.com   //域名

R1dhcp-config#default-router 192.168.1.1  //默认网关,这个地址要和相应的网络所连接的路由器的以太网地址相同。

R1dhcp-config#netbios-name-server 192.168.1.2  //WINS服务器

R1dhcp-config#dns server 192.168.1.4  //DNS服务器

R1dhcp-config#option 150 ip 192.168.1.3  //TFTP服务器

R1dhcp-config#lease infinite   //定义租期

R1config#ip dhcp excluded-address 192.168.1.1 192.168.1.5  //排除地址段

(2)       设置windows客户端

首先在windows 下把TCP/IP地址设置为自动获取,如果DHCP服务器还提供DNSWINS等,也可以把他们设置为自动获取。

DHCP的基本配置

 

接下来我们可以使用 ipconfig/renew来更新Ip地址,并使用ipconfig/all来查看IP地址的配置情况了。