首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >我有两个vlans在同一个路由器上,不能互相切换

我有两个vlans在同一个路由器上,不能互相切换
EN

Network Engineering用户
提问于 2016-05-03 15:09:48
回答 1查看 698关注 0票数 4

我正在使用cisco数据包跟踪程序6.2的学生版本。

我有两个vlans连接到同一个路由器,但它们不能互相切换。这是我的路由器和交换机的配置。

我的路由器:

代码语言:javascript
复制
version 12.4
no service timestamps log datetime msec
no service timestamps debug datetime msec
no service password-encryption
hostname Router
ip dhcp excluded-address 192.168.10.254
ip dhcp excluded-address 192.168.20.254
ip dhcp pool 10
network 192.168.10.0 255.255.255.0
ip dhcp pool 20
network 192.168.20.0 255.255.255.0
ip cef
no ipv6 cef
spanning-tree mode pvst
interface FastEthernet0/0
no ip address
duplex auto
speed auto
interface FastEthernet0/0.10
encapsulation dot1Q 10
ip address 192.168.10.254 255.255.255.0
interface FastEthernet0/0.20
encapsulation dot1Q 20
ip address 192.168.20.254 255.255.255.0
interface FastEthernet0/1
no ip address
duplex auto
speed auto
shutdown
interface Vlan1
no ip address
shutdown
ip classless
ip flow-export version 9
no cdp run
line con 0
line aux 0
line vty 0 4
 login
end

和我的开关:

代码语言:javascript
复制
version 12.1
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 access vlan 10
interface FastEthernet0/2
switchport access vlan 20
interface FastEthernet0/3
switchport mode trunk
ports 4-24 are not configured. 
interface Vlan1
no ip address
shutdown
line con 0
line vty 0 4
login
line vty 5 15
login
end
EN

回答 1

Network Engineering用户

回答已采纳

发布于 2016-05-03 15:20:45

您忘记了DHCP配置中的默认网关。每个泳池都需要一个:

代码语言:javascript
复制
default-router 192.168.x.254
票数 1
EN
页面原文内容由Network Engineering提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://networkengineering.stackexchange.com/questions/30118

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档