The method of control plane data interaction in the distributed system
Technical field
The present invention relates to communication technical field, particularly relate to the method for control plane data interaction in a kind of distributed system.
Background technology
Distributed system generally is made up of master control borad, power board and miscellaneous service plate.Master control borad is divided into single master control borad and is used to realize the dual master control plate of master-slave back-up, is used for system management and protocol processes.Power board is realized the data interaction between integrated circuit board, master control borad and the power board plate that can permeate.Business board is responsible for the packet of different business is transmitted.For system is carried out unified management, making system is a complete integral body externally, it is mutual to need to carry out lot of data by control plane between master control borad and the business board, comprises the information that master control borad and business board are synchronous, as various list items synchronously, Interface status synchronous etc.; The information that master control borad manages business board, as ply-yarn drill off-line, online information, the various warning information of business board etc.
Publication number is that CN1825804A, name are called in the Chinese patent application of " system and method for realizing communication between distributed system boards ", discloses a kind of scheme that adopts Ethernet multicast mode to carry out data interaction between plate.The source plate card is that the standard ethernet frame header that packet adds one 18 byte becomes ethernet frame with data encapsulation in this scheme, be used for power board and carry out swap operation, the Ethernet switching chip on the power board is transmitted data according to the multicast destination address of above-mentioned ethernet frame in multicast.If adopt this scheme, when system's integrated circuit board number increased, the multicast table number that Ethernet switching chip need be supported on the power board was exponential increase, caused cost to increase; And the source plate card also needs extra field to be used for the phase related control information of transmission board intercard communication except needs increase a standard ethernet head, obviously influences communication efficiency.
Publication number is that CN101867520A, name are called in the Chinese patent application of " in the distributed system between integrated circuit board the method for exchanges data ", disclose a kind of employing and divided the scheme that the mode of VLAN (Virtual Local Area Networ, VLAN) is carried out data interaction between plate.In this scheme, the source plate card becomes data encapsulation ethernet frame equally and sends to power board, and the Ethernet switching chip on the power board is given other ply-yarn drills by the mode of broadcasting with data forwarding in VLAN.In this scheme, the required VLAN number of distributed system that integrated circuit board number is n is:
And the number of VLAN mostly is 4096 most, promptly adopts the distributed system maximum of this scheme can only support 12 integrated circuit boards, has promptly limited the quantity of system's integrated circuit board.Therefore, for the distributed system that has more integrated circuit boards, this scheme is also impracticable.And this scheme requires every integrated circuit board all to safeguard a VLAN corresponding relation list item, has increased the complexity that realizes, and the table lookup operation when at every turn sending data also can reduce communication efficiency.
In sum, in the existing distributed system between integrated circuit board the method for exchanges data have following defective:
(1) when system's integrated circuit board number increases, cost increases;
(2) the source plate card also needs extra field to be used for the phase related control information of transmission board intercard communication except needs increase a standard ethernet head, and communication efficiency is lower;
(3) the limited amount system of system's integrated circuit board, thereby influence practicality;
(4) require every integrated circuit board all to safeguard a VLAN corresponding relation list item, increased the complexity that realizes, the table lookup operation when at every turn sending data also can reduce communication efficiency;
(5) do not realize QoS (Quality of Service, service quality) function.
Summary of the invention
The objective of the invention is in order to overcome the deficiency of above-mentioned background technology, provide a kind of cost reduction, communication efficiency and quality improve, not restriction system integrated circuit board quantity, practicality is higher, realization is simple, have the method for control plane data interaction in the distributed system of simple qos feature.
The method of control plane data interaction in the distributed system provided by the invention, may further comprise the steps: a, system initialization: configuration control plane data are carried out all mutual combinations between integrated circuit board, and be that every kind of combination distributes a multicast and virtual LAN VLAN, form the corresponding relation of data interaction port set and multicast, according to described corresponding relation, the ethernet port that the Ethernet switching chip of power board is connected with each integrated circuit board adds multicast, carries out the QoS configuration according to the data type of control plane transmission on the Ethernet switching chip of power board; B, when control plane carries out data interaction, the source plate card that sends data is a packet encapsulation ethernet frame head, contain the purpose multicast address in the encapsulated Ethernet frames head, the ethernet frame that head is contained the purpose multicast address sends to the Ethernet switching chip of power board; The Ethernet switching chip of c, power board receives after described head contains the ethernet frame of purpose multicast address, carries out data interaction according to described purpose multicast address.
In technique scheme, the source address field in the ethernet frame head that encapsulates among the described step b is a self-defined information, and described self-defined information is for sending to the control information of purpose integrated circuit board.
In technique scheme, the protocol type field in the ethernet frame head that encapsulates among the described step b is packed ethernet frame data type partly, and the type of described data division comprises standard ethernet protocol type and self-defining data type.
In technique scheme, the precedence field in the virtual local area network tags territory in the ethernet frame head that encapsulates among the described step b obtains according to the qos policy of source plate card to processing data packets to be sent.
In technique scheme, purpose multicast address in the ethernet frame head that encapsulates among the described step b and the virtual local area network No. in the virtual local area network tags territory calculate according to the card number message bit pattern of purpose integrated circuit board.
In technique scheme, when the supported maximum integrated circuit board number of current system was n, the multicast number that the Ethernet switching chip of described power board need be supported was
In technique scheme, the port that all combination fingerboard cards of described control plane data interaction are connected with the Ethernet switching chip of power board carries out all combinations point-to-point, point-to-multipoint delivery.
In technique scheme, the Ethernet switching chip of described power board is operated in the pattern that unknown multicast wraps in inundation in the VLAN.
Compared with prior art, advantage of the present invention is as follows:
(1) the present invention is by Ethernet multicast (Multicast, promptly between sender and each recipient, realizing the transmission means that point-to-point configuration connects) mode realized clean culture, multicast, broadcast data mutual of network equipment control plane, if the integrated circuit board that system has is less, then adopt the multicast mode to carry out the data interaction of control plane; When system's integrated circuit board number increases, under the situation of not changing Ethernet switching chip, then adopt the VLAN+ multicast mode to carry out the data interaction of control plane, cost obviously reduces.
When (2) application is of the present invention, do not need extra field to be used for the phase related control information of transmission board intercard communication, do not require that every integrated circuit board all safeguards a VLAN corresponding relation list item yet, the table lookup operation when having saved each transmission data, so communication efficiency and quality obviously improve.
(3) the integrated circuit board quantity that system is supported without limits, practicality is higher.
(4) all do not safeguard a VLAN corresponding relation list item owing to require every integrated circuit board, therefore realize fairly simplely, saved memory space, and do not need to look into above-mentioned mapping table at every turn when sending data, and only need can obtain multicast and VLAN by simple calculating, improved efficient.
(5) realized simple qos feature.
Description of drawings
Fig. 1 is the structural representation that the distributed system boards cartoon is crossed the Ethernet switching chip interconnection;
Fig. 2 is a method flow diagram of the present invention.
Embodiment
The present invention is described in further detail below in conjunction with drawings and Examples.
Referring to shown in Figure 1, each port of the Ethernet switching chip of power board links to each other with each integrated circuit board in the system respectively, and in fact data communication shows as the data forwarding between the corresponding port on the Ethernet switching chip of power board between integrated circuit board.All combinations according to data communication between integrated circuit board comprise clean culture, multicast and broadcasting, and the Ethernet switching chip port that is connected with each integrated circuit board is made up, and obtain a set, and each element in the set is one group of port.When system had n piece integrated circuit board, the element number of set was
For each element distributes a multicast, then the Ethernet switching chip of power board need be supported
Individual multicast.
Referring to shown in Figure 2, the method for control plane data interaction comprises the following steps: in the distributed system of the present invention
A, system initialization: configuration control plane data are carried out all mutual combinations (all combinations point-to-point, point-to-multipoint delivery that the port that integrated circuit board is connected with the Ethernet switching chip of power board carries out) between integrated circuit board, and be that every kind of combination distributes a multicast, form the corresponding relation of data interaction port set and multicast, according to described corresponding relation, the ethernet port that the Ethernet switching chip of power board is connected with each integrated circuit board adds multicast, carries out the QoS configuration according to the data type of control plane transmission on the Ethernet switching chip of power board.Specifically in the process of system initialization, each port of Ethernet switching chip is determined VLAN and multicast table that this port need add according to the plate card number that is attached thereto on the power board.
B, when control plane carries out data interaction, the source plate card that sends data is a packet encapsulation ethernet frame head, contain the purpose multicast address in the encapsulated Ethernet frames head, the ethernet frame that head is contained the purpose multicast address sends to the Ethernet switching chip of power board.For example, when certain piece integrated circuit board sends data to other integrated circuit board, data encapsulation to be sent is become ethernet frame, calculate VLAN and purpose multicast address according to purpose plate card number, after other fields of padding ethernet frames head, again encapsulated Ethernet frames is sent to the Ethernet switching chip of power board.
Concrete, in the ethernet frame head of encapsulation: source address field is a self-defined information, promptly needs to send to the control information of purpose integrated circuit board; Protocol type field is packed ethernet frame data type partly, and the type of this data division comprises standard ethernet protocol type and self-defining data type.The virtual local area network tags territory comprises two parts: virtual local area network No. and precedence field.Precedence field in the virtual local area network tags territory obtains according to the qos policy of source plate card to processing data packets to be sent.Virtual local area network No. in purpose multicast address and the virtual local area network tags territory calculates according to the card number message bit pattern of purpose integrated circuit board.
The Ethernet switching chip of c, power board receives after described head contains the ethernet frame of purpose multicast address, in multicast group, transmit or inundation (Flooding in VLAN according to described purpose multicast address or VLAN, the topological structure that does not require maintaining network calculates with relevant route, only requires the node of the information that receives to transmit packet with broadcast mode).
When the supported maximum integrated circuit board number of current system was n, the multicast number that the Ethernet switching chip of described power board need be supported was
The Ethernet switching chip of power board is operated in the pattern that unknown multicast wraps in inundation in the VLAN.If the integrated circuit board that has of system is less, the multicast table number that the Ethernet switching chip of power board is supported greater than
Situation under, adopt the multicast mode to carry out the data interaction of control plane.When system's integrated circuit board number increased, the multicast table number of the required support of Ethernet switching chip of power board was exponential increase.And generally speaking, the multicast table that exchange chip is supported is big more, and the price of exchange chip is high more.Therefore the multicast table number of supporting for the Ethernet switching chip of power board less than
And do not change the situation of Ethernet switching chip, then adopt the VLAN+ multicast mode to carry out the data interaction of control plane, to reduce cost.
Describe method step of the present invention in detail below by 2 specific embodiments.
Embodiment 1: system's integrated circuit board number is 8
The method of control plane data interaction in the distributed system comprises the following steps: in the embodiment of the invention
Step 101: during system initialization, the Ethernet switching chip that power board is set is carried out the QoS configuration to the data type that may receive, corresponding relation according to plate card number and multicast address, determine the multicast that port adds, with 8 integrated circuit boards is example, and the multicast scope that the port that is connected with integrated circuit board n on the Ethernet switching chip of power board need add is:
{VLAN,MAC}={1,(01:00:00:00:00:00~01:00:00:00:00:FF)|(1<<(n-1))}
Step 102: when certain piece integrated circuit board when other integrated circuit boards send data, data encapsulation to be sent is become ethernet frame, no matter this packet need send to one or polylith ply-yarn drill, the destination address of the ethernet frame head of power board is a purpose multicast address, according to purpose plate card number { n
1, n
2... calculate above-mentioned purpose multicast address: 01:00:00:00:00:00| (1<<(n
1-1)) | (1<<(n
2-1)) ....The source address of above-mentioned ethernet frame is according to the actual requirements by User Defined.The information that the source plate card generally need carry is write daily record sign etc. as source plate card number, Flow Control sign, warning information.For above-mentioned ethernet frame adds VLAN and protocol type field.Vlan number is fixed as 1, and precedence field is provided with 802.1Q priority according to the source plate card to the qos policy of these data; Protocol type is the type of above-mentioned data.Encapsulated Ethernet frames is sent to the Ethernet switching chip of power board.
Step 103: after the Ethernet switching chip of power board is received encapsulated Ethernet frames, transmit in multicast according to the purpose multicast address of ethernet frame head, and carry out the mapping of priority query, and operate based on the QoS of stream according to 802.1Q.
Embodiment 2: system's integrated circuit board number is 16
Step 201: during system initialization, the Ethernet switching chip that power board is set is operated in the pattern that unknown multicast wraps in inundation in the VLAN; The data type that may receive is carried out the QoS configuration; Corresponding relation according to plate card number and multicast MAC and VLAN, determine multicast and VLAN that port adds, with system's integrated circuit board number is 16, the Ethernet switching chip multicast table number of power board is that 4K is an example, and multicast scope and VLAN scope that the port that is connected with integrated circuit board n on the Ethernet switching chip of power board need add are:
{VLAN,MAC}={1,(01:00:00:00:00:00~01:00:00:00:0F:FF)|(1<<(n-1))}
VLAN=(0x000~0x00F)|(1<<(n-1))+1
Step 202: when certain piece integrated circuit board sends data to other integrated circuit boards, data encapsulation to be sent is become ethernet frame, no matter this packet need send to one or polylith ply-yarn drill, the destination address of the ethernet frame head of power board is a purpose multicast address, according to purpose plate card number { n
1, n
2... calculate above-mentioned multicast address: 01:00:00:00:00:00| (1<<(n
1-1)) | (1<<(n
2-1)) ....The source address of ethernet frame is according to the actual requirements by User Defined.The information that the source plate card generally need carry is write daily record sign etc. as source plate card number, Flow Control sign, warning information.For above-mentioned ethernet frame adds VLAN and protocol type field.Vlan number calculates according to the above-mentioned purpose multicast address: the above-mentioned purpose multicast address
Totally 12 bits, i.e. [D
12: D
24] be vlan number, precedence field is provided with 802.1Q priority according to the source plate card to the qos policy of these data; Protocol type is the type of above-mentioned data.Encapsulated Ethernet frames is sent to the Ethernet switching chip of power board.
Step 203: after the Ethernet switching chip of power board is received encapsulated Ethernet frames, purpose multicast address according to the ethernet frame head is transmitted in multicast, if the Ethernet switching chip of power board does not find the multicast of this destination address correspondence, because the Ethernet switching chip of power board is operated in the pattern that unknown multicast wraps in inundation in the VLAN, therefore above-mentioned ethernet frame will be broadcasted in VLAN, and carry out the mapping of priority query, and based on the QoS operation of stream according to 802.1Q.
Obviously, those skilled in the art can carry out various changes and modification to the present invention and not break away from the spirit and scope of the present invention.Like this, if of the present invention these are revised and modification belongs within the scope of claim of the present invention and equivalent technologies thereof, then the present invention also is intended to comprise these changes and modification interior.
The content that is not described in detail in this specification belongs to this area professional and technical personnel's known prior art.