资源描述:
《实验四十一、DHCP配置》由会员上传分享,免费在线阅读,更多相关内容在行业资料-天天文库。
1、实验四十一、DHCP配置一、实验目的1.掌握DHCPSERVER的配置2.掌握DHCPCLIENT的配置3.掌握DHCPRELAY的配置二、应用环境1.在实际应用环境中需要为DHCP做中继以便让客户机获得IP地址2.也可以将路由器作为DHCP的服务器或者客户机三、实验设备1.DCR-1751两台2.PC机一台3.网线(交叉线)两条四、实验拓扑五、实验要求ROUTER-BROUTER-CPC机F0/0192.168.2.1E1/0192.168.3.1动态获得IP地址六、实验步骤第一步:按照实验三和上表配置接口IP地址第二步:DHC
2、P服务器的配置Router-B#confRouter-B_config#ipdhcpdpool1!定义地址池Router-B_config_dhcp#network192.168.2.0255.255.255.0!定义网络号Router-B_config_dhcp#range192.168.2.10192.168.2.20!定义地址范围Router-B_config_dhcp#lease1!定义租约为1天Router-B_config_dhcp#exitRouter-B_config#ipdhcpdenable!启动DHCP服务第
3、三步:验证Router-B#shipdhcppoolDHCPServerAddressPoolInformation:Pool1:Network:192.168.2.0Range:192.168.2.10-192.168.2.20Totaladdress:11Leasedaddress:1Abandonedaddress:0Availableaddress:10第四步:DHCP客户机的配置Router-C#confRouter-C_config#intf0/0Router-C_config_f0/0#ipaddressdhcp!配
4、置DHCP客户端Router-C_config_f0/0#^Z第五步:验证获得地址Router-C#showinterfacef0/0FastEthernet0/0isup,lineprotocolisupaddressis00e0.0f20.0368Interfaceaddressis192.168.2.10/24!获得了地址MTU1500bytes,BW100000kbit,DLY10usecEncapsulationARPA,loopbacknotsetKeepalivenotsetARPtype:ARPA,ARPtimeo
5、ut04:00:0060secondinputrate117bits/sec,0packets/sec!60secondoutputrate116bits/sec,0packets/sec!Full-duplex,100Mb/s,100BaseTX,1804Interrupt1729packetsinput,120998bytes,200rx_freebufReceived102unicasts,0lowmark,1729ri,0throttles0inputerrors,0CRC,0framing,0overrun,0long7
6、5packetsoutput,5213bytes,50tx_freebd,0underruns0outputerrors,0collisions,0interfaceresets0babbles,0latecollisions,0deferred,0err6000lostcarrier,0nocarrier0gracestop0buserror0outputbufferfailures,0outputbuffersswappedoutRouter-B#showipdhcpbinding!在服务器上看到被分配的地址IPAddress
7、HardwareAddressTypeLeaseExpired192.168.2.1000.e0.0f.20.03.68automaticFriJan200:21:022004DHCP中继的配置第六步:在服务器上新建地址池Router-B_config#ipdhcpdpool2!建立地址池Router-B_config_dhcp#network192.168.3.0255.255.255.0!设定网络号Router-B_config_dhcp#range192.168.3.10192.168.3.20!设定地址范围Router-B
8、_config_dhcp#default-router192.168.3.1!配置分配给客户机的网关Router-B_config_dhcp#dns-server1.1.1.1!配置分配给客户机的DNS服务器地址Router-B_config_dh