A method for realizing transmission of messages between an extended processor and a switch chip, wherein the method comprises: the switch chip receiving a first message from one of a plurality of service physical ports of the switch chip, the first message to be sent to the extended processor, amending a destination MAC of the received first message to be a first destination MAC, and then sending the first message to the extended processor through a physical port of the switch chip which connects the extended processor, wherein the first destination MAC corresponds to the service physical port; the extended processor resolving the first destination MAC of the first message to learn the service physical port that the first message is from; the extended processor adding related information to the first message as being a second message used to be sent to the switch chip, and sending the second message to the switch chip through the physical port of the switch chip; the related information comprising a second destination MAC and a multi-protocol tag switch MPLS tunnel tag, wherein an egress port of the second message corresponding to a value of the MPLS tunnel tag is one of the plurality of service physical ports of the switch chip; the switch chip determining the egress port of the second message according to the second destination MAC and the MPLS tunnel tag; wherein the step of the switch chip determining the egress port of the second message according to the second destination MAC and the MPLS tunnel tag comprises: the switch chip determining that MPLS processing needs to be performed for the second message according to the second destination MAC; the switch chip performing tunnel ending processing for the second message according to the tag value of the MPLS tunnel tag, and learning the egress port corresponding to the tag value; the switch chip performing the tunnel ending processing comprises deleting the related information added from the second message thereby restoring the first message and sending the first message out on an MPLS tunnel according to the MPLS tunnel tag. the switch chip receiving a first message from one of a plurality of service physical ports of the switch chip, the first message to be sent to the extended processor, amending a destination MAC of the received first message to be a first destination MAC, and then sending the first message to the extended processor through a physical port of the switch chip which connects the extended processor, wherein the first destination MAC corresponds to the service physical port; the extended processor resolving the first destination MAC of the first message to learn the service physical port that the first message is from; the extended processor adding related information to the first message as being a second message used to be sent to the switch chip, and sending the second message to the switch chip through the physical port of the switch chip; the related information comprising a second destination MAC and a multi-protocol tag switch MPLS tunnel tag, wherein an egress port of the second message corresponding to a value of the MPLS tunnel tag is one of the plurality of service physical ports of the switch chip; the switch chip determining the egress port of the second message according to the second destination MAC and the MPLS tunnel tag; wherein the step of the switch chip determining the egress port of the second message according to the second destination MAC and the MPLS tunnel tag comprises: the switch chip determining that MPLS processing needs to be performed for the second message according to the second destination MAC; the switch chip performing tunnel ending processing for the second message according to the tag value of the MPLS tunnel tag, and learning the egress port corresponding to the tag value; the switch chip performing the tunnel ending processing comprises deleting the related information added from the second message thereby restoring the first message and sending the first message out on an MPLS tunnel according to the MPLS tunnel tag. the switch chip determining that MPLS processing needs to be performed for the second message according to the second destination MAC; the switch chip performing tunnel ending processing for the second message according to the tag value of the MPLS tunnel tag, and learning the egress port corresponding to the tag value; the switch chip performing the tunnel ending processing comprises deleting the related information added from the second message thereby restoring the first message and sending the first message out on an MPLS tunnel according to the MPLS tunnel tag.