Switch>
Switch>ena
Switch>enable
Switch#conf t
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)#vtp domain 1(1是名字自己取)
Switch(config)#vtp password 1(1是密码自己取)
Switch(config)#vtp mode ?
client Set the device to client mode.(客户端模式)
server Set the device to server mode.(服务器模式)
transparent Set the device to transparent mode.(透明模式)(你想要设置成什么模式自己设置)
Switch(config)#int f0/4(2个交换机之间连接的端口做trunk口)
Switch(config-if)#sw mo trunk
在服务器上做下面配置。
Switch(config)#vlan 2
Switch(config-vlan)#exit
Switch(config)#vlan 3
Switch(config-vlan)#int f0/1(vlan1 pc的接口 看你自己接的口是哪个可以改的)
Switch(config-if)#switchport mode access
因为思科的默认vlan是1所以不用划。
Switch(config)#int f0/2(vlan2 pc接口 看你自己接的口是哪个可以改的)
Switch(config-if)#sw mo access
Switch(config-if)#sw acc vlan 2
Switch(config-if)#exit
Switch(config)#int f0/3(vlan3 pc接口 看你自己接的口是哪个可以改的)
Switch(config-if)#sw mo access
Switch(config-if)#sw acc vlan 3
Switch(config-if)#exit