Embodiment
Below by drawings and Examples, technical scheme of the present invention is described in further detail.
Fig. 3 is a structural representation of Ethernet message related in the embodiments of the invention.Being described as follows of this Ethernet message:
1, DMAC represents traditional target MAC (Media Access Control) address, 6 byte longs;
2, SMAC represents the conventional source MAC Address, 6 byte longs;
3, the traditional 802.1p/q of VLAN TAG (Optional, optional) expression, 4 byte longs;
4, Service Tag represents that this message is an Ethernet Mux message, and provide QoS, packet order preserving function simultaneously, wherein being described as of inside field: TYPE represents payload type, 0x9910, demultiplexing (DMux) sign, 2 byte longs; Pri represents precedence information, similar DSCP, and its length is that 3bit is long in the present embodiment; Res represents length in reserve, and its length is that 1bit is long in the present embodiment; Sequence represents packet order preserving information, as is used for the sequence number of packet order preserving, and its length can be long for 12bit in the present embodiment; Total Length is the loaded length unit of Ethernet message, wherein preserves the loaded length of Ethernet message, and described loaded length is to be unit with the byte.
5, FCS represent verification and, be used for 32 cyclic redundancy check (CRC) (Cyclic Redundancy Check, be called for short CRC) verification, its length is 4 byte longs among this embodiment.
6, Payload is the message payload, and the 0-1496 byte is to meet the restriction of Ethernet 64-1518 byte frame length, and when payload length was not enough, there was the Padding field in frame, maximum 42 bytes.Each sub-message is multiplexed in the Payload, adds multiplexing MuxHeader (3-4 byte) before each sub-message payload Sub Payload, forms a sub-message Payload Unit, and receiving device will carry out demultiplexing according to this MuxHeader.To being described below of Mux Header son field: UID represents user ID, can be that 16bit is long among this embodiment, and the user can be self-defined according to type of service; E:1bit, whether expression has extended field; Length:7bit represents the length of sub-message payload; Extend:8bit, the user can do self-defining expansion in Extend; The message that is re-used among the Payload can be an any type, as ATM cell or PPP message.
7, Padding (Optional, optional) field, when the payload length among the Payload was not enough, there was the Padding field in frame.
Wherein, in the present embodiment, described loaded length is the length information of described message payload, in other selectable execution modes, this loaded length also can be one or several the length sum among described message payload and above-mentioned DMAC, SMAC, Vlan TAG, Service Tag, Padding, the FCS.
Be example with multiplexing, demultiplexing below, ether message multiplexing of the present invention, Deplexing method are described in detail at the Ethernet message between 3G NodeB equipment and the RNC equipment.
Fig. 4 is intended to demultiplexing flow process diagram for NodeB and the message multiplexing between the RNC based on the ether bearer network among the present invention.As shown in Figure 4, message multiplexing between NodeB and the RNC and demultiplexing comprise following several aspect:
1, the NodeB side realizes that the ether of message of a certain class business is multiplexing, and accordingly, the RNC side realizes the ether demultiplexing;
2, the RNC side realizes that the ether of a certain class service message is multiplexing, and accordingly, the NodeB side realizes the ether demultiplexing;
3, use Ethernet to carry out the carrying of multiplexing packet.
With the message of voice class business, promptly voice message is multiplexed with example, and then Fig. 3 neutron message load SubPayload is Voice Payload.
At NodeB-〉the RNC direction, a plurality of sub-message from the terminal use is multiplexed among the Payload at NodeB, encapsulate according to type of message, length etc., carry out common ether encapsulation again, the ether bearer network carries out L2 and transmits, at the RNC end, the TYPE field among the Service Tag will be carried out the demultiplexing of message according to Mux Header if show that this message is Ethernet Mux.
At RNC-〉NodeB direction handling process is similarly, just RNC carries out the message multiplexing encapsulation, and NodeB carries out the message demultiplexing.
Embodiments of the invention provide a kind of ether message multiplexing method, comprising: receive sub-message to be packaged; When the length of this sub-message to be packaged is less than or equal to the maximum admissible length of presetting of sub-message Payload Unit, judge whether the length of the sub-message that this is to be packaged and the length sum of multiplexing Ethernet message allow transmission length greater than the default maximum of Ethernet message, if, then multiplexing Ethernet message is carried out ether encapsulation and transmission, simultaneously with sub-message multiplexing to a to be packaged new Ethernet message; If not, then with in the sub-message multiplexing to be packaged sub-message Payload Unit in the message payload of multiplexing Ethernet message, described sub-message Payload Unit comprises multiplexing head and sub-message payload, described sub-message payload carries this and treats multiplexing sub-message, and described multiplexing head comprises the length information and the user ID of the sub-message that this is to be packaged; And length that will this sub-message to be packaged is added in the loaded length of Ethernet message.
If the length of sub-message to be packaged is PKT_SIZE, the default maximum admissible length of single Sub Payload is MAX_PAYLOAD_SIZE, the length of multiplexing Ethernet message is OLD_MUX_SIZE, and the default maximum of Ethernet message allows that transmission length is MTU.
Fig. 5 is the flow chart of a kind of ether message multiplexing method embodiment one of the present invention.As shown in Figure 5, ether message multiplexing method may further comprise the steps:
Step 101, reception sub-message to be packaged.This embodiment message to be packaged is example with the voice message.
Step 102, judge whether ether multiplexing (Ethernet Mux) is enabled, if enable execution in step 104, otherwise execution in step 103.
Step 103, this voice message to be packaged is carried out the encapsulation of traditional ether and sends.
Step 104, judge the voice message that this is to be packaged length PKT_SIZE whether greater than the default maximum admissible length MAX_PAYLOAD_SIZE of single sub-message Payload Unit, if then execution in step 105; Otherwise then execution in step 106;
Step 105, multiplexing Ethernet message is carried out ether encapsulation and sent, and this voice message to be packaged is carried out traditional ether encapsulation and sends.Specifically comprise step 1051, multiplexing Ethernet message is carried out ether encapsulation and transmission; Step 1052, this voice message to be packaged is carried out the encapsulation of traditional ether and sends.
Step 106, judge whether the length PKT_SIZE of the voice message that this is to be packaged and the length OLD_MUX_SIZE sum of multiplexing Ethernet message allow transmission length M TU greater than the default maximum of Ethernet message; If then execution in step 107; If not, execution in step 108 then.
Step 107, multiplexing Ethernet message is carried out ether encapsulation and sent, simultaneously with sub-message multiplexing to a to be packaged new Ethernet message.Specifically comprise step 1071, multiplexing Ethernet message is carried out ether encapsulation and transmission; Step 1072, with sub-message multiplexing to a to be packaged new Ethernet message.
Step 108, with a sub-message multiplexing to be packaged sub-message Payload Unit to multiplexing Ethernet message.Described sub-message Payload Unit comprises multiplexing head and sub-message payload, described sub-message payload carries this and treats multiplexing voice message, described multiplexing head comprises the length information of the voice message that this is to be packaged, can also comprise the user ID of the voice message that this is to be packaged.
Step 109, length that will this voice message to be packaged are added to the loaded length that obtains current Ethernet message in the loaded length of multiplexing Ethernet message.Promptly add the length of the voice message that this is to be packaged in the Total Length field in Service Tag.
Above-mentioned steps 101-step 109 is that a voice message to be packaged is multiplexed into an entire flow in the Ethernet message.When receiving sub-message more than, as voice message but when being not limited to voice message, can in the equipment that receives sub-message, a timer be set, when still not having new sub-message and arriving, then this Ethernet message is encapsulated and sends when overtime.
Fig. 6 is the flow chart of a kind of ether message multiplexing method embodiment two of the present invention.As shown in Figure 6, the difference of this embodiment and a last embodiment is, also comprises after described step 109:
Step 110, startup timer;
Step 111, judge whether overtimely according to timer, if not overtime, then continue to receive new sub-message, execution in step 101; If overtime, then execution in step 112.
Step 112, current multiplexing Ethernet message is encapsulated and sends.
Among the above-mentioned ether message multiplexing method embodiment, the loaded length of Ethernet message can also be carried among the status flag information Service Tag of Ethernet message as shown in Figure 3.
The structural representation of Ethernet message as shown in Figure 3, can also in service mark information ServiceTag, carry the combination of following information or following information: the multiplexing type information TYPE of this Ethernet message, the precedence information Pri of this multiplexing packet, or the order-preserving information Sequence of this multiplexing packet.When ServiceTAG comprises TYPE simultaneously, when Pri and Sequence, also comprise before the ether encapsulation in that multiplexing Ethernet message is carried out: the multiplexing type information TYPE that this Ethernet message is set in Service Tag is that ether is multiplexing, promptly specifying the TYPE among the Service Tag is 0x9910, and this value can be self-defined; The precedence information pri of this multiplexing packet is set in Service Tag, can carries out the appointment of pri according to the Qos demand.Can carry out the appointment of Sequence according to the packet order preserving demand.More than the setting step of three kinds of parameters do not limit.
Fig. 7 is the flow chart of a kind of Ethernet message Deplexing method of the present invention embodiment one.As shown in Figure 7, the Ethernet message Deplexing method may further comprise the steps:
Step 201, reception Ethernet message.
Step 202, judge whether the multiplexing type information TYPE in the Ethernet message is that ether is multiplexing, if not, execution in step 203; If, execution in step 204.Judge promptly among this embodiment whether the TYPE among the Service Tag is 0x9910.
Step 203, common this Ethernet message of ether demultiplexing mode demultiplexing of employing.
Loaded length unit in step 204, the described Ethernet message of extraction and at least one sub-message Payload Unit, comprise sub-message payload and multiplexing head in the described sub-message Payload Unit, the length information that comprises described sub-message Payload Unit in the described multiplexing head comprises the loaded length of described Ethernet message in the described loaded length unit.
Step 205, according to this sub-message Payload Unit neutron message payload of length information demultiplexing of described sub-message payload.Wherein, according to the length of the sub-message payload among the Mux Header in the sub-message Payload Unit, institute's loaded service content among the sub-message Payload Unit of the demultiplexing neutron message payload Sub Payload.
Step 206, according to the user ID UID among multiplexing the Mux Header described business tine is delivered to the corresponding upper application program and handle.
Step 207, judge whether the length of the message of demultiplexing equals the loaded length of Ethernet message, if then execution in step 208; Otherwise execution in step 205 continues next sub-message Payload Unit in this Ethernet message of demultiplexing, equals the loaded length of Ethernet message until the length of the message of demultiplexing.Demultiplexing comprises: the demultiplexing of message payload reaches the demultiplexing with the multiplexing packet relevant information.The demultiplexing of message payload promptly carries out demultiplexing to the sub-message payload in the message payload.The information relevant with multiplexing packet comprises MAC, Vlan TAG, Service Tag, Padding and FCS.In the present embodiment because the loaded length in the Ethernet message is the length information of message payload Pay Load, so only more the total length of the sub-message Payload Unit of demultiplexing whether equal described loaded length.In other selectable execution modes, described loaded length also can be one or several the length sum in the described message payload information relevant with above-mentioned multiplexing packet (DMAC, SMAC, Vlan TAG, Service Tag, Padding, FCS), so in comparison procedure, judge loaded length that whether length separated the message of taking equals Ethernet message is and judge that the total length of the sub-message Payload Unit of demultiplexing adds whether the length of multiplexing packet relevant information equals the loaded length of Ethernet message.
Step 208, the de-multiplex operation of current Ethernet message of stopping.
When being provided with the precedence information of multiplexing packet in the service mark unit of Ethernet message, also comprise before the sub-message payload in the sub-message Payload Unit of demultiplexing: carry out traffic classification and priority scheduling according to described precedence information.
When being provided with the order-preserving information of multiplexing packet in the service mark unit of Ethernet message, also comprise before the sub-message payload in the sub-message Payload Unit of demultiplexing: carry out order-preserving according to described order-preserving information and handle.
Fig. 8 is the flow chart of a kind of Ethernet message Deplexing method of the present invention embodiment two.The difference of this embodiment and a last embodiment is, has increased operation of traffic classification and priority scheduling and order-preserving and has handled operation.Specifically between step 202 and step 204, also comprise:
Step 209, carry out traffic classification and priority scheduling according to the precedence information Pri among the service mark information Service Tag.Specify when disposing QoS when upper level applications, carry out traffic classification and priority scheduling, as based on the Qos of simple traffic classification or complex traffic classification etc. according to the precedence information Pri among the service mark information Service Tag according to priority.
Step 210, carry out order-preserving according to the order-preserving information Sequence among the service mark information Service Tag and handle.When upper level applications is specified the use sequence number of message, the place end can be corrected the order of received sub-message according to this sequence number, message with less sequence number will be handled by upper level applications earlier, and TCP also can be provided similar frame losing detection and retransmission mechanism.Sub-message described in the foregoing description is not limited to the packet services of ether bearer network carrying, as the wireless speech business; Can also comprise from the sub-message of networks such as SDH/PDH network, atm network, PSTN/POTS, the carrying that is similar to PPPoE, ATMoE is provided, carry out the multiplexing encapsulation of message, carry out demultiplexing at receiving terminal at transmitting terminal.Access device and server apparatus that each network connects the ether bearer network are nucleus equipment.Above figure atm network is an example, and major function comprises:
1, a plurality of ATM cell are multiplexed in the Ethernet message when going out atm network;
2, at server end, realize the demultiplexing of Ethernet message, obtain each ATM cell.
The message that is re-used (or cell) carries out the Ethernet message encapsulation on the equipment (or server) of source network access ether bearer network, bearer network carries out common L2 according to MAC Address to be transmitted, and carries out demultiplexing on reception network access equipment (or server).
ATM cell, PPP message, common IP message can take the multiplexing back of this mode to transmit on the ether bearer network, at the receiving terminal demultiplexing, so that the transmission means of similar ATMoE, PPPoE to be provided.
Fig. 9 is the structural representation of a kind of ether message multiplexing apparatus embodiments one of the present invention.As shown in Figure 9, comprising: receiver module 11, judge module 12, first package module 13, Multiplexing module 14 and accumulator module 15; Wherein, receiver module 11 is used to receive sub-message to be packaged; Judge module 12, be connected with receiver module 11, when the length of judging this sub-message to be packaged is less than or equal to the default maximum admissible length of sub-message Payload Unit, continue to judge whether the length of the sub-message that this is to be packaged and the length sum of multiplexing Ethernet message allow transmission length greater than the maximum of presetting of Ethernet message;
If, then call first package module 13, multiplexing Ethernet message is carried out ether encapsulation and transmission, call Multiplexing module 14 simultaneously, with sub-message multiplexing to a to be packaged new Ethernet message;
If not, then call Multiplexing module 14, with sub-message multiplexing to be packaged in a sub-message Payload Unit of multiplexing Ethernet message, described sub-message Payload Unit comprises multiplexing head and sub-message payload, described sub-message payload carries this and treats multiplexing sub-message, and described multiplexing head comprises the length information and the user ID of the sub-message that this is to be packaged; Call accumulator module 15 simultaneously, the loaded length that the length of the sub-message that this is to be packaged is added to multiplexing Ethernet message obtains the loaded length of current Ethernet message.Among this embodiment, multiplexing head can also comprise the user ID of sub-message to be packaged in the sub-message Payload Unit.
Figure 10 is the structural representation of a kind of ether message multiplexing apparatus embodiments two of the present invention.As shown in figure 10, the difference of this embodiment and above-mentioned ether message multiplexing apparatus embodiments one is, can also comprise first expansion module 16, and the multiplexing type information that is used for being provided with in the service mark unit of Ethernet message this Ethernet message is that ether is multiplexing; Can also comprise second expansion module 17, be used for being provided with the precedence information of this multiplexing packet in the service mark unit of Ethernet message; Can also comprise the 3rd expansion module 18, be used for being provided with the order-preserving information of this multiplexing packet in the service mark unit of Ethernet message.
When receiving sub-message more than, a regularly submodule can be set in the equipment that receives sub-message,, then this Ethernet message is encapsulated and sends when still not having new sub-message and arriving when overtime.Figure 11 is the structural representation of a kind of ether message multiplexing apparatus embodiments three of the present invention.As shown in figure 11, the difference of this embodiment and above-mentioned ether message multiplexing apparatus embodiments one is, in judge module 12, also comprise a timing submodule 1201, when accumulator module 15 will this sub-message to be packaged the length loaded length that is added to multiplexing Ethernet message obtain the loaded length of current Ethernet message after, regularly submodule 1201 picks up counting, when not having next sub-message within the predetermined time and arrive described receiver module 11, described first package module 13 carries out ether encapsulation and transmission to current multiplexing Ethernet message.
Figure 12 is the structural representation of a kind of ether message multiplexing apparatus embodiments four of the present invention.As shown in figure 12, among this embodiment, be also to comprise second package module 19 with the difference of above-mentioned a kind of ether message multiplexing apparatus embodiments one, the length of judging this sub-message to be packaged when judge module 12 is during greater than the default maximum admissible length of sub-message Payload Unit, call first package module 13, multiplexing Ethernet message is carried out ether encapsulation and transmission, call second package module 19 simultaneously, this sub-message to be packaged is carried out traditional ether encapsulation and transmission.
Figure 13 is the structural representation of a kind of Ethernet message demultiplexing of the present invention apparatus embodiments one.As shown in figure 12, comprising: receiver module 21 is used to receive the Ethernet message of encapsulation; Demultiplexing module 22 is connected with receiver module 21, is used for the length information according to the sub-message payload in the multiplexing head of a sub-message Payload Unit, this sub-message Payload Unit neutron message payload of demultiplexing; First judge module 24 is connected with demultiplexing module 22, judges whether the length of the message of demultiplexing equals the loaded length of Ethernet message, if then stop de-multiplex operation; Otherwise, call demultiplexing module 23, continue next sub-message Payload Unit of demultiplexing, equal the loaded length of Ethernet message until the length sum of the message of demultiplexing.Ethernet message demultiplexing equipment among this embodiment also comprises sending module 23, is connected with demultiplexing module 22, is used for according to the user ID of multiplexing head described business tine being delivered to the corresponding upper application program and handles.
Figure 14 is the structural representation of a kind of Ethernet message demultiplexing of the present invention apparatus embodiments two.As shown in figure 14, the difference of this embodiment and above-mentioned Ethernet message demultiplexing apparatus embodiments one is, can also comprise priority scheduling module 25, when being provided with the precedence information of multiplexing packet in the service mark unit of Ethernet message, be used for before the sub-message payload of the sub-message Payload Unit of demultiplexing, carrying out traffic classification and priority scheduling according to described precedence information.Can also comprise order-preserving processing module 26, when being provided with the order-preserving information of multiplexing packet in the service mark unit of Ethernet message, be used for before the sub-message payload of the sub-message Payload Unit of demultiplexing, carry out order-preserving according to described order-preserving information and handle.
Figure 15 is the structural representation of a kind of Ethernet message demultiplexing of the present invention apparatus embodiments three.As shown in figure 15, the difference of this embodiment and above-mentioned Ethernet message demultiplexing apparatus embodiments one is also to comprise second judge module 27, be connected with receiver module 21, when the multiplexing type information that this Ethernet message is set in the service mark unit of Ethernet message is that ether is when multiplexing, be used for before the sub-message payload of the sub-message Payload Unit of demultiplexing, second judge module 27 is used for judging according to described multiplexing type information whether the multiplexing type of described Ethernet message is that ether is multiplexing, if, then call demultiplexing module 22, according to the length information of the sub-message payload in the multiplexing head in the sub-message Payload Unit, this sub-message Payload Unit neutron message payload of demultiplexing.
Among the above embodiment of the present invention, providing a kind of directly goes into a plurality of sub-message multiplexing Ethernet message and carry out two layers of transmission manner on the ether bearer network, do not re-use the UDP/IP head, all add a multiplexing Mux Header before each sub-message with the type that characterizes the entrained business tine of this message payload and length etc., the EtherType field of expanding traditional ether is identification, QoS and the packet order preserving of TYPE with support Ethernet Mux frame, supports the encapsulation of traditional 802.1p/q and common ether.
In sum, the present invention has following advantage:
(1) further improves efficiency of transmission, strengthened flexibility, QoS characteristic, realized simplyr, further reduced exploitation and operation cost.
(2) removed IP head/UDP head, and before each sub-message, added a multiplexing Mux Header, thereby saved Internet resources, improved network resource utilization with the type that characterizes the entrained business tine of this message payload and length etc.;
(3) at but be not limited to can multiplexing in a large number packet services, a kind of mode that the variety of network types message carries out multiplexing transmission of carrying is provided.
It should be noted that at last: above embodiment only in order to technical scheme of the present invention to be described, is not intended to limit; Although with reference to previous embodiment the present invention is had been described in detail, those of ordinary skill in the art is to be understood that: it still can be made amendment to the technical scheme that aforementioned each embodiment put down in writing, and perhaps part technical characterictic wherein is equal to replacement; And these modifications or replacement do not make the essence of appropriate technical solution break away from the spirit and scope of various embodiments of the present invention technical scheme.