82By default, the packet format recognition mode of a port is auto. The port automatically distinguishes thetwo MSTP packet formats, and determines the format of packets that it will send based on the recognizedformat.You can configure the MSTP packet format on a port. When working in MSTP mode after theconfiguration, the port sends and receives only MSTP packets of the format that you have configured tocommunicate with devices that send packets of the same format.Follow these steps to configure the MSTP packet format to be supported on a port or a group of ports:To do... Use the command... RemarksEnter system view system-view —Enter Layer 2 Ethernetinterface view or Layer 2aggregate interface viewinterface interface-typeinterface-numberEnterinterfaceview or portgroup view Enter port group view port-group manual port-group-nameRequiredUse either command.Configure the mode that the port uses torecognize/send MSTP packetsstp compliance { auto | dot1s |legacy }Requiredauto by default.NOTE:• MSTP provides MSTP packet format incompatibility guard. In MSTP mode, if a port is configured torecognize/send MSTP packets in a mode other than auto, and if it receives a packet in a format differentfrom the specified type, the port becomes a designated port and remains in the discarding state toprevent the occurrence of a loop.• MSTP provides MSTP packet format frequent change guard. If a port receives MSTP packets of differentformats frequently, the MSTP packet format configuration contains errors. If the port is working in MSTPmode, it will be shut down for protection. Ports disabled in this way can be re-activated after a detectioninterval. For more information about the detection interval, seeFundamentals Configuration Guide.Enabling the output of port state transition informationIn a large-scale spanning tree network, you can enable devices to output the port state transitioninformation of all MSTIs or the specified MSTI in order to monitor the port states in real time.Follow these steps to enable output of port state transition information:To do... Use the command... RemarksEnter system view system-view —Enable output of port state transitioninformation (in STP/RSTP mode) stp port-log instance 0Enable output of port state transitioninformation (in PVST mode) stp port-log vlan vlan-listEnable output of port state transitioninformation (in MSTP mode)stp port-log instance { instance-id |all }RequiredUse any command.Enabled by default.Enabling the spanning tree featureYou must enable the spanning tree feature for the device before any other spanning tree relatedconfigurations can take effect.