- 积分
- 186
- 鸿鹄币
- 个
- 好评度
- 点
- 精华
- 注册时间
- 2016-6-4
- 最后登录
- 1970-1-1
- 阅读权限
- 20
- 听众
- 收听
助理工程师
|
3鸿鹄币
这个模拟器高大上,模拟PC就跟虚拟机一样就是WIN7的画面,内存根本不够用,暂时用路由代替,配完后发现路由(PC1)192.168.1.1 能 ping通网关路由 R1(192.168.1.254),另一端相同,但PC1无法ping通PC2
PC1 划分为VLAN10 PC2划分为VLAN20 ,R1路由 e/2 trunk ,剩下2个都是access
既然PC到网关能通 trunk应该没问题,难道单臂路由配置有误?麻烦各位大神帮小弟指点下迷津
拓扑图:
R1单臂路由配置:
Router(config)#interface e0/0
Router(config-if)#no shutdown
*May 29 00:43:01.829: %LINK-3-UPDOWN: Interface Ethernet0/0, changed state to up
*May 29 00:43:02.838: %LINEPROTO-5-UPDOWN: Line protocol on Interface Ethernet0/0, changed state to up
Router(config-if)#exit
Router(config)#interface e0/0.10
Router(config-subif)#encapsulation do
Router(config-subif)#encapsulation dot1Q 10
Router(config-subif)#ip add
Router(config-subif)#ip address 192.168.1.254 255.255.255.0
Router(config-subif)#no shutdown
Router(config)#inter
Router(config)#interface e0/0.20
Router(config-subif)#en
Router(config-subif)#encapsulation do
Router(config-subif)#encapsulation dot1Q 20
Router(config-subif)#ip add
Router(config-subif)#ip address 192.168.2.254 255.255.255.0
Router(config-subif)#no shu
Router(config-subif)#no shutdown
SW1配置:
Switch(config)#vlan 10
Switch(config-vlan)#name student
Switch(config-vlan)#exit
Switch(config)#vlan 20
Switch(config-vlan)#name teacher
Switch(config)#interface e0/0
Switch(config-if)#switchport mode access
Switch(config-if)#switchport access vlan 10
Switch(config-if)#exit
Switch(config)#interface e0/1
Switch(config-if)#switchport mode access
Switch(config-if)#switchport access vlan 20
Switch(config-if)#exit
Switch(config)#inter
Switch(config)#interface e0/2
Switch(config-if)#switchport trunk encapsulation dot1q
Switch(config-if)#switchport mode trunk
*May 29 00:41:41.871: %LINEPROTO-5-UPDOWN: Line protocol on Interface Ethernet0/2, changed state to down
Switch(config-if)#switchport tr
Switch(config-if)#switchport trunk
*May 29 00:41:43.901: %LINEPROTO-5-UPDOWN: Line protocol on Interface Ethernet0/2, changed state to up
Switch(config-if)#switchport trunk allowed vlan all
Switch(config-if)#exit
如果哪里写的不对尽管说,不要留面子
|
最佳答案
查看完整内容
我只是猜测啊你弄你pc的路由器没加网关 你试试 no ip routing 然后 ip default-gateway 加上各自子接口那个地址试试
|