CN100358322C - Method of multilayer VLAN switching - Google Patents

Method of multilayer VLAN switching Download PDF

Info

Publication number
CN100358322C
CN100358322C CNB200510069487XA CN200510069487A CN100358322C CN 100358322 C CN100358322 C CN 100358322C CN B200510069487X A CNB200510069487X A CN B200510069487XA CN 200510069487 A CN200510069487 A CN 200510069487A CN 100358322 C CN100358322 C CN 100358322C
Authority
CN
China
Prior art keywords
vlan
switching
packet
label
multilayer
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
CNB200510069487XA
Other languages
Chinese (zh)
Other versions
CN1725730A (en
Inventor
卢胜文
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
New H3C Technologies Co Ltd
Original Assignee
Hangzhou H3C Technologies Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hangzhou H3C Technologies Co Ltd filed Critical Hangzhou H3C Technologies Co Ltd
Priority to CNB200510069487XA priority Critical patent/CN100358322C/en
Priority to PCT/CN2005/002067 priority patent/WO2006094440A1/en
Publication of CN1725730A publication Critical patent/CN1725730A/en
Application granted granted Critical
Publication of CN100358322C publication Critical patent/CN100358322C/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The present invention discloses a method of multilayer VLAN switching, which comprises the steps: a VLAN switching route table is installed, and comprises VLAN information participating in switching under all switching domains; corresponding switching domain marks are obtained according to the VLAN switching route table; an outlet route of an input data packet is selected according to the switching domain marks and the target MAC address of the input data packet; the input data packet is retransmitted by the outlet route. The interconnection of multilayer VLAN data link layers is realized flexibly by the present invention; moreover, the number of accessed VLAN is not limited by 4094 VLAN resources of VLAN switching equipment; the present invention has the advantages of convenient network maintenance and convenient configuration.

Description

The method of multilayer VLAN exchange
Technical field
The present invention relates to network communications technology field, be specifically related to a kind of method of multilayer VLAN exchange.
Background technology
VLAN (VLAN) is meant on the basis of switched LAN, adopts the crossed over different segment of network management software structure, the logical network end to end of heterogeneous networks.VLAN forms a logical subnetwork, i.e. logical broadcast domain, and it can cover a plurality of network equipments, allows the network user who is in diverse geographic location to join in the logical subnetwork.The division of VLAN can mainly contain following three kinds according to different principles:
1. the VLAN based on port divides, and the several ports that are about on one or more switches are divided into a logical groups.
2. the VLAN based on MAC Address divides.MAC Address is meant the identifier of network interface card, and the MAC Address of each piece network interface card all is unique and is solidificated on the network interface card.
3. the VLAN based on route divides.Routing Protocol is operated in network layer, and corresponding work equipment has router and multi-layer switches (being three-tier switch).This mode allows a VLAN to cross over a plurality of switches, or a port is arranged in a plurality of VLAN.
Though the equipment that VLAN connected from the different network segments, can carry out direct communication each other, as being in the same network segment.Because VLAN is with the apparatus logic ground in the local area network (LAN) rather than physically is divided into the network segment one by one, so it can provide services such as user/Host Administration, allocated bandwidth and resources optimization flexibly.
802.1Q standard solves the problem that how catenet is divided into a plurality of fractions, supports the switching port of 802.1Q can be configured to transmit label frame or label frame not.A label field that comprises vlan information can be inserted in the Ether frame.If port has the equipment (as another switch) of supporting 802.1Q to link to each other, these label frames can transmit member of vlan's information between switch so.
In the IEEE 802.1Q label frame format in Ethernet, tag control information field TCI comprises User Priority (User Priority), canonical Format Indicator (Canonical Format Indicator) and VLAN ID.Wherein, VLAN ID is the identification field to VLAN, often is used in standard 802.1Q.This field is 12.Support the identification of 4096 (2^12) VLAN.In 4096 possible VID, VID=0 is used to discern frame priority.4095 (FFF) are as reserved value, so the maximum possible value of the VLAN that can divide in network is 4094, this is not enough for large-scale application, so the virtual local area network technology of multilayer occurred.If adopt two-layer VLAN label to represent a VLAN, i.e. QinQ (two label) technology, then a network just can be divided into 4094 * 4094 VLAN, can satisfy most application like this.
Intercommunication between the VLAN can only be by the route implementing of configuration 3 layers (protocol layers).When needs are set up VPN (Virtual Private Network), adopt 3 layers VPN technologies usually.3 layers of the most frequently used VPN technologies are exactly MPLS L3 VPN (based on 3 layers of VPN of multiprotocol label switching) at present, this needs equipment can support MPLS function and L3 VPN function, signaling and the complicated route that MPLS is required supported in configuration, requirement equipment has higher performance, has increased equipment cost and maintenance cost.This scheme is not subjected to the restriction of region and network, but requires backbone network to support MPLS, and is too complicated for the metropolitan area network that adopts the ether networking; And 3 layer intercommunication efficient and flexibility not as 2 layers (link layer).
A kind of VLAN switch technology is arranged at present, and the VLAN that is about to insert converts another one VLAN to, is mainly used in the conversion of public network VLAN ID and private network VLAN ID.Be characterized in that for example, at port 2, VLAN 2 converts VLAN 200 at the converting attribute of inbound port configuration VLAN ID, when VLAN 2 arrives port 2, just converted VLAN 200 like this to.
It must be public network VLAN ID that this conversion regime requires the VLAN ID after the conversion, can take the VLAN ID resource of switch itself; Only support the conversion of one deck VLAN ID, do not support the mutual conversion of multilayer VLAN ID; Can not change VLAN ID according to the characteristic of outbound port network, go into the VLAN ID that private network VLANID can only fixed conversion becomes a public network for one, realize man-to-man conversion, lack flexibility.
Summary of the invention
The method that the purpose of this invention is to provide a kind of multilayer VLAN exchange, efficient is low when realizing the VLAN intercommunication to overcome prior art by 3 layers, and the shortcoming of equipment complexity realizes the automatic exchange between multiple spot, the multilayer VLAN neatly.
For this reason, the invention provides following technical scheme:
A kind of method of multilayer VLAN exchange is characterized in that described method comprises step:
A, on the virtual LAN VLAN switching equipment configuration VLAN switching path table, described VLAN switching path table comprises and participates in all vlan informations of exchanging switching domain under;
B, receive packet, peel off the multilayer VLAN label of described packet,, obtain the switching domain sign of described packet correspondence according to the described VLAN switching path of described multilayer VLAN searching label table;
C, according to the outlet pathway of the described packet of purpose media access control MAC address choice of described switching domain sign and described packet;
D, utilize the pairing VLAN label of described outlet pathway that packet is encapsulated, transmit packet after the encapsulation by described outlet pathway.
When the switching domain of described packet correspondence had 2 above switching paths, described step C specifically comprised:
C1, transmit with switching domain sign and target MAC (Media Access Control) address inquiry;
If C2 is described corresponding outlet pathway is arranged in transmitting, then obtain this outlet pathway and corresponding VLAN label;
Do not have corresponding outlet pathway in transmitting if C3 is described, then obtain the corresponding whole outlet pathways except that ingress path of described switching domain sign and the VLAN label of correspondence according to described VLAN switching path table.
When the switching domain of packet correspondence has only 2 switching paths, can directly obtain described outlet pathway and corresponding VLAN label according to described VLAN switching path table.
Described step D comprises:
D1, after getting access to outlet pathway and corresponding VLAN label, transmit described packet by following process:
VLAN label encapsulated data packet according to described outlet pathway correspondence;
Packet after the encapsulation is transmitted by described outlet pathway;
D2, behind the VLAN label that gets access to corresponding whole outlet pathways except that ingress path of switching domain sign and correspondence, transmit described packet by following process:
Duplicate identical with described whole outlet pathway numbers, peel off the packet behind the multilayer VLAN label;
Packet after duplicating according to the VLAN label encapsulation of each outlet pathway correspondence respectively;
Packet after the encapsulation is transmitted by corresponding outlet pathway respectively.
Described transmitting comprises: switching domain sign, MAC Address, multilayer VLAN label, port numbers.
Described method also comprises step:
E, the source MAC and the multilayer VLAN label of described input packet are learnt in described the transmitting.
Between steps A and step B, also comprise step:
From described packet, take out with the switching path of configuration and support the corresponding multilayer VLAN label of the number of plies.
Described step B comprises:
During VLAN under the outside VLAN of described multilayer VLAN does not take this VLAN switching equipment, inquire about described VLAN switching path table, obtain corresponding switching domain sign according to the multilayer VLAN label and the inbound port of packet;
During VLAN under the outside VLAN of described multilayer VLAN takies this VLAN switching equipment,, obtain corresponding switching domain sign according to the described VLAN switching path of the multilayer VLAN searching label table of packet.
Alternatively, described step B also comprises:
When the corresponding a plurality of different switching domain ID of the input port of described packet, press the label depth-first or press configuration sequence and preferentially mate VLAN label in the described VLAN switching path table.
Described VLAN switching path table also comprises: with the corresponding connectivity port information of VLAN that participates in exchange under all switching domains
Described multilayer VLAN is private network or public network.
By above technical scheme provided by the invention as can be seen, the present invention is by setting up VLAN switching path table, in this table, comprise the vlan information that participates in exchange under all switching domains: switching domain sign, MAC Address, VLAN label, also may comprise port numbers, thereby set up the corresponding relation of switching domain sign with multilayer VLAN label and port, make the different paths under the same switching domain can realize 2 layer intercommunications, the VLAN that is exchanged does not take the VLAN resource of equipment itself, and just the VLAN number of Jie Ruing is not subjected to the restriction of 4094 VLAN resources of VLAN switching equipment; Carry out MAC address learning by multilayer VLAN label based on inlet, not only can learn MAC Address and port, but also can learn the VLAN label of correspondence outlet, thereby, improved the joint efficiency between the VLAN 2 layers of automatic exchange that realizes between multiple spot, the different number of plies VLAN.Utilize the present invention can realize the VPN operation simply, specify the teaming method of VPN flexibly, and need not carry out VLAN planning to VPN in advance, make operator carry out VLAN according to different regions and divide by the planning of oneself, and do not need any modification is made in the configuration of existing network, realize the VPN networking easily.
Description of drawings
Fig. 1 is the realization flow figure of the inventive method;
Fig. 2 is a flow chart of inquiring about and learn outlet pathway in the inventive method;
Fig. 3 is a VLAN networking schematic diagram;
Fig. 4 is the flow chart that receives data forwarding process in the vlan network shown in Figure 3;
Fig. 5 is the flow chart of response data repeating process in the vlan network shown in Figure 3;
Fig. 6 is the application schematic diagram of the present invention in the VPN networking.
Embodiment
Core of the present invention is by setting up VLAN switching path table, in this table, comprise the vlan information that participates in exchange under all switching domains: switching domain sign, MAC Address, VLAN label, also may comprise port numbers, thereby set up the corresponding relation of switching domain sign and multilayer VLAN label and port; After receiving the input packet,, obtain corresponding switching domain sign according to the multilayer VLAN searching label VLAN switching path table of this packet; Select the outlet pathway and the corresponding VLAN label of input packet according to the target MAC (Media Access Control) address of this switching domain sign and input packet; Peel off the multilayer VLAN label of input packet, by the VLAN label of choosing it is encapsulated, and by the input packet after the outlet pathway forwarding encapsulation, thereby realize two layers of interconnection of multilayer VLAN, for example, one deck VLAN and multilayer VLAN (one deck VLAN, two layers of VLAN, three layers of VLAN etc.), and the exchange between multilayer VLAN and the multilayer VLAN.
In order to make those skilled in the art person understand the present invention program better, the present invention is described in further detail below in conjunction with drawings and embodiments.
Realization flow figure with reference to the inventive method shown in Figure 1:
At first, in step 101: configuring virtual LAN VLAN switching path table, described VLAN switching path table comprise the vlan information that participates in exchange under all switching domains: switching domain sign, VLAN label, and the connectivity port information corresponding with it.
Usually, the outside VLAN of multilayer VLAN does not take the VLAN under this VLAN switching equipment, at this moment, the support of outside VLAN is not subjected to 4094 restriction, each port can independently be supported 4094 outside VLANs, need configuration VLAN switching path table not only will comprise the VLAN that participates in exchange under all switching domains, also will comprise the connectivity port information that it is corresponding.
Especially, during VLAN under the outside VLAN of multilayer VLAN takies this VLAN switching equipment, the outside VLAN maximum can only be supported 4094, only need comprise the vlan information that participates in exchange in the VLAN switching path table and get final product.By the VLAN label of this switching equipment configuration itself and the corresponding relation of port, just can find all paths in the affiliated switching domain of this VLAN easily.
That is to say, need to participate in switching domain of configuration the VLAN of exchange, the VLAN exchange is only carried out in user configured scope.So-called switching domain is meant the scope of VLAN exchange.Can exchange arbitrarily between the different VLAN in the same switching domain, and not be subjected to the restriction of the VLAN characteristic of inbound port and outbound port.Wherein, described multilayer VLAN is private network or public network.
To support that two-layer VLAN is an example, the VLAN switching path table of configuration is as shown in table 1 below below:
Table 1:
Switching domain ID One deck VLAN label Two layers of VLAN label Port numbers
?2 ?7 ?0 ?1
?2 ?100 ?2 ?2
?2 ?10 ?5 ?3
?3 ?10 ?0 ?3
On expressed switching domain ID and be respectively the vlan information that participates in exchange in 2 and 3, by one deck VLAN label, two layers of VLAN label (number of plies of configuration VLAN with need to support that the VLAN number of plies that inserts is consistent) and port numbers formation.Wherein, the span of every layer of VLAN is 1-4094, and 0 expression can be mated the VLAN of this layer arbitrarily.
Switching domain ID is that the configuration information in 2 the switching domain is as follows:
Article 1, configuration information represents that the ground floor VLAN of port one is VLAN 7, and second layer VLAN is that any VLAN can;
Article 2, configuration information represents that the ground floor VLAN of port 2 is VLAN 100, and second layer VLAN is VLAN 2;
Article 3, configuration information represents that the ground floor VLAN of port 3 is VLAN 10, and second layer VLAN is VLAN 5.
These three records have represented that switching domain ID is three switching paths in 2 the switching domain.Utilize the present invention, can be implemented in different switching paths in the same switching domain, whether belong to same VLAN and no longer be subject to two layers intercommunication.
Switching domain ID is that the configuration information in 3 the switching domain is as follows:
Article 4, configuration information represents that the ground floor VLAN of port 3 is VLAN 10, and second layer VLAN is that any VLAN can.
In when configuration, the number of plies of VLAN label in the definition list 1 according to actual needs, the VLAN label of configuration different levels, support the VLAN exchange of two-layer label if desired, then dispose two-layer VLAN label,, then dispose three layers of VLAN label if support the VLAN exchange of three layers of label.
Like this, promptly know the routing information and the affiliated switching domain of input packet according to this table.
If the outside VLAN that participates in the multilayer VLAN of exchange belongs to the VLAN of switching equipment itself, then when configuration participates in the vlan information of exchange, can dispose concrete port, and by inquiring about the VLAN allocation list of switch, can obtain whole ports that this VLAN comprises, with port and VLAN label information in conjunction with the switching path that can generate automatically under this switching domain.
Step 102: from the input packet, take out with the switching path of configuration and support the corresponding multilayer VLAN label of the number of plies.Which floor VLAN label the switching path of configuration can support, which floor VLAN label of outermost of just maximum data fetch packet.
Then, enter step 103: inquiry VLAN switching path table obtains corresponding switching domain sign.
Mentioned in above-mentioned steps 101, during VLAN under the outside VLAN of multilayer VLAN does not take this VLAN switching equipment, need be in VLAN switching path table the corresponding relation of configuring multi-layer label and port, at this moment, multilayer VLAN label and inbound port inquiry VLAN switching path table according to the input packet can obtain corresponding switching domain sign; And during the VLAN under the outside VLAN of multilayer VLAN takies this VLAN switching equipment, only need comprise switching domain sign, these information of VLAN label in the VLAN switching path table, therefore, at this moment only need multilayer VLAN searching label VLAN switching path table, can obtain corresponding switching domain sign according to the input packet.
After the VLAN switching equipment is received the input packet, know this packet is from which port, according to this port numbers and the multilayer VLAN searching label VLAN switching path table of getting, VLAN label in the coupling VLAN switching path table, obtain corresponding switching domain ID, so just obtain this VLAN and belong to which switching domain.
When the corresponding a plurality of different switching domain ID of the input port of input packet, the VLAN label hits and can mate by depth-first or by the configuration sequence priority principle during coupling VLAN label.
So-called depth-first principle is meant the VLAN label that preferential accuracy at target is high, for example, if the packet that receives from port 3 is the two-layer VLAN label data bag of VLAN10/VLAN5, go up then that the 3rd record and the 4th record all meet the requirements in the table 1, but the 3rd the precision of record is higher than the 4th record, and therefore selecting the switching domain ID in this record is 2.At this moment, two-layer VLAN label all need be peeled off.If the packet that port 3 receives is the two-layer VLAN label data bag of VLAN10/VLAN6, then can only hit the 4th record VLAN10/VLAN0, at this moment obtaining switching domain ID is 3, and only need peel off the outer field VLAN10 label that hits.
So-called configuration sequence priority principle is meant according to the configuration sequence in the VLAN switching path table and mates that who is configuration earlier, and who is coupling earlier.
Step 104: the outlet pathway of selecting the input packet according to the target MAC (Media Access Control) address of switching domain sign and input packet.
Step 105: transmit described input packet by the outlet pathway of choosing.
When selecting outlet pathway to obtain the outlet pathway of input packet correspondence, also need to obtain each layer VLAN label of outlet pathway correspondence, when transmitting the input data, that peels off earlier that it hits in step 103 goes into the VLAN label, then, encapsulate this packet according to the VLAN label that goes out that obtains again, transmit again after the encapsulation.
The present technique field personnel know, the MAC Address that two layers of exchange is based on network node is transmitted data, need set up addresses forwarding table during forwarding, has shown the corresponding relation of MAC Address and port in this addresses forwarding table.The present invention need set up one equally and transmit the forwarding relation that shows the vlan data bag, specifically exchanges to which port, is exchanged into which type of VLAN.Transmitting that the present invention sets up comprises following information: switching domain ID, MAC Address, VLAN label, port numbers.This table is according to setting up after source MAC in the input packet and the study of multilayer VLAN label, therefore, can not obtaining required outlet pathway information when this table of maiden visit.
Fig. 2 shows the flow process of inquiring about and learn outlet pathway in the inventive method:
At first, in step 201: transmit with switching domain sign and target MAC (Media Access Control) address inquiry;
Step 202: judge whether to inquire corresponding outlet pathway;
If inquire, then enter step 203: obtain this outlet pathway and corresponding VLAN label;
Otherwise, enter step 204: obtain corresponding whole outlet pathways except that ingress path of switching domain sign and corresponding VLAN label according to VLAN switching path table.
Step 205: will import during the source MAC of packet and multilayer VLAN label learn to transmit.The packet of returning like this, just can directly find the source MAC corresponding output port from transmit.
For example, transmitting of obtaining after the study is as shown in table 2 below:
Table 2:
Switching domain ID MAC Address One deck VLAN label Two layers of VLAN label Port numbers
?2 ?0x12345678 ?7 ?0 ?1
?2 ?0x12345679 ?100 ?2 ?2
?3 ?0x12345689 ?10 ?5 ?3
When transmitting the input packet, according to the difference of the outlet pathway of learning, repeating process is also slightly different.
If from transmit, directly get access to outlet pathway and corresponding VLAN label, then transmit the input packet by following process:
Peel off the multilayer VLAN label of input packet;
VLAN label encapsulation input packet according to the outlet pathway correspondence if export corresponding multilayer VLAN label, then adds multilayer successively in packet;
The port of input packet after the encapsulation from outlet pathway sent.
If can not from transmit, directly get access to outlet pathway, then need the input packet is broadcast on the possible outlet pathway, that is to say and to be broadcast on all the path corresponding port that to carry out in the VLAN exchange scope, at this moment, need obtain corresponding whole outlet pathways except that ingress path of switching domain sign and corresponding VLAN label from VLAN switching path table, will import packet then and be broadcast on these outlet pathway corresponding port.Owing to be the exchanges data that has multilayer VLAN label, therefore for the data that are broadcast to different port, also to encapsulate these data respectively according to its corresponding VLAN label, could transmit then.Concrete repeating process is as follows:
Peel off the multilayer VLAN label of input packet;
Duplicate identical with described whole outlet pathway numbers, peel off the input packet behind the multilayer VLAN label;
Input packet after duplicating according to the VLAN label encapsulation of each outlet pathway correspondence respectively;
Input packet after the encapsulation is transmitted by corresponding outlet pathway respectively.
The above-mentioned process of peeling off the multilayer VLAN label of input packet also can be can carry out after obtaining the input packet.
So just can guarantee that as long as destination device can both be received the packet of broadcasting in switching domain terminal equipment judges whether to mail to the packet of this equipment according to the target MAC (Media Access Control) address of the packet of receiving.If target MAC (Media Access Control) address is identical with the MAC Address of this equipment, then handle by normal flow; If inequality, then abandon this packet.
Below with reference to the forward-path in transmitting shown in the table 2, further specify the exchange process of multilayer VLAN.
The networking mode of VLAN switching domain 2 is as shown in Figure 3:
VLAN switching domain 2 is made of the VLAN100/VLAN2 under the VLAN7 under the port one, the port 2 and three networks of the VLAN10/VLAN5 under the port 3, these three independently network just form a big double layer network by multilayer VLAN exchange.
Suppose corresponding three equipment in A1, A2, three networks of A3, if A1 visit A2, then workflow is as shown in Figure 4:
At first, in step 401: from the input packet, obtain one deck VLAN7 (having only one deck VLAN label).
Step 402: with VLAN7 and port numbers 1 inquiry VLAN switching path table, obtaining switching domain ID is 2.Explanation is the packet that will carry out the VLAN exchange, peels off the VLAN7 label in the packet.
Step 403: the target MAC (Media Access Control) address inquiry with switching domain ID and packet is transmitted.
Step 404: judge whether to inquire the result.
If inquire, then enter step 405: the VLAN label of correspondence in the packaged Query Result sends on the Query Result corresponding port.
Suppose to transmit and be sky, and be to visit first to transmit, then can not inquire the result, promptly Dui Ying outlet pathway at this moment, enters step 406: according to switching domain ID inquiry VLAN switching path table, obtain switching domain ID and be 2 whole path VLAN7/1, VLAN100/VLAN2/2, VLAN10/VLAN5/3 three paths, because VLAN7/1 is the input path of packet, only need duplicate two piece of data, i.e. step 407: count duplicate packet by path.
Then, enter step 405: the VLAN label of correspondence in the packaged Query Result sends on the Query Result corresponding port.At above-mentioned two paths VLAN100/VLAN2/2, VLAN10/VLAN5/3, a copy of it data are stamped two-layer VLAN label 100 and 2, send from port 2 then; Another part stamped two-layer VLAN label 10 and 5, sends from port 3 then.
At this moment, A2 and A3 equipment can both be received data, but have only the MAC Address of A2 and the target MAC (Media Access Control) address coupling of packet, and A2 receives this data, and A3 can abandon these data.
In addition, also will be, go into during VLAN label VLAN 7, inbound port number and source MAC learn to transmit with the VLAN switching domain ID of packet, i.e. step 408: the VLAN7 of study inlet and source MAC are in transmit.Like this, exchange the packet of returning and just can directly be forwarded to port one according to transmitting.This step also can be finished after step 401.
After A2 receives packet, the flow process of responding A1 as shown in Figure 5:
At first, in step 501: from packet, obtain two-layer VLAN label VLAN 10/VLAN5.
Step 502: with VLAN10/VLAN5 and port numbers 3 inquiry VLAN switching path tables, obtaining switching domain ID is 2.Explanation is the packet that will carry out the VLAN exchange, peels off the VLAN10/VLAN5 label in the packet.
Step 503: the target MAC (Media Access Control) address inquiry with switching domain ID and packet is transmitted, because learn by the step 408 in the flow process shown in Figure 4 the address of A1, is VLAN7/1 so can inquire the outlet pathway of packet.
Step 504: the VLAN ID in the packaged Query Result sends on the port in the Query Result.At this, need stamp the VLAN7 label at data packet head, send from port one.
In addition, also will be, go into during VLAN label VLAN 10/VLAN5, inbound port numbers 3 and source MAC learn to transmit with the VLAN switching domain ID of packet, i.e. step 505: the VLAN10/VLAN5 of study inlet and source MAC are in transmit.
This step also can be finished after step 501.
As a special case among the present invention, certain switching domain is under the situation of having only two access points, promptly have only two switching paths in this switching domain,, therefore can directly find the outlet pathway and the corresponding VLAN label of input packet by VLAN switching path table because outlet is unique.After receiving packet, the switching path that takes out from import packet and dispose is supported the corresponding multilayer VLAN label of the number of plies, and which floor VLAN label the switching path of configuration can support, which floor VLAN label of outermost of just maximum data fetch packet; Then, inquiry VLAN switching path table obtains corresponding switching domain sign; Learn to have only two switching paths in this switching domain according to this switching domain sign, then by the multilayer VLAN label that takes out the packet from input and the vlan information in the input slogan coupling VLAN switching path table, can obtain the ingress path of this packet, then another paths in this switching domain is the outlet pathway of this packet.As seen, omitted in this way by the forwarding of target MAC (Media Access Control) address and the learning process of source MAC.Not only saved and transmitted resource, also can improve the forwarding performance of VLAN switching equipment greatly.
Certainly, the organizational form of VLAN switching path table can be varied, enumerates no longer one by one at this.
According to the practical application needs, the vlan information that all switching domains (comprising switching domain that has only two switching paths and the switching domain that two above switching paths are arranged) can be participated in exchange down is placed in the same VLAN switching path table, also can be with these two kinds VLAN switching path separate configuration with switching domain of different switching paths, such as, have only the routing information of two switching path tables to concern correspondence table by a VLAN switching path, in this table, all unique corresponding outlet pathway of each ingress path.
Describe the exchange process between the VLAN that has two-layer VLAN label above for example in detail, for the exchange between the two-layer above VLAN, processing procedure is similar to the above, does not repeat them here.
Utilize the present invention, can specify the teaming method of VPN neatly, and need not carry out VLAN planning to VPN in advance.
VLAN configuration for example shown in Figure 6:
Operator can carry out VLAN to different regions by the planning of oneself and divide, and the bottom is formed by inserting switching equipment, adds access VLAN switching equipment behind the two-layer VLAN label, can support 4094 * 4094 VLAN like this.
For company's first, it has two branches, first branch is positioned at region A, the VLAN switching equipment port that inserts the upper strata is P1, to distribute to user's VLAN be VLAN5 and insert switching equipment, second branch is positioned at region B, and the port that inserts the VLAN switching equipment on upper strata is P2, and to distribute to user's VLAN be VLAN10 and insert switching equipment.If desired this two branch of the VLAN10 of the VLAN5 of region A and region B is formed a VPN network and offer first company, then only need switching domain of configuration on the VLAN switching equipment, add switching path VLAN1/VLAN5/1 and VLAN2/VLAN10/2 simultaneously and get final product.
The switching domain ID that configuration first company forms is 20, and the switching domain and the switching path that dispose in VLAN switching path table are as shown in table 3 below:
Table 3:
Switching domain ID One deck VLAN label Two layers of VLAN label Port numbers
?20 ?1 ?5 ?1
?20 ?2 ?10 ?2
As seen, need not change the network configuration shown in Fig. 6, according to the configuration of table 3, the exchange process between the VLAN that has two-layer VLAN label of employing foregoing description, the intercommunication of first branch and second branch be can realize, the configuration and the maintenance of VPN networking and network made things convenient for.
Though described the present invention by embodiment, those of ordinary skills know, the present invention has many distortion and variation and do not break away from spirit of the present invention, wish that appended claim comprises these distortion and variation and do not break away from spirit of the present invention.

Claims (9)

1, a kind of method of multilayer VLAN exchange is characterized in that described method comprises step:
A, on the virtual LAN VLAN switching equipment configuration VLAN switching path table, described VLAN switching path table comprises and participates in all vlan informations of exchanging switching domain under;
B, receive packet, peel off the multilayer VLAN label of described packet,, obtain the switching domain sign of described packet correspondence according to the described VLAN switching path of described multilayer VLAN searching label table;
C, according to the outlet pathway of the described packet of purpose media access control MAC address choice of described switching domain sign and described packet;
D, utilize the pairing VLAN label of described outlet pathway that packet is encapsulated, transmit packet after the encapsulation by described outlet pathway.
2, the method for multilayer VLAN exchange according to claim 1 is characterized in that when the switching domain of described packet correspondence had 2 above switching paths, described step C specifically comprised:
C1, transmit with switching domain sign and target MAC (Media Access Control) address inquiry;
If C2 is described corresponding outlet pathway is arranged in transmitting, then obtain this outlet pathway and corresponding VLAN label;
Do not have corresponding outlet pathway in transmitting if C3 is described, then obtain the corresponding whole outlet pathways except that ingress path of described switching domain sign and the VLAN label of correspondence according to described VLAN switching path table.
3, the method for multilayer VLAN exchange according to claim 1 is characterized in that when the switching domain of described packet correspondence had only 2 switching paths, described step C was specially:
Directly obtain described outlet pathway and corresponding VLAN label according to described VLAN switching path table.
4, according to the method for claim 2 or 3 described multilayer VLAN exchanges, it is characterized in that described step D comprises:
D1, after getting access to outlet pathway and corresponding VLAN label, transmit described packet by following process:
VLAN label encapsulated data packet according to described outlet pathway correspondence;
Packet after the encapsulation is transmitted by described outlet pathway;
D2, behind the VLAN label that gets access to corresponding whole outlet pathways except that ingress path of switching domain sign and correspondence, transmit described packet by following process:
Duplicate identical with described whole outlet pathway numbers, peel off the packet behind the multilayer VLAN label;
Packet after duplicating according to the VLAN label encapsulation of each outlet pathway correspondence respectively;
Packet after the encapsulation is transmitted by corresponding outlet pathway respectively.
5, the method for multilayer VLAN exchange according to claim 2 is characterized in that described transmitting comprises: switching domain sign, MAC Address, multilayer VLAN label, port numbers.
6, the method for multilayer VLAN exchange according to claim 2 is characterized in that described method also comprises step:
E, the source MAC and the multilayer VLAN label of described input packet are learnt in described the transmitting.
7, the method for multilayer VLAN exchange according to claim 1 is characterized in that described step B comprises:
During VLAN under the outside VLAN of described multilayer VLAN does not take this VLAN switching equipment, inquire about described VLAN switching path table, obtain corresponding switching domain sign according to the multilayer VLAN label and the inbound port of packet;
During VLAN under the outside VLAN of described multilayer VLAN takies this VLAN switching equipment,, obtain corresponding switching domain sign according to the described VLAN switching path of the multilayer VLAN searching label table of packet.
8, the method for multilayer VLAN exchange according to claim 7 is characterized in that described step B also comprises:
When the corresponding a plurality of different switching domain ID of the input port of described packet, press the label depth-first or press configuration sequence and preferentially mate VLAN label in the described VLAN switching path table.
9, the method for multilayer VLAN exchange according to claim 1 is characterized in that described VLAN switching path table also comprises: with the corresponding connectivity port information of VLAN that participates in exchange under all switching domains.
CNB200510069487XA 2005-03-08 2005-04-30 Method of multilayer VLAN switching Expired - Fee Related CN100358322C (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CNB200510069487XA CN100358322C (en) 2005-04-08 2005-04-30 Method of multilayer VLAN switching
PCT/CN2005/002067 WO2006094440A1 (en) 2005-03-08 2005-12-01 A method of virtual local area network exchange and the network device thereof

Applications Claiming Priority (3)

Application Number Priority Date Filing Date Title
CN200510063527 2005-04-08
CN200510063527.X 2005-04-08
CNB200510069487XA CN100358322C (en) 2005-04-08 2005-04-30 Method of multilayer VLAN switching

Publications (2)

Publication Number Publication Date
CN1725730A CN1725730A (en) 2006-01-25
CN100358322C true CN100358322C (en) 2007-12-26

Family

ID=35924979

Family Applications (1)

Application Number Title Priority Date Filing Date
CNB200510069487XA Expired - Fee Related CN100358322C (en) 2005-03-08 2005-04-30 Method of multilayer VLAN switching

Country Status (1)

Country Link
CN (1) CN100358322C (en)

Families Citing this family (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN100433683C (en) * 2006-03-02 2008-11-12 中兴通讯股份有限公司 Virtual LAN exchange system and system apparatus signal interaction
CN1889396B (en) * 2006-07-13 2010-06-23 中兴通讯股份有限公司 Apparatus, System and method for realizing optical monitoring channel information transmission
CN101127696B (en) 2006-08-15 2012-06-27 华为技术有限公司 Data forwarding method for layer 2 network and network and node devices
CN101179479A (en) * 2006-11-09 2008-05-14 华为技术有限公司 Method, system and node for transmitting operation management and maintenance packet of ethernet
CN101764827B (en) * 2010-02-02 2012-05-23 中国电子科技集团公司第三十研究所 Method for realizing apparatus concatenation and increasing user quantity
CN102811173B (en) * 2012-07-26 2015-12-02 杭州华三通信技术有限公司 A kind of MAC address learning method and apparatus
CN105471742B (en) * 2014-06-20 2018-11-09 新华三技术有限公司 A kind of message processing method and equipment
CN110191043B (en) * 2019-05-23 2021-08-27 北京永信至诚科技股份有限公司 VLAN (virtual local area network) dividing method and system for urban network target range
CN110995603A (en) * 2019-12-09 2020-04-10 广州信天翁信息科技有限公司 Many-to-many transmission method of data and heterogeneous data transmission layer

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1357997A (en) * 2000-12-15 2002-07-10 华为技术有限公司 Virtual local area network access method in Ethernet access network
CN1457178A (en) * 2002-05-10 2003-11-19 华为技术有限公司 Communication method for sharing one subnet section of protocol between network by multiple virtual local networks
WO2004034643A1 (en) * 2002-10-09 2004-04-22 Diseño De Sistemas En Silicio, S.A. Method of implementing virtual local area networks on electrical network communication systems
WO2004040855A1 (en) * 2002-10-29 2004-05-13 Cisco Technology, Inc. Multi- tiered virtual local area network (vlan) domain mapping mechanism
CN1581818A (en) * 2003-07-31 2005-02-16 华为技术有限公司 Method for supporting multi-port virtual LAN by multi-protocol label swtich

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1357997A (en) * 2000-12-15 2002-07-10 华为技术有限公司 Virtual local area network access method in Ethernet access network
CN1457178A (en) * 2002-05-10 2003-11-19 华为技术有限公司 Communication method for sharing one subnet section of protocol between network by multiple virtual local networks
WO2004034643A1 (en) * 2002-10-09 2004-04-22 Diseño De Sistemas En Silicio, S.A. Method of implementing virtual local area networks on electrical network communication systems
WO2004040855A1 (en) * 2002-10-29 2004-05-13 Cisco Technology, Inc. Multi- tiered virtual local area network (vlan) domain mapping mechanism
CN1581818A (en) * 2003-07-31 2005-02-16 华为技术有限公司 Method for supporting multi-port virtual LAN by multi-protocol label swtich

Also Published As

Publication number Publication date
CN1725730A (en) 2006-01-25

Similar Documents

Publication Publication Date Title
CN100358322C (en) Method of multilayer VLAN switching
CN100442772C (en) Bridge-connection transmitting method
CN1866919B (en) Service switching method based on VLAN stack
US7693144B2 (en) Method of providing VPLS service in a bridged (e.g. 802.1D) network of a service provider
CN101692646B (en) Method for handling layer-2 forwarding and distributed device
CN100563190C (en) Realize the method and system of hierarchical virtual private switch service
US8228928B2 (en) System and method for providing support for multipoint L2VPN services in devices without local bridging
CN102801625B (en) A kind of method of heterogeneous network double layer intercommunication and equipment
CN100596094C (en) Implementation method and switching device of multi-point to multi-point service
US20080080535A1 (en) Method and system for transmitting packet
US20100008365A1 (en) Method and system for transparent lan services in a packet network
CN102185778B (en) Method and device for transmitting data based on VLL (Virtual Lease Line)
CN101442467B (en) Method for providing multipoint to multipoint connection in network based on operator backbone network transmission
CN101616014B (en) Method for realizing cross-virtual private local area network multicast
CN102148766B (en) Method for service interworking in PON (passive optical network) under three-layer function networking
CN101926129A (en) Evolution of Ethernet networks
CN100407704C (en) Method of dynamically learning address on MAC layer
CN100382531C (en) Switching in method for virtual special network and realizing apparatus
CN101729355B (en) Method for realizing particular virtual local area network and device
CN100563205C (en) The implementation method of user-isolated virtual local area network (LAN) and the network equipment of application thereof
CN100413281C (en) Method for realizing virtual exchange using QinQ technique
CN109639552A (en) A kind of three-layer forwarding method and device
JP2002247089A (en) Packet routing method and device
CN100518128C (en) Multi-point to multi-point VPN interconnecting method, system and device in PBT network
CN101536410A (en) LAN topology detection and assignment of addresses

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
CP03 Change of name, title or address

Address after: 310052 Binjiang District Changhe Road, Zhejiang, China, No. 466, No.

Patentee after: NEW H3C TECHNOLOGIES Co.,Ltd.

Address before: 310053 Hangzhou hi tech Industrial Development Zone, Zhejiang province science and Technology Industrial Park, No. 310 and No. six road, HUAWEI, Hangzhou production base

Patentee before: HANGZHOU H3C TECHNOLOGIES Co.,Ltd.

CP03 Change of name, title or address
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20071226

CF01 Termination of patent right due to non-payment of annual fee