我的问题是,当我尝试使用 DHCP 服务器提供 IP 地址时,它提供的 IP 地址是 DHCP 服务器的默认网关,它只向一台 PC 提供 IP 地址,其余的 PC 我得到了错误 DHCP 失败 APIPA 正在使用
非常感谢所有帮助将不胜感激
路由器配置:
Current configuration : 2394 bytes
!
version 12.4
no service timestamps log datetime msec
no service timestamps debug datetime msec
no service password-encryption
!
hostname HQ
!
!
!
enable secret 5 $1$mERr$GvDaTJK9lhdXRUPWKA74O0
!
!
!
!
!
!
no ip cef
ipv6 unicast-routing
!
no ipv6 cef
!
!
!
username isp password 0 isppassword
!
!
!
!
!
!
!
!
ip ssh version 2
ip domain-name ccnars.com
!
!
spanning-tree mode pvst
!
!
!
!
!
!
interface FastEthernet0/0
no ip address
duplex auto
speed auto
!
interface FastEthernet0/0.9
encapsulation dot1Q 9
ip address 172.16.1.41 255.255.255.248
!
interface FastEthernet0/0.10
encapsulation dot1Q 10
ip address 172.16.1.33 255.255.255.248
!
interface FastEthernet0/0.15
encapsulation dot1Q 15
ip address 172.16.1.17 255.255.255.240
!
interface FastEthernet0/0.20
encapsulation dot1Q 20
ip address 172.16.1.1 255.255.255.240
!
interface FastEthernet0/0.25
encapsulation dot1Q 25
ip address 172.16.0.241 255.255.255.240
!
interface FastEthernet0/0.30
encapsulation dot1Q 30
ip address 172.16.0.225 255.255.255.240
!
interface FastEthernet0/0.40
encapsulation dot1Q 40
ip address 172.16.0.193 255.255.255.224
!
interface FastEthernet0/0.45
encapsulation dot1Q 45
ip address 172.16.0.161 255.255.255.224
!
interface FastEthernet0/0.50
encapsulation dot1Q 50
ip address 172.16.0.129 255.255.255.224
!
interface FastEthernet0/0.55
encapsulation dot1Q 55
ip address 172.16.0.97 255.255.255.224
ip helper-address 172.16.0.99
!
interface FastEthernet0/0.60
encapsulation dot1Q 60
ip address 172.16.0.65 255.255.255.224
ip helper-address 172.16.0.99
!
interface FastEthernet0/0.65
encapsulation dot1Q 1 native
ip address 172.16.0.1 255.255.255.192
ip helper-address 172.16.0.99
!
interface FastEthernet0/1
no ip address
duplex auto
speed auto
shutdown
!
interface Serial0/0/0
no ip address
clock rate 2000000
shutdown
!
interface Serial0/0/1
no ip address
clock rate 2000000
shutdown
!
interface Serial0/1/0
ip address 122.49.0.129 255.255.255.224
ipv6 address 2000:ACAD:2017:0:7A31::129/94
ipv6 enable
!
interface Serial0/1/1
no ip address
clock rate 2000000
shutdown
!
interface Vlan1
no ip address
shutdown
!
ip classless
ip route 0.0.0.0 0.0.0.0 122.49.0.130
!
ip flow-export version 9
!
ipv6 route ::/0 2000:ACAD:2017:0:7A31::130
!
!
!
!
!
!
line con 0
password password
login
!
line aux 0
!
line vty 0 3
login local
line vty 4
login
!
!
!
end
连接到路由器的 L3 交换机的配置:
Current configuration : 2126 bytes
!
version 12.2
no service timestamps log datetime msec
no service timestamps debug datetime msec
no service password-encryption
!
hostname Switch
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
spanning-tree mode pvst
!
!
!
!
!
!
interface FastEthernet0/1
switchport trunk encapsulation dot1q
switchport mode trunk
duplex full
speed 100
!
interface FastEthernet0/2
switchport trunk encapsulation dot1q
switchport mode trunk
duplex full
speed 100
!
interface FastEthernet0/3
switchport trunk encapsulation dot1q
switchport mode trunk
duplex full
speed 100
!
interface FastEthernet0/4
switchport trunk encapsulation dot1q
switchport mode trunk
duplex full
speed 100
!
interface FastEthernet0/5
duplex full
speed 100
!
interface FastEthernet0/6
duplex full
speed 100
!
interface FastEthernet0/7
duplex full
speed 100
!
interface FastEthernet0/8
duplex full
speed 100
!
interface FastEthernet0/9
duplex full
speed 100
!
interface FastEthernet0/10
duplex full
speed 100
!
interface FastEthernet0/11
duplex full
speed 100
!
interface FastEthernet0/12
duplex full
speed 100
!
interface FastEthernet0/13
duplex full
speed 100
!
interface FastEthernet0/14
duplex full
speed 100
!
interface FastEthernet0/15
duplex full
speed 100
!
interface FastEthernet0/16
duplex full
speed 100
!
interface FastEthernet0/17
duplex full
speed 100
!
interface FastEthernet0/18
duplex full
speed 100
!
interface FastEthernet0/19
duplex full
speed 100
!
interface FastEthernet0/20
duplex full
speed 100
!
interface FastEthernet0/21
duplex full
speed 100
!
interface FastEthernet0/22
duplex full
speed 100
!
interface FastEthernet0/23
duplex full
speed 100
!
interface FastEthernet0/24
duplex full
speed 100
!
interface GigabitEthernet0/1
switchport trunk encapsulation dot1q
switchport mode trunk
!
interface GigabitEthernet0/2
!
interface Vlan1
no ip address
shutdown
!
interface Vlan50
mac-address 0090.0cb3.9901
ip address 172.16.0.132 255.255.255.224
!
ip default-gateway 172.16.0.129
ip classless
!
ip flow-export version 9
!
!
!
!
!
!
!
line con 0
!
line aux 0
!
line vty 0 4
login
!
!
!
end
L2交换机中间的L3交换机配置:
Building configuration...
Current configuration : 2065 bytes
!
version 12.2
no service timestamps log datetime msec
no service timestamps debug datetime msec
no service password-encryption
!
hostname Switch
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
spanning-tree mode pvst
!
!
!
!
!
!
interface FastEthernet0/1
switchport trunk encapsulation dot1q
switchport mode trunk
duplex full
speed 100
!
interface FastEthernet0/2
switchport trunk encapsulation dot1q
switchport mode trunk
duplex full
speed 100
!
interface FastEthernet0/3
switchport trunk encapsulation dot1q
switchport mode trunk
duplex full
speed 100
!
interface FastEthernet0/4
switchport trunk encapsulation dot1q
switchport mode trunk
duplex full
speed 100
!
interface FastEthernet0/5
duplex full
speed 100
!
interface FastEthernet0/6
duplex full
speed 100
!
interface FastEthernet0/7
duplex full
speed 100
!
interface FastEthernet0/8
duplex full
speed 100
!
interface FastEthernet0/9
duplex full
speed 100
!
interface FastEthernet0/10
duplex full
speed 100
!
interface FastEthernet0/11
duplex full
speed 100
!
interface FastEthernet0/12
duplex full
speed 100
!
interface FastEthernet0/13
duplex full
speed 100
!
interface FastEthernet0/14
duplex full
speed 100
!
interface FastEthernet0/15
duplex full
speed 100
!
interface FastEthernet0/16
duplex full
speed 100
!
interface FastEthernet0/17
duplex full
speed 100
!
interface FastEthernet0/18
duplex full
speed 100
!
interface FastEthernet0/19
duplex full
speed 100
!
interface FastEthernet0/20
duplex full
speed 100
!
interface FastEthernet0/21
duplex full
speed 100
!
interface FastEthernet0/22
duplex full
speed 100
!
interface FastEthernet0/23
duplex full
speed 100
!
interface FastEthernet0/24
duplex full
speed 100
!
interface GigabitEthernet0/1
!
interface GigabitEthernet0/2
!
interface Vlan1
no ip address
shutdown
!
interface Vlan50
mac-address 0001.647d.b301
ip address 172.16.0.132 255.255.255.224
!
ip default-gateway 172.16.0.129
ip classless
!
ip flow-export version 9
!
!
!
!
!
!
!
line con 0
!
line aux 0
!
line vty 0 4
login
!
!
!
end
L2 交换机的配置:
urrent configuration : 2999 bytes
!
version 12.2
no service timestamps log datetime msec
no service timestamps debug datetime msec
no service password-encryption
!
hostname Switch
!
!
!
!
!
spanning-tree mode pvst
!
interface FastEthernet0/1
switchport mode trunk
duplex full
speed 100
!
interface FastEthernet0/2
switchport access vlan 65
switchport mode access
duplex full
speed 100
!
interface FastEthernet0/3
switchport access vlan 60
switchport mode access
duplex full
speed 100
!
interface FastEthernet0/4
switchport access vlan 60
switchport mode access
duplex full
speed 100
!
interface FastEthernet0/5
switchport access vlan 50
switchport mode access
duplex full
speed 100
!
interface FastEthernet0/6
switchport access vlan 50
switchport mode access
duplex full
speed 100
!
interface FastEthernet0/7
switchport access vlan 45
switchport mode access
duplex full
speed 100
!
interface FastEthernet0/8
switchport access vlan 45
switchport mode access
duplex full
speed 100
!
interface FastEthernet0/9
switchport access vlan 40
switchport mode access
duplex full
speed 100
!
interface FastEthernet0/10
switchport access vlan 40
switchport mode access
duplex full
speed 100
!
interface FastEthernet0/11
switchport access vlan 30
switchport mode access
duplex full
speed 100
!
interface FastEthernet0/12
switchport access vlan 30
switchport mode access
duplex full
speed 100
!
interface FastEthernet0/13
switchport access vlan 25
switchport mode access
duplex full
speed 100
!
interface FastEthernet0/14
switchport access vlan 25
switchport mode access
duplex full
speed 100
!
interface FastEthernet0/15
switchport access vlan 20
switchport mode access
duplex full
speed 100
!
interface FastEthernet0/16
switchport access vlan 20
switchport mode access
duplex full
speed 100
!
interface FastEthernet0/17
switchport access vlan 15
switchport mode access
duplex full
speed 100
!
interface FastEthernet0/18
switchport access vlan 15
switchport mode access
duplex full
speed 100
!
interface FastEthernet0/19
switchport access vlan 10
switchport mode access
duplex full
speed 100
!
interface FastEthernet0/20
switchport access vlan 10
switchport mode access
duplex full
speed 100
!
interface FastEthernet0/21
switchport access vlan 9
switchport mode access
duplex full
speed 100
!
interface FastEthernet0/22
switchport access vlan 9
switchport mode access
duplex full
speed 100
!
interface FastEthernet0/23
switchport access vlan 55
switchport mode access
duplex full
speed 100
!
interface FastEthernet0/24
switchport access vlan 55
switchport mode access
duplex full
speed 100
!
interface GigabitEthernet0/1
!
interface GigabitEthernet0/2
!
interface Vlan1
no ip address
shutdown
!
interface Vlan50
mac-address 00d0.ba6d.a901
ip address 172.16.0.129 255.255.255.224
!
interface Vlan65
mac-address 00d0.ba6d.a902
no ip address
!
ip default-gateway 172.16.0.129
!
!
!
!
line con 0
!
line vty 0 4
login
line vty 5 15
login
!
!
!
end
