命令
配置
VLAN命令
vlan dot1q tag native 在trunk链路上携带nativeVLAN的tag
VLAN的配置
- access配置
- int 接口
- swithport mode access
- swithport access vlan 10
- trunk配置
- int 接口
- switchport trunk encapsulation dot1q
- switchport mode trunk
- switchport trunk allowed vlan none 拒绝所有
- switchport trunk allowed vlan add (1-10、22,33,44,55)
- DTP
- DA:switchport mode dynamic auto
- 接口不会主动发送DTP消息,但是当收到对方发送的dtp消息,可以返回DTP消息。接口接收到DTP消息,该接口可以成为trunk。
- DD:switchport mode dynamic desirable
- 接口可以主动发送dtp消息,但是必须接收到对方发送