- 积分
- 3787
金币1976
贡献1598
活跃度8
人民币0
UID2
主题213
回帖9
注册时间2023-4-27
最后登录2024-5-20
版主
- 积分
- 3787
|
马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。
您需要 登录 才可以下载或查看,没有账号?请使用中文注册
×
路由器怎么设置 路由器全部怎么安装 路由器怎么设置 路由器亮红灯什么原因 路由器登录入口和光猫的区别 路由器怎么重启 路由器怎么连接 路由器桥接教程详细 路由器干什么用:ensp中路由器如何配置vlan关于cisco路由器vlan配置问题~
一、ensp中路由器如何配置vlan
创建vlan:
[sw1]vlan 10 //创建VLAN10
[sw1-vlan10]vlan 20 //创建VLAN20
配置access:
[sw1]interface Ethernet 0/0/1 //进入以太网接口0/0/1
[sw1-Ethernet0/0/1]port link-type access //配置接口类型为Access
[sw1-Ethernet0/0/1]port default vlan 10 //分配接口给VLAN10
配置trunk:
[sw1]interface Ethernet 0/0/4
[sw1-Ethernet0/0/4]port link-type trunk //配置接口类型为trunk
[sw1-Ethernet0/0/4]port trunk allow-pass vlan 10 20//trunk口允许通过的VLAN
二、关于cisco路由器vlan配置问题~
需要通过单臂路由才能是不同的vlan之间通信,具体配置就是进入子接口中封装802.1Q协议配置vlan的IP地址并且no shutdown
Router(config)#interface f0/0.1
%LINK-5-CHANGED: Interface FastEthernet0/0.1, changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet0/0.1, changed state to upRouter(config-subif)#en
Router(config-subif)#encapsulation do
Router(config-subif)#encapsulation dot1Q ?
<1-1005> IEEE 802.1Q VLAN ID
Router(config-subif)#encapsulation dot1Q 1
Router(config-subif)#ip ad
Router(config-subif)#ip address 192.168.1.1 255.255.255.0
Router(config-subif)#no sh
Router(config-subif)#no shutdown
Router(config-subif)# |
|