LAB12:DHCP中继
switch分解试验部分-LAB12:DHCP中继
精选 转载一、实验目的
1、掌握DHCP中继的应用
二、实验内容
拓扑图:
需求:
1、VLAN 10、VLAN 20内的PC能够从DHCP Server(Server-PT)动态获得IP地址;
2 、DHCP Server(Server-PT)属于VLAN 101;
三、实验配置
配置思路:
DHCP工作时使用广播地址,同时PC和DHCP Server又不在同一VLAN中,而VLAN拥有分割广播域的作用,从而导致PC不能从DHCP Server 获取IP地址。这就需要我们在负责VLAN间路由的3560-24PS 的交换机上启用DHCP中继来解决问题。
配置
1、开启3560-24PS的DHCP服务功能
Switch(config)#service dhcp
2、开启路由功能
Switch(config)#ip routing
3、开启DHCP中继功能
Switch(config)#ip dhcp relay information option
Switch(config)#interface vlan 10
Switch(config-if)#ip helper-address 192.168.101.1 (设置中继目标地址为DHCP Server )
验证:
Switch#debug ip dhcp server packet
*Mar 1 01:42:58.663: DHCPD: incoming interface name is Vlan10
*Mar 1 01:42:58.663: DHCPD: Looking up binding using address 192.168.10.254
*Mar 1 01:42:58.663: DHCPD: setting giaddr to 192.168.10.254.
*Mar 1 01:42:58.663: DHCPD: adding relay information option.
*Mar 1 01:42:58.663: DHCPD: BOOTREQUEST from 0100.2264.4bab.eb forwarded to 192.168.20.1.
*Mar 1 01:42:58.667: DHCPD: incoming interface name is Vlan20
*Mar 1 01:42:58.667: DHCPD: forwarding BOOTREPLY to client 0022.644b.abeb.
*Mar 1 01:42:58.667: old_giaddr = 0.0.0.0, giaddr=0.0.0.0, flag=0
*Mar 1 01:42:58.667: DHCPD: Option82 is currently:
*Mar 1 01:42:58.667: 020c020a0000c0a80afe0a000000
*Mar 1 01:42:58.667: DHCPD: Removing option82 information
*Mar 1 01:42:58.667: DHCPD: Option82 is removed
*Mar 1 01:42:58.667: DHCPD: broadcasting BOOTREPLY to client 0022.644b.abeb.
*Mar 1 01:43:02.731: DHCPD: incoming interface name is Vlan10
*Mar 1 01:43:02.731: DHCPD: Looking up binding using address 192.168.10.254
*Mar 1 01:43:02.731: DHCPD: setting giaddr to 192.168.10.254.
*Mar 1 01:43:02.731: DHCPD: adding relay information option.
*Mar 1 01:43:02.731: DHCPD: BOOTREQUEST from 0100.2264.4bab.eb forwarded to 192.168.20.1.
*Mar 1 01:43:02.735: DHCPD: incoming interface name is Vlan20
*Mar 1 01:43:02.735: DHCPD: forwarding BOOTREPLY to client 0022.644b.abeb.
*Mar 1 01:43:02.735: old_giaddr = 0.0.0.0, giaddr=0.0.0.0, flag=0
*Mar 1 01:43:02.735: DHCPD: Option82 is currently:
*Mar 1 01:43:02.735: 020c020a0000c0a80afe0a000000
*Mar 1 01:43:02.735: DHCPD: Removing option82 information
*Mar 1 01:43:02.735: DHCPD: Option82 is removed
*Mar 1 01:43:02.735: DHCPD: broadcasting BOOTREPLY to client 0022.644b.abeb.
四、应用场景
当使用Windows2003、Windows2008、Linux等为DHCP Server,并且和PC不在同一网段时;
提问和评论都可以,用心的回复会被更多人看到
评论
发布评论
相关文章
-
OSPF分解试验部分-LAB12:OSPF cost修改
OSPF分解试验部分-LAB12:OSPF cost修改
OSPF 试验 休闲 cost 分解 -
switch分解试验部分-LAB9:EtherChannel
switch分解试验部分-LAB9:EtherChannel
EtherChannel 试验 休闲 switch 分解 -
switch分解试验部分-LAB11:动态地址分配(DHCP)
switch分解试验部分-LAB11:动态地址分配(DHCP)
DHCP 地址 动态 switch 分解 -
switch分解试验部分-LAB8:SVI实验
switch分解试验部分-LAB8:SVI实验
实验 试验 switch SVI 分解 -
switch分解试验部分-LAB16:VLAN ACL
switch分解试验部分-LAB16:VLAN ACL
VLAN ACL 试验 switch 分解 -
switch分解试验部分-LAB13:IP SIA
switch分解试验部分-LAB13:IP SIA
试验 休闲 switch SIA 分解 -
switch分解试验部分-LAB3:VLAN端口划分
switch分解试验部分-LAB3:VLAN端口划分
端口 VLAN 试验 switch 分解 -
switch分解试验部分-LAB6:PVST+ & RSTP
switch分解试验部分-LAB6:PVST+ & RSTP
试验 switch RSTP PVST 分解 -
switch分解试验部分-LAB1:VLAN的创建
switch分解试验部分-LAB1:VLAN的创建
VLAN 试验 休闲 switch 分解 -
switch分解试验部分-LAB15:Dynamic ARP Inspect
switch分解试验部分-LAB15:Dynamic ARP Inspect
ARP switch Dynamic Inspect 分解 -
switch分解试验部分-LAB4:VLAN VTP设置
switch分解试验部分-LAB4:VLAN VTP设置
VLAN VTP 试验 switch 分解 -
switch分解试验部分-LAB10:Hot Standby Router Protocol(HSRP)
switch分解试验部分-LAB10:Hot Standby Router Protocol(HSRP)
Router Protocol Standby switch Hot -
switch分解试验部分-LAB7:生成树防护(STP Guard)
switch分解试验部分-LAB7:生成树防护(STP Guard)
STP switch 防护 Guard 分解 -
switch分解试验部分-LAB14:交换机端口安全
switch分解试验部分-LAB14:交换机端口安全
交换机 端口 试验 switch 分解 -
EIGRP分解试验部分-LAB1:EIGRP基本试验
EIGRP分解试验部分-LAB1:EIGRP基本试验
职场 EIGRP 试验 休闲 分解 -
switch分解试验部分-LAB5:Spanning Tree Protocol (STP 802.1D)
switch分解试验部分-LAB5:Spanning Tree Protocol (STP 802.1D)
STP Protocol switch Tree Spanning -
switch分解试验部分-LAB2:交换机端口操作模式设置
switch分解试验部分-LAB2:交换机端口操作模式设置
交换机 端口 模式 switch 分解