我遇到了 DHCP 无法穿越到交换机后面的设备的问题。我部署了许多其他具有几乎相同配置的交换机,它们能够接收 DHCP 地址。在我遇到问题的这个交换机上,大多数设备都有一个静态地址,它们可以访问并且可以从网络访问就好了。我正在尝试将 AP 添加到其中一个端口,作为 UniFi,它需要从服务器获取 DHCP 地址,但无法这样做。当我将 AP 连接到具有相同端口配置的另一台交换机时,它会正确获取 DHCP 地址。在这个有 DHCP 问题的交换机上,如果我分配了一个静态地址,那么我又可以访问网络了。
我想弄清楚为什么 DHCP 没有被正确传递,或者我是否有配置错误。DHCP 服务器是 Windows 服务器,所有其他未连接到此交换机的设备都可以根据需要联系和接收预留或地址。
VLAN 信息由 VTP 向下传递,并且是最新版本。
问题开关配置:
!
! Last configuration change at 19:25:03 UTC Tue Jul 1 2014
! NVRAM config last updated at 19:25:05 UTC Tue Jul 1 2014
!
version 12.2
no service pad
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
boot-start-marker
boot-end-marker
!
!
!
no aaa new-model
switch 1 provision ws-c2960s-24ps-l
authentication mac-move permit
ip subnet-zero
!
!
!
!
spanning-tree mode pvst
spanning-tree etherchannel guard misconfig
spanning-tree extend system-id
!
!
!
!
vlan internal allocation policy ascending
!
!
!
interface FastEthernet0
no ip address
!
interface GigabitEthernet1/0/1
description MDF uplink 1/0/20
switchport mode trunk
!
interface GigabitEthernet1/0/2
description Fixed Cam
switchport access vlan 100
switchport mode access
spanning-tree portfast
!
interface GigabitEthernet1/0/3
description PLC
switchport access vlan 100
switchport mode access
spanning-tree portfast
!
interface GigabitEthernet1/0/4
switchport access vlan 100
switchport mode access
spanning-tree portfast
!
interface GigabitEthernet1/0/5
switchport access vlan 100
switchport mode access
spanning-tree portfast
!
interface GigabitEthernet1/0/6
switchport access vlan 100
switchport mode access
spanning-tree portfast
!
interface GigabitEthernet1/0/7
description IDF Link 1/0/22
switchport mode trunk
!
interface GigabitEthernet1/0/8
switchport access vlan 100
switchport mode access
spanning-tree portfast
!
interface GigabitEthernet1/0/9
switchport access vlan 100
switchport mode access
spanning-tree portfast
!
interface GigabitEthernet1/0/10
switchport access vlan 100
switchport mode access
spanning-tree portfast
!
interface GigabitEthernet1/0/11
switchport access vlan 100
switchport mode access
spanning-tree portfast
!
interface GigabitEthernet1/0/12
switchport access vlan 100
switchport mode access
spanning-tree portfast
!
interface GigabitEthernet1/0/13
switchport access vlan 100
switchport mode access
spanning-tree portfast
!
interface GigabitEthernet1/0/14
switchport access vlan 100
switchport mode access
spanning-tree portfast
!
interface GigabitEthernet1/0/15
switchport access vlan 100
switchport mode access
spanning-tree portfast
!
interface GigabitEthernet1/0/16
switchport access vlan 100
switchport mode access
spanning-tree portfast
!
interface GigabitEthernet1/0/17
switchport access vlan 100
switchport mode access
spanning-tree portfast
!
interface GigabitEthernet1/0/18
switchport access vlan 100
switchport mode access
spanning-tree portfast
!
interface GigabitEthernet1/0/19
switchport access vlan 100
switchport mode access
spanning-tree portfast
!
interface GigabitEthernet1/0/20
switchport access vlan 100
switchport mode access
spanning-tree portfast
!
interface GigabitEthernet1/0/21
switchport access vlan 100
switchport mode access
spanning-tree portfast
!
interface GigabitEthernet1/0/22
switchport access vlan 100
switchport mode access
spanning-tree portfast
!
interface GigabitEthernet1/0/23
switchport access vlan 205
switchport mode access
!
interface GigabitEthernet1/0/24
description UniFi
switchport trunk native vlan 200
switchport mode trunk
!
interface GigabitEthernet1/0/25
!
interface GigabitEthernet1/0/26
!
interface GigabitEthernet1/0/27
!
interface GigabitEthernet1/0/28
!
interface Vlan1
no ip address
!
interface Vlan205
ip address 192.168.205.35 255.255.255.0
!
ip default-gateway 192.168.205.1
ip http server
ip http secure-server
ip sla enable reaction-alerts
!
!
line con 0
line vty 0 4
password ----
login
line vty 5 15
login
!
end
VLAN(通过 VTP)
VLAN Name Status Ports
---- -------------------------------- --------- -------------------------------
1 default active Gi1/0/22, Gi1/0/25, Gi1/0/26
Gi1/0/27, Gi1/0/28
99 guest active
100 plc active Gi1/0/2, Gi1/0/3, Gi1/0/4
Gi1/0/5, Gi1/0/6, Gi1/0/8
Gi1/0/9, Gi1/0/10, Gi1/0/11
Gi1/0/12, Gi1/0/13, Gi1/0/14
Gi1/0/15, Gi1/0/16, Gi1/0/17
Gi1/0/18, Gi1/0/19, Gi1/0/20
Gi1/0/21
200 wlan active
205 Mgmnt active Gi1/0/23
接口:
Port Name Status Vlan Duplex Speed Type
Gi1/0/1 MDF uplink 1/0/20 connected trunk a-half a-100 10/100/1000BaseTX
Gi1/0/2 Fixed Cam connected 100 a-full a-100 10/100/1000BaseTX
Gi1/0/3 PLC connected 100 a-full a-100 10/100/1000BaseTX
Gi1/0/4 connected 100 a-full a-100 10/100/1000BaseTX
Gi1/0/5 notconnect 100 auto auto 10/100/1000BaseTX
Gi1/0/6 notconnect 100 auto auto 10/100/1000BaseTX
Gi1/0/7 IDF Link 1/0/22 connected trunk a-full a-100 10/100/1000BaseTX
Gi1/0/8 notconnect 100 auto auto 10/100/1000BaseTX
Gi1/0/9 connected 100 a-full a-1000 10/100/1000BaseTX
Gi1/0/10 notconnect 100 auto auto 10/100/1000BaseTX
Gi1/0/11 notconnect 100 auto auto 10/100/1000BaseTX
Gi1/0/12 notconnect 100 auto auto 10/100/1000BaseTX
Gi1/0/13 notconnect 100 auto auto 10/100/1000BaseTX
Gi1/0/14 connected 100 a-full a-100 10/100/1000BaseTX
Gi1/0/15 notconnect 100 auto auto 10/100/1000BaseTX
Gi1/0/16 notconnect 100 auto auto 10/100/1000BaseTX
Gi1/0/17 notconnect 100 auto auto 10/100/1000BaseTX
Gi1/0/18 notconnect 100 auto auto 10/100/1000BaseTX
Gi1/0/19 notconnect 100 auto auto 10/100/1000BaseTX
Gi1/0/20 notconnect 100 auto auto 10/100/1000BaseTX
Gi1/0/21 notconnect 100 auto auto 10/100/1000BaseTX
Gi1/0/22 notconnect 1 auto auto 10/100/1000BaseTX
Gi1/0/23 notconnect 205 auto auto 10/100/1000BaseTX
Gi1/0/24 UniFi connected trunk a-full a-100 10/100/1000BaseTX
Gi1/0/25 notconnect 1 auto auto Not Present
Gi1/0/26 notconnect 1 auto auto Not Present
Gi1/0/27 notconnect 1 auto auto Not Present
Gi1/0/28 notconnect 1 auto auto Not Present
Fa0 notconnect routed auto auto 10/100BaseTX
问题切换sh interfaces trunk
:
Port Mode Encapsulation Status Native vlan
Gi1/0/1 on 802.1q trunking 1
Gi1/0/7 on 802.1q trunking 1
Gi1/0/24 on 802.1q trunking 200
Port Vlans allowed on trunk
Gi1/0/1 1-4094
Gi1/0/7 1-4094
Gi1/0/24 1-4094
Port Vlans allowed and active in management domain
Gi1/0/1 1,98-111,200-215,300
Gi1/0/7 1,98-111,200-215,300
Gi1/0/24 1,98-111,200-215,300
Port Vlans in spanning tree forwarding state and not pruned
Gi1/0/1 1,98-111,200-215,300
Gi1/0/7 1,98-111,200-215,300
Gi1/0/24 1,98-111,200-215,300
MDF Gi1/0/20(问题交换机上与Gi1/0/1的连接):
sh interfaces trunk
Port Mode Encapsulation Status Native vlan
Gi1/0/20 on 802.1q trunking 1
Port Vlans allowed on trunk
Gi1/0/20 1-4094
Port Vlans allowed and active in management domain
Gi1/0/20 1,98-111,200-215,300
Port Vlans in spanning tree forwarding state and not pruned
Gi1/0/20 1,98-111,200-215,300
sh run
!
interface GigabitEthernet1/0/20
description ProblemSwitch gi1/0/1
switchport mode trunk
!
STP信息
问题切换
sh spanning-tree vlan 200
VLAN0200
Spanning tree enabled protocol ieee
Root ID Priority 24683
Address b4a4.e322.7500
Cost 19
Port 1 (GigabitEthernet1/0/1)
Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec
Bridge ID Priority 32875 (priority 32768 sys-id-ext 200)
Address b4a4.e313.2480
Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec
Aging Time 300 sec
Interface Role Sts Cost Prio.Nbr Type
------------------- ---- --- --------- -------- --------------------------------
Gi1/0/1 Root FWD 19 128.1 P2p
Gi1/0/7 Desg FWD 19 128.7 P2p
Gi1/0/24 Desg FWD 19 128.24 P2p
sh spanning-tree interface gi1/0/1
Vlan Role Sts Cost Prio.Nbr Type
------------------- ---- --- --------- -------- --------------------------------
VLAN0001 Root FWD 19 128.1 P2p
VLAN0098 Root FWD 19 128.1 P2p
VLAN0099 Root FWD 19 128.1 P2p
VLAN0100 Root FWD 19 128.1 P2p
VLAN0101 Root FWD 19 128.1 P2p
VLAN0102 Root FWD 19 128.1 P2p
VLAN0103 Root FWD 19 128.1 P2p
VLAN0104 Root FWD 19 128.1 P2p
VLAN0105 Root FWD 19 128.1 P2p
VLAN0106 Root FWD 19 128.1 P2p
VLAN01.1 Root FWD 19 128.1 P2p
VLAN0108 Root FWD 19 128.1 P2p
VLAN0109 Root FWD 19 128.1 P2p
VLAN0110 Root FWD 19 128.1 P2p
VLAN0111 Root FWD 19 128.1 P2p
VLAN0200 Root FWD 19 128.1 P2p
VLAN0201 Root FWD 19 128.1 P2p
VLAN0205 Root FWD 19 128.1 P2p
VLAN0211 Root FWD 19 128.1 P2p
VLAN0300 Root FWD 19 128.1 P2p
中密度纤维板开关
sh spanning-tree vlan 200
VLAN0200
Spanning tree enabled protocol rstp
Root ID Priority 24683
Address b4a4.e322.7500
This bridge is the root
Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec
Bridge ID Priority 24683 (priority 24576 sys-id-ext 200)
Address b4a4.e322.7500
Hello Time 2 sec Max Age 20 sec Forward Delay 15 sec
Aging Time 300 sec
Interface Role Sts Cost Prio.Nbr Type
------------------- ---- --- --------- -------- --------------------------------
Gi2/0/1 Desg FWD 4 128.55 P2p Edge
Gi2/0/2 Desg FWD 4 128.56 P2p Edge
Gi2/0/3 Desg FWD 4 128.57 P2p Edge
Gi2/0/12 Desg FWD 4 128.66 P2p Peer(STP)
Gi2/0/13 Desg FWD 4 128.67 P2p
Gi2/0/18 Desg FWD 19 128.72 P2p Peer(STP)
Gi2/0/24 Desg FWD 19 128.78 P2p
Gi2/0/25 Desg FWD 4 128.79 P2p
Interface Role Sts Cost Prio.Nbr Type
------------------- ---- --- --------- -------- --------------------------------
Gi2/0/26 Desg FWD 4 128.80 P2p Peer(STP)
Gi1/0/1 Desg FWD 4 128.1 P2p Edge
Gi1/0/2 Desg FWD 4 128.2 P2p Edge
Gi1/0/3 Desg FWD 4 128.3 P2p Edge
Gi1/0/20 Desg FWD 19 128.20 P2p Peer(STP)
Gi1/0/21 Desg FWD 19 128.21 P2p Peer(STP)
Gi1/0/22 Desg FWD 4 128.22 P2p
Gi1/0/24 Desg FWD 4 128.24 P2p
Gi1/0/25 Desg FWD 4 128.25 P2p Peer(STP)
Gi3/0/1 Desg FWD 4 128.109 P2p Edge
Gi3/0/2 Desg FWD 4 128.110 P2p Edge
Gi3/0/3 Desg FWD 4 128.111 P2p Edge
sh spanning-tree interface gi1/0/20
Vlan Role Sts Cost Prio.Nbr Type
------------------- ---- --- --------- -------- --------------------------------
VLAN0001 Desg FWD 19 128.20 P2p Peer(STP)
VLAN0098 Desg FWD 19 128.20 P2p Peer(STP)
VLAN0099 Desg FWD 19 128.20 P2p Peer(STP)
VLAN0100 Desg FWD 19 128.20 P2p Peer(STP)
VLAN0101 Desg FWD 19 128.20 P2p Peer(STP)
VLAN0102 Desg FWD 19 128.20 P2p Peer(STP)
VLAN0103 Desg FWD 19 128.20 P2p Peer(STP)
VLAN0104 Desg FWD 19 128.20 P2p Peer(STP)
VLAN0105 Desg FWD 19 128.20 P2p Peer(STP)
VLAN0106 Desg FWD 19 128.20 P2p Peer(STP)
VLAN0107 Desg FWD 19 128.20 P2p Peer(STP)
VLAN0108 Desg FWD 19 128.20 P2p Peer(STP)
VLAN0109 Desg FWD 19 128.20 P2p Peer(STP)
VLAN0110 Desg FWD 19 128.20 P2p Peer(STP)
VLAN0111 Desg FWD 19 128.20 P2p Peer(STP)
VLAN0200 Desg FWD 19 128.20 P2p Peer(STP)
VLAN0201 Desg FWD 19 128.20 P2p Peer(STP)
VLAN0205 Desg FWD 19 128.20 P2p Peer(STP)
VLAN0211 Desg FWD 19 128.20 P2p Peer(STP)
VLAN0300 Desg FWD 19 128.20 P2p Peer(STP)
我可以毫无问题地从交换机 ping 网关和服务器。在静态分配的 IP 和 DNS 不在本机 VLAN 上的计算机上,我无法 ping 计算机名称,但可以 ping IP 地址。通过分配本地 VLAN ip,我可以 ping 计算机名称。
有人可以帮助弄清楚为什么我无法从这台交换机后面获得 DHCP 地址吗?
编辑:包括整个消毒配置。