• 产品与解决方案
  • 行业解决方案
  • 服务
  • 支持
  • 合作伙伴
  • 新华三人才研学中心
  • 关于我们

H3C低端以太网交换机 典型配置指导(V1.01)

05-GVRP典型配置指导

本章节下载  (135.71 KB)

docurl=/cn/Service/Document_Software/Document_Center/Switches/Catalog/E/E328[E352]/Configure/Typical_Configuration_Example/E328[E352]_Typical_Configuration_Example(V1.01)/200808/614425_30005_0.htm

05-GVRP典型配置指导


 

第1章  GVRP典型配置指导

1.1  GVRP典型配置指导

通过使用GVRP,可以使同一局域网内的交换机接收来自其它交换机的VLAN注册信息,并动态更新本地的VLAN注册信息,包括:当前的VLAN、这些VLAN可以通过哪个端口到达等。而且设备能够将本地的VLAN注册信息向其它设备传播,使同一局域网内所有设备的VLAN信息达成一致,减少人工配置的工作量。

1.1.1  组网图

图1-1 GVRP组网示意图

1.1.2  应用要求

l              组网情况如上图所示,所有交换机均为S3600以太网交换机。

l              交换机上涉及的以太网端口均配置为Trunk端口,且允许所有VLAN通过;

l              所有交换机均开启全局GVRP和端口GVRP功能;

l              SwitchC配置静态VLAN5,SwitchD 配置静态VLAN8,SwitchE配置静态VLAN5和VLAN7,SwitchA和SwitchB未进行静态VLAN的配置;

l              配置SwitchE的以太网端口Ethernet1/0/1的注册模式为Fixed,显示SwitchA、SwitchB和SwitchE上动态注册的VLAN信息;

l              配置SwitchE的以太网端口Ethernet1/0/1的注册模式为Forbidden,显示SwitchA、SwitchB和SwitchE上动态注册的VLAN信息。

1.1.3  适用产品、版本

表1-1 配置适用的交换机产品与软硬件版本关系

产品

软件版本

硬件版本

S5600系列

Release 1510、Release 1602软件版本

全系列硬件版本

S5100-SI/EI系列

Release 2200、Release 2201软件版本

全系列硬件版本

S3600-SI/EI系列

Release 1510、Release 1602软件版本

全系列硬件版本

S3100-EI系列

Release 2104、Release 2107软件版本

全系列硬件版本

S3100-C-SI系列

S3100-T-SI系列

Release 0011、Release 2102、Release 2107软件版本

全系列硬件版本

S3100-TP-SI系列

Release 2102、Release 2107软件版本

全系列硬件版本

(除S3100-52TP-SI)

S3100-52TP-SI

Release 2106、Release 2107软件版本

S3100-52TP-SI

S3100-52P

Release 1500、Release 1602软件版本

S3100-52P

S2126-EI

Release 2102、Release 2106、Release 2107软件版本

S2126-EI

S2000-EA系列

Release 2107软件版本

全系列硬件版本

E352&E328

Release 1510、Release 1602软件版本

E352&E328

E152

Release 1500、Release 1602软件版本

E152

E126

Release 0011、Release 2102、Release 2107软件版本

E126

E126A

Release 2104 、Release 2107软件版本

E126A

 

1.1.4  配置过程和解释

l              配置SwitchA

# 开启全局GVRP。

<SwitchA> system-view

[SwitchA] gvrp

# 将以太网端口Ethernet1/0/1配置为Trunk端口,并允许所有VLAN通过。

[SwitchA] interface Ethernet 1/0/1

[SwitchA-Ethernet1/0/1] port link-type trunk

[SwitchA-Ethernet1/0/1] port trunk permit vlan all

# 在以太网端口Ethernet1/0/1上开启GVRP。

[SwitchA-Ethernet1/0/1] gvrp

[SwitchA-Ethernet1/0/1] quit

# 将以太网端口Ethernet1/0/2配置为Trunk端口,并允许所有VLAN通过。

[SwitchA] interface Ethernet 1/0/2

[SwitchA-Ethernet1/0/2] port link-type trunk

[SwitchA-Ethernet1/0/2] port trunk permit vlan all

# 在以太网端口Ethernet1/0/2上开启GVRP。

[SwitchA-Ethernet1/0/2] gvrp

[SwitchA-Ethernet1/0/2] quit

# 将以太网端口Ethernet1/0/3配置为Trunk端口,并允许所有VLAN通过。

[SwitchA] interface Ethernet 1/0/3

[SwitchA-Ethernet1/0/3] port link-type trunk

[SwitchA-Ethernet1/0/3] port trunk permit vlan all

# 在以太网端口Ethernet1/0/3上开启GVRP。

[SwitchA-Ethernet1/0/3] gvrp

[SwitchA-Ethernet1/0/3] quit

l              配置SwitchB

# 配置Ethernet1/0/1和Ethernet1/0/2端口为Trunk端口,允许所有VLAN通过;并开启全局和以上两个端口的GVRP功能。配置过程可参见SwitchA的配置。

l              配置SwitchC

# 创建VLAN 5

<SwitchC> system-view

[SwitchC] vlan5

[SwitchC-vlan5]

# 配置Ethernet1/0/1端口为Trunk端口,允许所有VLAN通过,并开启全局和该端口的GVRP功能。配置过程可参见SwitchA的配置。

&  说明:

为避免重复,以下设备的配置只描述配置要点,具体配置命令可参考上述设备的配置。

 

