在配置三层交换机时

 

当遇到 

    输入 Switch(config-if)#swicthport  mode trunk  想改变端口为trunk 模式时 报出错误

    Command rejected: An interface whose trunk encapsulation is "Auto" can not be configured to "trunk" mode.

     (中文:命令被拒绝:接口的中继封装是“自动”不能被配置的“主干”模式。)

只需要 像单臂路由一样 给端口封装一个  接口封装协议。如下命令

Switch(config-if)#switchport trunk encapsulation dot1q 

 于是就解决问题了 开启了虚拟链路