实验目的:
1、掌握VTP基本配置。
2、理解VTP的Server、Client模式。
3、理解VTP的管理域、密码、配置版本号。
实验拓扑:
实验步骤:
1、依据图中拓扑部署VTP技术,整个VTP管理域为PingingLab,密码为Cisco,其中SW1为Server,其他交换机为Client,配置如下=>
SW1上配置:
SW1#vlan database SW1(vlan)#vtp server SW1(vlan)#vtp domain PingingLab SW1(vlan)#vtp password Cisco SW1(vlan)#exit
SW2上配置:
SW2#vlan database SW2(vlan)#vtp client SW2(vlan)#vtp domain PingingLab SW2(vlan)#vtp password Cisco SW2(vlan)#exit
SW3上配置:
SW3#vlan database SW3(vlan)#vtp client SW3(vlan)#vtp domain PingingLab SW3(vlan)#vtp password Cisco SW3(vlan)#exit
此时查看VTP信息,如下:
SW1#show vtp status VTP Version : 2 Configuration Revision : 0 Maximum VLANs supported locally : 256 Number of existing VLANs : 5[PL2] VTP Operating Mode : Server VTP Domain Name : PingingLab VTP Pruning Mode : Disabled VTP V2 Mode : Disabled VTP Traps Generation : Disabled MD5 digest : 0x4E 0xC8 0xE0 0x2D 0x31 0x2E 0x45 0x01 Configuration last modified by 0.0.0.0 at 3-1-02 01:22:27 Local updater ID is 0.0.0.0 (no valid interface found)
SW2#show vtp status VTP Version : 2 Configuration Revision : 0 Maximum VLANs supported locally : 256 Number of existing VLANs : 5 VTP Operating Mode : Client VTP Domain Name : PingingLab VTP Pruning Mode : Disabled VTP V2 Mode : Disabled VTP Traps Generation : Disabled MD5 digest : 0x4E 0xC8 0xE0 0x2D 0x31 0x2E 0x45 0x01 Configuration last modified by 0.0.0.0 at 3-1-02 01:22:27
以上可以看出,由于此时Server端未创建VLAN,默认配置版本号都为0。
2、为了使得全网都能学习到VLAN10/20/30,需要在Server创建,配置如下=>
SW1(vlan)#vlan 10 name VLAN_10 SW1(vlan)#vlan 20 name VLAN_20 SW1(vlan)#vlan 30 name VLAN_30 SW1(vlan)#exit
此时查看SW1上VTP信息,如下:
SW1#show vtp status VTP Version : 2 Configuration Revision : 1 Maximum VLANs supported locally : 256 Number of existing VLANs : 8 VTP Operating Mode : Server VTP Domain Name : PingingLab VTP Pruning Mode : Disabled VTP V2 Mode : Disabled VTP Traps Generation : Disabled MD5 digest : 0x46 0xD6 0x5A 0x38 0xF2 0xFD 0xA5 0xE6 Configuration last modified by 0.0.0.0 at 3-1-02 01:39:10 Local updater ID is 0.0.0.0 (no valid interface found)
由于VLAN信息出现变动,所以VTP版本号增加,此时查看其他Client端信息,如下:
SW2#show vtp status VTP Version : 2 Configuration Revision : 1 Maximum VLANs supported locally : 256 Number of existing VLANs : 8 VTP Operating Mode : Client VTP Domain Name : PingingLab VTP Pruning Mode : Disabled VTP V2 Mode : Disabled VTP Traps Generation : Disabled MD5 digest : 0x46 0xD6 0x5A 0x38 0xF2 0xFD 0xA5 0xE6 Configuration last modified by 0.0.0.0 at 3-1-02 01:39:10
可以看到,由于Server端版本号较高,Client端已经从Server端同步VLAN信息,查看VLAN信息,如下:
SW2#show vlan-switch brief VLAN Name Status Ports ---- -------------------------------- --------- ------------------------------- 1 default active Fa0/1, Fa0/3, Fa0/4, Fa0/5 Fa0/6, Fa0/7, Fa0/8, Fa0/9 Fa0/10, Fa0/11, Fa0/12, Fa0/13 Fa0/14, Fa0/15 10 VLAN_10 active 20 VLAN_20 active 30 VLAN_30 active 1002 fddi-default active 1003 token-ring-default active 1004 fddinet-default active 1005 trnet-default active
同样在SW3上查看VLAN信息,如下:
SW3#show vlan-switch brief VLAN Name Status Ports ---- -------------------------------- --------- ------------------------------- 1 default active Fa0/0, Fa0/3, Fa0/4, Fa0/5 Fa0/6, Fa0/7, Fa0/8, Fa0/9 Fa0/10, Fa0/11, Fa0/12, Fa0/13 Fa0/14, Fa0/15 10 VLAN_10 active 20 VLAN_20 active 30 VLAN_30 active 1002 fddi-default active 1003 token-ring-default active 1004 fddinet-default active 1005 trnet-default active
可以看到,通过部署VTP技术,此时VLAN信息全局同步。
3、修改SW2和SW3的管理域或者密码,并在SW1修改VLAN信息,查看VTP同步效果。
SW2上修改域名:
SW2(vlan)#vtp domain PL Changing VTP domain name from PingingLab to PL SW2(vlan)#exit
SW3上修改密码:
SW3(vlan)#vtp password PL Setting device VLAN database password to PL. SW3(vlan)#exit
SW1上修改VLAN:
SW1#vlan database SW1(vlan)#vlan 10 name TEST SW1(vlan)#no vlan 20 SW1(vlan)#exit
此时查看SW1上VLAN信息:
SW1#show vlan-switch brief VLAN Name Status Ports ---- -------------------------------- --------- ------------------------------- 1 default active Fa0/2, Fa0/3, Fa0/4, Fa0/5 Fa0/6, Fa0/7, Fa0/8, Fa0/9 Fa0/10, Fa0/11, Fa0/12, Fa0/13 Fa0/14, Fa0/15 10 TEST active 1002 fddi-default active 1003 token-ring-default active 1004 fddinet-default active 1005 trnet-default active
再次观察SW2和SW3的VLAN信息,如下:
SW2#show vlan-switch brief VLAN Name Status Ports ---- -------------------------------- --------- ------------------------------- 1 default active Fa0/1, Fa0/3, Fa0/4, Fa0/5 Fa0/6, Fa0/7, Fa0/8, Fa0/9 Fa0/10, Fa0/11, Fa0/12, Fa0/13 Fa0/14, Fa0/15 10 VLAN_10 active 20 VLAN_20 active 30 VLAN_30 active 1002 fddi-default active 1003 token-ring-default active 1004 fddinet-default active 1005 trnet-default active
SW3#show vlan-switch brief VLAN Name Status Ports ---- -------------------------------- --------- ------------------------------- 1 default active Fa0/0, Fa0/3, Fa0/4, Fa0/5 Fa0/6, Fa0/7, Fa0/8, Fa0/9 Fa0/10, Fa0/11, Fa0/12, Fa0/13 Fa0/14, Fa0/15 10 VLAN_10 active 20 VLAN_20 active 30 VLAN_30 active 1002 fddi-default active 1003 token-ring-default active 1004 fddinet-default active 1005 trnet-default active
可以看到,由于域名和密码的不一致,所以导致VTP信息无法同步。此实验完成。
- 还没有人评论,欢迎说说您的想法!