l              配置SwitchD

# 配置Ethernet1/0/1端口为Trunk端口,允许所有VLAN通过;同时开启全局和该端口的GVRP功能。

# 创建VLAN8

l              配置SwitchE

# 配置Ethernet1/0/1端口为Trunk端口,允许所有VLAN通过;同时开启全局和该端口的GVRP功能。

# 创建VLAN5VLAN7

l              显示SwitchASwitchBSwitchE上动态注册的VLAN信息。

# 显示SwitchA上的动态VLAN信息。

[SwitchA] display vlan dynamic

 Total 3 dynamic VLAN exist(s).

 The following dynamic VLANs exist:

  5, 7, 8,

# 显示SwitchB上的动态VLAN信息。

[SwitchB] display vlan dynamic

 Total 3 dynamic VLAN exist(s).

 The following dynamic VLANs exist:

  5, 7, 8,

# 显示SwitchE上的动态VLAN信息。

[SwitchE] display vlan dynamic

 Total 1 dynamic VLAN exist(s).

 The following dynamic VLANs exist:

8

可以看到,SwitchA和SwitchB上已经注册了用户在SwitchE上静态创建的VLAN7,且SwitchE能够正常注册由SwitchB传播来的VLAN8。

l              配置SwitchE的以太网端口Ethernet1/0/1的注册模式为fixed,即禁止端口动态注册VLAN,仅允许本地创建的VLAN向外传播。显示SwitchA、SwitchB和SwitchE上动态注册的VLAN信息。

# 配置SwitchE的以太网端口Ethernet1/0/1的注册模式为fixed。

[SwitchE] interface Ethernet 1/0/1

[SwitchE-Ethernet1/0/1] gvrp registration fixed

# 显示SwitchA上的动态VLAN信息。

[SwitchA] display vlan dynamic

 Total 3 dynamic VLAN exist(s).

 The following dynamic VLANs exist:

  5, 7, 8,

# 显示SwitchB上的动态VLAN信息。

[SwitchB] display vlan dynamic

 Total 3 dynamic VLAN exist(s).

 The following dynamic VLANs exist:

  5, 7, 8,

# 显示SwitchE上的动态VLAN信息。

[SwitchE-Ethernet1/0/1] display vlan dynamic

No dynamic vlans exist!

可以看到,SwitchA和SwitchB上已经注册了用户在SwitchE上静态创建的VLAN7,但SwitchE无法注册由SwitchB传播来的VLAN8。

l              配置SwitchE的以太网端口Ethernet1/0/1的注册模式为forbidden,显示SwitchA、SwitchB和SwitchE上动态注册的VLAN信息。

# 配置SwitchE的以太网端口Ethernet1/0/1的注册模式为forbidden,即禁止端口动态注册VLAN,仅允许缺省VLAN1向外传播。

[SwitchE-Ethernet1/0/1] gvrp registration forbidden

# 显示SwitchA上的动态VLAN信息。

[SwitchA] display vlan dynamic

 Total 2 dynamic VLAN exist(s).

 The following dynamic VLANs exist:

  5, 8,

# 显示SwitchB上的动态VLAN信息。

[SwitchB] display vlan dynamic

 Total 2 dynamic VLAN exist(s).

 The following dynamic VLANs exist:

  5, 8,

# 显示SwitchE上的动态VLAN信息。

[SwitchE] display vlan dynamic

No dynamic vlans exist!

可以看到,SwitchA和SwitchB上均没有注册VLAN7,且SwitchE上也不能注册由SwitchB传播来的VLAN8。

1.1.5  完整配置

l              SwitchA上的配置

#

 gvrp

#

interface Ethernet1/0/1

 port link-type trunk

 port trunk permit vlan all

 gvrp

#

interface Ethernet1/0/2

 port link-type trunk

 port trunk permit vlan all

 gvrp

#

interface Ethernet1/0/3

 port link-type trunk

 port trunk permit vlan all

 gvrp                          

l              SwitchB上的配置

#

 gvrp

#

interface Ethernet1/0/1

 port link-type trunk

 port trunk permit vlan all

 gvrp

#

interface Ethernet1/0/2

 port link-type trunk

 port trunk permit vlan all

 gvrp

l              SwitchC上的配置

#

 gvrp

#

vlan 5

#

interface Ethernet1/0/1

 port link-type trunk

 port trunk permit vlan all

 gvrp

l              SwitchD上的配置

#

 gvrp

#

vlan 8

#

interface Ethernet1/0/1

 port link-type trunk

 port trunk permit vlan all

 gvrp

l              SwitchE上的配置

#

 gvrp

#

vlan 5

#

vlan 7

#

interface Ethernet1/0/1

 port link-type trunk

 port trunk permit vlan all

 gvrp registration forbidden

 gvrp

1.1.6  配置注意事项

l              port trunk permit vlan all命令只在GVRP功能配置过程中是必须执行的,在没有配置GVRP的情况下,建议用户不要使用该命令,以防止未授权VLAN的用户通过该端口访问受限资源。

l              开启端口GVRP功能前,必须先开启全局GVRP功能。

l              需要启动GVRP的端口必须为Trunk端口,而且在该端口上开启GVRP后,交换机不允许用户改变端口的Trunk类型为其他类型。

 

不同款型规格的资料略有差异, 详细信息请向具体销售和400咨询。H3C保留在没有任何通知或提示的情况下对资料内容进行修改的权利!

新华三官网
联系我们