我的家庭实验室里有这样的情况

我的cisco 2600路由器只有一个物理接口,所以我把它分成三个子接口
笔记本电脑上的Internet通过以太网电缆工作正常,并从netgear路由器获得有效的ip。
发布于 2014-03-29 12:46:21
若要确认使用什么集群设置,请执行以下操作:
show interfaces trunk我喜欢保持子接口is与VLAN号相匹配,尽管它不是必需的。使用如下配置:
! Switch
! Port to Laptop
interface Fax/x
switchport mode access
switchport access vlan 1
spanning-tree portfast
description Port to PC
! Port to Netgear
interface Fax/x
switchport mode access
switchport access vlan 1
spanning-tree portfast
description Port to Netgear
! Port to Cisco router
interface Fax/x
switchport trunk encapsulation dot1q
switchport mode trunk
spanning-tree portfast trunk
description port to Cisco router对于路由器:
! Router
! Port to switch
interface E0/0.1
encapsulation dot1q 1 native
ip add 192.168.0.70 255.255.255.0
description VLAN1 to Netgear
interface E0/0.10
encapsulation dot1q 10
ip add 192.168.10.70 255.255.255.0
description VLAN10
interface E0/0.20
encapsulation dot1q 20
ip add 192.168.20.70 255.255.255.0
description VLAN20
ip routing
ip route 0.0.0.0 0.0.0.0 192.168.0.1显然,在子网中用您想要的IP替换IP。
发布于 2014-06-04 13:37:39
似乎在连接到默认网关的端口上的开关上存在标记问题。您在端口中指定了允许的vlans吗?尝试添加命令switchport trunk allowed vlan 1,10,20
https://networkengineering.stackexchange.com/questions/7079
复制相似问题