最佳答案
https://www.h3c.com/cn/d_201903/1157324_30005_0.htm#_Toc487656267
# 创建VLAN 10,配置VLAN接口的IP地址为10.1.1.1/24。
[DeviceA] vlan 10
[DeviceA-vlan10] quit
[DeviceA] interface vlan-interface 10
[DeviceA-Vlan-interface10] ip address 10.1.1.1 255.255.255.0
# 开启设备的本地代理ARP功能。
[DeviceA-Vlan-interface10] local-proxy-arp enable
[DeviceA-Vlan-interface10] quit
# 创建VLAN 2,并添加端口Ten-GigabitEthernet1/0/1和端口Ten-GigabitEthernet1/0/2。
[DeviceA-vlan2] port ten-gigabitethernet 1/0/1 ten-gigabitethernet 1/0/2
[DeviceA-vlan2] quit
# 创建VLAN 3,并添加端口Ten-GigabitEthernet1/0/3和端口Ten-GigabitEthernet1/0/4。
[DeviceA-vlan3] port ten-gigabitethernet 1/0/3 ten-gigabitethernet 1/0/4
[DeviceA-vlan3] quit
# 创建VLAN 5,并添加端口Ten-GigabitEthernet1/0/5和端口Ten-GigabitEthernet1/0/6。
[DeviceA-vlan5] port ten-gigabitethernet 1/0/5 ten-gigabitethernet 1/0/6
[DeviceA-vlan5] quit
# 配置VLAN 10为Super VLAN,其关联的Sub VLAN为VLAN 2、VLAN 3和VLAN 5。
[DeviceA-vlan10] supervlan
[DeviceA-vlan10] subvlan 2 3 5
[DeviceA-vlan10] quit
[DeviceA] quit
(0)
Device A连接不同VLAN用户,其中,端口GigabitEthernet1/0/1和端口GigabitEthernet1/0/2属于VLAN 2,端口GigabitEthernet1/0/3和端口GigabitEthernet1/0/4属于VLAN 3,端口GigabitEthernet1/0/5和端口GigabitEthernet1/0/6属于VLAN 5。
为实现Device A连接的各VLAN用户(均在10.1.1.0/24网段)之间能够满足二层隔离和三层互通的同时,节省IP资源,创建Super VLAN,其关联的Sub VLAN公用Super VLAN interface的IP地址10.1.1.1/24作为三层通信的网关地址。
图2-1 配置Super VLAN组网图
# 创建VLAN 10,配置VLAN接口的IP地址为10.1.1.1/24。
<DeviceA> system-view
[DeviceA] vlan 10
[DeviceA-vlan10] quit
[DeviceA] interface vlan-interface 10
[DeviceA-Vlan-interface10] ip address 10.1.1.1 255.255.255.0
# 开启设备的本地代理ARP功能。
[DeviceA-Vlan-interface10] local-proxy-arp enable
[DeviceA-Vlan-interface10] quit
# 创建VLAN 2,并向VLAN 2中添加端口GigabitEthernet1/0/1和端口GigabitEthernet1/0/2。
[DeviceA] vlan 2
[DeviceA-vlan2] port gigabitethernet 1/0/1 gigabitethernet 1/0/2
[DeviceA-vlan2] quit
# 创建VLAN 3,并向VLAN 3中添加端口GigabitEthernet1/0/3和端口GigabitEthernet1/0/4。
[DeviceA] vlan 3
[DeviceA-vlan3] port gigabitethernet 1/0/3 gigabitethernet 1/0/4
[DeviceA-vlan3] quit
# 创建VLAN 5,并向VLAN 5中添加端口GigabitEthernet1/0/5和端口GigabitEthernet1/0/6。
[DeviceA] vlan 5
[DeviceA-vlan5] port gigabitethernet 1/0/5 gigabitethernet 1/0/6
[DeviceA-vlan5] quit
# 配置VLAN 10为Super VLAN,其关联的Sub VLAN为VLAN 2、VLAN 3和VLAN 5。
[DeviceA] vlan 10
[DeviceA-vlan10] supervlan
[DeviceA-vlan10] subvlan 2 3 5
[DeviceA-vlan10] quit
[DeviceA] quit
# 查看Super VLAN的相关信息,验证以上配置是否生效。
<DeviceA> display supervlan
Super VLAN ID: 10
Sub-VLAN ID: 2-3 5
VLAN ID: 10
VLAN type: Static
It is a super VLAN.
Route interface: Configured
Ipv4 address: 10.1.1.1
Ipv4 subnet mask: 255.255.255.0
Description: VLAN 0010
Name: VLAN 0010
Tagged ports: None
Untagged ports: None
VLAN ID: 2
VLAN type: Static
It is a sub-VLAN.
Route interface: Configured
Ipv4 address: 10.1.1.1
Ipv4 subnet mask: 255.255.255.0
Description: VLAN 0002
Name: VLAN 0002
Tagged ports: None
Untagged ports:
GigabitEthernet1/0/1
GigabitEthernet1/0/2
VLAN ID: 3
VLAN type: Static
It is a sub-VLAN.
Route interface: Configured
Ipv4 address: 10.1.1.1
Ipv4 subnet mask: 255.255.255.0
Description: VLAN 0003
Name: VLAN 0003
Tagged ports: None
Untagged ports:
GigabitEthernet1/0/3
GigabitEthernet1/0/4
VLAN ID: 5
VLAN type: Static
It is a sub-VLAN.
Route unterface: Configured
Ipv4 address: 10.1.1.1
Ipv4 subnet mask: 255.255.255.0
Description: VLAN 0005
Name: VLAN 0005
Tagged ports: None
Untagged ports:
GigabitEthernet1/0/5
GigabitEthernet1/0/6
(0)
暂无评论
参考下,我自己归整的
vlan 2
#
vlan 3 to 70
#
vlan 10
supervlan
subvlan 3 to 70 一个主VLAN下包含多个子VLAN,每个子VLAN之间互不通信,但是可以和三层网通信
#
stp global enable
#
interface NULL0
#
interface Vlan-interface2 打印机VLAN
ip address 192.168.2.1 255.255.255.0
#
interface Vlan-interface10 终端VLAN
ip address 192.168.10.1 255.255.254.0 子网掩码根据客户终端数划分
local-proxy-arp enable 开启本地ARP代理
#
interface GigabitEthernet1/0/1
port link-mode bridge
port access vlan 2
#
interface GigabitEthernet1/0/2
port link-mode bridge
port access vlan 3
#
interface GigabitEthernet1/0/3 交换机级联配置,不可以用TRUNK口
port link-mode bridge
port link-type hybrid
port hybrid vlan 2 to 90 tagged
(0)
暂无评论
亲~登录后才可以操作哦!
确定你的邮箱还未认证,请认证邮箱或绑定手机后进行当前操作
举报
×
侵犯我的权益
×
侵犯了我企业的权益
×
抄袭了我的内容
×
原文链接或出处
诽谤我
×
对根叔社区有害的内容
×
不规范转载
×
举报说明
暂无评论