conn :
SW2 e0/0 --- e0/0 SW1 e0/1 --- SW3 e0/0
配置文件 :
----SW1---
SW1#show runn
SW1#show running-config
Building configuration...
Current configuration : 1546 bytes
!
! Last configuration change at 14:41:04 CST Sat Mar 9 2013
!
version 15.1
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
service compress-config
!
hostname SW1
clock timezone CST 8 0
no ipv6 cef
ipv6 multicast rpf use-bgp
no ip domain-lookup
ip cef
spanning-tree mode pvst
spanning-tree extend system-id
vlan internal allocation policy ascending
interface Ethernet0/0
duplex auto
interface Ethernet0/1
duplex auto
!
interface Ethernet0/2
duplex auto
no ip http server
control-plane
line con 0
logging synchronous
line aux 0
line vty 0 4
!
end
SW1#show vtp sta
VTP Version capable : 1 to 3
VTP version running : 2
VTP Domain Name : cisco
VTP Pruning Mode : Disabled
VTP Traps Generation : Disabled
Device ID : 0200.3000.0a00
Configuration last modified by 0.0.0.0 at 3-9-13 06:38:32
Local updater ID is 0.0.0.0 (no valid interface found)
Feature VLAN:
--------------
VTP Operating Mode : Server
Maximum VLANs supported locally : 1005
Number of existing VLANs : 18
Configuration Revision : 14
MD5 digest : 0x80 0x33 0xF8 0xED 0xB2 0xE5 0x27 0x5E
0x47 0x03 0x6B 0xF3 0x8F 0xE9 0xC4 0x7B
SW1#show vlan b
VLAN Name Status Ports
---- -------------------------------- --------- -------------------------------
1 default active Et0/2, Et0/3, Et1/0, Et1/1
Et1/2, Et1/3
2 VLAN0002 active
3 VLAN0003 active
4 VLAN0004 active
5 VLAN0005 active
6 VLAN0006 active
10 VLAN0010 active
11 VLAN0011 active
12 VLAN0012 active
15 VLAN0015 active
100 VLAN0100 active
101 VLAN0101 active
111 VLAN0111 active
1000 VLAN1000 active
1002 fddi-default act/unsup
1003 trcrf-default act/unsup
1004 fddinet-default act/unsup
1005 trbrf-default act/unsup
---SW-2---
SW2# show runn
Building configuration...
Current configuration : 1546 bytes
!
! Last configuration change at 14:56:10 CST Sat Mar 9 2013
!
version 15.1
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
service compress-config
!
hostname SW2
!
no aaa new-model
clock timezone CST 8 0
no ipv6 cef
ipv6 multicast rpf use-bgp
vtp domain cisco
vtp mode transparent
!
no ip domain-lookup
ip cef
!
spanning-tree mode pvst
spanning-tree extend system-id
!
vlan internal allocation policy ascending
!
vlan 10,13,100,111,1000
!
interface Ethernet0/0
duplex auto
no ip http server
!
control-plane
!
!
line con 0
logging synchronous
line aux 0
line vty 0 4
!
end
SW2# show vtp sta
VTP Version capable : 1 to 3
VTP version running : 2
VTP Domain Name : cisco
VTP Pruning Mode : Disabled
VTP Traps Generation : Disabled
Device ID : 0200.3000.0b00
Configuration last modified by 0.0.0.0 at 3-9-13 06:08:06
Feature VLAN:
--------------
VTP Operating Mode : Transparent
Maximum VLANs supported locally : 1005
Number of existing VLANs : 10
Configuration Revision : 0
MD5 digest : 0x0E 0x35 0xBD 0xD7 0xF9 0x9A 0x17 0xC0
0xE2 0x75 0x12 0xDA 0x95 0xB7 0x18 0x9C
SW2#show vlan brief
VLAN Name Status Ports
---- -------------------------------- --------- -------------------------------
1 default active Et0/1, Et0/2, Et0/3, Et1/0
Et1/1, Et1/2, Et1/3
10 VLAN0010 active
13 VLAN0013 active
100 VLAN0100 active
111 VLAN0111 active
1000 VLAN1000 active
1002 fddi-default act/unsup
1003 trcrf-default act/unsup
1004 fddinet-default act/unsup
1005 trbrf-default act/unsup
(SW2 VTP是同步完成vlan 10,13,100,111后从Server改为Transparent)
---SW3---
SW3#show runn
Building configuration...
Current configuration : 1481 bytes
!
! Last configuration change at 14:47:21 CST Sat Mar 9 2013
!
version 15.1
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
service compress-config
!
hostname SW3
no aaa new-model
clock timezone CST 8 0
no ipv6 cef
ipv6 multicast rpf use-bgp
!
no ip domain-lookup
ip cef
spanning-tree mode pvst
spanning-tree extend system-id
!
vlan internal allocation policy ascending
interface Ethernet0/0
duplex auto
!
no ip http server
!
control-plane
!
!
line con 0
logging synchronous
line aux 0
line vty 0 4
!
end
SW3# show vtp sta
VTP Version capable : 1 to 3
VTP version running : 2
VTP Domain Name : cisco
VTP Pruning Mode : Disabled
VTP Traps Generation : Disabled
Device ID : 0200.3000.0c00
Configuration last modified by 0.0.0.0 at 3-9-13 06:38:32
Local updater ID is 0.0.0.0 (no valid interface found)
Feature VLAN:
--------------
VTP Operating Mode : Server
Maximum VLANs supported locally : 1005
Number of existing VLANs : 18
Configuration Revision : 14
MD5 digest : 0x80 0x33 0xF8 0xED 0xB2 0xE5 0x27 0x5E
0x47 0x03 0x6B 0xF3 0x8F 0xE9 0xC4 0x7B
SW3#show vlan brief
VLAN Name Status Ports
---- -------------------------------- --------- -------------------------------
1 default active Et0/1, Et0/2, Et0/3, Et1/0
Et1/1, Et1/2, Et1/3
2 VLAN0002 active
3 VLAN0003 active
4 VLAN0004 active
5 VLAN0005 active
6 VLAN0006 active
10 VLAN0010 active
11 VLAN0011 active
12 VLAN0012 active
15 VLAN0015 active
100 VLAN0100 active
101 VLAN0101 active
111 VLAN0111 active
1000 VLAN1000 active
1002 fddi-default act/unsup
1003 trcrf-default act/unsup
1004 fddinet-default act/unsup
1005 trbrf-default act/unsup
实验总结 :
VTP 版本一致
VTP 域名定义
VLAN 创建
观察VTP修订版本号和VTP数目变化
VTP三种模式 :
修改VTP工作模式会导致VTP修订版本号置0 但VLAN数据不会丢失
VTP工作过程中VLAN传输原理与规则 :
从高版本号的交换机想低版本号的交换机传输 (VTP工作模式为Server/Client)
VTP透明模式在工作过程中版本号和VLAN不发生改变 可创建和修改VLAN
可以提供透明转发其他网络交换机VLAN数据的功能
VTP Server模式在工作过程中版本号会随VLAN的创建修改和VTP模式变换而发生改变
VTP Client模式在工作过程中版本号会随其他交换机的同步数据而发生改变
VLAN由其他交换机传递而创建在本地数据库 此模式并不允许手动创建和修改VLAN数据