WO2015000173A1 - 建立隧道的方法、分配标签的方法、设备及网络系统 - Google Patents

建立隧道的方法、分配标签的方法、设备及网络系统 Download PDF

Info

Publication number
WO2015000173A1
WO2015000173A1 PCT/CN2013/078887 CN2013078887W WO2015000173A1 WO 2015000173 A1 WO2015000173 A1 WO 2015000173A1 CN 2013078887 W CN2013078887 W CN 2013078887W WO 2015000173 A1 WO2015000173 A1 WO 2015000173A1
Authority
WO
WIPO (PCT)
Prior art keywords
egress
virtual node
link
router
node
Prior art date
Application number
PCT/CN2013/078887
Other languages
English (en)
French (fr)
Inventor
周鹏
Original Assignee
华为技术有限公司
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 华为技术有限公司 filed Critical 华为技术有限公司
Priority to PCT/CN2013/078887 priority Critical patent/WO2015000173A1/zh
Priority to EP13888861.5A priority patent/EP3002913B1/en
Priority to CN201380077524.4A priority patent/CN105379197B/zh
Publication of WO2015000173A1 publication Critical patent/WO2015000173A1/zh
Priority to US14/986,144 priority patent/US10003531B2/en

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/50Routing or path finding of packets in data switching networks using label swapping, e.g. multi-protocol label switch [MPLS]
    • H04L45/507Label distribution
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/46Interconnection of networks
    • H04L12/4633Interconnection of networks using encapsulation techniques, e.g. tunneling
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/46Interconnection of networks
    • H04L12/4641Virtual LANs, VLANs, e.g. virtual private networks [VPN]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/64Hybrid switching systems
    • H04L12/6418Hybrid transport
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/02Topology update or discovery
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/02Topology update or discovery
    • H04L45/03Topology update or discovery by updating link state protocols
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L45/00Routing or path finding of packets in data switching networks
    • H04L45/02Topology update or discovery
    • H04L45/033Topology update or discovery by updating distance vector protocols

Definitions

  • the invention relates to a method for establishing a tunnel, a method for distributing a label, a device and a network system.
  • MPLS Multi-Protocol Label Switching
  • IP Internet Protocol
  • MPLS replaces IP forwarding with label switching.
  • a tag is a short, fixed-length connection identifier that has only local meaning. The tag is encapsulated between the link layer and the network layer.
  • MPLS is not limited to any particular link layer protocol and can transport network packets using any Layer 2 medium.
  • MPLS is not a service or application. It is actually a tunneling technology. This technology not only supports a variety of high-level protocols and services, but also ensures the security of information transmission to a certain extent.
  • LDP Label Distribution Protocol
  • EMUs Fingering Equivalence Class
  • LSP Label Switched Path
  • MPLS supports multi-layer labels, and the forwarding plane is connection-oriented, so it has good scalability, making it possible to provide various services to customers on a unified MPLS/IP infrastructure network architecture.
  • LSR Label Switched Router
  • the Label Switched Router (LSR) can directly map the routing information of the network layer to the switching path of the data link layer to establish an LSP at the network layer.
  • LDP is widely used in VPN services. It has the advantages of simple networking and configuration, support for routing topology to drive LSPs, and support for large-capacity LSPs.
  • Virtual Private Network is a virtual private communication network established in the public network by means of an Internet Service Provider (ISP) and a Network Service Provider (NSP).
  • ISP Internet Service Provider
  • NSP Network Service Provider
  • the basic principle of VPN is to use tunnel technology to encapsulate VPN packets in tunnels and establish private data transmission through VPN backbone network.
  • the transmission channel realizes transparent transmission of messages.
  • Tunneling technology uses one protocol to encapsulate another protocol packet, and the encapsulation protocol itself can be encapsulated or carried by other encapsulation protocols.
  • BGP/MPLS IP VPN is a kind of L3VPN (Layer 3 Virtual Private Network). It uses BGP (Border Gateway Protocol) to advertise VPN routes on the service provider backbone network and uses MPLS (Multiprotocol Label Switch) to forward VPNs on the service provider backbone network.
  • the IP address here refers to the IP packet carried by the VPN.
  • PWE3 Pulseudo-Wire Emulation Edge to Edge
  • ATM Asynchronous Transfer Mode
  • FR Framework Relay
  • Ethernet etc.
  • PWE3 enables operators to migrate legacy services to packet-switched network PSNs to reduce network operating costs.
  • different levels of the network need to support redundancy: When the resources of the network nodes, links, channels, etc. that are in use are faulty, they can switch to other redundant available resources to ensure that the network can continue to provide provisions. Service.
  • LDP FRR is a fast protection method that pre-calculates the protection path of the tunnel and immediately switches the data packet to the alternate path after detecting the failure of the primary path.
  • LDP FRR can be protected against nodes and links. Protection is always initiated by faulty upstream neighbors. Different nodes establish different protection paths for downstream nodes. Since the path or tunnel from the ingress node to the egress node is usually very long, the upstream node initiates a protection switch, and until the path is completely switched, a long switching time is required.
  • an object of embodiments of the present invention is to provide a method, a device, and a network system for establishing a tunnel to reduce the time for protection switching.
  • embodiments of the present invention adopt the following technical solutions.
  • an embodiment of the present invention provides a network system, including a first export operation.
  • the egress PE, the second egress PE, and the ingress operator edge device Ingress PE communicates with the customer edge device CE, and the second egress PE communicates with the CE, the first Egress PE And the second egress PE is located in a redundant protection group that includes the first egress PE and the second egress PE, where the first egress PE is a primary device, and the second egress PE is a standby device.
  • the first egress PE is configured to: generate a virtual node, where the virtual node has a globally unique router ID, and the virtual node is used as a next hop node of the first egress PE, The virtual node is used as the next hop node of the second egress PE; the first link state message is sent to the ingress PE, and the first link state message includes: a router ID and a location of the first egress PE Status information of the link of the first egress PE to the virtual node, the status information of the link of the first egress PE to the virtual node, including the link of the first Egress PE to the virtual node Cost value M and the virtual a router ID of the point: sending a second link status message to the ingress PE, where the second link status message includes: a router ID of the virtual node, and a link of the virtual node to the first egress PE The status information of the link between the virtual node and the link of the second egress PE, and the status information of the link of the virtual node
  • the cost value T of the path and the router ID of the second egress PE; the second egress PE is configured to: generate the virtual node, send a third link status message to the ingress PE, and the third link
  • the status message includes: a router ID of the second egress PE and the second Egress PE to the virtual node
  • the status information of the link of the second egress PE to the virtual node includes the cost value S of the link of the second Egress PE to the virtual node and the Router of the virtual node.
  • the fourth link status message includes: a router ID of the virtual node and status information of a link of the virtual node to the first egress PE And the status information of the link of the virtual node to the second egress PE, and the status information of the link of the virtual node to the first egress PE includes a chain of the virtual node to the first Egress PE
  • the cost value N of the path and the router ID of the first egress PE, and the status information of the link from the virtual node to the second egress PE includes the cost of the link from the virtual node to the second egress PE.
  • C34+S>M 2 where Px is any neighboring node of the first egress PE, Pxy is any neighboring node of the Px in the network after the first egress PE is removed, and Sxy3 is the Pxy to the The cost of the shortest path of the first egress PE, and the cost of the shortest path of the first egress PE to the second egress PE, and C34 is the cost of the shortest path from the first egress PE to the second egress PE.
  • the router ID of the virtual node is statically configured, or is between the first Egress PE and the second Egress PE. Dynamic negotiation is obtained. With reference to the first aspect and the first possible implementation manner of the first aspect, in a second possible implementation manner of the first aspect, the router ID of the virtual node is a loopback identifier.
  • the first or second possible implementation manner of the first aspect in a third possible implementation manner of the first aspect, if the MS pair satisfying (1) or (2) has multiple groups And selecting the smallest MS pair or the M smallest MS pair, carrying the M in the selected MS pair in the first link state information, and carrying the S in the selected MS pair in the third chain. Road status information.
  • M l
  • S is the maximum cost of the internal gateway protocol IGP.
  • the router ID of the virtual node The IP address of the network protocol owned by the highest priority of the first egress PE and the second egress PE.
  • the second aspect of the present invention provides a network system, including a first egress operator edge device Egress PE, a second egress PE, and an ingress operator edge device Ingress PE, where the first Egress PE communicates with the customer edge device CE.
  • the second egress PE is in communication with the CE, where the first egress PE and the second egress PE are located in a redundant protection group including the first egress PE and the second egress PE, where The first egress PE is a primary device, and the second egress PE is a standby device.
  • the first egress PE is configured to: generate a virtual node, where the virtual node has a globally unique router in the network system.
  • the first link state message includes: a router ID of the first egress PE and state information of a link of the first egress PE to the virtual node, where the first Egress PE is to the virtual node
  • the status information of the link includes the cost value M of the link of the first egress PE to the virtual node and the router ID of the virtual node; sending a second link status message to the Ingress PE, where the The two-link status message includes: a router ID of the virtual node, status information of the link of the virtual node to the first egress PE, and status information of the link of the virtual node to the second egress PE
  • the status information of the link of the virtual node to the first egress PE includes a cost value N of the link of the virtual node to the first egress PE and a router ID of the
  • the second Egress PE is configured to: generate the virtual node, and send the third chain.
  • the status message is sent to the ingress PE, and the third link status message includes: a router ID of the second egress PE and status information of a link of the second egress PE to the virtual node, where The status information of the link of the second Egress PE to the virtual node includes a cost value S of the link between the second egress PE and the virtual node, and a router ID of the virtual node; sending a fourth link status message to The fourth link state message of the Ingress PE includes: a router ID of the virtual node, status information of a link of the virtual node to the first egress PE, and the virtual node to the second The status information of the link of the egress PE, the status information of the link of the virtual node to the first egress PE, including the cost value N of the link of the virtual node to the first egress PE, and the first Router ID of the egress PE, the virtual node to the second
  • the router ID of the virtual node is statically configured, or is obtained by dynamic negotiation between the first egress PE and the second egress PE.
  • the router ID of the virtual node is a loopback identifier.
  • the router ID of the virtual node is the first Egress PE The owned and unoccupied IP address or the network protocol IP address owned by the second egress PE and not occupied.
  • the router ID of the virtual node is the first Egress PE and the second Egress PE The IP address of the network protocol owned by the medium priority and not occupied.
  • the first label is statically configured, or The dynamic negotiation between the first egress PE and the second egress PE is obtained.
  • the embodiment of the present invention provides a method for establishing a tunnel, where the method is applied to a network system, where the network system includes an egress PE, a second egress PE, and an ingress PE, an ingress PE.
  • the first Egress PE and the customer edge device CE In the communication, the second egress PE is in communication with the CE, and the first egress PE and the second egress PE are in a redundant protection group including the first egress PE and the second egress PE, where The first egress PE is the primary device, and the second egress PE is the standby device.
  • the method includes: generating a virtual node in the first egress PE, where the virtual node has a globally unique router ID in the network system. The virtual node is used as a next hop node of the first egress PE, the virtual node is used as a next hop node of the second egress PE, and the virtual node is generated on the second egress PE.
  • the first egress PE sends a first link state message to the ingress PE, where the first link state message includes: a router ID of the first egress PE and the first Egress PE to the virtual Status information of the link of the node, the state information of the link of the first egress PE to the virtual node, the cost value M of the link of the first Egress PE to the virtual node, and the virtual node Router ID; the first Egress PE sends the second The link state message is sent to the ingress PE, and the second link state message includes: a router ID of the virtual node, status information of the link of the virtual node to the first egress PE, and the virtual node.
  • the second egress PE sends a third link status message to the ingress PE, where the third link status message includes: a router ID of the second egress PE and the first The status information of the link of the second egress PE to the virtual node, and the status information of the link of the second egress PE to the virtual node, including the cost value of the link of the second egress PE to the virtual node S and the router ID of the virtual node;
  • the second Eg The ress PE sends a fourth link status message to the Ingress PE
  • C34+S>M 2 where Px is any neighboring node of the first egress PE, Pxy is any neighboring node of the Px in the network after the first egress PE is removed, and Sxy3 is the Pxy to the The cost of the shortest path of the first egress PE, and the cost of the shortest path of the first egress PE to the second egress PE, and C34 is the cost of the shortest path from the first egress PE to the second egress PE.
  • the generating a virtual node on the first egress PE and the second egress PE includes: the first egress PE and the second Egress PE pass dynamic The virtual node is generated in a negotiated manner.
  • the first egress PE and the second egress PE generate the virtual node by using dynamic negotiation.
  • the method includes: establishing an inter-frame communication protocol ICCP connection between the first egress PE and the second egress PE, respectively sending a priority to the other party, and selecting a priority
  • the party with the highest level determines the router ID of the virtual node.
  • the router ID of the virtual node is the first Egress PE and the second Egress PE The IP address of the network protocol owned by the high-level party and not occupied.
  • a fourth possible implementation manner of the third aspect if the priorities of the first egress PE and the second egress PE are equal, The address of the first egress PE and the second egress PE is determined by the larger one of the first egress PE and the second egress PE, and the router ID of the virtual node is determined.
  • the priorities of the first egress PE and the second egress PE are equal, The address of the first egress PE and the second egress PE is determined by the smaller one of the first egress PE and the second egress PE, and the router ID of the virtual node is determined.
  • the router ID of the virtual node is the first Egress PE and the second The owned and unused address of the larger address of the Egress PE.
  • the router ID of the virtual node is the first Egress PE and the second The owned and unused address of the smaller address of the Egress PE.
  • the first egress PE and the second egress PE generate the virtual node by using a dynamic negotiation manner, including: carrying a first type-length-value TLV in the inter-frame communication protocol ICCP packet, where the A TLV includes a vNH field and a priority field, the priority field carrying the ICCP address.
  • the first egress PE and the second egress PE respectively allocate the first label to the first forwarding equivalence class of the first VPN, including: the first Egress PE and The second egress PE allocates the first label by means of dynamic negotiation.
  • the first egress PE and the second egress PE allocate the foregoing by using a dynamic negotiation manner
  • a label includes: establishing an ICCP connection between the first egress PE and the second egress PE, respectively sending a priority to the other party, and selecting a party with a higher priority to determine the first label.
  • the priorities of the first egress PE and the second egress PE are equal, The address of the first egress PE and the second egress PE is determined by the larger one of the first egress PE and the second egress PE.
  • the addresses of the first egress PE and the second egress PE are equal, The address of the first egress PE and the second egress PE is determined by the smaller one of the first egress PE and the second egress PE.
  • the first Egress PE and the The second egress PE allocates the first label by using a dynamic negotiation manner, and the second TLV is implemented by carrying a second TLV in the ICCP packet, where the second TLV includes a VPN label field and a priority field, where the priority field is And a priority of the sender of the ICCP packet, where the VPN label field carries the first label provided by the sender of the ICCP packet.
  • the second TLV further includes an available label upper limit field and an available label lower limit field, where the available label is The upper limit field and the available lower label field are used to determine the range of labels that the sender of the ICCP message can provide.
  • the first or second or third or fourth or fifth of the third aspect Species or sixth or seventh or eighth or ninth or tenth or eleventh or twelfth or thirteenth possible implementation, fifteenth in the third aspect
  • each VPN label allocation mode may be adopted, or a per-route label allocation manner or a per-interface label allocation manner may be adopted.
  • the first or second or third or fourth or fifth or sixth or seventh or eighth or ninth or tenth or Eleventh or twelfth or thirteenth or fourteenth or fifteenth possible implementation manner, in the sixteenth possible implementation manner of the third aspect if (1) or 2)
  • the MS pair has multiple groups, then select the S smallest MS pair or the M smallest MS pair, and carry the M in the selected MS pair in the first link state information, and select the selected MS pair. S is carried in the third link state information.
  • the embodiment of the present invention provides a label distribution method, where the method is applied to a network system, where the network system includes an egress PE, a second egress PE, and an ingress operator edge device Ingress PE.
  • the first egress PE is in communication with the customer edge device CE
  • the second egress PE is in communication with the CE
  • the first egress PE and the second egress PE are located in the first Egress PE and the In the redundancy protection group of the second egress PE
  • the first egress PE is the primary device
  • the second egress PE is the standby device.
  • the method includes: generating a virtual node in the first Egress PE.
  • the virtual node has a globally unique router ID in the network system, and the virtual node is used as a next hop node of the first egress PE, and the virtual node is used as a next hop node of the second egress PE.
  • the first egress PE sends a first link state message to the ingress PE, where the first link state message includes: the first Egress PE The router ID and the status information of the link of the first egress PE to the virtual node, where the status information includes the cost value M of the link of the first egress PE to the virtual node, and the virtual node
  • the router ID is sent by the first egress PE to the ingress PE
  • the second link state message includes: a router ID of the virtual node, and the virtual node to the first Egress The status information of the link of the PE and the status information of the link of the virtual node to the second egress PE, and the status information of the link of the virtual node to the first egress PE includes the virtual node to the location
  • the cost value N of the link of the first egress PE and the router ID of the first egress PE, and the status information of the link of the virtual node to the second egress PE includes the virtual node
  • the second egress PE sends a fourth link state message to the ingress PE, where the fourth link state message includes: a router ID of the virtual node, the virtual node
  • the status information of the link to the first egress PE and the status information of the link of the virtual node to the second egress PE, and the status information of the link of the virtual node to the first egress PE includes The cost value N of the link from the virtual node to the first egress PE and the router ID of the first egress PE, and the status information of the link of the virtual node to the second egress PE includes the virtual The link of the node to the link of the second egress PE An ost value T and a router ID of the second egress PE; the first egress PE allocates a first label to the first forwarding equivalence class of the first virtual private network VPN, and sends the first label and the virtual The router ID of the node is given to the Ingress.
  • the second egress PE allocates the first label to the first forwarding equivalence class of the first VPN, and sends the first label and the router ID of the virtual node to the Ingress PE. .
  • the virtual node is generated by dynamic negotiation.
  • the first egress PE and the second egress PE generate the virtual node by using dynamic negotiation
  • the method includes: establishing an inter-frame communication protocol ICCP connection between the first egress PE and the second egress PE, respectively sending a priority to the peer, and selecting a party with a higher priority to determine a router ID of the virtual node.
  • the router ID of the virtual node is the first Egress PE and An IP address owned by a higher priority party in the second egress PE and not occupied.
  • a fourth possible implementation manner of the fourth aspect if the priorities of the first egress PE and the second egress PE are equal, The address of the first egress PE and the second egress PE is compared, and the router ID of the virtual node is determined by the larger one of the first egress PE and the second egress PE.
  • the first egress PE and the second egress PE have the same priority, The address of the first egress PE and the second egress PE is compared, and the router ID of the virtual node is determined by the smaller one of the first egress PE and the second egress PE.
  • the router ID of the virtual node is owned by a larger one of the first egress PE and the second egress PE Unoccupied address.
  • the virtual The router ID of the node is an address owned by the smaller one of the first egress PE and the second egress PE and is not occupied.
  • the first egress PE and the second egress PE generate the virtual node by using dynamic negotiation, including: carrying the first type-length-value TLV in the inter-frame communication protocol ICCP packet
  • the first TLV includes a vNH field and a priority field, where the priority field carries the priority of the sender of the ICCP message, and the vNH field carries the address of the sender of the CC message.
  • the first egress PE and the second egress PE respectively allocate the first label to the first forwarding equivalence class of the first VPN, including: An egress PE and the second egress PE allocate the first label by means of dynamic negotiation.
  • the first egress PE and the second egress PE allocate the A label includes: establishing an ICCP connection between the first egress PE and the second egress PE, respectively sending a priority to the other party, and selecting a party with a higher priority to determine the first label.
  • the addresses of the first egress PE and the second egress PE are determined by the larger one of the first egress PE and the second egress PE.
  • the priorities of the first egress PE and the second egress PE are equal, The address of the first egress PE and the second egress PE is determined by the smaller one of the first egress PE and the second egress PE.
  • the first Egress PE and the The second egress PE allocates the first label by using a dynamic negotiation manner, and the second TLV is implemented by carrying a second TLV in the ICCP packet, where the second TLV includes a VPN label field and a priority field, where the priority field is And a priority of the sender of the ICCP packet, where the VPN label field carries the first label provided by the sender of the ICCP packet.
  • the second TLV further includes an available label upper limit field and an available label lower limit field, where the available label is The upper limit field and the available lower label field are used to determine the range of labels that the sender of the ICCP message can provide.
  • the label allocation method can also adopt the method of assigning each route label or the label distribution method of each interface.
  • the fifth aspect, the embodiment of the present invention provides a first carrier edge device PE, where the first PE is located in a network system including a second PE, an ingress operator edge device Ingess PE, and the first PE, The first PE and the second PE are used as an egress PE, and the first PE and the second PE are located in a redundant protection group including the first PE and the second PE.
  • the first PE is the primary PE
  • the second PE is the standby PE
  • the first PE is in communication with the customer edge device CE
  • the second PE is in communication with the CE.
  • the first PE includes: Virtual node generation module, first state release module, first a virtual node status issuing module, where: the first virtual node generating module is configured to generate a virtual node on the first PE, where the virtual node has a globally unique router ID in the network system, and the virtual node Used as a next hop node of the first PE, the virtual node is used as a next hop node of the second PE; the first state issuing module is configured to send a first link state message to The first link state message includes: the router ID of the first port and the state information of the link of the first PE to the virtual node, the first PE to the virtual The status information of the link of the node includes the cost value M of the link of the first PE to the virtual node and the router ID of the virtual node; the first virtual node status issuing module is further configured to send the second a link state message to the ingress PE, where the second link state message includes: a router ID of the virtual node, status information of a link of the virtual node to the first
  • the method further includes: a first virtual node address negotiation module, configured to negotiate with the second PE to determine a router ID of the same virtual node.
  • the first PE may further include a first label negotiation module, where Negotiating with the second PE determines the same tag.
  • the first or second possible implementation manner of the fifth aspect in the third possible implementation manner of the fifth aspect, if the MS pairs satisfying (1) or (2) are The group selects the smallest MS pair or the M smallest MS pair, carries the M of the selected MS pair in the first link state information, and carries the selected MS pair in the third. In the link status information.
  • the method, the device, and the system in the embodiment of the present invention configure the same virtual next hop on the egress PE in the redundancy protection group, and send the address of the virtual next hop node to the ingress PE, so that the Ingress PE
  • FIG. 1 is a schematic diagram of a network architecture according to an embodiment of the present invention
  • FIG. 2 is a schematic flowchart of a method for establishing a tunnel according to an embodiment of the present invention
  • FIG. 3 is a schematic diagram of a network architecture including a virtual node according to an embodiment of the present invention
  • FIG. 5 is a schematic flowchart of a method for negotiating a vNH of a virtual node by extending an ICCP according to an embodiment of the present invention
  • FIG. 6 is a schematic flowchart of a method for negotiating a vNH of a virtual node by extending an ICCP according to an embodiment of the present invention
  • FIG. 7 is a schematic diagram of a format of an ICC parameter in an ICCP packet header shown in FIG. 6
  • FIG. 8 is a schematic diagram of a format of a vNH TLV according to an embodiment of the present invention
  • 9 is a schematic diagram of a format of a vNH RG connect message according to an embodiment of the present invention
  • FIG. 10 is a schematic diagram of a format of a vNH RG disconnect message according to an embodiment of the present invention
  • 12 is a schematic flowchart of a method for negotiating a VPN label according to an embodiment of the present invention
  • FIG. 13 is a schematic diagram of a label distribution method according to an embodiment of the present invention
  • FIG. 14 is a schematic diagram of a format of a VPN connect message according to an embodiment of the present invention
  • Figure 16 is a schematic diagram of a format of a VPN application data message according to an embodiment of the present invention
  • Figure 17 is a schematic diagram of a format of a VPN label TLV according to an embodiment of the present invention
  • Figure 18 is a schematic diagram of a network structure of a port-shaped network according to an embodiment of the present invention
  • 20 is a schematic diagram of two network architectures according to Embodiment 2 of the present invention
  • FIG. 21 and FIG. 22 are respectively schematic diagrams of two network architectures according to Embodiment 3 of the present invention
  • FIG. 23 is a schematic diagram of a network structure according to Embodiment 4 of the present invention
  • FIG. 25 is a schematic structural diagram of another network structure according to an embodiment of the present invention
  • FIG. 26 is a schematic structural diagram of a first PE device according to an embodiment of the present invention.
  • the TLV mentioned in the embodiment of the present invention refers to a tag-length-value, a tag-length-value.
  • the IGP (Interior Gateway Protocol) mentioned in the embodiment of the present invention may be an OSPF (Open Shortest Path First) protocol or an ISIS (Intermediate System to Intermediate System) ten. MRT (Maximally Redundant Trees) protocol.
  • the tunnel or the path mentioned in the embodiment of the present invention may be an MPLS tunnel, a GRE (Generic Routing Encapsulation) tunnel, an L2TP tunnel, or an IPsec tunnel.
  • the multiple Egress PEs pass the ICCP.
  • ICCP negotiation is performed between the two.
  • the MRT is used as the IGP protocol, setting the ⁇ and S to any legal value ensures that the last hop node of the egress PE can calculate the second path (alternate path), for example, setting both M and S. Is 1.
  • the second path does not pass through the Egress PE through which the first path (the primary path) passes.
  • the MRT protocol in the IGP protocol can calculate the second path (alternate path) without being restricted by the networking. All embodiments of the invention can be applied to a two-plane network.
  • a network N is called a two-plane network if the following conditions are met:
  • a network portion composed of Rli nodes and links between them is referred to as a plane of the network N; a network portion composed of R2i nodes and links between them is referred to as the network N.
  • the "network” may be an IP network or an MPLS network, and the "node” may be a routing device, or other device having routing functionality.
  • PE can be a routing device, or other device with routing capabilities.
  • the IP address may be an IPv4 (Internet Protocol Version 4) address or an IPv6 (Internet Protocol Version 6) address; the IP network refers to an IPv4 network or an IPv6 network or a mixed IPv4 and IPv6 network.
  • the Router ID is the address of an interface on the device.
  • the router ID can be a loopback address, that is, the IP address of the loopback interface, or the IP address of the device. Of course, it can also be the identifier of other 32-bit unsigned integers.
  • the network includes PE1, PE2, PE3, PE4, PI, and P2.
  • PE Provide Edge device
  • PE2, PE3, and PE4 are the carrier edge devices of the network.
  • CE Customer Edge Device
  • CE1 and CE2 are user devices.
  • CE1 and CE2 belong to the same virtual device.
  • Virtual Private Network (VPN) assuming that CE1 and CE2 belong to VPN1.
  • CE1 is located at site1 and CE2 is at site2.
  • CE2 is dual-homed to PE3 and PE4.
  • CE1 can communicate with CE2 via PE1, P I, and PE3 in sequence, or communicate with CE2 via PE2, P2, and PE4.
  • BGP Border Gateway Protocol
  • P1 and P2 are Provider devices (operator backbone devices) and can have one or more. That is, there may be one or more P devices on the path between PE1 and PE3, and one or more P devices may exist on the path between PE2 and PE4.
  • the CE, PE, and P devices can be routers or other network devices with routing capabilities.
  • the PE device can also be a BRAS (Broadband Remote Access Server).
  • the CE provides the user with a connection to the PE.
  • the PE processes the VPN data from the CE or the LSP (Label Swiching Path) based on the stored routing information, and the PE is responsible for exchanging routing information with other PEs.
  • the P device is a backbone network device that is not connected to any CE.
  • the VPN data is transparently forwarded according to the outer label of the packet.
  • the P device only maintains the routing information of the PE device but does not maintain the VPN-related routing information.
  • Embodiment 1 As shown in FIG. 2, based on the network architecture shown in FIG. 1, the method for establishing a tunnel according to an embodiment of the present invention includes: S200. Establishing a redundant protection group including the first egress PE and the second egress PE, and taking the network architecture shown in FIG. 1 and FIG. 3 as an example.
  • the redundancy protection group includes PE3 and PE4, and the PE3 is assumed to be the first Egress PE and the PE4.
  • PE3 and PE4 can discover that the next hop of the peer and its own are both CE2. Therefore, it is determined that PE3 and PE4 are in the same redundancy protection group. In addition, PE3 and PE4 may also use route reflectors to determine that both parties are in the same redundant protection group. For L3 VPN, it can also be discovered by comparing the broadcast of the VPN route with the route received locally from the CE. Optionally, there may be two or more Egress PEs in the redundant protection group.
  • a virtual node is generated on the first egress PE and the second egress PE to be a virtual node on the first egress PE and the second egress PE, where the virtual node has a globally unique router in the network. ID, the virtual node is used as a next hop node of the first egress PE, and the virtual node is used as a next hop node of the second egress PE.
  • the generation of the virtual node can be implemented by static configuration or dynamic negotiation.
  • PE1 is the ingress PE
  • PE3 and PE4 are the egress PEs.
  • the virtual nodes are generated on PE3 and PE4.
  • the virtual node has a router ID.
  • the router ID can be a loopback loopback address.
  • the router ID is called vNH (virtual next HOP).
  • the network architecture containing the virtual nodes is shown in Figure 3.
  • the router ID of the virtual node may be an IP address owned by the PE3 and an IP address that is not occupied by the PE4, or any loopback address or IP address that is not duplicated between the node devices in the IGP domain.
  • the virtual node is connected to PE3 and PE4 respectively, and the virtual node represents the protection relationship between PE3 and PE4.
  • the vNH of the virtual node can be implemented through static configuration on PE3 and PE4, or through ICCP (Inter-Chassis Communication Protocol) negotiation between PE3 and PE4.
  • the virtual node is only visible to the nodes in the IGP (Internal Gateway Protocol) domain, that is, it is only visible to the devices and devices in the network, and is invisible to CE2.
  • CE2 is still associated with ⁇ 3 and ⁇ 4.
  • the vNH of the virtual node can adopt a unique loopback address in the network, and can adopt a static configuration or a dynamic selection method.
  • the static configuration needs to be configured on multiple egress PEs in the redundancy protection group.
  • the vNH of the virtual node can be statically configured on PE3 and PE4. If the vNH of the virtual node is configured in the dynamic negotiation mode, a loopback address is dynamically negotiated in multiple egress PEs in the redundancy protection group.
  • a method for negotiating a vNH of a virtual node is applied to the L3VPN, including:
  • PE3 in the context identifier.
  • the "PE4" can be represented by the router ID of PE3 and the router ID of PE4.
  • the virtual next hop vNH If the virtual next hop vNH is not selected, select an unused loopback address or IP address from the loopback address pool of the highest priority of PE3 and PE4 as the router ID of the context identifier, and The virtual next hop vNH re-advertises the VPN route with the virtual next hop.
  • the VPN route carries a second attribute, where the second attribute indicates the priority of the vNH.
  • the PE3 and the PE4 can learn that the peer PE also has the context identifier processing capability, and compare the priority of the PE3 and the PE4 according to the carried attributes. Then, compare the next hop in the peer route with the next hop of the local route, and select the PE with the smaller IP address as the virtual next hop vNH. If the result of the selection is the local address, no processing is performed; if the result of the selection is the peer PE, the VPN route is re-published according to the new vNH.
  • the redundancy protection group RG includes two Egress PEs PE3 and PE4, PE3.
  • the method of negotiating the vNH of the virtual node by extending the ICCP (Inter-Chassis Communication Protocol), and the method of negotiating the vNH of the virtual node by extending the ICCP includes:
  • Redundant protection group The local PE and the peer PE in the RG send ICCP capability packets to each other to request to establish an ICCP connection.
  • the local PE and the peer PE After the local PE and the peer PE receive the ICCP Capability packet sent by the peer, the local PE and the peer PE restart to establish an ICCP connection.
  • the local PE and the peer PE send vNH RG connect packets to each other.
  • the local PE and the peer PE respectively send a vNH data message to the other party, where the vNH data message carries a vNH TLV, where the vNH TLV carries the sender's priority.
  • the local PE and the peer PE After receiving the vNH data message with the vNH TLV sent by the peer, the local PE and the peer PE compare the priority of the vNH data message sent by the peer with the priority of the vNH data message. If the vNH data message sent by the other party is carried, If the priority is greater than the priority of the user, the one with the smaller priority configures the unoccupied address as the vNH of the virtual node, and the one with the higher priority chooses the one that is owned by the user and is not occupied. The address is configured as the V ray of the virtual node.
  • the vNH of the virtual node generated on the PE3 may be configured as an address that is owned by the PE3 and is not occupied (such as address 1), and the virtual node generated on the PE4.
  • the vNH can also be configured as the address selected by the PE3 (such as the address 1). If the priority of the PE3 is less than the priority of the PE4, the vNH of the virtual node generated on the PE3 can be configured as an address that is owned by the PE4 and is not occupied. Address 2), the vNH of the virtual node generated on PE4 can also be configured as an address owned by PE4 and not occupied (such as address 2).
  • the ICCP message can be carried by an LDP (Label Distribution Protocol) message.
  • the LDP message may include an LDP header and an LDP packet whose type value is 0x0700 to 0x07ff.
  • the message mentioned in the embodiment of FIG. 5 is as follows:
  • the format of the ICCP header (ICC header) is as shown in FIG. 6.
  • ICCP header includes U bits
  • U bit Unknown message bit.
  • Message Type Identifies the type of ICCP message, which must be in the range between 0x0700 and 0x07ff.
  • Message Length A two-byte integer that identifies the total length of the message, excluding the U-bit, message type, and length field message ID (Message ID): A four-byte value that identifies the message .
  • the sender PE uses this field to facilitate identification of the RG notification message that can be applied to the message. When the PE sends an RG notification message as a response to the message, it shall add the message identifier to the "NAK TLV" of the RG notification message.
  • ICC RG ID TLV TLV of type 0x0005, length 4, containing 4 bytes of undefined integer, indicating the Redundancy Group of the sending device.
  • Mandatory Parameters Variable length required parameters.
  • Optional Parameters Variable length optional message parameters.
  • Type (Type) 14 bits, indicating the parameter type Length (Length): Byte length of TLV, excluding U-bit, F-bit, type and length field
  • TLV ( s ) Depending on the message type, there may be one or more TLVs or no TLVs
  • the ICCP negotiating the vNH of the virtual node may be implemented by adding a vNH TLV to the ICC message.
  • FIG. 8 it is a schematic diagram of a format of a vNH TLV according to an embodiment of the present invention.
  • the vNH TLV includes U bits, F bits, Type, Length, Priority, vNH, and Reserved field ( Reserved ). The meaning of each field is as follows:
  • the TLV can be forwarded as opaque data in the node without identifying the TLV type (Type): 14 bits, indicating the parameter type, the length can be arbitrarily set (Length): TLV word Section length, excluding U bits, F bits, type and length Degree domain.
  • Priority indicates the priority virtual next hop vNH of the node that generates the message containing the TLV: indicates the IP address of the node that generates the message containing the TLV, and the IP address may be an IPv4 address or an IPv6 address reserved field ( Reserved ): Reserved for other purposes.
  • the vNH TLV is carried in the vNH data message sent by the local egress PE to the peer egress PE.
  • the vNH TLV carries the vNH data message.
  • the PE that receives the vNH data message compares its own priority with the priority carried in the received vNH data message. If its priority is higher than the received priority. If the priority of the vNH data message is the same, the vNH selected by the vNH data message is selected as the router ID of the virtual node. If the priority of the vNH data message is less than the priority of the received vNH data message, the vNH data message is selected.
  • the sender selected by the sender as the virtual router's router ID; if its own priority is equal to the priority carried in the received vNH data message, the sender of the received vNH data message and the party with the largest IP address are selected.
  • the vNH is the router ID of the virtual node.
  • ⁇ 3 and ⁇ 4 respectively send an NH data message to the other party, and the first vNH data message sent by the PE3 carries the priority of the PE3 and the IP address of the PE3, and the second vNH data message sent by the PE4 carries the priority of the PE4. IP address of PE4. If the priority of the PE3 is higher than the priority of the PE4, the vNH selected by the PE3 is selected as the router ID of the virtual node. If the priority of the PE3 is less than the priority of the PE4, the vNH selected by the PE4 is selected as the router ID of the virtual node. If the priority of the PE3 is equal to the priority of the PE4, the IP address of the PE3 and the IP address of the PE4 are compared.
  • the vNH selected by the PE3 is selected as the router ID of the virtual node. If the IP address is smaller than the IP address of PE4, the vNH selected by PE4 is selected as the router ID of the virtual node.
  • IP address of ⁇ 3 is smaller than the IP address of PE4, select vNH selected by PE3 as the virtual node.
  • the egress PE with the highest priority can select the IP address or loopback address that is owned by the Egress PE as the virtual node generated on each Egress PE in the redundancy protection group. You can also select the globally unique Router ID in the network.
  • the vNH RG connect message format is shown in Figure 9.
  • the vNH RG connect message carries a vNH connect TLV, which includes a U bit, an F bit, a Type, a Length, a Protocol Version, an A bit, a Reserved field, and an optional sub-option. TLV.
  • the value of the type (Type) is customized, for example, it can be 0x0101.
  • the type value in the vNH RG disconnect message can be 0x0701.
  • the vNH RG disconnect message carries the disconnect code TLV, and of course other optional TLVs can be carried.
  • the length of the Type and Length in the vNH disconnect code TLV is 2 bytes.
  • the values of Type and Length are customized.
  • the type in the vNH disconnect code TLV can be 0x0104.
  • the vNH RG application data message format is shown in Figure 11.
  • the message type and the TLV type code value are just one possible code value, and can be other values, as long as they are not standard (draft-ietf- The assigned values in pwe3-iccp-l l (other related standards) can be conflicted.
  • the first egress PE After the virtual node is generated on the first egress PE, the first egress PE sends a first link status message to the ingress operator edge device Ingress PE, where the first link status message includes: The status information of the link of the egress PE and the link of the first egress PE to the virtual node, and the status information of the link of the first egress PE to the virtual node includes the first Egress PE to The cost value M of the link of the virtual node and the router ID of the virtual node.
  • the first egress PE sends a second link state message to the ingress PE, where the second link state message includes: a router of the virtual node ID, a status of the link of the virtual node to the first egress PE And the status information of the link between the virtual node and the second egress PE, and the status information of the link of the virtual node to the first egress PE includes the virtual node to the first Egress PE.
  • the cost value N of the link and the router ID of the first egress PE, and the status information of the link from the virtual node to the second egress PE includes the link of the virtual node to the second egress PE.
  • the cost value T and the router ID of the second egress PE includes: a router of the virtual node ID, a status of the link of the virtual node to the first egress PE And the status information of the link between the virtual node and the second egress PE, and the status information of the link of the virtual node to the first egress PE includes the virtual node
  • the N and the T are the maximum cost values of the internal gateway protocol IGP.
  • the second egress PE sends a third link status message to the ingress PE, where the third link status message includes: the second Egress PE And the status information of the link of the second egress PE to the virtual node, and the status information of the link of the second egress PE to the virtual node includes the second Egress PE to the virtual The cost value S of the link of the node and the router ID of the virtual node.
  • the second egress PE sends a fourth link status message to the ingress PE, where the fourth link status message includes: a router of the virtual node ID, status information of the link of the virtual node to the first egress PE, and status information of the link of the virtual node to the second egress PE, the virtual node to the first Egress PE
  • the status information of the link includes the cost value N of the link from the virtual node to the first egress PE and the router ID of the first egress PE, and the link between the virtual node and the second egress PE
  • the status information includes a cost value T of the link from the virtual node to the second egress PE and a router ID of the second egress PE.
  • the N and the T are the maximum cost values of the internal gateway protocol IGP.
  • the Ingress PE such as PE1 receives the first link state message, the second link state message, the third link state message, and the fourth link state message, obtain the The vNH of the virtual node, the cost value M of the link of the first egress PE to the virtual node, and the cost value S of the link of the second Egress PE to the virtual node.
  • any one of the first link state message, the second link state message, the third link state message, and the fourth link state message may also be Including other attributes, such as MPLS TE tunnels, including bandwidth, affinity attributes, One or more of colors, etc.
  • S and M can be set to any legal IGP cost value. It is also possible to configure S and M statically. Furthermore, the present invention provides an automatic calculation method for a GRE tunnel and an MPLS tunnel established based on LDP.
  • the cost value S of the link of the second Egress PE to the virtual node, and the determined cost value M of the link from the first Egress PE to the virtual node and the second Egress PE to the virtual node is synchronized to the redundancy protection group where the first egress PE and the second egress PE are located:
  • Px is any neighboring node of the first egress PE
  • Pxy is any neighboring node of the Px in the network after the first egress PE is removed.
  • Sxy3 is the cost value of the shortest path of the Pxy to the first egress PE
  • Sxy4 is the cost value of the shortest path of the Pxy to the second egress PE
  • C34 is the first Egress PE to the Cost value of the shortest path of the second Egress PE.
  • each Egress PE in the redundancy protection group can calculate the MS pair that satisfies inequality 1 and inequality 2, that is, the PE3 in the redundancy protection group can calculate the inequality. 1 and MS pairs of inequality 2, PE4 in the redundancy protection group can also calculate MS pairs satisfying inequality 1 and inequality 2.
  • the Ss of all the egress PEs that are deployed in the redundancy protection group can be determined by negotiation.
  • the S smallest MS pair or the M smallest MS pair is selected, and the selected MS pair is synchronized to the redundancy protection group.
  • the M in the selected MS pair is carried in the first link state information, and the S in the selected MS pair is carried in the third link state information.
  • the MS pair may be determined according to mode (1) or mode (2) on any one of the redundancy protection groups, and the determined MS pair is synchronized to other Egress PEs in the redundancy protection group.
  • the synchronization of the determined MS pair to other egress PEs in the redundancy protection group may be implemented by using a synchronization protocol.
  • M and S can also be configured on all Egress PEs of the redundancy protection group according to the mode (2). For example, you can set M to 1 and set S to the maximum value of the cost in the IGP protocol.
  • M and S may also be calculated according to mode (1) or (2) on multiple Egress PEs of the redundancy protection group, if multiple sets of MS pairs satisfying the condition are obtained according to mode (1) or (2), Then, the S smallest MS pair or the M smallest MS pair is selected. Of course, a set of MS pairs satisfying the inequalities 1 and 2 may also be selected.
  • the M in the selected MS pair is carried in the first link state information
  • the S in the selected MS pair is carried in the third link state information.
  • the last hop node P1 of PE3 calculates the third path through PE1 starting from P1 and not passing through PE3 through the IGP: ⁇ 1-> ⁇ 2-> ⁇ 4-> virtual node, the third path and the PE1 in the first path ->P1 Form the second path: ⁇ 1-> ⁇ 1-> ⁇ 2-> ⁇ 4->Virtual node.
  • the second path does not pass through Egress PE PE3.
  • the tunnel from the Ingress PE to the virtual node includes a first path and a second path.
  • the first path and the second path may be an MPLS LSP generated by running LDP, or may be a path or a tunnel generated according to other protocols.
  • the IGP may be an OSPF (Open Shortest Path First) protocol or an ISIS (Intermediate System to Intermediate System) protocol or an MRT.
  • PE1 is the ingress PE
  • PE3 and PE4 are the egress PEs.
  • PE3 is the primary device (Primary PE) in the redundant protection group including PE3 and PE4, and PE4 is the PE3 and PE4.
  • the backup device in the redundant protection group (Backup PE) establishes a primary tunnel or primary path ⁇ 1-> ⁇ 1-> ⁇ 3-> virtual node that reaches the virtual node through the primary device PE3, and establishes the primary device PE3 in turn.
  • the previous hop node P1, the previous hop node of the standby device PE4, and the backup device PE4 reach the protection tunnel or protection path of the virtual node? 1->?1->?2->? 4->Virtual node, the protection tunnel Or the protection path does not pass through the primary device PE3.
  • each node is the primary device (Primary PE) in the redundant protection group including PE3 and PE4, and PE4 is the PE3 and PE4.
  • the backup device in the redundant protection group (Backup PE) establishes a primary tunnel or primary path
  • the intermediate node containing the path determines the next hop according to its own total cost to the virtual node, thereby obtaining the entire tunnel path.
  • MPLS Multi Protocol Label Switch
  • the tunnel is route-dependent.
  • PE3 is used as the transit node of the primary tunnel, you can set the cost of the IGP link.
  • PE4 is required as the transit node of the primary tunnel, the link cost values of the IGPs of PE3 and PE4 can be exchanged.
  • the setting of the link cost value can also have other setting methods. For a specific network, there are multiple values that can be used, usually a range. The above method is only one of them.
  • a pair of PEs that are mutually protected are the primary devices.
  • the standby devices are relative to the ingress PE of the tunnel (such as PE1 in Figure 3). Different Ingress PEs may have different primary devices and backups. device.
  • the cost setting can be used to calculate the second path according to the LFA algorithm when the M and S solutions are available, so that the protection of the egress PE can be switched to the second by the P device of the egress PE. The path is done.
  • the method of the embodiment of the present invention can be implemented by simply replacing the Egress PE without changing the P device that supports the LFA on the live network.
  • the other method for setting the cost value is: M and S satisfy X+M ⁇ Y+S, where X is the cost value of the shortest path from the Ingress PE to the first Egress PE, and Y is from the Ingress. Cost value of the shortest path from the PE to the second egress PE. For example, you can set M to 1 and S to be the legal maximum of IGP (the legal maximum values of different IGP protocols are different, and the specific implementation vendors will be slightly different).
  • This cost setting has the same primary and backup devices for all Ingress PEs. In some cases, it is not important for the active device to be the backup device. If a different ingress PE can select a PE in the redundancy protection group as the primary Egress PE, the traffic load balancing is beneficial.
  • the MRT is used as the IGP protocol
  • setting the M and S to any legal value ensures that the last hop of the Egress PE can calculate the second path (alternate path). For example, both M and S are set to 1.
  • the second path (the alternate path) does not pass through the Egress PE through which the first path (the primary path) passes.
  • the MRT protocol in the IGP protocol can calculate the second path (alternate path) without being restricted by the networking.
  • the virtual node, the link between the virtual node and the PE3, and the generation of the link between the virtual node and the PE4 can be completed by using the IGP protocol between the PE3 and the PE4.
  • the first LSA includes: Router ID and PE3 of PE3.
  • the status information of the link of the virtual node, and the status information of the link of the PE3 to the virtual node includes the cost value of the link of the PE3 to the virtual node and the router ID of the virtual node.
  • PE3 Since the virtual node is generated on PE3, PE3 also constructs a second LSA "on behalf of" the virtual node, and the second LSA is Flooding into the entire network.
  • the second LSA includes: a router ID of the virtual node, status information of the link of the virtual node to the PE3, and status information of a link of the link of the virtual node to the PE4.
  • the status information of the link from the virtual node to the PE3 includes the cost value of the link from the virtual node to the PE3 and the router ID of the PE3.
  • the status information of the link from the virtual node to the PE4 includes the link of the virtual node to the PE4. Cost value and the router ID of PE4.
  • the OSPF domain can be the entire network.
  • the PE4 updates its link state and neighbor relationship, constructs a third LSA, and floods the third LSA to the entire network.
  • the third LSA includes: a router ID of the PE4 and status information of the link of the PE4 to the virtual node, and the status information of the link of the PE4 to the virtual node includes a cost value of the link of the PE4 to the virtual node, and the virtual node Router ID.
  • the PE4 also constructs a fourth LSA on behalf of the virtual node, and floods the fourth LSA to the entire network.
  • the fourth LSA includes: a router ID of the virtual node, Status information of the link from the virtual node to PE3, and status information of the link from the virtual node to PE4.
  • the status information of the link from the virtual node to the PE3 includes the cost value of the link from the virtual node to the PE3 and the router ID of the PE3.
  • the status information of the link from the virtual node to the PE4 includes the link of the virtual node to the PE4. Cost value and the router ID of PE4.
  • PE3 and PE4 flood the LSAs into the OSPF domain.
  • the link status is the description information on the OSPF interface of the router, such as the IP address, subnet mask, network type, cost value, and so on.
  • the OSPF routers exchange not the routing table, but the link status.
  • the OSPF router (such as PE1) obtains the exact network path to each target by obtaining all the link state information in the network.
  • the link state and the neighbor relationship are configured to construct a first link state message LSP (Link-state PDU), and flood the first LSP to the entire network, where the first LSP includes: a router ID of PE3 and a PE3 to the virtual The shape of the link of the node
  • the status information of the link of the PE3 to the virtual node includes the cost value of the link of the PE3 to the virtual node and the router ID of the virtual node.
  • the PE3 also constructs a second LSP on behalf of the virtual node, and floods the second LSP to the entire network.
  • the second LSP includes: a router ID of the virtual node, Status information of the link of the virtual node to PE3 and status information of the link of the link of the virtual node to PE4.
  • the status information of the link from the virtual node to the PE3 includes the cost value of the link from the virtual node to the PE3 and the router ID of the PE3.
  • the status information of the link from the virtual node to the PE4 includes the link of the virtual node to the PE4. Cost value and the router ID of PE4.
  • Egress PEs in the redundancy protection group also construct corresponding LSPs and flood these LSPs into the entire ISIS domain, which may be the entire network.
  • the PE4 updates its link state and neighbor relationship, constructs a third LSP, and floods the third LSP to the entire network.
  • the third LSP includes: a router ID of the PE4 and status information of the link of the PE4 to the virtual node, and the status information of the link of the PE4 to the virtual node includes a cost value of the link of the PE4 to the virtual node, and the virtual Router ID of the node.
  • the PE4 also constructs a fourth LSP on behalf of the virtual node, and floods the fourth LSP to the entire network.
  • the fourth LSP includes: the router ID of the virtual node.
  • the status information of the link from the virtual node to the PE3 includes the cost value of the link from the virtual node to the PE3 and the router ID of the PE3.
  • the status information of the link from the virtual node to the PE4 includes the link of the virtual node to the PE4. Cost value and the router ID of PE4.
  • PE3 and PE4 flood these LSPs into the ISIS domain, so that other nodes in the same ISIS domain as PE3 and PE4, such as PE1, can "see” the virtual node, the link between the virtual node and PE3, The link between the virtual node and the PE4, thereby being able to establish a tunnel from PE1 to the vNH of the virtual node. Attribute value of the link between the generated virtual node and the egress PE in the redundant protection group
  • cost value can be set automatically or manually according to the situation. For example, if you want PE3 to be the node through which the primary path of the tunnel passes, and PE4 becomes the node through which the alternate path of the tunnel passes, you can set the cost of the link from PE3 to the virtual node to 1, and connect the link from PE4 to the virtual node.
  • the cost value is set to the maximum cost of the IGP. According to the different IGPs running between PE3 and PE4, you can set the maximum cost of different links. For example, when OSPF is running on the network, the link is used.
  • the maximum cost value can be set to 65535.
  • the cost value of the link from the virtual node to the PE3 and the cost of the link from the virtual node to the PE4 can be set to the maximum cost of the IGP.
  • the virtual node needs to be configured in overload mode.
  • the OSPF protocol can be implemented by setting the cost value of the link from the virtual node to the egress PE node PE3 and the cost value of the link from the virtual node to the PE4 to the maximum cost of the IGP. Under the ISIS protocol, this can be achieved by setting the overload bit of the second LSP and the fourth LSP to 1.
  • a physical link is usually bidirectional, and the links described in the IGP are directional, and each direction needs to be described separately.
  • the cost value of a physical link in different directions may be different or the same.
  • Virtual nodes are not physically present, but are generated for other nodes in the IGP domain to calculate a PE3 tunnel.
  • the upstream node P1 of PE3 can calculate another standby tunnel that reaches PE4, such as PE1->P1->P2->PE4, and the standby tunnel does not pass through PE3. In this way, when the PE3 is faulty, the traffic can be switched to the standby tunnel through the P1 to reach the PE4, thereby achieving the purpose of protecting the PE3.
  • PE3 and PE4 are symmetric, the primary tunnel passing through PE4 can also be established, and the upper hop node of PE4 (such as P2 in Figure 3) establishes a standby tunnel that passes through PE3 and does not pass through PE4, such as PE1->P2- >P1->PE3.
  • the traffic is switched to the backup tunnel on P2 to protect PE4.
  • the first egress PE allocates a first label to the first forwarding equivalence class of the first virtual private network VPN
  • the second egress PE allocates the first label to the first forwarding equivalence class of the first VPN.
  • the egress PE and the second egress PE respectively allocate the first label to the first forwarding equivalence class of the first VPN.
  • Assigning labels can be either assigning labels to each route, assigning labels to each VPN, or assigning labels to each interface or port. .
  • Each PE has its own label space and is allocated independently. If the ingress PE sends a packet to the egress PE, the ingress PE adds the label assigned to the VPN by the egress PE.
  • PE3 is usually a VPN (such as VPN1).
  • the assigned VPN label is 1100
  • the VPN label assigned by PE4 to the VPN1 may be 2100.
  • PE3 can correctly find the corresponding VPN with 1100 (that is, VPN1). ). If the VPN packet carrying the VPN label 1100 is sent to the PE4, the PE4 will not be able to identify the VPN packet and correctly process it. Otherwise, the packet will be forwarded to other VPNs incorrectly, or the corresponding entry of the VPN label 1100 is not available on the PE4. The VPN packet is discarded or the VPN packet is not processed.
  • PE3 and PE4 allocate the same VPN to a VPN (such as VPN1) through dynamic negotiation or static configuration when it finds that it is in the redundancy protection group.
  • a VPN such as VPN1
  • the label so that the VPN message can be correctly processed regardless of whether the VPN is sent to the primary PE (such as PE3) or the standby PE (such as PE4).
  • An ICCP session can be established between PE3 and PE4, and the same label assigned to the VPN is negotiated. Both PE3 and PE4 use the same label as the label of the VPN route when advertising VPN routes.
  • the method of assigning each VPN label can actually use the method of assigning labels per route (that is, assigning a label to each route of the VPN), or assigning each interface.
  • Label mode one label is assigned to each attached circuit AC (Attached Circuit) interface).
  • a method for assigning a VPN label by using a VPN includes:
  • the local PE (such as PE3 in Figure 3) and the peer PE (such as PE4 in Figure 3) send ICCP capability packets to the other party to request the establishment of an ICCP connection.
  • the local PE and the peer PE send VPN RG connect packets to each other.
  • 51205 The local PE and the peer PE respectively send a VPN data message to the other party, where the VPN data message includes a VPN label TLV, and the VPN label TLV carries its own priority.
  • Assign Lr If the priority of the local PE is greater than that of the remote PE, and the label (Lr) assigned by the peer PE is already occupied by the local PE, a label Li is selected from the available label space of the peer PE. The end PE is not assigned, and the local PE allocates Li to the VPN. Update the ICCP message with the newly assigned tag. If the priority of the local PE is smaller than that of the peer PE, check whether the label Lr allocated by the peer PE is already occupied by the local PE. If the label Lr allocated by the peer PE is not occupied by the local PE, Use Lr. If the label Lr allocated by the peer PE is occupied by the local PE, the peer PE allocates a new label L1, and the update ICCP message is sent to the local PE.
  • the label L1 is not occupied by the local PE, the label is used. L1 is used as the label of the VPN. If the label L1 is occupied by the local PE, the peer PE allocates another label Ln as the label of the VPN. If the priority of the local PE is the same as the priority of the peer PE, the local PE and the peer PE report errors respectively, and send an RG notification message carrying the reject TLV and the priority error TLV.
  • the local PE determines a label that is available to both parties, and sends the label to the peer PE in the VPN label TLV of the VPN data message.
  • the peer PE After the VPN data message sent by the local PE is received by the peer PE, the peer PE checks the availability of the label determined by the local PE.
  • the peer PE determines that the label determined by the local PE is unavailable, the peer PE sends a VPN data message to the local PE.
  • the VPN label TLV of the VPN data message carries the label value recommended by the peer PE and the peer PE. Available label space;
  • the local PE receives the VPN data message sent by the peer PE and carries the label value recommended by the peer PE and the available label space of the peer PE, reselects the label, and carries the newly selected label.
  • the packet is sent to the peer PE in the VPN label TLV of the VPN data message;
  • the primary egress PE (such as P3) of the egress PE of the egress PE (such as PE3) can be used when the active Egress PE (such as PE3) fails.
  • the traffic is quickly switched from the primary Egress PE (such as PE3) to the standby Egress PE (such as PE4).
  • There are several methods for detecting the fault of the primary Egress PE For example, you can determine whether the primary PE is faulty according to the status of the physical interface. You can also run BFD between the ingress PE (such as PE1) and the egress PE (such as PE3).
  • the Bidirectional Forwarding Detection (Bidirectional Forwarding Detection) protocol determines whether the primary PE is faulty.
  • the backup path can be pre-computed and installed on the forwarding plane.
  • the BFD protocol or Ethernet OAM Interconnection Management and Maintenance
  • the backup path can be used from the primary PE within 50ms.
  • PE3 to the standby PE (such as PE4).
  • Fault detection can also be limited to the link layer between the two devices directly connected to the link.
  • the fault detection can be limited to P1 on the primary tunnel.
  • the backup PE (such as PE4) needs to be able to correctly process the VPN inner label.
  • the primary PE such as PE3
  • the standby PE such as PE4
  • the method of assigning the same label to the VPN enables the standby PE (such as PE4) to receive the traffic switched from the primary PE (such as PE3) and process it according to the normal VPN process, without special forwarding hardware and processes.
  • the VPN connect message is used to establish a single application connection between the ICCP redundancy protection group connection and the PE in the redundancy protection group (individual application) Connections). As shown in Figure 14, the VPN connect message includes:
  • the VPN connect TLV includes: U bit, F bit, Type, Length, Protocol Version, A bit, Reserved field, and optional sub TLV.
  • the value of the type (Type) is customized, for example, it can be 0x0111.
  • the value of the protocol version field can be 0x0001.
  • the values of U bits and F bits can be set to zero.
  • the VPN disconnect message is used as:
  • the type value of the VPN disconnect message can be 0x0701.
  • the VPN disconnect message carries the VPN disconnect code TLV shown in Figure 15 (a).
  • the VPN disconnect message can also carry other optional TLVs.
  • the type of the Type and Length in the TLV is 2 bytes.
  • the values of Type and Length are customized.
  • the type in the VPN disconnect code TLV can be 0x0114.
  • the VPN disconnect message may also carry the VPN disconnect Cause TLV shown in Figure 15 (b).
  • the VPN disconnect Cause TLV includes: U bit, F bit, Length (Type), Type (Type), and Disconnect Cause String.
  • Disconnect Cause String indicates the reason why the ICCP connection is disconnected during VPN label negotiation.
  • the value of the U bit and the F bit may be zero.
  • the length of the Type and Length in the TLV is 2 bytes.
  • the values of Type and Length are customized.
  • the type in the VPN disconnect code TLV can be Is 0x0115.
  • the VPN application data message is used to transfer data between PEs in the same redundancy protection group.
  • the VPN application data message includes: a single VPN application data message can be used to carry data of an application, and multiple application TLVs can be carried in a separate VPN application. In the data message, as long as the multiple application TLVs belong to the application.
  • the format of the VPN application data message includes an ICC header with the message type RG Application Data Message (0x703) and an application specific TLV (Application specific TLV).
  • the VPN application data message in addition to the ICC header, the VPN application data message also includes the VPN feature TLV: VPN config TLV.
  • the VPN config TLV includes U bits, F bits, Type, Length, Redundant Object Identification (ROID), Service Name TLV (Service Name TLV), and VPN Label TLV (VPN Label TLV), where U and F bits The value can be 0.
  • the type value can be 0x01112.
  • the ROID Redundant Object Identifier
  • the redundant object may be a link, a link, a virtual local area network, or the like.
  • the service name TLV can include U bits, F bits, Type, Length, and service name.
  • the U bit and F bit value can be 0, the Type value is customized, for example, it can be 0x0113, the service name includes the name of the L2VPN service instance encoded in UTF-8 format, and the service name field can be up to 80 characters (character ).
  • the VPN label TLV is used to identify the PE that sends the VPN application data message.
  • the VPN label assigned by the Ingress PE The primary PE (such as PE3) and the standby PE (such as PE4) send VPN application data messages to each other to negotiate the same VPN label for the ingress PE.
  • the VPN label TLV format is shown in Figure 17.
  • the VPN label TLV includes U bits, F bits, Type, Length, Label Lower, Label upper, and Reserved.
  • the value of the U bit and the F bit may be 0, and the value of the type (Type) is a custom value, for example, it may be 0x0102.
  • Label Lower identifies the lower limit of the available label space;
  • Label upper identifies the upper limit of the available label space.
  • the message type in the above message and the encoded value of the TLV type are only one possible encoded value, and may be other values as long as they do not conflict with the assigned values in the standard (draft-ietf-pwe3-iccp-l l ). .
  • the method in the foregoing embodiment is directed to a scenario in which a redundant protection group includes only two egress PEs, and the method can be applied to a redundancy protection group including multiple egress PEs (Egress PEs).
  • a PE is the node through which the primary tunnel of an ingress PE passes.
  • the other PEs are the nodes through which the backup tunnel passes, and the backup tunnel does not pass through the PE node through which the primary tunnel passes.
  • multiple standby PEs can replace the primary PE in priority order, that is, switch the primary tunnel to a standby tunnel.
  • a redundancy protection group that includes multiple egress PEs
  • the other egress PEs in the remaining protection group are the standby Egress PEs of the redundancy protection group. If the egress PEs have the same priority and are the highest priority egress PEs in the redundancy protection group, compare the addresses of the multiple Egress PEs with the same priority and select the multiple priorities.
  • the egress PE with the largest or smallest address is the primary Egress PE.
  • the redundancy protection group includes five egress PEs: PE1, PE2, PE3, PE4, and PE5, PE1, PE2, and PE3 have the same priority and the priorities of PE1, PE2, and PE3 are higher than those of PE4 and PE5.
  • Level compare the address between PE1, the address of PE2, and the address of PE3. Assume that the comparison result is that the address of PE 1 is greater than the address of PE2. If the address of PE2 is greater than the address of PE3, the PE1 with the largest address can be selected as the The primary Egress PE of the redundancy protection group. Of course, the PE3 with the lowest address can also be selected as the primary Egress PE of the redundancy protection group.
  • the tunnel can be set up from the ingress PE to the virtual node through the egress PE.
  • the backup tunnel can be set up.
  • the standby tunnel does not pass through the primary Egress PE.
  • multiple standby egress PEs can replace the active egress PEs in the priority order. That is, the traffic is switched from the primary tunnel that passes the primary Egress PE to the virtual node to the primary PE.
  • the last hop node and the standby Egress PE reach the standby tunnel of the virtual node.
  • the ICCP negotiation of PE is achieved through two-two ICCP negotiations.
  • the method of the embodiment of the present invention can also be used together with MRT (Maximally Redundant Trees) FRR (Fast ReRoute), and the MRT FRR can ensure that the backup tunnel can be calculated as long as the network is 2-connected.
  • the backup tunnel calculated by the upstream neighbor of the primary PE does not pass through the primary PE. That is to say, once the primary PE fails, the packet can be switched to the backup PE.
  • a network is said to be 2-connected, if the network is only split into 2 parts or more when at least two nodes are deleted (A graph that has no cut-vertices. This is a graph that requires Two nodes to be removed before the network is partitioned ).
  • the definition of the 2-connected network can be found in the IETF draft-enyedi-rtgwg-mrt-fir-algorithm-02.
  • some networks may not use MRT FRR technology.
  • the upstream Egress PE is used.
  • the neighbor may not calculate the backup tunnel.
  • the embodiment of the present invention further provides a method for generating a link cost value between the active and standby Egress PEs to the virtual nodes, which can improve the possibility of calculating the backup tunnel based on the LDP FRR of the IGP LFA, and improve the technical solution of the embodiment of the present invention. Deployability.
  • the primary Egress PE is the PE3 and the standby Egress PE is the PE4.
  • the link cost of the PE3 to the virtual node is M
  • the link cost of the PE4 to the virtual node is S.
  • S and M can be set to any legal IGP cost value. It is also possible to configure S and M statically.
  • the present invention provides an MPLS tunnel for GRE tunnels and LDP-based establishment. Automatic calculation method.
  • the cost value M of the link from the PE3 to the virtual node and the cost value S of the link from the PE4 to the virtual node are synchronized to the redundant protection group in which the PE3 and the PE4 are located:
  • X is the cost value of the shortest path from the Ingress PE to the first Egress PE (PE3), which is greater than the value from the Ingress PE to the second Egress PE (PE4)
  • PE3 the cost value of the shortest path
  • PE4 the cost value of the link from the egress PE to the virtual node
  • each Egress PE in the redundancy protection group can calculate the MS pair that satisfies inequality 1 and inequality 2, that is, the PE3 in the redundancy protection group can calculate the inequality.
  • PE4 in the redundancy protection group can also calculate MS pairs satisfying inequality 1 and inequality 2. If multiple egress PEs in a redundant protection group have different MS pairs, the Ss of all the egress PEs that are deployed in the redundancy protection group can be determined by negotiation. Optionally, if multiple sets of MS pairs satisfying the condition are obtained according to the mode (1) or (2), the S smallest MS pair or the M smallest MS pair is selected, and the selected MS pair is synchronized to the redundancy protection group. All Egress PEs. The M in the selected MS pair is carried in the first link state information, and the S in the selected MS pair is carried in the third link state information.
  • the MS pair may be determined according to mode (1) or mode (2) on any one of the redundancy protection groups, and the determined MS pair is synchronized to other Egress PEs in the redundancy protection group.
  • the synchronization of the determined MS pair to other egress PEs in the redundancy protection group may be implemented by using a synchronization protocol.
  • M and S can also be configured on all Egress PEs of the redundancy protection group according to the mode (2). For example, you can set M to 1 and set S to the maximum value of the cost in the IGP protocol.
  • M and S may also be calculated according to mode (1) or (2) on multiple Egress PEs of the redundancy protection group, if multiple sets of MS pairs satisfying the condition are obtained according to mode (1) or (2), Then, the S smallest MS pair or the M smallest MS pair is selected. Of course, a set of MS pairs satisfying the inequalities 1 and 2 may also be selected.
  • the M in the selected MS pair is carried in the first link state information
  • the S in the selected MS pair is carried in the third link state information.
  • the primary tunnel is a ⁇ 1-> ⁇ 1-> ⁇ 3-> virtual node.
  • the standby tunnel is ⁇ 1-> ⁇ 1-> ⁇ 2-> ⁇ 4->virtual node.
  • the cost of the PE3 to the virtual node is M
  • the cost of the PE4 to the virtual node is S.
  • the appropriate Egress PE can be found according to the link cost between the four devices.
  • the cost of the link of the virtual node meets the LFA calculation requirements. If C+D>A+B. C + S ⁇ A + B + M can be, that is, MS > C - (A + B).
  • the method of the embodiment of the present invention is applied to an L3VPN, and PE1, PE2, PE3, PE4, P1, and P2 are all located in an MPLS network, where PE1, PE2, PE3, and PE4 are located at the edge of the MPLS network.
  • the network is a symmetric network.
  • PE1, P3, and PE3 are in the A plane
  • PE2, P2, and PE4 are in the B plane.
  • the A plane and the B plane are symmetric.
  • the CE1 and the CE2 belong to a VPN.
  • VPN1 is the ingress node for packets from CE1 to CE2.
  • PE3 and PE4 are outgoing nodes.
  • a virtual node is generated on PE3.
  • the router ID of the virtual node is ⁇ 1.
  • a virtual node with the address vNHl is also generated on PE4.
  • the method of dynamically negotiating vNH1 can be performed by dynamically negotiating or statically configuring the vNH1 of the virtual node. Referring to the method described in FIG. 4 and the corresponding paragraphs, reference may also be made to the methods described in FIGS. 5-11 and the corresponding paragraphs. Assume that PE3 is the primary PE and the secondary PE is the backup PE in the redundant protection group. Establish a tunnel from PE1 to the virtual node. The tunnel from PE1 to the virtual node includes the primary path and the alternate path. PE1 calculates the first path (primary path) through PE3 starting from PE1 through IGP: ⁇ 1-> ⁇ 1-> ⁇ 3->Virtual node.
  • the last hop node P1 of PE3 calculates the third path through PE1 and does not pass through PE3 through the IGP through the IGP: ⁇ 1-> ⁇ 2-> ⁇ 4->virtual node, the third path and the PE1 in the first path ->P1 constitutes the second path (alternate path): PE 1 -> P 1 -> P2 -> PE4 -> virtual node.
  • the second path does not pass through Egress PE PE3.
  • a BGP session is established between the egress PE PE3 and the ingress PE PE1.
  • the router ID vNH1 of the same virtual node is used as the BGP next hop of the VPN.
  • the VPN route advertised by PE3 can be VPN1: prefixl->Ll, vNHl; that is, when PE1 receives the packet belonging to VPN1, it labels the packet with L1 and sends it to the primary path PE1->P1->PE3.
  • CE2 If PE3 fails, the packet of VPN1 passing through PE3 is automatically switched to PE4.
  • the tunnel from PE2 to the virtual node includes the primary path and the alternate path.
  • PE2 calculates the fourth path (the primary path) of PE4 starting from PE2 through the IGP: PE2->P2->PE4-> virtual node.
  • the last hop node P2 of PE4 calculates the sixth path through PE3 and does not pass through PE4 through the IGP.
  • the ⁇ 2-> ⁇ 1-> ⁇ 3-> virtual node, the PE2 in the sixth path and the fourth path is calculated by the IGP.
  • ->P2 forms the fifth path (alternate path): PE2->P2->P 1 ->PE3-> virtual node.
  • the fifth path does not pass through Egress PE PE4.
  • a BGP session is established between the Egress PE and the ingress PE PE2.
  • a BGP session is also established between PE3 and PE2.
  • the router ID vNH1 of the same virtual node is used as the BGP next hop of the VPN.
  • the VPN route advertised by PE4 to PE2 can be VPN1: prefix 1->L1, vNHl; that is, when PE2 receives the packet belonging to VPN1, it advertises the packet L1, and the primary path PE2->P2- >PE4 is sent to CE2. If PE4 fails, the packet of VPN1 passing through PE4 is automatically switched to PE3, that is, it is switched to the alternate path PE2->P2->P1->PE3 of PE3 to the redundant protection group.
  • Embodiment 3 As shown in FIG. 20, the method in this embodiment of the present invention is applied to an L3VPN, where PE1, PE2, PE3, PE4, P1, and P2 are all located in an MP S network, where PE1, PE2, PE3, and PE4 are located in the MP S network. edge.
  • CE1 and CE2 belong to a VPN, such as VPN1.
  • PE1 is the ingress node and PE3 and PE4 are the egress nodes.
  • CE3 and CE4 belong to a VPN, such as VPN2.
  • PE2 is the ingress node and PE3 and PE4 are the egress nodes.
  • Two virtual nodes can be generated on PE3 and PE4 respectively: a first virtual node and a second virtual node, where the solid line indicates the primary path through the primary PE (Primary PE), and the dotted line indicates the standby through the standby PE (Backup PE). path.
  • the packets passing through the ingress PE are transmitted by the first virtual node, and the packets passing through the ingress PE are transmitted by the second virtual node, so that the traffic distribution is uniform.
  • two virtual nodes are generated on PE3: a first virtual node and a second virtual node, the address of the first virtual node (virtual node 1) is vHN1, and the address of the second virtual node (virtual node 2) is vNH2.
  • the first virtual node and address with address vNHl are also generated on PE4.
  • the vNH1 of the first virtual node and the vNH2 of the second virtual node may be determined by dynamic negotiation or static configuration.
  • the method for dynamically negotiating vNH1 or vNH2 may refer to the method described in FIG. 4 and the corresponding paragraphs, and may also refer to FIG. 5 to FIG. The method described in the corresponding paragraph.
  • LDP is used to establish an MPLS tunnel
  • the cost value for example, sets the link cost of PE3 to virtual node 1 to 1, and sets the link cost of PE4 to virtual node 1 to the maximum IGP cost.
  • the method of dynamically negotiating vNH2 can refer to the method described in FIG. 4 and the corresponding paragraphs, and can also refer to the methods described in FIG. 5-11 and the corresponding paragraphs.
  • the vNH1 is the BGP next hop of the VPN1 route.
  • the first redundancy protection group can be established.
  • the first redundancy protection group includes PE3 and PE4.
  • the PE3 can be assumed to be the primary PE and the PE4 is the standby PE. Backup PE).
  • a tunnel from the PE1 to the virtual node is established, and the tunnel from the PE1 to the virtual node includes an active path and an alternate path.
  • PE1 calculates the first path (primary path) through PE3 starting from PE1 through IGP: ⁇ 1-> ⁇ 1-> ⁇ 3->virtual node.
  • the last hop node P 1 of PE3 calculates the third path through PE1 and does not pass through PE3 through the IGP through the IGP: P 1 -> P2 -> PE4 -> ⁇ ⁇ A , the third path and the first path PE1->P1 in the path constitutes the second path (alternate path): ⁇ 1-> ⁇ 1-> ⁇ 2-> ⁇ 4->Virtual node.
  • the BGP session is established between the Egress PE PE3 and the Ingress PE PE1.
  • the BGP session is established between PE4 and PE1.
  • the router ID vNH1 of the virtual node is used as the BGP of VPN1.
  • the route of VPN1 advertised by PE3 can be VPN1: prefixl->Ll, vNHl; that is, when PE1 receives the packet belonging to VPN1, it labels L1 with the label, and PE1->P1- > PE3 is sent to CE2. If PE3 fails, BJ automatically switches the packet of VPN1 through PE3 to PE4, and the path is adjusted to PE1->P1->P2->PE4.
  • PE4 can identify the label L1 carried in the packet.
  • vNH2 as the BGP next hop of VPN2 route, a second redundancy protection group can be established.
  • the second redundant protection group includes PE3 and PE4. It can be assumed that PE4 is the primary PE (Primary PE) and PE3 is the standby PE.
  • the tunnel from PE2 to the virtual node includes the primary path and the alternate path.
  • PE2 calculates the fourth path (the primary path) of PE4 starting from PE2 through the IGP: PE2->P2->PE4-> virtual node.
  • the last hop node P2 of PE4 calculates the sixth path through P2 starting from P2 and not passing through PE4 through the IGP: P2->P 1 ->PE3 - >) ⁇ ⁇ ?
  • the sixth path and the fourth PE2->P2 in the path constitutes the fifth path (alternate path): ⁇ 2-> ⁇ 2-> ⁇ 1-> ⁇ 3->Virtual node.
  • the fifth path does not pass through Egress PE PE4.
  • a BGP session is established between the Egress PE PE4 and the ingress PE PE2.
  • a BGP session is established between PE3 and PE2.
  • the router ID of the virtual node is used as the BGP next hop of VPN2.
  • the route of VPN2 advertised by PE4 to PE2 can be VPN2: prefix 1->L2, vNH2, that is, when PE2 receives the packet belonging to VPN2, it labels the packet with L2, and PE2->P2->PE4 After being sent to CE2, PE4 can recognize that the label L2 carried in the packet corresponds to VPN2. If the PE4 is faulty, the packet of the VPN2 that passes the PE4 is automatically switched to the PE3, and the path is adjusted to PE2->P2->P1->PE3. The label L2 carried by the packet corresponds to the VPN2.
  • PE1 and PE2 After receiving the VPN route, PE1 and PE2 can find the corresponding tunnel according to vNH.
  • the tunnel calculates the protection tunnel on the upper hop node of the active Egress PE and protects the active PE.
  • the ingress PE does not care which Egress PE is the primary PE and which is the standby PE.
  • the tunnels selected by different Ingress PEs may have different primary Egress PEs.
  • the LDP FRR based on the IGP LFA can be used to calculate the backup path.
  • the MRT FRR based LDP FRR algorithm or other algorithms Traffic can be distributed to Egress PEs that are mutually protected.
  • the LDP mapping message When the LDP sends the LDP mapping message, the LDP mapping message carries a TLV.
  • the value range of the TLV is vNH.
  • the ingress PE uses the vNH in the TLV to find the corresponding tunnel.
  • the tunnel has the function of protecting the primary PE. If the two ACs of the dual-homed CE are attached to the load balance mode, or the two ACs are active, the ingress PE establishes an Egress PE. In the tunnel, which Egress PE is the primary PE, and which PE is the standby PE can be arbitrary.
  • the tunnels selected by different ingress PEs may have different primary egress PEs. The traffic can be distributed to the Egress PEs that are protected by each other.
  • the primary Egress PE and the AC are in the same state.
  • the AC uses the MC-LAG (Multi-Chassis Link Aggregation Group). Aggregation group).
  • the LDP is used to establish the PW label between the PE1 and the PE3.
  • the LDP uses the downstream autonomous allocation mode to allocate PW labels.
  • the PEs use the extended discovery mechanism to establish an LDP session.
  • the LDP Mapping message includes the FEC TLV, the label TLV, and other optional parameters.
  • the FEC TLV is used to distinguish different PWs that are bound to PW tags.
  • a TLV may be carried in the LDP mapping message, and the value range of the TLV is vNH.
  • the ingress PE uses the vNH in the TLV to find the corresponding tunnel.
  • the tunnel has the function of protecting the active PE.
  • PE1, PE2, PE3, PE4, P1, and P2 are all located in the MPLS network, where PE1, PE2, PE3, and PE4 are located at the edge of the MPLS network.
  • CE1 and CE2 belong to a VPN.
  • VPN1, CE3, and CE4 belong to a VPN, such as VPN2.
  • PE1 is the ingress node and PE3 and PE4 are the egress nodes.
  • PE2 is the ingress node and PE3 and PE4 are the egress nodes.
  • the packet is added with an MPLS label on the ingress node and sent to the egress node through the MPLS LSP tunnel.
  • the egress node parses the next hop corresponding to the packet according to the label carried in the packet. , remove the label and forward it to the CE.
  • CE1 communicates with CE2 through PE1->P1->PE3 in turn;
  • CE3 communicates with CE4 through PE2->P2->PE4.
  • a virtual node is generated on PE3.
  • the router ID of the virtual node is ⁇ 1.
  • a virtual node with the address vNHl is also generated on PE4.
  • the vNH1 of the virtual node may be determined through dynamic negotiation or static configuration.
  • the method for dynamically negotiating the vNH1 may refer to the method described in FIG. 4 and the corresponding paragraphs, and may also refer to the methods described in FIG. 5-11 and the corresponding paragraphs.
  • a first LDP session is established between the outbound node PE3 and the ingress node PE1.
  • the PE3 is the VPN1, that is, the VPN corresponding to the CE2 advertises the first LDP mapping message, and the router ID vNH1 of the virtual node is used as the next hop of the PW label in the first LDP mapping message, that is, the PE3 is the PW label advertised by the VPN 1. It may be P Wl -> L 1 , vNH 1 , and the PW label indicates that there is a pseudo line PW1 from PE 1 to PE3, and the text transmitted through the pseudo line PW1 will be tagged L1 at the ingress node PE1, the message The destination node address is vNH1. After the label L1 is added to the ingress node PE1, the packet reaches the PE3 through P1.
  • the PE3 determines the label L1 corresponding to the pseudo line PW1 carried by the packet according to its label mapping table, and then removes the label L1.
  • the message is sent to the next hop CE2 of PW1.
  • the packet of the VPN1 that passes the PE3 is switched to the PE4.
  • the path is adjusted to PE1 -> P1 -> P2 -> PE4.
  • the packet of the VPN1 still uses the label L1.
  • the switch is used. It is not perceptible. Because the switch is only switched from the previous hop node of the primary Egress PE (PE3) to the standby Egress PE (PE4), the active Egress PE reaches the active tunnel of the virtual node and reaches the virtual via the standby Egress PE.
  • a second LDP session is established between the outbound node PE4 and the ingress node PE2.
  • the PE4 is the VPN2, that is, the VPN corresponding to the CE4 advertises the second LDP mapping message, and the router IDvNH1 of the virtual node is used as the next hop ILM of the PW label in the second LDP mapping message, that is, the PW label issued by the VPN4 for the VPN2 can be
  • the PW label indicates that there is a pseudowire PW2 from PE2 to PE4, and the packet transmitted through the pseudowire PW2 will be tagged with L2 at the ingress PE2, and the destination node address of the packet is vNH1, after the label L2 is added to the ingress PE2, the packet arrives at the PE4 through the P2, and the PE4 determines the label L2 corresponding to the packet L2 corresponding to the pseudowire PW2 according to its label mapping table, and then removes the
  • the switch is used. It is not perceptible. Because the switch is only switched from the previous hop node of the primary Egress PE (PE4) to the standby Egress PE (PE3), the active Egress PE reaches the active tunnel of the virtual node and reaches the virtual via the standby Egress PE. The standby tunnel of the node does not seem to switch tunnels in the Ingress PE. As shown in FIG. 22, two virtual nodes are used, so that a part of the PW adopts the virtual node 1, and another part adopts the virtual node 2, so that the traffic distribution is relatively uniform.
  • PE1, PE2, PE3, PE4, P1, and P2 are all located in the MP S network.
  • PE1, PE2, PE3, and PE4 are located at the edge of the MPLS network.
  • CE1 and CE2 belong to a VPN, such as VPN1, and CE3 and CE4 belong to a VPN, such as VPN2.
  • PE1 is the ingress node and PE3 and PE4 are the egress nodes.
  • CE3 communicates with CE4 through PE1->PE2->P2->PE4.
  • a virtual node 1 is generated on PE3, and the address of the virtual node 1 is ⁇ 1.
  • a virtual node with the address vNHl is also generated on PE4.
  • the vNH1 of the virtual node may be determined through dynamic negotiation or static configuration.
  • the method for dynamically negotiating the vNH1 may refer to the method described in FIG. 4 and the corresponding paragraphs, and may also refer to the methods described in FIG. 5-11 and the corresponding paragraphs.
  • the tunnel from PE1 to the virtual node includes the primary path and the alternate path.
  • the first LDP session is established between the egress node PE3 and the ingress PE1.
  • the PE3 is the VPN1, that is, the VPN corresponding to the CE2 advertises the first LDP mapping message, and the address vNH1 of the virtual node 1 is used as the PW label in the first LDP mapping message.
  • the next hop, that is, the PW label issued by PE3 for VPN1 may be PW1->L1, vNHl.
  • the PW label indicates that there is a pseudowire PW1 from PE1 to PE3, and the text transmitted through the pseudowire PW1 will be at the ingress PE1.
  • a tag L1 is added, and the destination node address of the packet is vNH1. After the tag L1 is added to the ingress PE1, the packet reaches the PE3 through the P1.
  • the PE3 determines the tag L1 corresponding to the packet according to its tag mapping table.
  • the packet is sent to the next hop CE2 of the PW1.
  • the packet of the VPN1 passing through the PE3 is automatically switched to the PE4, and the path is adjusted to PE1->P1->P2->PE4, the VPN1 message still uses the label L1, for VPN
  • the switch is not perceptible, since the switch is only from the primary Egress PE (PE3)
  • the previous hop node switches to the standby Egress PE (PE4). After the primary Egress PE reaches the primary tunnel of the virtual node 1, and the standby Egress PE reaches the standby tunnel of the virtual node 1, the Ingress PE does not switch the tunnel.
  • PE3 and PE4 can also establish a second redundant protection group and generate a corresponding virtual node 2.
  • a virtual node 2 is generated on PE3, and the address of the virtual node 2 is vNH2.
  • a virtual node 2 with the address vNH2 is also generated on PE4.
  • the vNH2 of the virtual node 2 can be determined through dynamic negotiation or static configuration.
  • the method for dynamically negotiating the vNH2 can refer to the method described in FIG. 4 and the corresponding paragraphs, and can also refer to the methods described in FIG. 5-11 and the corresponding paragraphs. It is assumed that PE4 is the primary PE in the second redundancy protection group, and PE3 is the backup PE.
  • the second LDP session is established between the outgoing node PE4 and the ingress PE 1.
  • PE4 is VPN2, that is, The VPN corresponding to the CE4 advertises the second LDP mapping message, and the address vNH2 of the virtual node 2 is used as the next hop ILM of the PW label in the second LDP mapping message, that is, the PW label advertised by the PE4 for the VPN2 may be PW2->L2.
  • vNH2 the PW label indicates that there is a pseudowire PW2 from PE1 to PE4, and the packet transmitted through the pseudowire PW2 will be tagged with L2 at the ingress PE1, and the destination node address of the packet is vNH2, the packet After the label L2 is added to the ingress PE1, the PE2 is sent to the PE4 via PE2->P2.
  • the PE4 determines the label L2 corresponding to the packet carrying the pseudowire PW2 according to its label mapping table, then removes the label L2 and sends the packet to the packet.
  • the next hop of the PW2 is CE4. If the PE4 fails, the packet of the VPN2 that passes the PE4 is automatically switched to the PE3, and the path is adjusted to PE1->PE2->P2->P1->PE3. The packet of the VPN2 still uses the label. L2, for the VPN service, the switch does not feel Because the switch is only switched from the previous hop node of the primary Egress PE (PE4) to the standby Egress PE (PE3), the primary Egress PE reaches the virtual node's primary tunnel and the standby Egress PE arrives at the virtual node. The tunnel does not seem to switch tunnels in the Ingress PE.
  • the fifth embodiment of the present invention further provides a network system, where the network system includes an egress PE, a second egress PE, and an ingress interface edge device Ingress PE, the first egress PE and the client.
  • Edge device CE communication, the second Egress PE and the CE pass The first egress PE and the second egress PE are located in a redundant protection group that includes the first egress PE and the second egress PE, where the first egress PE is a primary device, and the second Egress is The PE is a backup device.
  • the first egress PE is PE3, the second egress PE is PE4, and CE2 is in communication with PE3 and PE4.
  • the first Egress PE includes: a first virtual node generating module 2301, a first state publishing module 2302, and a first virtual node state publishing module 2303, where: a first virtual node generating module 2301 is configured to: Generating a virtual node on the first egress PE, where the virtual node has a globally unique router ID, and the virtual node is used as a next hop node of the first egress PE, and the virtual node is used.
  • the first link advertised module 2302 is configured to send a first link state message to the ingress PE, where the first link state message includes: the first The router ID of the egress PE and the status information of the link of the first egress PE to the virtual node, and the status information of the link of the first egress PE to the virtual node includes the first Egress PE to the The cost value M of the link of the virtual node and the router ID of the virtual node; the first virtual node status issuing module 2303 is configured to send a second link status message to the ingress PE, where the second link status is Eliminate And including: a router ID of the virtual node, status information of the link of the virtual node to the first egress PE, and status information of a link of the virtual node to the second egress PE, the virtual node
  • the status information of the link to the first egress PE includes the cost value N of the link from the virtual node to the first egress PE and the router ID of the first egress PE, where the virtual node
  • the N and the T are the maximum cost values of the internal gateway protocol IGP.
  • the second Egress PE includes: a second virtual node generating module 2304, a second state publishing module 2305, and a second virtual node state publishing module 2306, where: a second virtual node generating module 2304 is configured to be in the second Egress Generate the above on the PE a virtual node generated on a virtual PE; a second state publishing module 2305, configured to send a third link state message to the ingress PE, where the third link state message includes: a router ID of the second egress PE Status information of the link of the second egress PE to the virtual node, and the status information of the link of the second Egress PE to the virtual node includes a chain of the second Egress PE to the virtual node
  • the cost value S of the path and the router ID of the virtual node; the second virtual node status issuing module 2306 is configured to send a fourth link status message to the ingress PE, where the fourth link status message includes: a router ID
  • the N and the T are the maximum cost values of the internal gateway protocol IGP.
  • the Ingress PE such as PE1 receives the first link state message, the second link state message, the third link state message, and the fourth link state message, obtain the The vNH of the virtual node, the cost value M of the link of the first egress PE to the virtual node, and the cost value S of the link of the second Egress PE to the virtual node.
  • any one of the first link state message, the second link state message, the third link state message, and the fourth link state message may also be Other attributes, such as MPLS TE tunnels, include one or more of bandwidth, affinity attributes, colors, and so on.
  • the cost value of the link can be set to any legal IGP cost value.
  • the cost values S and M of the link can be set to any legal IGP cost value. You can also statically configure the cost values S and M of the link.
  • At least one of the first Egress PE and the second Egress PE according to the mode (1) Or (2) determining a cost value M of the link of the first egress PE to the virtual node, and a cost value S of the link of the second Egress PE to the virtual node, and determining the The cost value M of the link from the egress PE to the virtual node and the cost value S of the link from the second egress PE to the virtual node are synchronized to the first Egress PE and the second Egress PE.
  • the redundancy protection group In the redundancy protection group:
  • Sxy3 is the cost of the shortest path of the Pxy to the first egress PE
  • Sxy4 is the cost of the shortest path of the Pxy to the second egress PE.
  • the value of C34 is the cost value of the shortest path of the first egress PE to the second egress PE.
  • each Egress PE in the redundancy protection group can calculate the MS pair that satisfies inequality 1 and inequality 2, that is, the PE3 in the redundancy protection group can calculate the inequality. 1 and MS pairs of inequality 2, PE4 in the redundancy protection group can also calculate MS pairs satisfying inequality 1 and inequality 2.
  • multiple egress PEs in the redundancy protection group calculate different MS pairs
  • multiple The Ss of all Egress PEs that are deployed in the redundancy protection group can be determined through negotiation.
  • the S smallest MS pair or the M smallest MS pair is selected, and the selected MS pair is synchronized to the redundancy protection group.
  • the M in the selected MS pair is carried in the first link state information, and the S in the selected MS pair is carried in the third link state information.
  • the MS pair may be determined according to mode (1) or mode (2) on any one of the redundancy protection groups, and the determined MS pair is synchronized to other Egress PEs in the redundancy protection group.
  • the synchronization of the determined MS pair to other egress PEs in the redundancy protection group may be implemented by using a synchronization protocol.
  • M and S can also be configured on all Egress PEs of the redundancy protection group according to the mode (2). For example, you can set M to 1 and set S to the maximum value of the cost in the IGP protocol.
  • M and S may also be calculated according to mode (1) or (2) on multiple Egress PEs of the redundancy protection group, if multiple sets of MS pairs satisfying the condition are obtained according to mode (1) or (2), Then, the S smallest MS pair or the M smallest MS pair is selected. Of course, a set of MS pairs satisfying the inequalities 1 and 2 may also be selected.
  • the M in the selected MS pair is carried in the first link state information
  • the S in the selected MS pair is carried in the third link state information.
  • OSPF Open Shortest Path First
  • the link state and neighbor relationship of PE3 are changed after the virtual node is generated on PE3. Therefore, PE3 updates its own. Link state and neighbor relationship, constructing a Link State Advertisement (LSA), and flooding the first LSA to the entire network.
  • the first LSA includes: Router ID and PE3 of PE3.
  • the status information of the link of the virtual node, and the status information of the link of the PE3 to the virtual node includes the cost value of the link of the PE3 to the virtual node and the router ID of the virtual node.
  • PE3 Since the virtual node is generated on PE3, PE3 also constructs a second LSA "on behalf of" the virtual node, and floods the second LSA to the entire network.
  • the second LSA includes: a router ID of the virtual node, status information of the link of the virtual node to the PE3, and status information of a link of the link of the virtual node to the PE4.
  • the status information of the link from the virtual node to the PE3 includes the cost value of the link from the virtual node to the PE3 and the router ID of the PE3.
  • the status information of the link from the virtual node to the PE4 includes the link of the virtual node to the PE4. Cost value and the router ID of PE4.
  • the OSPF domain can be the entire network.
  • the PE4 updates its link state and neighbor relationship, constructs a third LSA, and floods the third LSA to the entire network.
  • the third LSA includes: a router ID of the PE4 and status information of the link of the PE4 to the virtual node, and the status information of the link of the PE4 to the virtual node includes a cost value of the link of the PE4 to the virtual node, and the virtual node Router ID.
  • the PE4 also constructs a fourth LSA on behalf of the virtual node, and floods the fourth LSA to the entire network.
  • the fourth LSA includes: a router ID of the virtual node, Status information of the link from the virtual node to PE3, and status information of the link from the virtual node to PE4.
  • the status information of the link from the virtual node to the PE3 includes the cost value of the link from the virtual node to the PE3 and the router ID of the PE3.
  • the status information of the link from the virtual node to the PE4 includes the link of the virtual node to the PE4. Cost value and the router ID of PE4.
  • PE3 and PE4 flood the LSAs into the OSPF domain.
  • the link status is the description information on the OSPF interface of the router, such as the IP address, subnet mask, network type, cost value, and so on.
  • the OSPF routers exchange not the routing table, but the link status.
  • the OSPF router (such as PE1) obtains the exact network path to each target by obtaining all the link state information in the network.
  • the link state and the neighbor relationship are configured to construct a first link state message LSP (Link-state PDU), and flood the first LSP to the entire network, where the first LSP includes: a router ID of PE3 and a PE3 to the virtual Status information of the link of the node, and the status information of the link of the PE3 to the virtual node includes the cost value of the link of the PE3 to the virtual node and the router ID of the virtual node.
  • LSP Link-state PDU
  • the virtual node Since the virtual node is generated on PE3, PE3 The virtual node also constructs a second LSP, and floods the second LSP to the entire network.
  • the second LSP includes: a router ID of the virtual node, and status information of the link from the virtual node to the PE3.
  • the status information of the link from the virtual node to the PE3 includes the cost value of the link from the virtual node to the PE3 and the router ID of the PE3.
  • the status information of the link from the virtual node to the PE4 includes the link of the virtual node to the PE4. Cost value and the router ID of PE4.
  • Egress PEs in the redundancy protection group also construct corresponding LSPs and flood these LSPs into the entire ISIS domain, which may be the entire network.
  • the PE4 updates its link state and neighbor relationship, constructs a third LSP, and floods the third LSP to the entire network.
  • the third LSP includes: a router ID of the PE4 and status information of the link of the PE4 to the virtual node, and the status information of the link of the PE4 to the virtual node includes a cost value of the link of the PE4 to the virtual node, and the virtual Router ID of the node.
  • the PE4 also constructs a fourth LSP on behalf of the virtual node, and floods the fourth LSP to the entire network.
  • the fourth LSP includes: the router ID of the virtual node.
  • the status information of the link from the virtual node to the PE3 includes the cost value of the link from the virtual node to the PE3 and the router ID of the PE3.
  • the status information of the link from the virtual node to the PE4 includes the link of the virtual node to the PE4. Cost value and the router ID of PE4.
  • PE3 and PE4 flood these LSPs into the ISIS domain, so that other nodes in the same ISIS domain as PE3 and PE4, such as PE 1, can "see” the virtual node, the link between the virtual node and PE3.
  • the attribute value (cost value) of the link between the generated virtual node and the egress PE in the redundancy protection group can be set automatically or manually.
  • the cost value is set to the maximum cost of the IGP.
  • the cost value of the link from the virtual node to the PE3 and the link from the virtual node to the PE4 may be The cost value is set to the maximum cost of the IGP.
  • the OSPF protocol can be implemented by setting the cost value of the link from the virtual node to the egress PE node PE3 and the cost value of the link from the virtual node to the PE4 to the maximum cost of the IGP. Under the ISIS protocol, this can be achieved by setting the overload bit of the second LSP and the fourth LSP to 1.
  • a physical link is usually bidirectional, and the links described in the IGP are directional, and each direction needs to be described separately. The cost value of a physical link in different directions may be different or the same. Virtual nodes are not physically present, but are generated for other nodes in the IGP domain to calculate a PE3 tunnel.
  • the upstream node P1 of PE3 can calculate another standby tunnel that reaches PE4, such as PE1->P1->P2->PE4, and the standby tunnel does not pass through PE3. In this way, when the PE3 is faulty, the traffic can be switched to the standby tunnel through the P1 to reach the PE4, thereby achieving the purpose of protecting the PE3. Because PE3 and PE4 are symmetric, the primary tunnel passing through PE4 can also be established, and the upper hop node of PE4 (such as P2 in Figure 3) establishes a standby tunnel that passes through PE3 and does not pass through PE4, such as PE1->P2- >P1->PE3. When PE4 is faulty, the traffic is switched to the backup tunnel on P2 to protect PE4. Optionally, as shown in FIG.
  • the first egress PE may further include a first virtual node address negotiation module 2307, configured to negotiate with the second egress PE to determine a router ID of the same virtual node.
  • the second first egress PE may further include a second virtual node address negotiation module 2308, configured to negotiate with the virtual node address negotiation module 2307 of the first egress PE to determine a router ID of the same virtual node.
  • the first egress PE may further include a first label negotiation module 2309, configured to negotiate with the second egress PE to determine the same label.
  • the second egress PE may further include a second label negotiation module 2310, configured to negotiate with the first egress PE to determine the same label.
  • the network system may also be a third Egress PE, and the third Egress PE is located in the packet.
  • the third Egress PE is used as a backup device in the redundancy protection group of the first egress PE and the second egress PE.
  • the vNH of the virtual node may be determined by static configuration or dynamic negotiation between the first egress PE, the second egress PE, and the third egress PE. For the method of dynamically negotiating vNH, refer to FIG. 4 and its corresponding paragraph.
  • each module in the embodiment of the present invention may be implemented by using corresponding hardware.
  • the network system, the first egress PE, and the second egress PE may be applied to an L2VPN or an L3VPN.
  • Embodiment 6 The embodiment of the present invention further provides another network system, where the network system includes a first PE device, a second PE device, and an Igress PE, where the first PE device and the second PE device function as an Egress PE.
  • the first PE device communicates with a customer edge device CE, and the second PE device communicates with the CE.
  • the first PE device and the second PE device are in a redundant protection group including the first PE device and the second PE device, where the first PE device is a primary device, and the first The second PE device is a backup device.
  • the first PE device is configured to: generate a virtual node, where the virtual node has a globally unique router ID, and the virtual node is used as a next hop node of the first PE device, where the virtual The node is used as the next hop node of the second PE device, and sends a first link state message to the ingress PE, where the first link state message includes: a router ID of the first PE device, and the The status information of the link of the first PE device to the virtual node, the status information of the link of the first PE device to the virtual node, including the cost of the link of the first PE device to the virtual node a value M and a router ID of the virtual node; Sending a second link status message to the ingress PE, where the second link status message includes: a router ID of the virtual node, status information of the link of the virtual node to the first PE device, and a location The status information of the link of the virtual node to the second PE device, and the status information of the link of the virtual node to the first e
  • the cost value N and the router ID of the first PE device, and the status information of the link from the virtual node to the second egress PE includes the cost value T of the link from the virtual node to the second PE device.
  • a router ID of the second PE device where the second PE device is configured to: generate the virtual node, and send a third link status message to the ingress PE, where the third link status message includes: a router ID of the second PE device and status information of the link of the second PE device to the virtual node, and status information of the link of the second PE device to the virtual node includes the second PE
  • the cost value S of the link of the device to the virtual node and the virtual a router ID of the point sending a fourth link status message to the ingress PE, where the fourth link status message includes: a router ID of the virtual node, and a link of the virtual node to the first PE device State information and status information of the link of the virtual node to the second PE device, the status information of the link of the virtual node to the first PE device includes
  • the first device When the virtual short node is generated on the first PE device, the first device generates the virtual node The link state and the neighbor relationship of the PE device are changed. Therefore, the first PE device updates its link state and neighbor relationship, and constructs a Link State Advertisement (LSA), and the first link state broadcast data (LSA).
  • LSA Link State Advertisement
  • LSA Link State broadcast data
  • An LSA is flooded to the entire network, and the first LSA includes: a router ID of the first PE device and status information of a link of the first PE device to the virtual node, where the first PE device is The status information of the link of the virtual node includes a cost value of the link of the first PE device to the virtual node and a router ID of the virtual node. Since the virtual node is generated on the first PE device, the first PE device also constructs a second LSA "on behalf of" the virtual node, and floods the second LSA to the entire network.
  • the second LSA includes: a router ID of the virtual node, status information of the link of the virtual node to the first PE device, and status information of a link of the link of the virtual node to the second PE device.
  • the status information of the link of the virtual node to the first PE device includes a cost value of the link of the virtual node to the first PE device and a router ID of the first PE device, where the virtual node reaches the
  • the status information of the link of the second PE device includes a cost value of the link of the virtual node to the second PE device and a router ID of the second PE device.
  • other Egress PEs in the redundancy protection group also construct corresponding LSAs and flood these LSAs into the entire 0SPF domain, which may be the entire network. For example, after the virtual node is generated on the second PE device, the link state and the neighbor relationship of the second PE device are changed. Therefore, the second PE device updates its link state and neighbor relationship.
  • the third LSA, and the third LSA is flooded into the entire network.
  • the third LSA includes: a router ID of the second PE device and status information of a link of the second PE device to the virtual node, and status information of the link of the second PE device to the virtual node includes The cost value of the link of the second PE device to the virtual node and the router ID of the virtual node.
  • the second PE device constructs a fourth LSA "on behalf of" the virtual node, and floods the fourth LSA to the entire network, the fourth LSA is generated on the second PE device.
  • the status information of the link of the virtual node to the first PE device includes a cost value of the link of the virtual node to the first PE device and a router ID of the first PE device, where the virtual node is
  • the status information of the link of the second PE device includes a cost value of the link of the virtual node to the second PE device and a router ID of the second PE device.
  • PE1 can "see" the virtual node, the link between the virtual node and the first PE device, and the link between the virtual node and the second PE device, thereby being able to establish from PE1 to The virtual node's vNH tunnel.
  • the link status is the description information on the OSPF interface of the router, such as the IP address, subnet mask, network type, cost value, and so on.
  • the OSPF routers exchange not the routing table, but the link status.
  • the OSPF router (such as PE1) obtains the exact network path to each target by obtaining all the link state information in the network.
  • the first PE device updates its link state and neighbor relationship, and constructs a first link state message LSP (Link-state PDU).
  • the first LSP is flooded to the entire network, and the first LSP includes: a router ID of the first PE device and status information of a link of the first PE device to the virtual node, where the first PE device is The status information of the link of the virtual node includes the cost value of the link of the first PE device to the virtual node and the router ID of the virtual node.
  • the first PE device also constructs a second LSP on behalf of the virtual node, and floods the second LSP to the entire network, the second LSP. And including: a router ID of the virtual node, status information of a link of the virtual node to the first PE device, and status information of a link of a link of the virtual node to the second PE device.
  • the status information of the link of the virtual node to the first PE device includes a cost value of the link of the virtual node to the first PE device and a router ID of the first PE device, where the virtual node is
  • the status information of the link of the second PE device includes a cost value of the link of the virtual node to the second PE device and a router ID of the second PE device.
  • other Egress PEs in the redundancy protection group also construct corresponding LSPs and flood these LSPs into the entire ISIS domain, which may be the entire network.
  • the second PE device updates its link state and neighbor relationship.
  • the second PE device also constructs a fourth LSP on behalf of the virtual node, and floods the fourth LSP to the entire network, the fourth LSP.
  • the status information of the link of the virtual node to the first PE device includes a cost value of the link of the virtual node to the first PE device and a router ID of the first PE device, where the virtual node reaches the
  • the status information of the link of the second PE device includes a cost value of the link of the virtual node to the second PE device and a router ID of the second PE device.
  • the first PE device and the second PE device flood the LSPs into the ISIS domain, such that other nodes in the same ISIS domain, such as PE1, are located with the first PE device and the second PE device. Being able to "see" the virtual node, the link between the virtual node and the first PE device, the link between the virtual node and the second PE device, thereby being able to establish a PE1 to the virtual node
  • the tunnel of vNH The attribute value (cost value) of the link between the generated virtual node and the egress PE in the redundancy protection group can be set automatically or manually.
  • the link of the first PE device to the virtual node may be The cost value is set to 1 and the cost of the link from PE4 to the virtual node is set to the maximum cost of the IGP.
  • the maximum cost of the link can be set according to different IGPs running between the first PE device and the second PE device. For example, when the network runs 0SPF, the maximum link cost can be set to 65535.
  • the cost value of the link of the virtual node to the first PE device and the cost value of the link of the virtual node to the second PE device are both set to IGP in order to prevent the virtual node from taking over the transit traffic. Maximum cost value. In order to avoid punch-through traffic, the virtual node needs to be configured in overload mode.
  • the cost value of the link of the virtual node to the first PE device and the cost value of the link of the virtual node to the second PE device are set to be the maximum cost value of the IGP. Under the ISIS protocol, this can be achieved by setting the overload bit of the second LSP and the fourth LSP to 1.
  • a physical link is usually bidirectional, and the links described in the IGP are directional, and each direction needs to be described separately.
  • the first PE device may further include a first virtual node address negotiation module, And determining, by the second PE device, a router ID of the same virtual node.
  • the second PE device may further include a second virtual node address negotiation module, configured to negotiate with the virtual node address negotiation module of the first PE device to determine a router ID of the same virtual node.
  • the first PE device may further include a first label negotiation module, configured to negotiate with the second PE device to determine the same label.
  • the second PE device may further include a second label negotiation module, configured to negotiate with the first PE device to determine the same label. For details on how to negotiate the same label, refer to Figure 12-17 and its corresponding paragraphs.
  • Embodiment 7 The embodiment of the present invention further provides another network system, where the network system includes a first PE device and a second PE device, where the first PE device and the second PE device serve as Egress PEs, respectively Edge device CE communication.
  • the network system further includes a third PE device as an Ingress PE.
  • the first PE device and the second PE device are in a redundant protection group including the first PE device and the second PE device, where the first PE device is a primary device, and the first The second PE device is a backup device. As shown in FIG.
  • the first PE device includes: a first bus 2601; and a first processor 2602, a first memory 2603, and a first interface 2604 connected to the first bus 2601, the first memory 2603 for storing
  • the first processor 2602 is configured to perform the following operations: generating, at the first PE device, a virtual node, where the virtual node has a globally unique Router ID in the network system, where the virtual node is used as a next hop node of the first device, the virtual node serving as a next hop node of the second device; triggering the first interface 2604 to send a first link state message to the The ingress PE, the first link state message includes: a router ID of the first PE device, and status information of a link of the first PE device to the virtual node, where the first PE device is The status information of the link of the virtual node includes a cost value M of the link of the first PE device to the virtual node and a router ID of the virtual node; triggering the first interface 2604 to send the first bus 2601 through
  • Status information of the link between the virtual node and the second PE device, and status information of the link of the virtual node to the first PE device includes the virtual node to the first PE device Link cost value N And the router ID of the first PE device, the status information of the link of the virtual node to the second PE device includes a cost value T of the link from the virtual node to the second PE device, and the Router ID of the second PE device.
  • the N and the T are the maximum cost values of the internal gateway protocol IGP.
  • the cost value M of the link from the first PE device to the virtual node and the cost value S of the link from the second PE device to the virtual node may also be Other attributes, such as MPLS TE tunnels, include one or more of bandwidth, affinity attributes, colors, and so on.
  • the cost value of the link can be set to any legal IGP cost value. For example, for an MPLS TE tunnel with an explicit route, the cost of the link S or M can be set to any legal IGP cost. You can also statically configure the cost of link S or M.
  • each Egress PE in the redundancy protection group can calculate the MS pair that satisfies inequality 1 and inequality 2, that is, the PE3 in the redundancy protection group can calculate the inequality. 1 and MS pairs of inequality 2, PE4 in the redundancy protection group can also calculate MS pairs satisfying inequality 1 and inequality 2.
  • the Ss of all the egress PEs that are deployed in the redundancy protection group can be determined by negotiation.
  • the S smallest MS pair or the M smallest MS pair is selected, and the selected MS pair is synchronized to the redundancy protection group.
  • the M in the selected MS pair is carried in the first link state information, and the S in the selected MS pair is carried in the third link state information.
  • the MS pair may be determined according to mode (1) or mode (2) on any one of the redundancy protection groups, and the determined MS pair is synchronized to other Egress PEs in the redundancy protection group.
  • the synchronization of the determined MS pair to other egress PEs in the redundancy protection group may be implemented by using a synchronization protocol.
  • M and S can also be configured on all Egress PEs of the redundancy protection group according to the mode (2). For example, you can set M to 1 and set S to the maximum value of the cost in the IGP protocol.
  • M and S on the multiple Egress PEs of the redundancy protection group, if multiple sets of MS pairs satisfying the condition are obtained according to the mode (1) or (2), The S smallest MS pair or the M smallest MS pair is selected. Of course, a set of MS pairs satisfying inequalities 1 and 2 may also be selected.
  • the M in the selected MS pair is carried in the first link state information
  • the S in the selected MS pair is carried in the third link state information.
  • OSPF Open Shortest Path First
  • the link state and neighbor relationship of the first PE device are generated after the virtual node is generated on the first PE device.
  • the first PE device updates its link state and neighbor relationship, constructs a Link State Advertisement (LSA), and floods the first LSA to the entire network.
  • the first LSA includes: a router ID of the first PE device and status information of a link of the first PE device to the virtual node, and status information of the link of the first PE device to the virtual node includes The cost value of the link of the first PE device to the virtual node and the router ID of the virtual node.
  • the first PE device Since the virtual node is generated on the first PE device, the first PE device also constructs a second LSA "on behalf of" the virtual node, and floods the second LSA to the entire network.
  • the second LSA includes: a router ID of the virtual node, status information of the link of the virtual node to the first PE device, and status information of a link of the link of the virtual node to the second PE device.
  • the status information of the link of the virtual node to the first PE device includes a cost value of the link of the virtual node to the first PE device and a router ID of the first PE device, where the virtual node reaches the
  • the status information of the link of the second PE device includes a cost value of the link of the virtual node to the second PE device and a router ID of the second PE device.
  • other Egress PEs in the redundancy protection group also construct corresponding LSAs and flood these LSAs into the entire 0SPF domain, which may be the entire network. For example, after the virtual node is generated on the second PE device, the link state and the neighbor relationship of the second PE device are changed. Therefore, the second PE device updates its link state and neighbor relationship.
  • the third LSA, and the third LSA is flooded into the entire network.
  • the third LSA includes: a router ID of the second PE device and status information of a link of the second PE device to the virtual node, and status information of the link of the second PE device to the virtual node includes The cost value of the link of the second PE device to the virtual node and the router ID of the virtual node.
  • the second PE device constructs a fourth LSA "on behalf of" the virtual node, and floods the fourth LSA to the entire network, the fourth LSA is generated on the second PE device.
  • the status information of the link of the virtual node to the first PE device includes a cost value of the link of the virtual node to the first PE device and a router ID of the first PE device, where the virtual node is
  • the status information of the link of the second PE device includes a cost value of the link of the virtual node to the second PE device and a router ID of the second PE device.
  • the first PE device and the second PE device flood the LSAs into the OSPF domain, such that the other PEs in the same OSPF domain as the first PE device and the second PE device, for example, PE1 Being able to "see" the virtual node, the link between the virtual node and the first PE device, the link between the virtual node and the second PE device, thereby being able to establish a PE1 to the virtual node
  • the tunnel of vNH is the description information on the OSPF interface of the router, such as the IP address, subnet mask, network type, cost value, and so on.
  • the OSPF routers exchange not the routing table, but the link status.
  • the OSPF router (such as PE1) obtains the exact network path to each target by obtaining all the link state information in the network.
  • the first PE device updates its link state and neighbor relationship, constructs a first link state message LSP (Link-state PDU), and
  • the first LSP is flooded to the entire network, and the first LSP includes: a router ID of the first PE device and status information of a link of the first PE device to the virtual node, where the first PE device is The status information of the link of the virtual node includes the cost value of the link of the first PE device to the virtual node and the router ID of the virtual node.
  • the first PE device also constructs a second LSP on behalf of the virtual node, and floods the second LSP to the entire network, the second LSP. And including: a router ID of the virtual node, status information of a link of the virtual node to the first PE device, and status information of a link of a link of the virtual node to the second PE device.
  • the status information of the link of the virtual node to the first PE device includes a cost value of the link of the virtual node to the first PE device and a router ID of the first PE device, where the virtual node is
  • the status information of the link of the second PE device includes a cost value of the link of the virtual node to the second PE device and a router ID of the second PE device.
  • the ISIS domain can be the entire network.
  • the link state and the neighbor relationship of the second PE device are changed. Therefore, the second PE device updates its link state and neighbor relationship.
  • the third LSP includes: a router ID of the second PE device and a status information of a link of the second PE device to the virtual node, where The status information of the link of the second PE device to the virtual node includes a cost value of the link of the second PE device to the virtual node and a router ID of the virtual node.
  • the second PE device also constructs a fourth LSP on behalf of the virtual node, and floods the fourth LSP to the entire network, the fourth LSP.
  • the status information of the link of the virtual node to the first PE device includes a cost value of the link of the virtual node to the first PE device and a router ID of the first PE device, where the virtual node reaches the
  • the status information of the link of the second PE device includes a cost value of the link of the virtual node to the second PE device and a router ID of the second PE device.
  • the attribute value (cost value) of the link between the generated virtual node and the egress PE in the redundancy protection group can be set automatically or manually. For example, if the first PE device is required to be the node through which the primary path of the tunnel passes, and the second PE device becomes the node through which the alternate path of the tunnel passes, the link of the first PE device to the virtual node may be The cost value is set to 1 and the cost of the link from PE4 to the virtual node is set to the maximum cost of the IGP.
  • the maximum cost of the link can be set according to different IGPs running between the first PE device and the second PE device. For example, when the network runs 0SPF, the maximum link cost can be set to 65535.
  • the cost value of the link of the virtual node to the first PE device and the cost value of the link of the virtual node to the second PE device are both set to IGP in order to prevent the virtual node from taking over the transit traffic. Maximum cost value. In order to avoid punch-through traffic, the virtual node needs to be configured in overload mode. Under the 0SPF protocol, the virtual node can be accessed by The cost value of the link of the first PE device and the cost value of the link of the virtual node to the second PE device are set to be the maximum cost of the IGP.
  • the first processor may further execute the instruction to perform the following operations:: negotiate with the second PE device to determine a router ID of the same virtual node.
  • the second processor may further execute the instruction to: determine, according to the first processor of the first PE device, the router ID of the same virtual node. For details about the router ID negotiation method of the virtual node, refer to FIG. 4 and its corresponding paragraphs, and refer to FIG.
  • the first processor 2602 can further execute the instruction to perform the following operations: determining, by the second PE device, the same label.
  • the second processor may further execute the instruction to perform the following operations: determining, by the first PE device, the same label.
  • each module in the embodiment of the present invention may be implemented by using corresponding hardware.
  • the network system, the first egress PE, and the second egress PE may be applied to an L2VPN or an L3VPN.
  • the primary Egress PE and the standby egress PE when the primary Egress PE and the standby egress PE advertise the VRF (Virtual Routing Forwarding) route to which the CE node belongs, the primary Egress PE and the standby Egress PE are respectively VRF labels (such as the first VRF tag) assigns the same VPN route label.
  • the method, the device, and the system in the embodiment of the present invention configure the same virtual next hop on the egress PE in the redundancy protection group, and send the address of the virtual next hop node to the ingress PE, so that the Ingress PE
  • the switch involves a relatively small number of node devices, so that the protection switch can be completed in a short period of time.
  • the switch is seamless and not perceived by the upper layer service.
  • the division of the unit is only a logical function division.
  • there may be another division manner for example, multiple units or components may be combined or Can be integrated into another system, or some features can be ignored, or not executed.
  • the mutual coupling or direct coupling or communication connection shown or discussed may be an indirect coupling or communication connection through some interface, device or unit, and may be in an electrical, mechanical or other form.
  • the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of the embodiment.
  • each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
  • the above integrated unit can be implemented in the form of hardware or in the form of hardware plus software functional units.
  • the detector, the transmitter, the receiver, and the acquisition unit can all be implemented by a general-purpose CPU or an Application Specific Integrated Circuit (ASIC) or a Field-Programmable Gate Array (FPGA).
  • ASIC Application Specific Integrated Circuit
  • FPGA Field-Programmable Gate Array
  • the above-described integrated unit implemented in the form of a software functional unit can be stored in a computer readable storage medium.
  • the software functional unit described above is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, server, or network device, etc.) to perform portions of the steps of the methods described in various embodiments of the present invention.
  • a computer device which may be a personal computer, server, or network device, etc.
  • the foregoing storage medium includes: a USB flash drive, a mobile hard disk, a read-only memory (ROM), A random access memory (RAM), a disk, or an optical disk that can store various program codes.

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer Security & Cryptography (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

一种分配标签的方法,用于网络系统,该网络系统包括第一和第二Egress PE、Ingress PE,该第一和第二Egress PE分别与CE通信,该第一、第二Egress PE位于包括同一冗余保护组内,分别作为主备用设备;该第一、第二Egress PE分别生成虚拟节点,该虚拟节点具有该网络系统中全局唯一的Router ID,该虚拟节点用作该第一、第二Egress PE的下一跳节点;第一、第二Egress PE发送链路状态信息给Ingress PE,使Ingress PE获得第一、第二Egress PE的Router ID、虚拟节点的Router ID,以及第一、第二Egress PE的链路状态信息,该第一、第二Egress PE分别为第一虚拟专用网络VPN的第一转发等价类分配第一标签,并发送该第一标签和该虚拟节点的Router ID给该Ingress PE。

Description

建立隧道的方法、 分配标签的方法、 设备及网络系统 技术领域
本发明涉及一种建立隧道的方法、 分配标签的方法、 设备及网络系统。
背景技术
多协议标签交换 MPLS ( Multi-Protocol Label Switching )位于 TCP/IP 协议栈中的链路层和网络层之间, 用于向 IP ( Internet Protocol , 网络协议 ) 层提供连接服务, 同时又从链路层得到服务。 MPLS以标签交换替代 IP转 发。 标签是一个短而定长的、 只具有本地意义的连接标识符。 标签封装在 链路层和网络层之间。 MPLS不局限于任何特定的链路层协议, 能够使用任 意二层介质传输网络分组。 MPLS并不是一种业务或者应用,它实际上是一 种隧道技术。 这种技术不仅支持多种高层协议与业务, 而且在一定程度上 可以保证信息传输的安全性。 标签分发协议 LDP ( Label Distribution Protocol )是多协议标签交换 MPLS的一种控制协议, 相当于传统网络中的 信令协议, 负责转发等价类 FEC ( Forwarding Equivalence Class ) 的分类、 标签的分配以及标签交换路径 LSP ( Label Switched Path ) 的建立和维护等 操作。 LDP规定了标签分发过程中的各种消息以及相关处理过程。
MPLS支持多层标签, 并且转发平面面向连接, 故具有良好的扩展性, 使在统一的 MPLS/IP基础网络架构上为客户提供各类服务成为可能。 通过 LDP协议, 标签交换路由器 LSR ( Label Switched Router )可以把网络层的 路由信息直接映射到数据链路层的交换路径上, 建立起网络层的 LSP。 目 前, LDP广泛地应用于 VPN服务, 具有组网和配置简单、 支持路由拓朴驱 动建立 LSP、 支持大容量 LSP等优点。 虚拟专用网络 VPN ( Virtual Private Network )是依靠 Internet服务提供 商 ISP ( Internet Service Provider )和网络服务提供商 NSP ( Network Service Provider )在公共网络中建立的虚拟专用通信网络。 VPN的基本原理是利用 隧道技术, 把 VPN报文封装在隧道中, 利用 VPN骨干网建立专用数据传 输通道, 实现报文的透明传输。 隧道技术使用一种协议封装另外一种协议 报文, 而封装协议本身也可以被其他封装协议所封装或承载。
BGP/MPLS IP VPN是一种 L3VPN ( Layer 3 Virtual Private Network )„ 它使用 BGP ( Border Gateway Protocol )在服务提供商骨干网上发布 VPN 路由, 使用 MPLS ( Multiprotocol Label Switch )在服务提供商骨干网上转 发 VPN报文。 这里的 IP是指 VPN承载的是 IP报文。
PWE3 ( Pseudo-Wire Emulation Edge to Edge, 边缘到边缘的伪线仿真 ) 是一种在 PSN网络上仿真象 ATM ( Asynchronous Transfer Mode, 异步传输 模式)、 FR ( Frame Relay, 帧中继)、 Ethernet等业务的关键属性的机制。 PWE3可以使运营商把传统业务迁移到包交换网络 PSN上来以降低网络运 营成本。 为了保证业务的高可用性, 网络的不同层次都需要支持冗余: 当正在 使用的网络节点、 链路、 通道等资源发生故障时能切换到其他冗余的可用 资源上, 保证网络能继续提供规定的服务。
LDP FRR是一种预先计算隧道的保护路径, 当检测到主用路径故障后 立即把数据报文切换到备用路径的快速保护方法。 LDP FRR可以针对节点 和链路来保护, 保护总是由故障的上游邻居发起的, 不同的节点会为下游 节点建立不同的保护路径。 由于从入口节点到出口节点的路径或隧道通常 很长, 上游节点发起保护切换后, 直到路径全部切换完成, 需要较长的切 换时间。
发明内容 本发明实施例的目的在于提供一种建立隧道的方法、 设备和网络系统, 以减少保护切换的时间。 为达到上述目的, 本发明的实施例采用如下技术方案。 第一方面, 本发明实施例提供一种网络系统, 包括包括第一出口运营 商边缘设备 Egress PE、 第二 Egress PE和入口运营商边缘设备 Ingress PE , 所述第一 Egress PE与客户边缘设备 CE通信 , 所述第二 Egress PE与所述 CE通信, 所述第一 Egress PE和所述第二 Egress PE位于包括所述第一 Egress PE 和所述第二 Egress PE的冗余保护组内, 其中所述第一 Egress PE为主用设 备, 所述第二 Egress PE为备用设备; 所述第一 Egress PE用于: 生成虚拟节点, 所述虚拟节点具有所述网络系统中全局唯一的 Router ID, 所述虚拟节点用作所述第一 Egress PE的下一跳节点, 所述虚拟节点用 作所述第二 Egress PE的下一跳节点; 发送第一链路状态消息给所述 Ingress PE, 所述第一链路状态消息包 括:所述第一 Egress PE的 Router ID和所述第一 Egress PE到所述虚拟节点 的链路的状态信息, 所述第一 Egress PE到所述虚拟节点的链路的状态信息 包括所述第一 Egress PE到所述虚拟节点的链路的 cost值 M和所述虚拟节 点的 Router ID; 发送第二链路状态消息给所述 Ingress PE, 所述第二链路状态消息包 括: 所述虚拟节点的 Router ID、所述虚拟节点到所述第一 Egress PE的链路 的状态信息和所述虚拟节点到所述第二 Egress PE的链路的状态信息, 所述 虚拟节点到所述第一 Egress PE的链路的状态信息包括所述虚拟节点到所述 第一 Egress PE的链路的 cost值 N和所述第一 Egress PE的 Router ID ,所述 虚拟节点到所述第二 Egress PE的链路的状态信息包括所述虚拟节点到所述 第二 Egress PE的链路的 cost值 T和所述第二 Egress PE的 Router ID; 所述第二 Egress PE用于: 生成所述虚拟节点, 发送第三链路状态消息给所述 Ingress PE, 所述第三链路状态消息包 括:所述第二 Egress PE的 Router ID和所述第二 Egress PE到所述虚拟节点 的链路的状态信息, 所述第二 Egress PE到所述虚拟节点的链路的状态信息 包括所述第二 Egress PE到所述虚拟节点的链路的 cost值 S和所述虚拟节点 的 Router ID; 发送第四链路状态消息给所述 Ingress PE, 所述第四链路状态消息包 括: 所述虚拟节点的 Router ID和所述虚拟节点到所述第一 Egress PE的链 路的状态信息、 所述虚拟节点到所述第二 Egress PE的链路的状态信息, 所 述虚拟节点到所述第一 Egress PE的链路的状态信息包括所述虚拟节点到所 述第一 Egress PE的链路的 cost值 N和所述第一 Egress PE的 Router ID,所 述虚拟节点到所述第二 Egress PE的链路的状态信息包括所述虚拟节点到所 述第二 Egress PE的链路的 cost值 T和所述第二 Egress PE的 Router ID; 其中所述 N和所述 T为内部网关协议 IGP的最大 cost值,所述 S和所 述 M满足( 1 )或 ( 2 )
( 1 )
Sxy4+S>Sxy3+M ① 和
C34+S>M ② 其中, Px为所述第一 Egress PE的任何邻居节点 , Pxy为去掉所述第一 Egress PE后的网络中所述 Px的任意邻居节点, Sxy3为所述 Pxy到所述第 一 Egress PE的最短路径的 cost值 , Sxy4为所述 Pxy到所述第二 Egress PE 的最短路径的 cost值 , C34为所述第一 Egress PE到所述第二 Egress PE的 最短路径的 cost值;
( 2 ) X+M<Y+S ③ 其中 X为从所述 Ingress PE到所述第一 Egress PE的最短路径的 cost 值, Y为从所述 Ingress PE到所述第二 Egress PE的最短路径的 cost值。 在第一方面的第一种可能的实现方式中, 所述虚拟节点的 Router ID为 静态配置的, 或者, 通过在所述第一 Egress PE和所述第二 Egress PE之间 动态协商得到。 结合第一方面和第一方面的第一种可能的实现方式, 在第一方面的第 二种可能的实现方式中, 所述虚拟节点的 Router ID为环回标识 Loopback ID。 结合第一方面、 第一方面的第一种或第二种可能的实现方式, 在第一 方面的第三种可能的实现方式中, 如果满足( 1 )或(2 )的 M-S对有多组, 则选择 S最小的 M-S对或者 M最小的 M-S对,将选择的 M-S对中的 M携 带在所述第一链路状态信息中, 将选择的 M-S对中的 S携带在所述第三链 路状态信息中。 结合第一方面、 第一方面的第一种或第二种可能的实现方式或第三种 可能的实现方式, 在第一方面的第四种可能的实现方式中, 对于方式(2 ) 中, M=l , S为内部网关协议 IGP的最大 cost值。 结合第一方面、 第一方面的第一种或第二种或第三种或第四种可能的 实现方式,在第一方面的第五种可能的实现方式中,所述虚拟节点的 Router ID为所述第一 Egress PE和第二 Egress PE中优先级高者所拥有的且未被占 用的网络协议 IP地址。
第二方面, 本发明实施例提供一种网络系统, 包括第一出口运营商边 缘设备 Egress PE、 第二 Egress PE和入口运营商边缘设备 Ingress PE, 所述 第一 Egress PE与客户边缘设备 CE通信 ,所述第二 Egress PE与所述 CE通 信, 所述第一 Egress PE和所述第二 Egress PE位于包括所述第一 Egress PE 和所述第二 Egress PE的冗余保护组内, 其中所述第一 Egress PE为主用设 备, 所述第二 Egress PE为备用设备; 所述第一 Egress PE用于: 生成虚拟节点, 所述虚拟节点具有所述网络系统中全局唯一的 Router ID, 所述虚拟节点用作所述第一 Egress PE的下一跳节点, 所述虚拟节点用 作所述第二 Egress PE的下一跳节点; 发送第一链路状态消息给所述 Ingress PE, 所述第一链路状态消息包 括:所述第一 Egress PE的 Router ID和所述第一 Egress PE到所述虚拟节点 的链路的状态信息, 所述第一 Egress PE到所述虚拟节点的链路的状态信息 包括所述第一 Egress PE到所述虚拟节点的链路的 cost值 M和所述虚拟节 点的 Router ID; 发送第二链路状态消息给所述 Ingress PE, 所述第二链路状态消息包 括: 所述虚拟节点的 Router ID、所述虚拟节点到所述第一 Egress PE的链路 的状态信息和所述虚拟节点到所述第二 Egress PE的链路的状态信息, 所述 虚拟节点到所述第一 Egress PE的链路的状态信息包括所述虚拟节点到所述 第一 Egress PE的链路的 cost值 N和所述第一 Egress PE的 Router ID,所述 虚拟节点到所述第二 Egress PE的链路的状态信息包括所述虚拟节点到所述 第二 Egress PE的链路的 cost值 T和所述第二 Egress PE的 Router ID; 所述第二 Egress PE用于: 生成所述虚拟节点, 发送第三链路状态消息给所述 Ingress PE, 所述第三链路状态消息包 括:所述第二 Egress PE的 Router ID和所述第二 Egress PE到所述虚拟节点 的链路的状态信息, 所述第二 Egress PE到所述虚拟节点的链路的状态信息 包括所述第二 Egress PE到所述虚拟节点的链路的 cost值 S和所述虚拟节点 的 Router ID; 发送第四链路状态消息给所述 Ingress PE, 所述第四链路状态消息包 括: 所述虚拟节点的 Router ID、所述虚拟节点到所述第一 Egress PE的链路 的状态信息和所述虚拟节点到所述第二 Egress PE的链路的状态信息, 所述 虚拟节点到所述第一 Egress PE的链路的状态信息包括所述虚拟节点到所述 第一 Egress PE的链路的 cost值 N和所述第一 Egress PE的 Router ID,所述 虚拟节点到所述第二 Egress PE的链路的状态信息包括所述虚拟节点到所述 第二 Egress PE的链路的 cost值 T和所述第二 Egress PE的 Router ID; 所述第一 Egress PE还用于为第一虚拟专用网络 VPN的第一转发等价 类分配第一标签, 并发送所述第一标签和所述虚拟节点的 Router ID给所述 Ingress PE; 所述第二 Egress PE还用于为所述第一 VPN的所述第一转发等价类分 配所述第一标签, 并发送所述第一标签和所述虚拟节点的 Router ID给所述 Ingress PE。 在第二方面的第一种可能的实现方式中, 所述虚拟节点的 Router ID为 静态配置的, 或者 , 通过所述第一 Egress PE和所述第二 Egress PE之间动 态协商得到。 结合第二方面、 第二方面的第一种可能的实现方式, 在第二方面的第 二种可能的实现方式中, 所述虚拟节点的 Router ID为环回标识 Loopback ID。 结合第二方面、 第二方面的第一种或第二种可能的实现方式, 在第二 方面的第三种可能的实现方式中, 所述虚拟节点的 Router ID 为所述第一 Egress PE所拥有的且未被占用的 IP地址或所述第二 Egress PE所拥有的且 未被占用的网络协议 IP地址。 结合第二方面的第一种或第二种可能的实现方式, 在第二方面的第四 种可能的实现方式中, 所述虚拟节点的 Router ID为所述第一 Egress PE和 第二 Egress PE中优先级高者所拥有的且未被占用的网络协议 IP地址。 结合第二方面的第一种或第二种或第三种或第四种可能的实现方式, 在第二方面的第五种可能的实现方式中, 所述第一标签为静态配置的, 或 者, 通过所述第一 Egress PE和第二 Egress PE之间动态协商得到。 第三方面, 本发明实施例提供一种建立隧道的方法, 该方法应用于网 络系统,所述网络系统包括第一出口运营商边缘设备 Egress PE、第二 Egress PE和入口运营商设备 Ingress PE , 所述第一 Egress PE与客户边缘设备 CE 通信 ,所述第二 Egress PE与所述 CE通信 ,所述第一 Egress PE和第二 Egress PE处于包括所述第一 Egress PE和所述第二 Egress PE的冗余保护组内 , 其 中所述第一 Egress PE为主用设备, 所述第二 Egress PE为备用设备; 所述方法包括: 在所述第一 Egress PE生成虚拟节点, 所述虚拟节点具有所述网络系统 中全局唯一的 Router ID,所述虚拟节点用作所述第一 Egress PE的下一跳节 点, 所述虚拟节点用作所述第二 Egress PE的下一跳节点; 在所述第二 Egress PE上生成所述虚拟节点; 所述第一 Egress PE发送第一链路状态消息给所述 Ingress PE , 所述第 一链路状态消息包括:所述第一 Egress PE的 Router ID和所述第一 Egress PE 到所述虚拟节点的链路的状态信息, 所述第一 Egress PE到所述虚拟节点的 链路的状态信息包括所述第一 Egress PE到所述虚拟节点的链路的 cost值 M 和所述虚拟节点的 Router ID; 所述第一 Egress PE发送第二链路状态消息给所述 Ingress PE , 所述第 二链路状态消息包括: 所述虚拟节点的 Router ID、 所述虚拟节点到所述第 一 Egress PE的链路的状态信息和所述虚拟节点到所述第二 Egress PE的链 路的状态信息, 所述虚拟节点到所述第一 Egress PE的链路的状态信息包括 所述虚拟节点到所述第一 Egress PE的链路的 cost值 N和所述第一 Egress PE 的 Router ID,所述虚拟节点到所述第二 Egress PE的链路的状态信息包括所 述虚拟节点到所述第二 Egress PE的链路的 cost值 T和所述第二 Egress PE 的 Router ID; 所述第二 Egress PE发送第三链路状态消息给所述 Ingress PE, 所述第 三链路状态消息包括:所述第二 Egress PE的 Router ID和所述第二 Egress PE 到所述虚拟节点的链路的状态信息, 所述第二 Egress PE到所述虚拟节点的 链路的状态信息包括所述第二 Egress PE到所述虚拟节点的链路的 cost值 S 和所述虚拟节点的 Router ID; 所述第二 Egress PE发送第四链路状态消息给所述 Ingress PE , 所述第 四链路状态消息包括: 所述虚拟节点的 Router ID、 所述虚拟节点到所述第 一 Egress PE的链路的状态信息和所述虚拟节点到所述第二 Egress PE的链 路的状态信息, 所述虚拟节点到所述第一 Egress PE的链路的状态信息包括 所述虚拟节点到所述第一 Egress PE的链路的 cost值 N和所述第一 Egress PE 的 Router ID,所述虚拟节点到所述第二 Egress PE的链路的状态信息包括所 述虚拟节点到所述第二 Egress PE的链路的 cost值 T和所述第二 Egress PE 的 Router ID; 其中所述 N和所述 T为内部网关协议 IGP的最大 cost值,所述 S所述 M满足 ( 1 )或( 2 ): ( 1 ) Sxy4+S>Sxy3+M ①和
C34+S>M ② 其中, Px为所述第一 Egress PE的任何邻居节点 , Pxy为去掉所述第一 Egress PE后的网络中所述 Px的任意邻居节点, Sxy3为所述 Pxy到所述第 一 Egress PE的最短路径的 cost值 , Sxy4为所述 Pxy到所述第二 Egress PE 的最短路径的 cost值 , C34为所述第一 Egress PE到所述第二 Egress PE的 最短路径的 cost值;
( 2 ) X+M<Y+S ③ 其中 X为从所述 Ingress PE到所述第一 Egress PE的最短路径的 cost 值, Y为从所述 Ingress PE到所述第二 Egress PE的最短路径的 cost值。 在第三方面的第一种可能的实现方式中, 在所述第一 Egress PE和所述 第二 Egress PE上生成虚拟节点, 包括: 所述第一 Egress PE和所述第二 Egress PE通过动态协商的方式生成所述虚拟节点。 结合第三方面的第一种可能的实现方式, 在第三方面的第二种可能的 实现方式中, 所述第一 Egress PE和所述第二 Egress PE通过动态协商的方 式生成所述虚拟节点 , 包括: 所述第一 Egress PE和所述第二 Egress PE之 间建立框间通信协议 ICCP连接, 分别向对方发送自身的优先级, 选择优先 级高的一方来确定所述虚拟节点的 Router ID。 结合第三方面的第二种可能的实现方式, 在第三方面的第三种可能的 实现方式中, 所述虚拟节点的 Router ID是所述第一 Egress PE和所述第二 Egress PE中优先级高的一方所拥有的且未被占用的网络协议 IP地址。 结合第三方面的第三种可能的实现方式, 在第三方面的第四种可能的 实现方式中,如果所述第一 Egress PE和所述第二 Egress PE的优先级相等, 则比较所述第一 Egress PE和所述第二 Egress PE的地址,由所述第一 Egress PE和所述第二 Egress PE中地址较大一方来确定所述虚拟节点的 Router ID。 结合第三方面的第三种可能的实现方式, 在第三方面的第五种可能的 实现方式中,如果所述第一 Egress PE和所述第二 Egress PE的优先级相等, 则比较所述第一 Egress PE和所述第二 Egress PE的地址,由所述第一 Egress PE和所述第二 Egress PE中地址较小一方来确定所述虚拟节点的 Router ID。 结合第三方面的第四种或第五种可能的实现方式, 在第三方面的第六 种可能的实现方式中, 所述虚拟节点的 Router ID是所述第一 Egress PE和 所述第二 Egress PE中地址较大一方的所拥有且未使用的地址。 结合第三方面的第四种或第五种可能的实现方式, 在第三方面的第七 种可能的实现方式中, 所述虚拟节点的 Router ID是所述第一 Egress PE和 所述第二 Egress PE中地址较小一方的所拥有且未使用的地址。 结合第三方面的第一种或第二种或第三种或第四种或第五种或第六种 或第七种可能的实现方式, 在第三方面的第八种可能的实现方式中, 所述 第一 Egress PE和所述第二 Egress PE通过动态协商的方式生成所述虚拟节 点, 包括: 通过在框间通信协议 ICCP报文中携带第一类型-长度-值 TLV, 所述第一 TLV包括 vNH字段和优先级字段,所述优先级字段携带所述 ICCP 址。 结合第三方面、 第三方面的第一种或第二种或第三种或第四种或第五 种或第六种或第七种或第八种可能的实现方式, 在第三方面的第九种可能 的实现方式中, 所述第一 Egress PE和所述第二 Egress PE分别为第一 VPN 的所述第一转发等价类分配所述所述第一标签, 包括: 所述第一 Egress PE 和所述第二 Egress PE通过动态协商的方式来分配所述第一标签。 结合第三方面的第九种可能的实现方式, 在第三方面的第十种可能的 实现方式中, 所述第一 Egress PE和所述第二 Egress PE通过动态协商的方 式来分配所述第一标签, 包括: 所述第一 Egress PE和所述第二 Egress PE 之间建立 ICCP连接, 分别向对方发送自身的优先级, 选择优先级高的一方 来确定所述第一标签。 结合第三方面的第十种可能的实现方式, 在第三方面的第十一种可能 的实现方式中 , 如果所述第一 Egress PE和所述第二 Egress PE的优先级相 等, 则比较所述第一 Egress PE和所述第二 Egress PE的地址, 由所述第一 Egress PE和所述第二 Egress PE中地址较大一方来确定所述第一标签。 结合第三方面的第十种可能的实现方式, 在第三方面的第十二种可能 的实现方式中 , 如果所述第一 Egress PE和所述第二 Egress PE的优先级相 等, 则比较所述第一 Egress PE和所述第二 Egress PE的地址, 由所述第一 Egress PE和所述第二 Egress PE中地址较小一方来确定所述第一标签。 结合第三方面的第九种或第十种或第十一种或第十二种可能的实现方 式, 在第三方面的第十三种可能的实现方式中, 所述第一 Egress PE和所述 第二 Egress PE通过动态协商的方式来分配所述第一标签, 通过在 ICCP报 文中携带第二 TLV来实现, 所述第二 TLV包括 VPN label字段和优先级字 段,所述优先级字段携带所述 ICCP报文的发送方的优先级,所述 VPN label 字段携带所述 ICCP报文的发送方提供的所述第一标签。 结合第三方面的第十三种可能的实现方式, 在第三方面的第十四种可 能的实现方式中, 所述第二 TLV还包括可用标签上限字段和可用标签下限 字段, 所述可用标签上限字段和所述可用标签下限字段用来确定所述 ICCP 报文的发送方可以提供的标签范围。 结合第三方面、 第三方面的第一种或第二种或第三种或第四种或第五 种或第六种或第七种或第八种或第九种或第十种或第十一种或第十二种或 第十三种可能的实现方式, 在第三方面的第十五种可能的实现方式中, 当 所述 VPN为 L3 VPN时 , 可以采用每 VPN标签分配方式 , 也可以采用每路 由标签分配方式或者每接口标签分配方式。 结合第三方面、 第三方面的第一种或第二种或第三种或第四种或第五 种或第六种或第七种或第八种或第九种或第十种或第十一种或第十二种或 第十三种或第十四种或第十五种可能的实现方式, 在第三方面的第十六种 可能的实现方式中, 如果满足(1 )或 (2 ) 的 M-S对有多组, 则选择 S最 小的 M-S对或者 M最小的 M-S对,将选择的 M-S对中的 M携带在所述第 一链路状态信息中, 将选择的 M-S对中的 S携带在所述第三链路状态信息 中。 结合第三方面、 第三方面的第一种或第二种或第三种或第四种或第五 种或第六种或第七种或第八种或第九种或第十种或第十一种或第十二种或 第十三种或第十四种或第十五种可能的实现方式, 在第三方面的第十七种 可能的实现方式中, 对于方式(2 ) 中, M=l , S为内部网关协议 IGP的最 大 cost值。 第四方面, 本发明实施例提供一种标签分配方法, 所述方法应用于网 络系统,所述网络系统包括第一出口运营商边缘设备 Egress PE、第二 Egress PE和入口运营商边缘设备 Ingress PE , 所述第一 Egress PE与客户边缘设备 CE通信, 所述第二 Egress PE与所述 CE通信, 所述第一 Egress PE和所述 第二 Egress PE位于包括所述第一 Egress PE和所述第二 Egress PE的冗余保 护组内, 其中所述第一 Egress PE为主用设备, 所述第二 Egress PE为备用 设备; 所述方法包括: 在所述第一 Egress PE生成虚拟节点, 所述虚拟节点具有所述网络系统 中全局唯一的 Router ID,所述虚拟节点用作所述第一 Egress PE的下一跳节 点, 所述虚拟节点用作所述第二 Egress PE的下一跳节点; 在所述第二 Egress PE上生成所述虚拟节点; 所述第一 Egress PE发送第一链路状态消息给所述 Ingress PE , 所述第 一链路状态消息包括:所述第一 Egress PE的 Router ID和所述第一 Egress PE 到所述虚拟节点的链路的状态信息, 所述状态信息包括所述第一 Egress PE 到所述虚拟节点的链路的 cost值 M和所述虚拟节点的 Router ID; 所述第一 Egress PE发送第二链路状态消息给所述 Ingress PE , 所述第 二链路状态消息包括: 所述虚拟节点的 Router ID、 所述虚拟节点到所述第 一 Egress PE的链路的状态信息和所述虚拟节点到所述第二 Egress PE的链 路的状态信息, 所述虚拟节点到所述第一 Egress PE的链路的状态信息包括 所述虚拟节点到所述第一 Egress PE的链路的 cost值 N和所述第一 Egress PE 的 Router ID,所述虚拟节点到所述第二 Egress PE的链路的状态信息包括所 述虚拟节点到所述第二 Egress PE的链路的 cost值 T和所述第二 Egress PE 的 Router ID; 所述第二 Egress PE发送第三链路状态消息给所述 Ingress PE, 所述第 三链路状态消息包括:所述第二 Egress PE的 Router ID和所述第二 Egress PE 到所述虚拟节点的链路的状态信息, 所述第二 Egress PE到所述虚拟节点的 链路的状态信息包括所述第二 Egress PE到所述虚拟节点的链路的 cost值 S 和所述虚拟节点的 Router ID; 所述第二 Egress PE发送第四链路状态消息给所述 Ingress PE , 所述第 四链路状态消息包括: 所述虚拟节点的 Router ID、 所述虚拟节点到所述第 一 Egress PE的链路的状态信息和所述虚拟节点到所述第二 Egress PE的链 路的状态信息, 所述虚拟节点到所述第一 Egress PE的链路的状态信息包括 所述虚拟节点到所述第一 Egress PE的链路的 cost值 N和所述第一 Egress PE 的 Router ID,所述虚拟节点到所述第二 Egress PE的链路的状态信息包括所 述虚拟节点到所述第二 Egress PE的链路的 cost值 T和所述第二 Egress PE 的 Router ID; 所述第一 Egress PE为第一虚拟专用网络 VPN的第一转发等价类分配 第一标签,并发送所述第一标签和所述虚拟节点的 Router ID给所述 Ingress PE; 所述第二 Egress PE为所述第一 VPN的所述第一转发等价类分配所述 第一标签,并发送所述第一标签和所述虚拟节点的 Router ID给所述 Ingress PE。 在第四方面的第一种可能的实现方式中,在所述第一 Egress PE和所述 第二 Egress PE上生成所述虚拟节点, 包括: 所述第一 Egress PE和所述第 二 Egress PE通过动态协商的方式生成所述虚拟节点。 结合第四方面的第一种可能的实现方式, 在第四方面的第二种可能的 实现方式中, 所述第一 Egress PE和所述第二 Egress PE通过动态协商的方 式生成所述虚拟节点 , 包括: 所述第一 Egress PE和所述第二 Egress PE之 间建立框间通信协议 ICCP连接, 分别向对方发送自身的优先级, 选择优先 级高的一方来确定所述虚拟节点的 Router ID。 结合第四方面、 第四方面的第一种或第二种可能的实现方式, 在第四 方面的第三种可能的实现方式中, 所述虚拟节点的 Router ID是所述第一 Egress PE和所述第二 Egress PE中优先级高的一方所拥有的且未被占用的 IP地址。 结合第四方面的第二种或第三种可能的实现方式, 在第四方面的第四 种可能的实现方式中, 如果所述第一 Egress PE和所述第二 Egress PE的优 先级相等, 则比较所述第一 Egress PE和所述第二 Egress PE的地址, 由所 述第一 Egress PE和所述第二 Egress PE中地址较大一方来确定所述虚拟节 点的 Router ID。 结合第四方面的第二种或第三种可能的实现方式, 在第四方面的第五 种可能的实现方式中, 如果所述第一 Egress PE和所述第二 Egress PE的优 先级相等, 则比较所述第一 Egress PE和所述第二 Egress PE的地址, 由所 述第一 Egress PE和所述第二 Egress PE中地址较小一方来确定所述虚拟节 点的 Router ID。 结合第四方面、 第四方面的第一种或第二种或第三种或第四种或第五 种可能的实现方式, 在第四方面的第六种可能的实现方式中, 所述虚拟节 点的 Router ID是所述第一 Egress PE和所述第二 Egress PE中地址较大一方 所拥有的且未被占用的地址。 结合第四方面、 第四方面的第一种或第二种或第三种或第四种或第五 种可能的实现方式, 在第四方面的第七种可能的实现方式中, 所述虚拟节 点的 Router ID是所述第一 Egress PE和所述第二 Egress PE中地址较小一方 所拥有的且未被占用的地址。 结合第四方面、 第四方面的第一种或第二种或第三种或第四种或第五 种或第六种或第七种可能的实现方式, 在第四方面的第八种可能的实现方 式中, 所述第一 Egress PE和所述第二 Egress PE通过动态协商的方式生成 所述虚拟节点, 包括: 通过在框间通信协议 ICCP报文中携带第一类型-长 度-值 TLV, 所述第一 TLV包括 vNH字段和优先级字段, 所述优先级字段 携带所述 ICCP报文的发送方的优先级, 所述 vNH字段携带所述 CC报文 的发送方的地址。 结合第四方面、 第四方面的第一种或第二种或第三种或第四种或第五 种或第六种或第七种或第八种可能的实现方式, 在第四方面的第九种可能 的实现方式中, 所述第一 Egress PE和所述第二 Egress PE分别为第一 VPN 的所述第一转发等价类分配所述所述第一标签, 包括: 所述第一 Egress PE 和所述第二 Egress PE通过动态协商的方式来分配所述第一标签。 结合第四方面的第九种可能的实现方式, 在第四方面的第十种可能的 实现方式中, 所述第一 Egress PE和所述第二 Egress PE通过动态协商的方 式来分配所述第一标签, 包括: 所述第一 Egress PE和所述第二 Egress PE 之间建立 ICCP连接, 分别向对方发送自身的优先级, 选择优先级高的一方 来确定所述第一标签。 结合第四方面的第十种可能的实现方式, 在第四方面的第十一种可能 的实现方式中 , 如果所述第一 Egress PE和所述第二 Egress PE的优先级相 等, 则比较所述第一 Egress PE和所述第二 Egress PE的地址, 由所述第一 Egress PE和所述第二 Egress PE中地址较大一方来确定所述第一标签。 结合第四方面的第十种可能的实现方式, 在第四方面的第十二种可能 的实现方式中 , 如果所述第一 Egress PE和所述第二 Egress PE的优先级相 等, 则比较所述第一 Egress PE和所述第二 Egress PE的地址, 由所述第一 Egress PE和所述第二 Egress PE中地址较小一方来确定所述第一标签。 结合第四方面的第九种或第十种或第十一种或第十二种可能的实现方 式, 在第四方面的第十三种可能的实现方式中, 所述第一 Egress PE和所述 第二 Egress PE通过动态协商的方式来分配所述第一标签, 通过在 ICCP报 文中携带第二 TLV来实现, 所述第二 TLV包括 VPN label字段和优先级字 段,所述优先级字段携带所述 ICCP报文的发送方的优先级,所述 VPN label 字段携带所述 ICCP报文的发送方提供的所述第一标签。 结合第四方面的第十三种可能的实现方式, 在第四方面的第十四种可 能的实现方式中, 所述第二 TLV还包括可用标签上限字段和可用标签下限 字段, 所述可用标签上限字段和所述可用标签下限字段用来确定所述 ICCP 报文的发送方可以提供的标签范围。 结合第四方面、 第四方面的第一种或第二种或第三种或第四种或第五 种或第六种或第七种或第八种或第九种或第十种或第十一种或第十二种或 第十三种或第十四种可能的实现方式, 在第四方面的第十五种可能的实现 方式中, 当所述 VPN为 L3VPN时, 可以采用每 VPN标签分配方式, 也可 以采用每路由标签分配方式或者每接口标签分配方式。
第五方面, 本发明实施例提供一种第一运营商边缘设备 PE, 所述第一 PE位于包括第二 PE、 入口运营商边缘设备 Ingess PE和所述第一 PE的网 络系统内 ,所述第一 PE和所述第二 PE作为出口运营商边缘设备 Egress PE, 所述第一 PE和所述第二 PE位于包括所述第一 PE和所述第二 PE的冗余保 护组内, 所述第一 PE作为主用 PE, 所述第二 PE作为备用 PE, 所述第一 PE与客户边缘设备 CE通信, 所述第二 PE与所述 CE通信; 所述第一 PE包括: 第一虚拟节点生成模块、 第一状态发布模块、 第一 虚拟节点状态发布模块, 其中: 所述第一虚拟节点生成模块, 用于在所述第一 PE上生成虚拟节点, 所 述虚拟节点具有所述网络系统中全局唯一的 Router ID, 所述虚拟节点用作 所述第一 PE的下一跳节点, 所述虚拟节点用作所述所述第二 PE的下一跳 节点; 所述第一状态发布模块, 用于发送第一链路状态消息给所述 Ingress PE , 所述第一链路状态消息包括: 所述第一 ΡΕ的 Router ID和所述第一 PE 到所述虚拟节点的链路的状态信息,所述第一 PE到所述虚拟节点的链路的 状态信息包括所述第一 PE到所述虚拟节点的链路的 cost值 M和所述虚拟 节点的 Router ID; 所述第一虚拟节点状态发布模块, 还用于发送第二链路状态消息给所 述 Ingress PE, 所述第二链路状态消息包括: 所述虚拟节点的 Router ID、 所 述虚拟节点到所述第一 PE 的链路的状态信息和所述虚拟节点到所述第二 PE的链路的状态信息, 所述虚拟节点到所述第一 PE的链路的状态信息包 括所述虚拟节点到所述第一 PE的链路的 cost值 N和所述第一 PE的 Router ID,所述虚拟节点到所述第二 PE的链路的状态信息包括所述虚拟节点到所 述第二 PE的链路的 cost值 T和所述第二 PE的 Router ID, 其中所述 N和 所述 T为内部网关协议 IGP的最大 cost值, 所述 S和所述 M满足( 1 )或 ( 2 ):
( 1 )
Sxy4+S>Sxy3+M ① 和
C34+S>M ② 其中, Px为所述第一 PE的任何邻居节点, Pxy为去掉所述第一 PE后 的网络中所述 Px的任意邻居节点, Sxy3为所述 Pxy到所述第一 PE的最短 路径的 cost值, Sxy4为所述 Pxy到所述第二 PE的最短路径的 cost值, C34 为所述第一 PE到所述第二 PE的最短路径的 cost值;
( 2 ) X+M<Y+S ③ 其中 X为从所述 Ingress PE到所述第一 PE的最短路径的 cost值, Y为 从所述 Ingress PE到所述第二 PE的最短路径的 cost值。 在第五方面的第一种可能的实现方式中, 还包括第一虚拟节点地址协 商模块, 用于与所述第二 PE协商确定相同的虚拟节点的 Router ID。 结合第五方面、 第五方面的的第一种可能的实现方式, 在第五方面的 第二种可能的实现方式中,还包括所述第一 PE还可以包括第一标签协商模 块, 用于与所述第二 PE协商确定相同的标签。 结合第五方面、 第五方面的的第一种或第二种可能的实现方式, 在第 五方面的第三种可能的实现方式中, 如果满足(1 )或 (2 ) 的 M-S对有多 组, 则选择 S最小的 M-S对或者 M最小的 M-S对, 将选择的 M-S对中的 M携带在所述第一链路状态信息中, 将选择的 M-S对中的 S携带在所述第 三链路状态信息中。 结合第五方面、 第五方面的的第一种或第二种可能的实现方式, 在第 五方面的第二种可能的实现方式中, 对于方式(2 ) 中, M=l , S为 IGP的 最大 cost值。 本发明实施例所述的方法、设备、 系统, 通过在冗余保护组中的 Egress PE上配置相同的虚拟下一跳, 并将该虚拟下一跳节点的地址发送给 Ingress PE, 从而 Ingress PE能够建立经过主用 Egress PE的主隧道, 以及依次经过 主用 Egress EP的上一跳节点、 备用 Egress PE的上一跳节点、 备用 Egress 的备用隧道, 当主用 Egress PE发生故障时, 可以直接切换到备用隧道, 该 切换所涉及的节点设备相对较少, 因而可以以较短的时间完成保护切换, 对该隧道上承载的上层业务来说, 该切换是无缝的、 不被上层业务感知的。 附图说明
为了更清楚地说明本发明实施例或现有技术中的技术方案, 下面将对 实施例或现有技术描述中所需要使用的附图作一简单地介绍, 显而易见地, 下面描述中的附图是本发明的一些实施例, 对于本领域普通技术人员来讲, 在不付出创造性劳动性的前提下, 还可以根据这些附图获得其他的附图。 图 1为本发明实施例的一种网络架构示意图; 图 2为本发明实施例的建立隧道的方法的流程示意图; 图 3为本发明实施例的一种包括虚拟节点的网络架构示意图; 图 4 为本发明实施例的一种协商虚拟节点的 vNH 的方法的流程示意 图; 图 5为本发明实施例的一种通过扩展 ICCP来协商虚拟节点的 vNH的 方法的流程示意图; 图 6为本发明实施例的 ICCP报文头 (ICC header )格式的示意图; 图 7为图 6所示的 ICCP报文头中的 ICC参数的格式的示意图; 图 8为本发明实施例的 vNH TLV的格式的示意图; 图 9为本发明实施例的 vNH RG connect消息的格式示意图; 图 10为本发明实施例的 vNH RG disconnect消息的格式示意图; 图 11为本发明实施例的 vNH RG application data消息的格式示意图; 图 12为本发明实施例的一种协商分配 VPN标签的方法的流程示意图; 图 13为本发明实施例的一种标签分配方法的示意图; 图 14为本发明实施例的 VPN connect消息的格式示意图; 示意图; 图 16为本发明实施例的 VPN application data消息的格式示意图; 图 17为本发明实施例的 VPN label TLV的格式示意图; 图 18为本发明实施例的口字形网络架构示意图; 图 19和 20分别为本发明实施例二的两种网络架构示意图; 图 21和 22分别为本发明实施例三的两种网络架构示意图; 图 23为本发明实施例四的一种网络结构示意图; 图 24为本发明实施例的另一种网络结构示意图; 图 25为本发明实施例的另一种网络结构示意图; 图 26为本发明实施例的一种第一 PE设备的结构示意图。
具体实施方式
为使本发明实施例的目的、 技术方案和优点更加清楚, 下面将结合本 发明实施例中的附图, 对本发明实施例中的技术方案进行描述, 显然, 所 描述的实施例是本发明一部分实施例, 而不是全部的实施例。 基于本发明 中的实施例, 本领域普通技术人员在没有做出创造性劳动前提下所获得的 所有其他实施例, 都属于本发明保护的范围。 本发明实施例中提到的 TLV, 是指 tag-length-value, 标签 -长度 -值。 本 发明实施例中提到的 IGP ( Interior Gateway Protocol, 内部网关协议 ), 可以 是 OSPF ( Open Shortest Path First , 开放最短路径优先) 协议、 ISIS ( Intermediate system to intermediate system, 中间系统到中间系统 )十办议、 MRT ( Maximally Redundant Trees , 最大冗余树 )协议。 本发明实施例中提 到的隧道或路径可以为 MPLS隧道、 GRE ( Generic Routing Encapsulation, 通用路由封装) 隧道、 L2TP 隧道、 IPsec 隧道。 本发明实施例中, 如果有 个 Egress PE位于同一冗余保护组中,则该多个 Egress PE之间通过 ICCP 协商 vNH或标签时, 均为两两之间进行 ICCP协商。 本发明所有实施例中, 如果采用 MRT作为 IGP协议, 则设置 Μ和 S 为任意合法值都可以保证 Egress PE的上一跳节点能计算出第二路径 (备用 路径), 比如设置 M和 S都为 1。 所述第二路径(备用路径)不经过第一路 径(主用路径 )经过的 Egress PE。 采用 IGP协议中的 MRT协议能不受组 网限制地计算出第二路径(备用路径)。 本发明的所有实施例, 均可以应用于双平面网络。 一个网络 N如果满 足下面条件, 称为双平面网络: 该网络包含 Rll,R12,...,Rln,R21,R22,...,R2n节点, l<=i<=n。
( b ) 当且仅当 Rli和 Rlj间有链路时 R2i和 R2j间有链路, 且这两个 链路的 cost值相等。
( c ) Rli和 R2j有链路的必要条件是 i = j。 在该双平面网络网络中, 由 Rli节点及其之间的链路构成的网络部分 称为该网络 N的一个平面; 由 R2i节点及其之间的链路构成的网络部分称 为该网络 N的另外一个平面。 Rli和 R2i称为对称节点。 其中, l<=i<=n。 本发明的所有实施例中, "网络"可以是 IP网络或者 MPLS网络, "节 点" 可以是路由设备, 或者其他具有路由功能的设备。 "PE" 可以是路由设 备, 或者其他具有路由功能的设备。 "Ingress PE" 可以是路由设备, 或者其 他具有路由功能的设备。 "Egress PE" 可以是路由设备, 或者其他具有路由 功能的设备。 CE及客户边缘设备可以是路由设备, 或者其他具有路由功能 的设备。 本发明的所有实施例中, "VPN标签"、 "VPN路由标签"均指用于 VPN 路由的标签。 本发明的所有实施例中, IP地址, 可以为 IPv4 (互联网协议第四版) 地址或 IPv6 (互联网协议第六版)地址; IP网络是指 IPv4网络或 IPv6网 络或者 IPv4与 IPv6混合组网的网络。 本发明的所有实施例中, Router ID是设备上的某个接口的地址。 Router ID可以是环回地址( loopback address ), 即 loopback接口的 IP地址, 也可 以是设备的 IP地址。 当然, 也可以是其他 32位的无符号整数的标识。
如图 1所示, 网络中包括 PE1、 PE2、 PE3、 PE4、 PI和 P2等设备。 PE ( Provider Edge device , 运营商边缘设备) 1、 PE2、 PE3、 PE4为网络的运 营商边缘设备, CE ( Customer Edge device , 客户边缘设备 ) 1和 CE2为用 户设备, CE1和 CE2同属于一个虚拟专用网 VPN ( Virtual Private Network, VPN ),假设 CE1和 CE2同属于 VPN1。 CE1位于站点 sitel , CE2位于 site2。 CE2双归连接到 PE3和 PE4。 CE1可以依次经 PE1、 P I和 PE3与 CE2进行 通信, 也可以依次经 PE2、 P2和 PE4与 CE2进行通信。 对于 L3VPN而言, PE3和 PE4可以通过 BGP ( Border Gateway Protocol, 边界网关协议 )建立 邻居关系。
P1和 P2是运营商设备(Provider device , 运营商骨干设备), 可以有一 个或多个。 也就是说, PE1和 PE3之间的路径上可能有一个或多个 P设备, PE2和 PE4之间的路径上也可能存在一个或多个 P设备。 其中 CE、 PE、 P 设备都可以是路由器或其它具有路由功能的网络设备。 PE设备还可以是 BRAS ( Broadband Remote Access Server, 宽带远程接入服务器)。 CE为用 户提供到 PE 的连接, PE根据存放的路由信息将来自 CE或 LSP ( Label Swiching Path, 标签交换路径) 的 VPN数据处理后进行转发, 并且 PE还 负责与其他 PE交换路由信息。 P设备是不连接任何 CE的骨干网设备, 根 据分组的外层标签对 VPN数据进行透明转发, P设备只维护到 PE设备的 路由信息而不维护 VPN相关的路由信息。
实施例一 如图 2所示, 基于图 1所示的网络架构, 本发明实施例的建立隧道的 方法, 包括: S200、 建立包括第一 Egress PE和第二 Egress PE的冗余保护组 以图 1和 3所示的网络架构为例, 冗余保护组中包括 PE3和 PE4, 假 定 PE3为第一 Egress PE, PE4为第二 Egress PE。 可以通过静态配置的方式 将 PE3和 PE4配置在同一冗余保护组中 ,并指定 PE3和 PE4中的一个作为 该冗余保护组中的主用 Egress PE, 另一个作为该冗余保护组的备用 Egress PE。如果 PE3和 PE4之间运行 BGP, PE3和 PE4可以通过广播路由的方式 发现对方和自身的下一跳均为 CE2, 因此确定 PE3和 PE4处于同一冗余保 护组中。 另外, PE3和 PE4也可能通过路由反射器来确定双方处于同一冗 余保护组中。 对 L3 VPN , 还可以用 VPN路由的广播和本地从 CE收到的路 由比较来发现。 可选地, 所述冗余保护组中可以有两个或两个以上的 Egress PE。
S202、 在第一 Egress PE和所述第二 Egress PE上生成虚拟节点 在所述第一 Egress PE和所述第二 Egress PE上成虚拟节点 , 所述虚拟 节点具有所述网络中全局唯一的 Router ID, 所述虚拟节点用作所述第一 Egress PE的下一跳节点 , 所述虚拟节点用作所述第二 Egress PE的下一跳 节点。 所述虚拟节点的生成可以通过静态配置或者动态协商的方式实现。 对于图 1所示的网络架构, PE1作为 Ingress PE, PE3和 PE4作为 Egress PE, 在 PE3和 PE4上分别生成虚拟节点。 该虚拟节点有一个 Router ID。 所述 Router ID可以是环回 loopback地址。 该 Router ID称为 vNH ( virtual Next HOP, 虚拟下一跳)。 包含虚拟节点的网络架构如图 3所示。 该虚拟节点的 Router ID可以是 PE3所拥有且未被占用的 IP地址或者 PE4所拥有且未被 占用的 IP 地址, 也可以是任何一个与该 IGP 域内的节点设备不重复的 loopback地址或 IP地址。 该虚拟节点分别连接 PE3和 PE4, 该虚拟节点代 表 PE3和 PE4的保护关系。 该虚拟节点的 vNH可以通过在 PE3和 PE4上 静态配置实现, 也可以通过 PE3 和 PE4 之间的 ICCP ( Inter-Chassis Communication Protocol, 框间通信协议)协商实现。 该虚拟节点仅对 IGP ( Internal Gateway Protocol , 内部网关协议 )域内的节点可见, 即, 仅对网 络内的 Ρ设备和 ΡΕ设备可见,对于 CE2不可见, CE2仍然是与 ΡΕ3和 ΡΕ4 分别连接。 虚拟节点的 vNH可以采用网络中具有唯一性的 loopback地址,可以采 用静态配置或者动态选择的方法。 静态配置需要在冗余保护组中的多个 Egress PE上都做配置,在该实施例中可以是在 PE3和 PE4上静态配置虚拟 节点的 vNH。 如果采用动态协商的方式配置虚拟节点的 vNH, 则是在冗余 保护组中的多个 Egress PE中动态协商选择一个 loopback地址。 如图 4所示,一种协商虚拟节点的 vNH的方法,应用于 L3VPN, 包括:
5401、 PE3和 PE4—旦发现有备用 Egress PE存在, 则生成一个上下文 标识 <PE3 , PE4>, 并将该上下文标识发送给所述冗余保护组中的其他 PE, 上下文标识中的 "PE3" 和 "PE4" 可以分别用 PE3的 Router ID和 PE4的 Router ID表示。
5402、 确定该上下文标识是否已经有选定的虚拟下一跳 vNH, 如果有 已经有选定的虚拟下一跳 vNH,则直接使用该选定的虚拟下一跳 vNH作为 该 VPN路由的下一跳重新发布该 VPN路由, 携带第一属性, 该第一属性 用于表示 PE3和 PE4的优先级大小;
5403、 如果没有选定的虚拟下一跳 vNH, 则从 PE3和 PE4中优先级高 者的 loopback地址池中选择一个未使用过的 loopback地址或 IP地址,作为 该上下文标识的 Router ID, 并作为虚拟下一跳 vNH, 用该虚拟下一跳重新 发布该 VPN路由, 该 VPN路由携带第二属性, 该第二属性表示该 vNH的 优先级大小。
5404、 当收到携带该第二属性的路由时, PE3和 PE4能够获知对端 PE 也具备上下文标识处理能力, 则按照携带的属性比较 PE3和 PE4的优先级 大小; 如果 PE3和 PE4优先级相同, 则比较对端路由中的下一跳和本端路 由的下一跳, 选择 IP地址小的 PE作为虚拟下一跳 vNH。 如果选择结果是 本端地址, 则不做处理; 如果选择结果是对端 PE, 则按照新的 vNH重新发 布该 VPN路由。 如图 5所示,假设冗余保护组 RG包括两个 Egress PE PE3和 PE4, PE3 和 PE4之间通过扩展 ICCP ( Inter-Chassis Communication Protocol, 才匡间通 信协议)来协商虚拟节点的 vNH, —种通过扩展 ICCP来协商虚拟节点的 vNH的方法, 包括:
5501 , 冗余保护组 RG中的本端 PE和对端 PE分别向对方发送 ICCP capability报文, 请求建立 ICCP连接;
5502, 本端 PE和对端 PE收到对方发送的 ICCP Capability报文后, 本 端 PE和对端 PE重启以建立 ICCP连接;
5503 , 本端 PE和对端 PE分别向对方发送 vNH RG connect报文;
5504,本端 PE和对端 PE收到对方发送到 vNH RG connect报文后 , 向 对方发送 vNH RG connect A-bit=l , 以确认收到了对方发送的 vNH RG connect报文;
5505, 本端 PE和对端 PE分别向对方发送 vNH data消息 ( vNH data message ), 所述 vNH data消息携带有 vNH TLV, 该 vNH TLV中携带发送 方的优先级;
5506, 本端 PE和对端 PE收到对方发送的带有 vNH TLV的 vNH data 消息后, 将对方发送的 vNH data消息携带的优先级与自身的优先级比较, 如果对方发送的 vNH data消息携带的优先级大于自身的优先级, 则优先级 小的一方将优先级大的一方所拥有且未被占用的地址配置为虚拟节点的 vNH, 优先级大的一方选择自身所拥有且未被占用的地址配置为虚拟节点 的 V丽。 在该实施例中, 如果 PE3的优先级大于 PE4的优先级, 则 PE3上生成 的虚拟节点的 vNH可配置为 PE3所拥有且未被占用的地址(比如地址 1 ), PE4上生成的虚拟节点的 vNH也可配置为 PE3选择的地址(比如地址 1 ); 如果 PE3的优先级小于 PE4的优先级, 则 PE3上生成的虚拟节点的 vNH 可配置为 PE4所拥有且未被占用的地址(比如地址 2 ), PE4上生成的虚拟 节点的 vNH也可配置为 PE4所拥有且未被占用的地址(比如地址 2 )。 其中 ICCP消息可以由 LDP( Label Distribution Protocol,标签分发协议 ) 消息 ? 载。 该 LDP消息可以包含 LDP 文头和 type值为 0x0700〜0x07ff 的 LDP报文。 图 5的实施例中提到的消息介绍如下: ICCP报文头( ICC header )格式如图 6所示。 ICCP报文头包括 U比特
( U bit )、 消息类型(Message Type )、 消息长度( Message Length )、 消息标 识(Message ID )、 ICC RG ID TLV、 强制参数 ( Mandatory Parameters )和 可选参数 ( Optional Parameters )。 各参数的意义 ^口下:
U 比特: 未知消息位。 当收到未知消息时, 如果 u=o, 则向消息生成 方返回通知; 如果 U=l , 该未知消息被忽略。 消息类型 ( Message Type ): 标识该 ICCP消息的类型, 必须在 0x0700 到 0x07ff之间的范围内。 消息长度(Message Length ): 两个字节整数, 标识该消息的字节总长 度, 不包括 U比特、 消息类型和长度域 消息标识( Message ID ): 四个字节值, 用于标识该消息。 发送方 PE 用该字段来方便标识 RG通知消息可以应用于该消息。 PE发送 RG通知消 息作为该消息的响应时,应当将该消息标识加入 RG通知消息的 "NAK TLV" 中。
ICC RG ID TLV: 类型 0x0005的 TLV, 长度 4, 包含 4个字节非定型 整数, 指示发送设备所在的冗余保护组(Redundancy Group ) 强制参数 ( Mandatory Parameters ): 可变长度的要求参数。 可选参数 ( Optional Parameters ): 可变长度的可选消息参数。 在图 6所示的 ICC header格式中, ICC ( Inter-Chassis Communication ) 参数的格式如图 7所示。 ICC参数包括 U比特、 F比特、类型、长度和 TLV。 各个字段的意义如下: U比特(U-bit ): 未知消息位。 当收到未知消息时, 如果 U=0, 则向消 息生成方返回通知; 如果 U=l , 该未知消息被忽略。
F比特( F-bit ): 转发未知的 TLV比特。 该 F比特用于当 U比特设定且 包含未知 TLV的 LDP消息被转发时。 如果 F=0, 该未知 TLV将不会与包 含的消息一起转发; 如果 F=l , 该未知 TLV将会与包含的消息一起转发。 通过设置 U比特和 F比特, TLV可以被作为不透明数据 ( opaque data )在 节点中转发而不识别该 TLV。 类型 (Type ): 14比特, 表示参数类型 长度(Length ): TLV的字节长度, 不包括 U比特、 F比特、 类型和长 度域
TLV ( s ): 根据消息类型, 可以有一个或多个 TLV, 也可以没有 TLV
本发明实施例中, ICCP协商虚拟节点的 vNH, 可以通过在 ICC消息中 增加 vNH TLV来实现。 如图 8所示, 为本发明实施例的 vNH TLV的格式 示意图。 该 vNH TLV包括 U比特、 F比特、 类型( Type ), 长度( Length )、 优先级(Priority ), vNH和保留字段( Reserved )。 各个字段的意义如下:
U 比特: 未知消息位。 当收到未知消息时, 如果 U=0, 则向消息生成 方返回通知; 如果 U=l , 该未知消息被忽略。
F比特( F-bit ): 转发未知的 TLV比特。 该 F比特用于当 U比特设定且 包含未知 TLV的 LDP消息被转发时。 如果 F=0, 该未知 TLV将不会与包 含的消息一起转发; 如果 F=l , 该未知 TLV将会与包含的消息一起转发。 通过设置 U比特和 F比特, TLV可以被作为不透明数据 ( opaque data )在 节点中转发而不识别该 TLV 类型 (Type ): 14比特, 表示参数类型, 可以任意设置 长度(Length ): TLV的字节长度, 不包括 U比特、 F比特、 类型和长 度域。 优先级(Priority ): 表示生成包含该 TLV的消息的节点的优先级 虚拟下一跳 vNH: 表示生成包含该 TLV的消息的节点的 IP地址, 该 IP地址可以是 IPv4地址或者 IPv6地址 保留字段(Reserved ): 保留用于其他用途。 冗余保护组中的多个 Egress PE通过 ICCP协商虚拟节点的 vNH时,在 本端 Egress PE发给对端 Egress PE的 vNH data消息中携带 vNH TLV,由于 该 vNH TLV中携带有 vNH data消息的发送方自身的优先级和发送方自身的 IP地址,因此收到该 vNH data消息的 PE将自身的优先级与收到的 vNH data 消息中携带的优先级比较, 如果自身的优先级高于收到的 vNH data消息中 携带的优先级, 则选择自身选择的 vNH作为虚拟节点的 Router ID; 如果自 身的优先级小于收到的 vNH data消息中携带的优先级, 则选择收到的 vNH data消息的发送方选择的 vNH作为虚拟节点的 Router ID;如果自身的优先 级等于收到的 vNH data消息中携带的优先级,则选择收到的 vNH data消息 的发送方和自身 IP地址大的一方选择的 vNH作为虚拟节点的 Router ID。 也就是说, ΡΕ3和 ΡΕ4分别向对方发送 NH data消息, PE3发送的第一 vNH data消息中携带 PE3的优先级和 PE3的 IP地址, PE4发送的第二 vNH data 消息中携带 PE4的优先级和 PE4的 IP地址。 如果 PE3的优先级高于 PE4 的优先级, 则选择 PE3选择的 vNH作为虚拟节点的 Router ID; 如果 PE3 的优先级小于 PE4的优先级,则选择 PE4选择的 vNH作为虚拟节点的 Router ID; 如果 PE3的优先级等于 PE4的优先级, 则比较 PE3的 IP地址和 PE4 的 IP地址的大小, 如果 PE3的 IP地址大于 PE4的 IP地址, 则选择 PE3选 择的 vNH作为虚拟节点的 Router ID, 如果 PE3的 IP地址小于 PE4的 IP 地址, 则选择 PE4选择的 vNH作为虚拟节点的 Router ID。 当然, 比较 IP 地址大小时,也可以选择 IP地址小的 PE来选择 vNH作为虚拟节点的 Router ID, 即比较 PE3的 IP地址和 PE4的 IP地址的大小 , 如果 PE3的 IP地址大 于 PE4的 IP地址 , 则选择 PE4选择的 vNH作为虚拟节点的 Router ID , 如 果 ΡΕ3的 IP地址小于 PE4的 IP地址,则选择 PE3选择的 vNH作为虚拟节 点的 Router ID。 优先级高的 Egress PE可以选择自身所拥有且未被占用的 IP地址或者 loopback地址作为冗余保护组中每个 Egress PE上生成的虚拟节 点的 νΝΗ ,也可以选择网络中全局唯一的 Router ID作为冗余保护组中每个 Egress PE上生成的虚拟节点的 vNH。
vNH RG connect消息格式如图 9所示。 vNH RG connect消息携带 vNH connect TLV, 该 vNH connect TLV包括 U比特、 F比特、 类型 (Type )、 长 度(Length ), 协议版本( Protocol Version )、 A比特、 保留字段( Reserved ) 和可选的子 TLV。 其中, 类型(Type )的值为自定义, 比如可以为 0x0101。
如图 10所示, vNH RG disconnect消息中, type值可以为 0x0701。 vNH RG disconnect message携带 disconnect code TLV , 当然也可以携带其他可选 的 TLV。 vNH disconnect code TLV中的 Type和 Length的长度为 2字节, Type和 Length的值自定义, 比如 vNH disconnect code TLV中的 type可以 为 0x0104。 vNH RG application data消息格式如图 11所示, vNH RG application data 消息中, 消息类型和 TLV类型的编码值只是一种可能的编码值, 还可以是 其他值, 只要不和标准(draft-ietf-pwe3-iccp-l l即其他相关标准) 中的已分 配值冲突即可。 在所述第一 Egress PE上生成所述虚拟节点之后, 所述第一 Egress PE 发送第一链路状态消息给入口运营商边缘设备 Ingress PE, 所述第一链路状 态消息包括:所述第一 Egress PE的 Router ID和所述第一 Egress PE到所述 虚拟节点的链路的状态信息, 所述第一 Egress PE到所述虚拟节点的链路的 状态信息包括所述第一 Egress PE到所述虚拟节点的链路的 cost值 M和所 述虚拟节点的 Router ID。 在所述第一 Egress PE上生成所述虚拟节点之后, 所述第一 Egress PE 发送第二链路状态消息给所述 Ingress PE, 所述第二链路状态消息包括: 所 述虚拟节点的 Router ID、所述虚拟节点到所述第一 Egress PE的链路的状态 信息和所述虚拟节点到所述第二 Egress PE的链路的状态信息, 所述虚拟节 点到所述第一 Egress PE 的链路的状态信息包括所述虚拟节点到所述第一 Egress PE的链路的 cost值 N和所述第一 Egress PE的 Router ID, 所述虚拟 节点到所述第二 Egress PE的链路的状态信息包括所述虚拟节点到所述第二 Egress PE的链路的 cost值 T和所述第二 Egress PE的 Router ID。 其中所述 N和所述 T为内部网关协议 IGP的最大 cost值。 在所述第二 Egress PE上生成所述虚拟节点之后, 所述第二 Egress PE 发送第三链路状态消息给所述 Ingress PE, 所述第三链路状态消息包括: 所 述第二 Egress PE的 Router ID和所述第二 Egress PE到所述虚拟节点的链路 的状态信息, 所述第二 Egress PE到所述虚拟节点的链路的状态信息包括所 述第二 Egress PE到所述虚拟节点的链路的 cost值 S 和所述虚拟节点的 Router ID。 在所述第二 Egress PE上生成所述虚拟节点之后, 所述第二 Egress PE 发送第四链路状态消息给所述 Ingress PE, 所述第四链路状态消息包括: 所 述虚拟节点的 Router ID、所述虚拟节点到所述第一 Egress PE的链路的状态 信息和所述虚拟节点到所述第二 Egress PE的链路的状态信息, 所述虚拟节 点到所述第一 Egress PE 的链路的状态信息包括所述虚拟节点到所述第一 Egress PE的链路的 cost值 N和所述第一 Egress PE的 Router ID, 所述虚拟 节点到所述第二 Egress PE的链路的状态信息包括所述虚拟节点到所述第二 Egress PE的链路的 cost值 T和所述第二 Egress PE的 Router ID。 其中所述 N和所述 T为内部网关协议 IGP的最大 cost值。 所述 Ingress PE (比如 PE1 )收到所述第一链路状态消息、 所述第二链 路状态消息、 所述第三链路状态消息和所述第四链路状态消息后, 获得所 述虚拟节点的 vNH、 所述第一 Egress PE到所述虚拟节点的链路的 cost值 M和所述第二 Egress PE到所述虚拟节点的链路的 cost值 S。 根据网络中采用的隧道类型不同, 所述第一链路状态消息、 所述第二 链路状态消息、 所述第三链路状态消息和所述第四链路状态消息中的任何 一个还可能包括其他属性, 比如对 MPLS TE隧道,还包括带宽、亲和属性、 颜色等中的一个或多个。
S和 M的值有多种设置方法, 比如对采用显式路由的 MPLS TE隧道, S和 M可以设置成任意合法的 IGP cost值。 也可以静态配置 S和 M。 此外本发明给出了一种用于 GRE隧道和基于 LDP建立的 MPLS隧道 的自动计算方法。 所述第一 Egress PE和所述第二 Egress PE中的至少一个,按照方式( 1 ) 或( 2 )确定所述第一 Egress PE到所述虚拟节点的链路的 cost值 M以及所 述第二 Egress PE到所述虚拟节点的链路的 cost值 S , 并将确定的所述第一 Egress PE到所述虚拟节点的链路的 cost值 M以及所述第二 Egress PE到所 述虚拟节点的链路的 cost值 S同步到所述第一 Egress PE和所述第二 Egress PE所在的冗余保护组中:
( 1 ) S和 M满足:
Sxy4+S>Sxy3+M ① 和 C34+S>M ② 其中, Px为所述第一 Egress PE的任何邻居节点 , Pxy为去掉所述第一 Egress PE后的网络中所述 Px的任意邻居节点, Sxy3为所述 Pxy到所述第 一 Egress PE的最短路径的 cost值 , Sxy4为所述 Pxy到所述第二 Egress PE 的最短路径的 cost值, C34为所述第一 Egress PE到所述第二 Egress PE的 最短路径的 cost值。
( 2 ) S和 M满足:
X+M<Y+S ③ 其中 X为从所述 Ingress PE到所述第一 Egress PE的最短路径的 cost 值, Y为从所述 Ingress PE到所述第二 Egress PE的最短路径的 cost值。 对于方式(1 ), 求解同时满足上述不等式①和不等式②的 S和 M, 即, 求解同时满足不等式①和不等式②的 M-S对。 对于 Egress PE到虚拟节点的链路的 cost值的计算,冗余保护组中的每 个 Egress PE均可计算满足不等式①和不等式②的 M-S对,即冗余保护组中 的 PE3可以计算满足不等式①和不等式②的 M-S对, 冗余保护组中的 PE4 也可以计算满足不等式①和不等式②的 M-S对。 如果冗余保护组中的多个 Egress PE计算出了不同的 M-S对, 则多个 Egress PE 之间可以通过协商的方式确定最终部署在冗余保护组的所有 Egress PE上的 S。 可选地, 如果根据方式( 1 )或 (2 )获得多组满足条件的 M-S对, 则 选择 S最小的 M-S对或者 M最小的 M-S对, 并将选择的 M-S对同步到冗 余保护组的所有 Egress PE。 将选择的 M-S对中的 M携带在所述第一链路 状态信息中, 将选择的 M-S对中的 S携带在所述第三链路状态信息中。 可选地, 可以在冗余保护组中的任意一个 Egress PE上根据方式( 1 ) 或方式(2 )确定 M-S对, 并将确定的 M-S对同步到冗余保护组中的其他 Egress PE上。 可选地, 对于将确定的 M-S对同步到冗余保护组中的其他 Egress PE上, 可以通过同步协议实现。 可选地, 也可以直接按照方式(2 )在冗余保护组的所有 Egress PE上 配置 M和 S。 比如, 可以将 M设置为 1 , 将 S设置为 IGP协议中的 cost值 的最大值。 可选地,还可以在冗余保护组的多个 Egress PE上按照方式( 1 )或( 2 ) 计算 M和 S, 如果根据方式( 1 )或( 2 )获得多组满足条件的 M-S对, 则 选择 S最小的 M-S对或者 M最小的 M-S对, 当然, 也可以任选一组满足 不等式①和②的 M-S对。 将选择的 M-S对中的 M携带在所述第一链路状 态信息中, 将选择的 M-S对中的 S携带在所述第三链路状态信息中。
S204、 建立从 Ingress PE到所述虚拟节点的隧道 结合图 3的网络架构,假定 PE3为第一 Egress PE, PE4为第二 Egress PE , PEl为 Ingress PE,建立从 Ingress PE到所述虚拟节点的隧道。 PEl通过 IGP 计算出以 PE1为起点, 经过 PE3的第一路径: ΡΕ1->Ρ1->ΡΕ3-> ^ 节点。 PE3的上一跳节点 P1通过 IGP计算出以 P1为起点,不经过 PE3 ,经过 PE4 的第三路径: Ρ1->Ρ2->ΡΕ4->虚拟节点,该第三路径和第一路径中的 PE1->P1 组成第二路径: ΡΕ1->Ρ1->Ρ2->ΡΕ4->虚拟节点。 第二路径不经过 Egress PE PE3。 从 Ingress PE到所述虚拟节点的隧道包括第一路径和第二路径。 所述第一路径和第二路径可以是通过运行 LDP生成的 MPLS LSP, 也 可以是根据其他协议生成的路径或隧道。 所述 IGP 可以是 OSPF ( Open Shortest Path First, 开放最短路径优先)协议或 ISIS ( Intermediate System to Intermediate System, 中间系统到中间系统)协议或 MRT。 在图 3所示的网络架构中, PE1为 Ingress PE, PE3和 PE4为 Egress PE, 假设 PE3为包括 PE3和 PE4的冗余保护组中的主用设备( Primary PE ), PE4 为 PE3和 PE4所在的冗余保护组中的备用设备 ( Backup PE ), 建立一条经 过主用设备 PE3 到达虚拟节点的主隧道或主路径 ΡΕ1->Ρ1->ΡΕ3->虚拟节 点, 同时建立依次经过主用设备 PE3的上一跳节点 P1、备用设备 PE4的上 一跳节点、 备用设备 PE4 到达虚拟节点的保护隧道或者保护路径 ? 1->?1->?2->? 4->虚拟节点 , 该保护隧道或者保护路径不经过主用设备 PE3。 主隧道的建立是经过 PE3还是 PE4因隧道类型不同而不同, 每个节点
(包含路径的中间节点 )都按照它自己到虚拟节点的总 cost确定下一跳, 从而得到整个隧道路径。 对 LDP 建立的 MPLS ( Multiple Protocol Label Switch, 多协议标签交换) 隧道, 隧道是依赖路由的, 当需要把 PE3 作为 主隧道的经过节点时, 可以按照上述的 IGP链路 cost值设置方法设置。 当 需要把 PE4作为主隧道的经过节点时 ,可以把上述 PE3和 PE4的 IGP的链 路 cost值交换。 链路 cost值的设置还可以有其他的设置方法, 对具体的网络可以有艮 多个值可以用, 通常是个范围。 上述方法只是其中之一。 一对互为保护关系的 PE谁是主用设备, 谁是备用设备是相对隧道的 Ingress PE (比如图 3中的 PE1 ) 而言的, 不同的 Ingress PE可能会有不同 的主用设备和备用设备。 当采用 LDP隧道时, 上述的 cost设置在 M、 S有 解时能够根据 LFA算法计算出第二路径, 从而使得 Egress PE的保护能由 Egress PE的上一跳节点 P设备把流量切换到第二路径来完成。采用该方法, 无需更改现网仅支持 LFA的 P设备, 只需替换 Egress PE就可以实现本发 明实施例的方法。 另一种 cost值的设置方法是: M和 S满足 X+M<Y+S, 其中 X为从所述 Ingress PE到所述第一 Egress PE的最短路径的 cost值 , Y 为从所述 Ingress PE到所述第二 Egress PE的最短路径的 cost值。 比如, 可 以设置 M为 1 , S为 IGP的合法最大值 (不同 IGP协议的合法最大值不同, 具体的实现厂家也会稍有区别)。 该 cost设置对所有的 Ingress PE都有相同 的主用设备和备用设备。 有时候, 谁是主用设备谁是备用设备并不重要, 如果不同的 Ingress PE能相对均匀地选择冗余保护组中的一个 PE作为主用 Egress PE则利于流量负载分担。 如果采用 MRT作为 IGP协议, 则设置 M和 S为任意合法值都可以保 证 Egress PE的上一跳能计算出第二路径 (备用路径 ) , 比如设置 M和 S都 为 1。所述第二路径 (备用路径 )不经过第一路径 (主用路径 )经过的 Egress PE。采用 IGP协议中的 MRT协议则能不受组网限制地计算出第二路径 (备 用路径)。 该虚拟节点、 该虚拟节点与 PE3之间的链路、 该虚拟节点与 PE4之间 的链路的生成, 可以通过 PE3和 PE4之间的 IGP协议完成。 当网络中的各个设备之间运行 0SPF ( Open Shortest Path First, 开放式 最短路径优先 )协议时, PE3上生成虚拟节点后, PE3的链路状态及邻居关 系均发生了变化, 因此 PE3更新自身的链路状态和邻居关系, 构造第一链 路状态广播数据 LSA ( Link State Advertisement, LSA ), 并将该第一 LSA 洪泛到整个网络中 , 该第一 LSA包括: PE3的 Router ID和 PE3到该虚拟 节点的链路的状态信息, PE3到该虚拟节点的链路的状态信息包括 PE3到 该虚拟节点的链路的 cost值和该虚拟节点的 Router ID。 由于 PE3上生成了 该虚拟节点, PE3还会 "代表"该虚拟节点构造第二 LSA, 并将该第二 LSA 洪泛到整个网络中。 该第二 LSA包括: 该虚拟节点的 Router ID、 该虚拟节 点到 PE3的链路的状态信息和该虚拟节点到 PE4的链路的链路的状态信息。 该虚拟节点到 PE3的链路的状态信息包括该虚拟节点到 PE3的链路的 cost 值和 PE3的 Router ID,该虚拟节点到 PE4的链路的状态信息包括该虚拟节 点到 PE4的链路的 cost值和 PE4的 Router ID。 类似地, 冗余保护组中的其 他 Egress PE, 也构造相应的 LSA并将这些 LSA洪泛到整个 OSPF域中, 该 OSPF域可以是整个网络。 比如 PE4上生成该虚拟节点后, PE4的链路 状态及邻居关系均发生了变化, 因此 PE4更新自身的链路状态和邻居关系, 构造第三 LSA, 并将该第三 LSA洪泛到整个网络中。 该第三 LSA包括: PE4的 Router ID和 PE4到该虚拟节点的链路的状态信息, PE4到该虚拟节 点的链路的状态信息包括 PE4到该虚拟节点的链路的 cost值和该虚拟节点 的 Router ID。 由于 PE4上生成了该虚拟节点, PE4还会 "代表" 该虚拟节 点构造第四 LSA, 并将该第四 LSA洪泛到整个网络中, 该第四 LSA包括: 该虚拟节点的 Router ID、 该虚拟节点到 PE3的链路的状态信息、 该虚拟节 点到 PE4的链路的状态信息。 该虚拟节点到 PE3的链路的状态信息包括该 虚拟节点到 PE3的链路的 cost值和 PE3的 Router ID, 该虚拟节点到 PE4 的链路的状态信息包括该虚拟节点到 PE4的链路的 cost值和 PE4的 Router ID。 PE3和 PE4把这些 LSA泛洪到 OSPF域中 , 这样, 与 PE3和 PE4处于 同一 OSPF域内的其他节点, 比如 PE1就能 "看到" 该虚拟节点、 该虚拟 节点与 PE3之间的链路、 该虚拟节点与 PE4之间的链路, 从而能够建立从 PE1到该虚拟节点的 vNH的隧道。 链路状态就是路由器的 OSPF接口上的 描述信息,例如接口上的 IP地址、子网掩码、 网络类型、 cost值等等。 OSPF 路由器之间交换的并不是路由表, 而是链路状态, OSPF路由器(比如 PE1 ) 通过获得网络中所有的链路状态信息, 从而计算出到达每个目标精确的网 络路径。 当 PE3和 PE4之间运行 ISIS( Intermediate system to intermediate system , 中间系统到中间系统)协议时, PE3上生成虚拟节点后, PE3的链路状态及 邻居关系均发生了变化, 因此 PE3更新自身的链路状态和邻居关系, 构造 第一链路状态报文 LSP ( Link-state PDU ), 并将该第一 LSP洪泛到整个网 络中,该第一 LSP包括: PE3的 Router ID和 PE3到该虚拟节点的链路的状 态信息, PE3到该虚拟节点的链路的状态信息包括 PE3到该虚拟节点的链 路的 cost值和虚拟节点的 Router ID。 由于 PE3上生成了该虚拟节点, PE3 还会 "代表" 该虚拟节点构造第二 LSP, 并将该第二 LSP洪泛到整个网络 中, 该第二 LSP包括: 该虚拟节点的 Router ID、 该虚拟节点到 PE3的链路 的状态信息和该虚拟节点到 PE4的链路的链路的状态信息。 该虚拟节点到 PE3 的链路的状态信息包括该虚拟节点到 PE3 的链路的 cost值和 PE3 的 Router ID, 该虚拟节点到 PE4的链路的状态信息包括该虚拟节点到 PE4的 链路的 cost值和 PE4的 Router ID。类似地,冗余保护组中的其他 Egress PE, 比如也构造相应的 LSP并将这些 LSP洪泛到整个 ISIS域中, 该 ISIS域可 以是整个网络。 比如 PE4上生成虚拟节点后, PE4的链路状态及邻居关系 均发生了变化, 因此 PE4更新自身的链路状态和邻居关系, 构造第三 LSP, 并将该第三 LSP洪泛到整个网络中, 该第三 LSP包括: PE4的 Router ID 和 PE4到该虚拟节点的链路的状态信息, PE4到该虚拟节点的链路的状态 信息包括 PE4到该虚拟节点的链路的 cost值和该虚拟节点的 Router ID。 由 于 PE4上生成了该虚拟节点, PE4还会 "代表" 该虚拟节点构造第四 LSP, 并将该第四 LSP洪泛到整个网络中,该第四 LSP包括:该虚拟节点的 Router ID、 该虚拟节点到 PE3的链路的状态信息、 该虚拟节点到 PE4的链路的状 态信息。 该虚拟节点到 PE3的链路的状态信息包括该虚拟节点到 PE3的链 路的 cost值和 PE3的 Router ID,该虚拟节点到 PE4的链路的状态信息包括 该虚拟节点到 PE4的链路的 cost值和 PE4的 Router ID。 PE3和 PE4把这些 LSP泛洪到 ISIS域中,这样,与 PE3和 PE4处于同一 ISIS域内的其他节点, 比如 PE1就能 "看到" 该虚拟节点、 该虚拟节点与 PE3之间的链路、 该虚 拟节点与 PE4之间的链路,从而能够建立从 PE1到该虚拟节点的 vNH的隧 道。 生成的虚拟节点与冗余保护组中的 Egress PE 之间的链路的属性值
( cost值)可以根据情况自动设置或者人工设置。 比如, 如果希望 PE3成 为隧道的主路径经过的节点, 而 PE4成为隧道的备用路径经过的节点, 则 可以把 PE3到虚拟节点的链路的 cost值设置为 1 , 把 PE4到虚拟节点的链 路的 cost值设置为 IGP的最大 cost值。根据 PE3和 PE4之间运行的不同的 IGP, 可以设置不同的链路最大 cost值, 比如该网络中运行 OSPF时, 链路 最大 cost值可以设置为 65535。 为了不让虚拟节点承担穿通流量(transit traffic ), 可以把虚拟节点到 PE3的链路的 cost值和虚拟节点到 PE4的链路 的 cost值都设置为 IGP最大 cost值。 为了避免穿通流量, 需要将虚拟节点 配置为 overload模式。 在 OSPF协议下可通过将该虚拟节点到 Egress PE节 点 PE3的链路的 cost值以及该虚拟节点到 PE4的链路的 cost值置为 IGP的 最大 cost值来实现。 在 ISIS协议下, 可以通过将所述第二 LSP和第四 LSP 的 overload bit位置 1来实现。在 IGP中,一个物理链路通常是双向的, IGP 里描述的链路都是有方向的, 每个方向需要单独描述。 一个物理链路在不 同方向上的 cost值可能不同, 也可能相同。 虚拟节点在物理上并不是真实存在的, 只是为了 IGP域内的其他节点 能够计算出一条经过 PE3的隧道而生成的。 PE3的上游节点 P1能计算出另 外一个到达 PE4的备用隧道, 比如 PE1->P1->P2->PE4, 该备用隧道不经过 PE3。 这样在 PE3故障时能通过 P 1把流量切换到备用隧道到达 PE4 , 从而 达到保护 PE3的目的。 因为 PE3和 PE4是对称的 , 也可以建立经过 PE4的主隧道 , 而在 PE4 的上一跳节点(比如图 3中的 P2 )建立经过 PE3且不经过 PE4的备用隧道, 比如 PE1->P2->P1->PE3 , 在 PE4故障时, 在 P2上把流量切换到备份隧道 上从而达到保护 PE4的目的。
S206、 第一 Egress PE为第一虚拟专用网络 VPN的第一转发等价类分 配第一标签, 第二 Egress PE为所述第一 VPN的第一转发等价类分配所述 第一标签 第一 Egress PE和第二 Egress PE分别为所述第一 VPN的第一转发等价 类分配所述第一标签。 分配标签可以是为每个路由分配标签, 也可以是为 每个 VPN分配标签, 还可以是为每个接口或端口分配标签。。 每个 PE都有 自己的一个标签空间, 并且独立地进行分配。 如果是每个 VPN分配标签, Ingress PE向 Egress PE发送报文时, 要给报文加上 Egress PE为该 VPN分 配的标签。 比如图 13中, 通常情况下, PE3为某个 VPN (比如 VPN1 )分 配的 VPN标签为 1100, 而 PE4为该 VPN1分配的 VPN标签可能是 2100。 在这种情况下,当 PE1发送该 VPN1的 VPN报文给 PE3时就需要使用 PE3 分配的 VPN标签 1100, 该 VPN报文到达 PE3后, PE3能正确地用 1100查 找到对应的 VPN (即 VPN1 )。 如果携带 VPN标签 1100的该 VPN报文被 发送到了 PE4, PE4将无法识别该 VPN报文并正确处理, 要么会错误地转 发到其他 VPN, 要么由于在 PE4上没有 VPN标签 1100对应的表项而丟弃 该 VPN报文或者不处理该 VPN报文。 本发明的实施例中, 由于 PE3和 PE4上生成了虚拟节点 , PE3和 PE4 在发现自身位于冗余保护组中时, 通过动态协商或通过静态配置为某个 VPN (比如 VPN1 )分配相同的 VPN标签, 从而无论该 VPN才艮文发送到主 用 PE (比如 PE3 )还是备用 PE (比如 PE4 ), 该 VPN报文都能被正确处理。
PE3和 PE4之间可以建立 ICCP会话 , 并且协商为 VPN分配的相同的 标签。 PE3和 PE4在发布 VPN路由时都采用该相同标签来作为 VPN路由 的标签。 这里采用的是每 VPN标签分配方式(即: 为每个 VPN分配一个 标签), 实际上也可以采用每路由分配标签的方式(即: 为 VPN的每个路 由分配一个标签), 或者每接口分配标签方式(每个联接电路 AC ( Attached Circuit )接口分配一个标签)。 以每 VPN分配标签为例, 如图 12所示, 协 商分配 VPN标签的方法, 包括:
51201 , 冗余保护组 RG中的本端 PE (比如图 3中的 PE3 )和对端 PE (比如图 3中的 PE4 )分别向对方发送 ICCP capability报文,请求建立 ICCP 连接;
51202 , ICCP连接建立后本端 PE和对端 PE重启;
51203 , 本端 PE和对端 PE分别向对方发送 VPN RG connect报文;
51204, 本端 PE和对端 PE收到对方发送到 VPN RG connect报文后 , 向^"方发送 VPN RG connect A-bit=l;
51205,本端 PE和对端 PE分别向对方发送 VPN data消息,该 VPN data 消息包括 VPN label TLV, 该 VPN label TLV中携带自身的优先级; 51206, 本端 PE和对端 PE收到对方发送的 VPN data消息后 , 将对方 发送的 VPN data消息携带的优先级与自身的优先级比较, 如果对方发送的 VPN data消息携带的优先级大于自身的优先级, 则优先级小的一方接受优 先级大的一方分配的 VPN标签, 这里^^定本端 PE的优先级大于对端 PE 的优先级。 也就是说, 如果本端 PE的优先级比远端 PE的优先级大, 对端 PE分 配的标签(Lr )在本端 PE还没有被占用 (未分配), 则选择本端 PE给该 VPN分配 Lr。 如果本端 PE的优先级比远端 PE的优先级大, 对端 PE分配 的标签(Lr )在本端 PE已经被占用, 则从对端 PE可用标签空间选择一个 标签 Li, 该 Li在本端 PE未分配, 本端 PE给该 VPN分配 Li。 用新分配的 标签更新 ICCP消息。 如果本端 PE的优先级比对端 PE的优先级小, 检查 对端 PE分配的标签 Lr在本端 PE是否已被占用, 如果对端 PE分配的标签 Lr在本端 PE没有被占用, 则采用 Lr。 如果对端 PE分配的标签 Lr在本端 PE被占用,则对端 PE分配一个新的标签 L1,更新 ICCP消息发给本端 PE, 如果该标签 L1未被本端 PE占用, 则使用该标签 L1作为 VPN的标签; 如 果该标签 L1被本端 PE占用, 则对端 PE分配另一个标签 Ln作为 VPN的 标签。 如果本端 PE的优先级与对端 PE的优先级相等, 则本端 PE和对端 PE分别报告错误, 发送 RG notification消息, 携带 reject TLV和优先级错 误 TLV。
51207, 本端 PE确定一个双方都可用的标签, 并将该标签携带在 VPN data消息的 VPN label TLV中发给对端 PE
51208, 对端 PE接收到优先级大的本端 PE发送的 VPN data消息后, 校验本端 PE确定的标签的可用性;
51209, 如果对端 PE确定本端 PE确定的标签不可用, 则对端 PE向本 端 PE发送 VPN data消息, 该 VPN data消息的 VPN label TLV中携带对端 PE建议的标签值和对端 PE的可用标签空间;
51210, 本端 PE收到对端 PE发送的携带对端 PE建议的标签值和对端 PE的可用标签空间的 VPN data消息, 重新选定标签, 并将新选定的标签携 带在 VPN data消息的 VPN label TLV中发送给对端 PE;
S1211 ,如果对方发送的 VPN data消息的 VPN label TLV携带的优先级 等于自身的优先级, 则向对方发送 disconnect消息断开双方的 ICCP连接。
建立从 Ingress PE到虚拟节点的隧道保护组之后, 主用 Egress PE (比 如 PE3 )的该主用 Egress PE的上一跳邻居(比如 P3 )就能在主用 Egress PE (比如 PE3 )故障时把流量从主用 Egress PE (比如 PE3 )迅速切换到备用 Egress PE (比如 PE4 )。 检测主用 Egress PE故障的方法可以有多种, 比如 可以根据物理接口的状态来确定主用 PE是否故障,也可以通过在 Ingress PE (比如 PE1 )和 Egress PE(比如 PE3 )之间运行 BFD( Bidirectional Forwarding Detection, 双向转发检测)协议来确定主用 PE是否故障。 备份路径可以预 先计算并且安装在转发平面, 通过 BFD 协议或者以太 OAM ( Operation Administration and Maintenance, 操作管理维护)检测, 检测时间也能控制 在 50ms以内, 所以能在 50ms内将流量从主用 PE (比如 PE3 )到备用 PE (比如 PE4 )。故障检测也可以局限在链路上直连的两个设备间的链路层面, 无需端到端(比如 PE1到 PE3跨越多跳 )的 BFD检测, 比如可以将故障检 测局限在主隧道上的 P1和 PE3这两个直连设备之间。 备用 PE (比如 PE4 )接收到从主用 PE切换过来的流量后, 需要能正 确处理 VPN 内层标签, 本发明实施例中, 为主用 PE (比如 PE3 )和备用 PE (比如 PE4 )的相同 VPN分配相同标签的方法 ,使得备用 PE (比如 PE4 ) 收到从主用 PE (比如 PE3 )切换过来的流量后能按照普通的 VPN流程进行 处理, 无需特殊的转发硬件和流程。
以下对图 12所示的 VPN标签协商方法中涉及的报文的格式做一简要 介绍。
VPN connect消息 ( VPN connect message )用于建立 ICCP冗余保护组 连接和冗余保护组内地 PE之间的单个应用程序连接 ( individual Application connections )。 如图 14所示, VPN connect消息包括:
( 1 ) 带有消息类型值为" RG Connect Message"(0x0700)的 ICC头部,
( 2 ) ICC发送方名称 TLV ( ICC Sender Name TLV ), 以及
( 3 ) 0个或一个应用特性连接 TLV ( Application-specific connect TLV )。
VPN connect TLV包括: U比特、 F比特、类型( Type ),长度( Length )、 协议版本(Protocol Version ), A 比特、 保留字段(Reserved )和可选的子 TLV。 其中, 类型 (Type ) 的值自定义, 比如可以为 0x0111。 协议版本字 段的值可以为 0x0001。 U比特和 F比特的值可以设为 0。
VPN disconnect消息用作:
( 1 )特定应用程序连接 ( articular Application connection )被关闭时的 信号, 或者,
( 2 )由于 PE希望离开冗余保护组而导致的 ICCP冗余保护组连接本身 被关闭的信号。 VPN disconnect消息的 type值可以为 0x0701。 VPN disconnect消息携 带有图 15 ( a )所示的 VPN disconnect code TLV, VPN disconnect消息中也 可以携带其他可选的 TLV。 VPN disconnect code TLV中的 Type和 Length 的长度为 2字节, Type和 Length的值自定义,比如 VPN disconnect code TLV 中的 type可以为 0x0114。 可选地, VPN disconnect 消息还可以携带图 15 ( b ) 所示的 VPN disconnect Cause TLV。 VPN disconnect Cause TLV包括: U比特、 F比特、 长度 ( Length )、 类型 ( Type )和 Disconnect Cause String。 Disconnect Cause String表示 VPN标签协商中 ICCP连接断开的原因。 U比特和 F比特的值 可以为 0。 VPN disconnect code TLV中的 Type和 Length的长度为 2字节, Type和 Length的值自定义, 比如 VPN disconnect code TLV中的 type可以 为 0x0115。
VPN application data消息用于在同一冗余保护组内地 PE之间传输数 据。如图 16所示, VPN application data消息包括:一个单个的 VPN application data消息可以被用于携带一个应用程序 (application ) 的数据, 多个应用程 序 TLV ( application TLV )可以携带在一个单独的 VPN application data消息 中, 只要该多个应用程序 TLV都属于该应用程序。 VPN application data消 息的格式包括带有消息类型为 RG Application Data Message(0x703)的 ICC 头部、 应用程序特性 TLV ( Application specific TLV )。 图 16中, 除了 ICC 头部以外, VPN application data消息还包括 VPN特性 TLV: VPN config TLV。 VPN config TLV包括 U比特、 F比特、 类型 ( Type ), 长度( Length )、 冗余对象标识 ROID、 业务名称 TLV ( service name TLV )和 VPN标签 TLV ( VPN label TLV ), 其中 U比特和 F比特的值均可以为 0。 类型值可以为 0x01112。 ROID ( Redundant Object Identifier )用于唯一地标识冗余保护组 中被保护的一个冗余对象 (Redundant Object )。 该冗余对象可以是链路 ( link ), 链路组 ( bundle )、 VLAN ( Virtual Local Area Network, 虚拟局域 网)等。业务名称 TLV可以包括 U比特、 F比特、类型( Type ),长度( Length ) 和业务名称( service name )。 U比特和 F比特值可以为 0, 类型 ( Type )值 为自定义, 比如可以为 0x0113 , 业务名称包括以 UTF-8格式编码的 L2VPN 业务实例的名称, 业务名称字段最长 80个字符( character )。 其中 VPN label TLV用于标识发送该 VPN application data消息的 PE为
Ingress PE分配的 VPN标签。 主用 PE (比如 PE3 )和备用 PE (比如 PE4 ) 分别向对方发送 VPN application data消息以协商为 Ingress PE分配相同的 VPN标签。 VPN label TLV格式如图 17所示, VPN label TLV包括 U比特、 F比特、 类型 (Type )、 长度(Length ), 标签下限( Label Lower )、 标签上 限( Label upper )和保留字段 ( Reserved )。 其中 U比特和 F比特的值可以 为 0, 类型 (Type ) 的值为自定义值, 比如可以为 0x0102。 Label Lower标 识可用标签空间下限值; Label upper标识可用标签空间上限值。 上述消息中的消息类型和 TLV类型的编码值只是一种可能的编码值, 还可以是其他值, 只要不和标准(draft-ietf-pwe3-iccp-l l ) 中的已分配值冲 突即可。
上述实施例的方法是针对一个冗余保护组中只包括两个出口 PE ( Egress PE )的场景, 该方法可以应用在包括多个出口 PE ( Egress PE )的 冗余保护组中, 该冗余保护组中, 一个 PE为某个 Ingress PE的主隧道经过 的节点, 其他 PE都是备份隧道经过的节点, 且备份隧道不经过主隧道经过 的 PE节点。 在包括多个出口 PE的场景中, 需要静态配置或者选举出主用 PE和备用 PE。 还可以静态配置或者通过选举指定多个备用 PE的优先级顺 序。主用 PE故障时,多个备用 PE可以按照优先级顺序来替换主用 PE,即, 将主用隧道切换到某个备用隧道上。在包括多个 Egress PE的冗余保护组中, 可以比较所述冗余保护组中所有 Egress PE 的优先级, 选择优先级最高的 Egress PE作为该冗余保护组的主用 Egress PE, 该冗余保护组中的其他 Egress PE作为该冗余保护组的备用 Egress PE。 如果比较过程中, 有多个 Egress PE的优先级相等且均为该冗余保护组中优先级最高的 Egress PE,则 比较该多个优先级相等的 Egress PE 的地址, 选择该多个优先级相等的 Egress PE中地址最大或最小的 Egress PE作为主用 Egress PE。 比如如果该 冗余保护组中包括 5个 Egress PE: PE1、 PE2、 PE3、 PE4、 PE5, PE1、 PE2 和 PE3的优先级相等且 PE1、 PE2和 PE3的优先级均高于 PE4和 PE5的优 先级, 则比较 PE1的地址、 PE2的地址和 PE3的地址之间的大小, 假定比 较结果是 PE 1的地址大于 PE2的地址, PE2的地址大于 PE3的地址, 则可 以选择地址最大的 PE1作为该冗余保护组的主用 Egress PE。 当然, 也可以 选择地址最小的 PE3作为该冗余保护组的主用 Egress PE。 选举出主用 Egress PE后, 可以建立从 Ingress PE经过主用 Egress PE 到达虚拟节点的隧道, 还可以建立多条依次经过主用 PE的上一跳节点、备 用 Egress PE, 到达虚拟节点的备用隧道, 所述备用隧道不经过主用 Egress PE。 主用 Egress PE故障时, 多个备用 Egress PE可以按照优先级顺序来替 换主用 Egress PE, 即, 将流量从经过主用 Egress PE到达虚拟节点的主用 隧道切换到某个经过主用 PE的上一跳节点和备用 Egress PE到达虚拟节点 的备用隧道上。 同一冗余保护组中的多个 Egress PE通过 ICCP协商时, 该多个 Egress
PE的 ICCP协商是通过两两 ICCP协商实现的。 本发明实施例的方法, 还可以和 MRT ( Maximally Redundant Trees , 最 大冗余树) FRR ( Fast ReRoute, 快速重路由) 配合使用, MRT FRR能确 保只要网络是 2-connected的就能够计算出备份隧道, 并且主 PE的上游邻 居计算出的备份隧道不会经过主 PE。 也就是说一旦主 PE故障后, 报文一 定能切换到备份 PE上。 一个网络被称为是 2-connected的, 如果这个网络 仅在至少有两个节点被删除时才被分割成 2部分或者更多部分( A graph that has no cut-vertices. This is a graph that requires two nodes to be removed before the network is partitioned )。 2-connected 网络的定义可以参考 IETF draft-enyedi-rtgwg-mrt-fir-algorithm-02。 然而, 有些网络可能不使用 MRT FRR技术。 对于使用基于 IGP LFA ( loop-free alternate,无环替代(下一兆 ) )的 LDP( Label Distribution Protocol, 标签分发协议) FRR ( Fast ReRoute,快速重路由)技术的网络,主用 Egress PE的上游邻居可能计算不到备份隧道。 本发明实施例还给出一个生成主备 Egress PE到虚拟节点间的链路 cost值的方法, 可以改进基于 IGP LFA的 LDP FRR计算出备份隧道的可能性, 提高本发明实施例的技术方案的可部 署性。 对于图 3所示的网络架构,假设主用 Egress PE为 PE3 ,备用 Egress PE 为 PE4, PE3到虚拟节点的链路 cost值为 M, PE4到虚拟节点的链路 cost 值为 S。 所述链路的 cost值有多种设置方法, 比如对采用显式路由的 MPLS TE隧道, S和 M可以设置成任意合法的 IGP cost值。 也可以静态配置 S和 M。 此外本发明给出了一种用于 GRE隧道和基于 LDP建立的 MPLS隧道 的自动计算方法。
PE3和 PE4中的至少一个, 按照方式( 1 )或 ( 2 )确定 PE3到所述虚 拟节点的链路的 cost值 M以及 PE4到所述虚拟节点的链路的 cost值 S, 并 将确定的 PE3到所述虚拟节点的链路的 cost值 M以及 PE4到所述虚拟节点 的链路的 cost值 S同步到所述 PE3和 PE4所在的冗余保护组中:
( 1 ) S和 M满足:
Sxy4+S>Sxy3+M ①和 C34+S>M ② 其中, Px为 PE3的任何邻居节点, Pxy为去掉 PE3后的网络中所述 Px 的任意邻居节点, Sxy3为所述 Pxy到 PE3的最短路径的 cost值, Sxy4为 所述 Pxy到 PE4的最短路径的 cost值, C34为 PE3到 PE4的最短路径 cost 值。
( 2 ) S和 M满足:
X+M<Y+S ③ 其中 X为从所述 Ingress PE到所述第一 Egress PE ( PE3 ) 的最短路径 的 cost值, 大于从所述 Ingress PE到所述第二 Egress PE ( PE4 ) 的最短路 径的 cost值。 对于方式(1 ), 求解同时满足上述不等式①和不等式②的 S和 M, 即, 求解同时满足不等式①和不等式②的 M-S对。 对于 Egress PE到虚拟节点的链路的 cost值的计算,冗余保护组中的每 个 Egress PE均可计算满足不等式①和不等式②的 M-S对,即冗余保护组中 的 PE3可以计算满足不等式①和不等式②的 M-S对, 冗余保护组中的 PE4 也可以计算满足不等式①和不等式②的 M-S对。 如果冗余保护组中的多个 Egress PE计算出了不同的 M-S对, 则多个 Egress PE 之间可以通过协商的方式确定最终部署在冗余保护组的所有 Egress PE上的 S。 可选地, 如果根据方式( 1 )或 (2 )获得多组满足条件的 M-S对, 则 选择 S最小的 M-S对或者 M最小的 M-S对, 并将选择的 M-S对同步到冗 余保护组的所有 Egress PE。 将选择的 M-S对中的 M携带在所述第一链路 状态信息中, 将选择的 M-S对中的 S携带在所述第三链路状态信息中。 可选地, 可以在冗余保护组中的任意一个 Egress PE上根据方式( 1 ) 或方式(2 )确定 M-S对, 并将确定的 M-S对同步到冗余保护组中的其他 Egress PE上。 可选地, 对于将确定的 M-S对同步到冗余保护组中的其他 Egress PE上, 可以通过同步协议实现。 可选地, 也可以直接按照方式(2 )在冗余保护组的所有 Egress PE上 配置 M和 S。 比如, 可以将 M设置为 1 , 将 S设置为 IGP协议中的 cost值 的最大值。 可选地,还可以在冗余保护组的多个 Egress PE上按照方式( 1 )或( 2 ) 计算 M和 S, 如果根据方式( 1 )或( 2 )获得多组满足条件的 M-S对, 则 选择 S最小的 M-S对或者 M最小的 M-S对, 当然, 也可以任选一组满足 不等式①和②的 M-S对。 将选择的 M-S对中的 M携带在所述第一链路状 态信息中, 将选择的 M-S对中的 S携带在所述第三链路状态信息中。 特别地, 图 18所示, 如果网络中互为保护的两个 Egress PE ( PE3和 PE4 )与网络侧的拓朴是口字型结构, 主隧道为 ΡΕ1->Ρ1->ΡΕ3->虚拟节点, 备用隧道为 ΡΕ1->Ρ1->Ρ2->ΡΕ4->虚拟节点。 殳设 P1到 PE3的链路的 cost 值为 A=10, PI i'J P2 ό 链路^ J cost值为 B=30, P2 PE4 ό 链路^ J cost值 为 C=20, PE3到 PE4之间的 cost值为 D=50, PE3到虚拟节点的 cost值为 M, PE4到虚拟节点的 cost值为 S,则根据这 4台设备之间的链路 cost也能 找到合适的 Egress PE到虚拟节点的链路的 cost满足 LFA计算要求。 如果 C+D>A+B。 C+S<A+B+M即可, 即 M-S >C-(A+B)。 这里可以设 置 M=2+C-A-B, S=l。 这只是其中一种设法, 还可以有其他设置方法, 只 要满足 M-S >C-(A+B)即可。 如果 C+D<A+B则可以设置 M=l , S=D即可。 这只是其中一种设法, 还可以有其他设置方法, 只要满足 S<D+M即可。 如果 C+D = A+B则可以设置 M=l , S=l即可。 这只是其中一种设法, 还可以把 M和 S设置为任意合法值。 该合法值是指就是 IGP协议规定的合 法的值范围中的任何一个。 如果一个 PE同时连接到两个或多个 P设备,则对每组 P设备都要满足 上述关系。
实施例二 如图 19所示, 本发明实施例的方法应用于 L3VPN, PE1、 PE2、 PE3、 PE4、 Pl、 P2均位于 MPLS网络中, 其中 PE1、 PE2、 PE3、 PE4位于 MPLS 网络的边缘。 所述网络为对称网络。 PE1、 P3、 PE3在 A平面, PE2、 P2、 PE4在 B平面, A平面和 B平面对称, CE1和 CE2属于一个 VPN, 比如 VPNK 对于从 CE1到 CE2的报文来说, PE1为入节点, PE3和 PE4为出 节点。 PE3上生成虚拟节点, 该虚拟节点的 Router ID为 νΝΗ1。 PE4上也 生成地址为 vNHl 的虚拟节点。 可以通过动态协商或者静态配置虚拟节点 的 vNHl ,动态协商 vNHl的方法可以参考图 4及对应的段落所描述的方法, 也可以参考图 5 ~ 11及对应的段落所描述的方法。假定该冗余保护组中 PE3 为主用 PE ( Primary PE ), PE4为备用 PE ( Backup PE )。 建立 PE1到虚拟 节点的隧道, PE1 到虚拟节点的隧道包括主用路径和备用路径。 PE1 通过 IGP 计算出以 PE1 为起点, 经过 PE3 的第一路径 (主用路径): ΡΕ1->Ρ1->ΡΕ3->虚拟节点。 PE3的上一跳节点 P1通过 IGP计算出以 P1为 起点, 不经过 PE3 , 经过 PE4的第三路径: Ρ1->Ρ2->ΡΕ4->虚拟节点, 该第 三路径和第一路径中的 PE1->P1 组成第二路径 (备用路径 ): PE 1 ->P 1 -〉 P2->PE4->虚拟节点。 第二路径不经过 Egress PE PE3。 Egress PE PE3与 Ingress PE PE1之间建立 BGP session。 PE3和 PE4发布 VPN路由时, 用相同的虚拟节点的 Router ID vNHl作为 VPN的 BGP下一跳。 比如, PE3 发布的 VPN路由可以是 VPNl : prefixl->Ll, vNHl ;即, PE1收到属于 VPN1 的报文时, 为该报文打上标签 L1 , 经主路径 PE1->P1->PE3发送到 CE2。 如果 PE3故障, 则自动把经过 PE3的 VPN1的报文切换到 PE4, 即切换到 PE1到第一冗余保护组的备用路径 PE1->P1->P2->PE4。 建立 PE2到虚拟节点的隧道, PE2到虚拟节点的隧道包括主用路径和 备用路径。 PE2通过 IGP计算出以 PE2为起点, 经过 PE4的第四路径 (主 用路径 ): PE2->P2->PE4->虚拟节点。 PE4的上一跳节点 P2通过 IGP计算 出以 P2为起点, 不经过 PE4, 经过 PE3的第六路径: Ρ2->Ρ1->ΡΕ3->虚拟 节点, 该第六路径和第四路径中的 PE2->P2组成第五路径 (备用路径): PE2->P2->P 1 -〉 PE3->虚拟节点。 第五路径不经过 Egress PE PE4。 Egress PE PE4与 Ingress PE PE2之间建立 BGP session, 对应的 PE3和 PE2间也建立 BGP session。 PE3和 PE4发布 VPN路由时,用相同的虚拟节点的 Router ID vNHl作为 VPN的 BGP下一跳。 比如, PE4向 PE2发布的 VPN路由可以 是 VPN1 : prefix 1->L1 , vNHl ; 即, PE2收到属于 VPN1的报文时, 为该 才艮文打上标签 L1 , 经主路径 PE2->P2->PE4发送到 CE2。 如果 PE4故障, 则自动把经过 PE4的 VPN1的报文切换到 PE3 , 即切换到 PE3到冗余保护 组的备用路径 PE2->P2->P 1 ->PE3。 实施例三 如图 20所示, 本发明实施例的方法应用于 L3VPN, PE1、 PE2、 PE3、 PE4、 Pl、 P2均位于 MP S网络中, 其中 PE1、 PE2、 PE3、 PE4位于 MP S 网络的边缘。 CE1和 CE2属于一个 VPN, 比如 VPN1。 对于从 CE1到 CE2 的报文来说, PE1为入节点, PE3和 PE4为出节点。 CE3和 CE4属于一个 VPN, 比如 VPN2。 对于从 CE3到 CE4的报文来说, PE2为入节点, PE3 和 PE4为出节点。 可以在 PE3和 PE4上分别生成两个虚拟节点: 第一虚拟 节点和第二虚拟节点, 其中实线表示经过主用 PE ( Primary PE )的主路径, 虚线表示经过备用 PE( Backup PE )的备用路径。使得一部分经过 Ingress PE 的报文采用第一虚拟节点传输,另外一部分经过 Ingress PE的报文采用第二 虚拟节点传输, 从而可以使得流量分布较为均匀。 假定在 PE3上生成两个虚拟节点: 第一虚拟节点和第二虚拟节点, 所 述第一虚拟节点 (虚拟节点 1 ) 的地址为 vHNl , 第二虚拟节点 (虚拟节点 2 ) 的地址为 vNH2。 在 PE4上也生成地址为 vNHl的第一虚拟节点和地址 为 vNH2 的第二虚拟节点。 可以通过动态协商或者静态配置确定第一虚拟 节点的 vNHl和第二虚拟节点的 vNH2, 动态协商 vNHl或 vNH2的方法可 以参考图 4及对应的段落所描述的方法, 也可以参考图 5 ~ 11及对应的段 落所描述的方法。 如果采用 LDP建立 MPLS隧道,可以对 PE3和 PE4进行如下设置: PE3 到虚拟节点 1的链路 cost值设置为一个较小的值, 使得任一 Ingress PE到 虚拟节点的总 cost值小于 IGP的最大 cost值, 比如将 PE3到虚拟节点 1的 链路 cost值设置为 1 ,将 PE4到虚拟节点 1的链路 cost值设置为最大 IGP cost 值。或者也可以将 PE3到虚拟节点 2的链路 cost值设置为最大 IGP cost值, 将 PE4到虚拟节点 2的链路 cost值设置为一个较小的值, 使得任一 Ingress PE到虚拟节点的总 cost值小于 IGP 的最大 cost值, 比如将 PE4到虚拟节 点 2的链路 cost值设置为 1。动态协商 vNH2的方法可以参考图 4及对应的 段落所描述的方法, 也可以参考图 5 ~ 11及对应的段落所描述的方法。 以 vNHl为 VPN1路由的 BGP下一跳, 可以建立第一冗余保护组, 该 第一冗余保护组包括 PE3和 PE4, 其中可以假定 PE3为主用 PE ( Primary PE ), PE4为备用 PE ( Backup PE )。 建立 PEl到虚拟节点的隧道, PEl到 虚拟节点的隧道包括主用路径和备用路径。 PE1通过 IGP计算出以 PE1为 起点, 经过 PE3的第一路径(主用路径): ΡΕ1->Ρ1->ΡΕ3->虚拟节点。 PE3 的上一跳节点 P 1通过 IGP计算出以 P 1为起点 , 不经过 PE3 , 经过 PE4的 第三路径: P 1 ->P2->PE4->^ ^ A , 该第三路径和第一路径中的 PE1->P1 组成第二路径(备用路径): ΡΕ1->Ρ1->Ρ2->ΡΕ4->虚拟节点。 第二路径不经 过 Egress PE PE3„ Egress PE PE3与 Ingress PE PEl之间建立 BGP session, PE4与 PEl之间建立 BGP session。 PE3和 PE4发布 VPN1路由时, 用虚拟 节点的 Router ID vNHl作为 VPN1的 BGP下一跳。比如,PE3发布的 VPN1 的路由可以是 VPN1 : prefixl->Ll, vNHl ; 即, PEl收到属于 VPN1的报文 时, 为该 4艮文打上标签 L1 , 经 PE1->P1->PE3发送到 CE2。 如果 PE3故障, 贝 J 自动把经过 PE3 的 VPN1 的报文切换到 PE4 , 路径调整为 PE1->P1->P2->PE4, PE4可以识别出该报文携带的标签 L1对应于 VPN1。 以 vNH2为 VPN2路由的 BGP下一跳, 可以建立第二冗余保护组, 该 第二冗余保护组包括 PE3和 PE4, 其中可以假定 PE4为主用 PE ( Primary PE ), PE3为备用 PE ( Backup PE )。 建立 PE2到虚拟节点的隧道, PE2到 虚拟节点的隧道包括主用路径和备用路径。 PE2通过 IGP计算出以 PE2为 起点, 经过 PE4的第四路径(主用路径): PE2->P2->PE4->虚拟节点。 PE4 的上一跳节点 P2通过 IGP计算出以 P2为起点 , 不经过 PE4 , 经过 PE3的 第六路径: P2->P 1 ->PE3 - >) λ ι? A , 该第六路径和第四路径中的 PE2->P2 组成第五路径(备用路径): ΡΕ2->Ρ2->Ρ1->ΡΕ3->虚拟节点。 第五路径不经 过 Egress PE PE4。 Egress PE PE4与 Ingress PE PE2之间建立 BGP session, PE3与 PE2之间建立 BGP session。 PE3和 PE4发布 VPN2路由时, 用虚拟 节点的 Router IDvNH2作为 VPN2的 BGP下一跳。 比如, PE4向 PE2发布 的 VPN2的路由可以是 VPN2: prefix 1->L2, vNH2,即, PE2收到属于 VPN2 的报文时, 为该报文打上标签 L2, 经 PE2->P2->PE4发送到 CE2, PE4可 以识别出该报文携带的标签 L2对应于 VPN2。 如果 PE4故障, 则自动把经 过 PE4的 VPN2的才艮文切换到 PE3 , 路径调整为 PE2->P2->P1->PE3 , PE3 可以识别出该报文携带的标签 L2对应于 VPN2。
PE1和 PE2收到 VPN路由后即可根据 vNH找到对应的隧道, 该隧道 在主用 Egress PE的上一跳节点计算出保护隧道,具有保护主用 PE的功能。
Ingress PE对 PE保护对中哪个 Egress PE为主用 PE, 哪个为备用 PE 并不关心。 而不同的 Ingress PE选择的隧道可能有不同的主 Egress PE。 所 以本发明实施例中的 Egress PE到虚拟节点的链路 cost值的设置可以采用自 动计算方法, 采用基于 IGP LFA的 LDP FRR来计算备份路径, 具体可以参 见实施例一中的描述。 也可以用基于 MRT FRR的 LDP FRR算法或者其他 算法。 流量可以分布到互为保护的 Egress PE上。 实施例四 互为保护的 Egress
PE发送 LDP mapping消息时, 在 LDP mapping消息中携带一个 TLV, 该 TLV的值域为 vNH。 Ingress PE收到 LDP mapping消息后即采用该 TLV中 的 vNH找到对应的隧道, 该隧道具有保护主 PE的功能。 如果双归的 CE的两个 AC ( attached circuit, CE连接 PE的链路 )处于 负载均衡(load balance )模式, 或者说两个 AC都是活跃( active ) 的, 则 Ingress PE建立的到 Egress PE的隧道中哪个 Egress PE为主用 PE, 哪个 PE 为备用 PE可以是任意的。 不同的 Ingress PE选择的隧道可能有不同的主 Egress PE, 从而流量可以分布到互为保护的 Egress PE上。 如果 Egress PE侧的 CE的两个 AC处于主备工作模式, 则通常要求隧 道的主 Egress PE 和 AC 的主用保持一致, 比如 AC 采用 MC-LAG ( Multi-chassis Link Aggregation Group, 跨框链路聚合组)。 如图 21所示, PE1和 PE3之间通过 LDP来建立伪线 PW, LDP采用下 游自主分配的方式来分配 PW标签, PE之间使用扩展到 Hello发现机制来 建立 LDP会话。 LDP Mapping消息包括 FEC TLV、标签 TLV和其他可选地 参数。 其中 FEC TLV用来区别绑定 PW标签的不同 PW。 在本发明的实施 例中, 可以在 LDP mapping消息中携带一个 TLV , 该 TLV的值域为 vNH。 Ingress PE收到 LDP mapping消息后即采用该 TLV中的 vNH找到对应的隧 道, 该隧道具有保护主用 PE的功能。 在图 21中, PE1、 PE2、 PE3、 PE4、 Pl、 P2均位于 MPLS网络中, 其 中 PE1、 PE2、 PE3、 PE4位于 MPLS网络的边缘。 CE1和 CE2属于一个 VPN, 比如 VPN1 , CE3和 CE4属于一个 VPN, 比如 VPN2。 对于从 CE1 到 CE2的报文来说, PE1为入节点, PE3和 PE4为出节点。 对于从 CE3到 CE4的报文来说, PE2为入节点, PE3和 PE4为出节点。 当在该 MPLS网 络上传输二层报文时, 报文在入节点被加上 MPLS标签, 经 MPLS LSP隧 道发送到出节点, 出节点根据报文携带的标签解析该报文对应的下一跳, 拆除标签后转发给 CE。 CE1依次经过 PE1->P1->PE3与 CE2通信; CE3依 次经过 PE2->P2->PE4与 CE4通信。 PE3上生成虚拟节点, 该虚拟节点的 Router ID为 νΝΗ1。 PE4上也生成地址为 vNHl的虚拟节点。可以通过动态 协商或者静态配置确定虚拟节点的 vNHl ,动态协商 vNHl的方法可以参考 图 4及对应的段落所描述的方法, 也可以参考图 5 ~ 11及对应的段落所描 述的方法。 建立包括 PE3和 PE4的第一冗余保护组。 假定该第一冗余保护 组中 PE3为主用 PE ( Primary PE ), PE4为备用 PE ( Backup PE )。 建立 PE1 到虚拟节点的隧道, PE1 到虚拟节点的隧道包括主用路径和备用路径。 出 节点 PE3和入节点 PE1之间建立第一 LDP session。 PE3为 VPN1,也就是对 应 CE2的 VPN发布第一 LDP mapping消息, 采用虚拟节点的 Router ID vNHl作为该第一 LDP mapping消息中的 PW标签的下一跳, 即, PE3为 VPN 1发布的 PW标签可以为 P Wl ->L 1 , vNH 1 , 该 P W标签表示从 PE 1到 PE3存在一条伪线 PW1 ,通过该伪线 PW1传输的 文在入节点 PE1将被加 上标签 L1 , 该报文的目的节点地址为 vNHl , 该报文在入节点 PE1加上标 签 L1后, 经 P1到达 PE3 , PE3根据自身的标签映射表确定该报文携带的 标签 L1对应伪线 PW1 , 则拆除标签 L1 , 并将该报文发送到 PW1的下一跳 CE2。 如果 PE3故障, 则自动把经过 PE3的 VPN1的报文切换到 PE4, 路径 调整为 PE1->P1->P2->PE4, 该 VPN1的报文仍然使用标签 L1 , 对于 VPN 业务来说, 该切换并不能感知, 由于该切换仅仅是从主用 Egress PE ( PE3 ) 的上一跳节点切换到备用 Egress PE ( PE4 ), 经过主用 Egress PE到达虚拟 节点的主用隧道和经过备用 Egress PE到达虚拟节点的备用隧道,在 Ingress PE看来并未切换隧道。出节点 PE4和入节点 PE2之间建立第二 LDP session。 PE4为 VPN2,也就是对应 CE4的 VPN发布第二 LDP mapping消息,采用虚 拟节点的 Router IDvNHl作为该第二 LDP mapping消息中的 PW标签的下 一跳 ILM, 即, PE4为 VPN2发布的 PW标签可以为 PW2->L2, vNHl , 该 PW标签表示从 PE2到 PE4存在一条伪线 PW2 ,通过该伪线 PW2传输的报 文在入节点 PE2将被加上标签 L2, 该报文的目的节点地址为 vNHl , 该报 文在入节点 PE2加上标签 L2后, 经 P2到达 PE4, PE4根据自身的标签映 射表确定该报文携带的标签 L2对应伪线 PW2, 则拆除标签 L2, 并将该报 文发送到 PW2的下一 3兆 CE4。 如果 PE4故障, 则自动把经过 PE4的 VPN2的报文切换到 PE3 , 路径 调整为 PE2->P2->P1->PE3 , 该 VPN2的报文仍然使用标签 L2, 对于 VPN 业务来说, 该切换并不能感知, 由于该切换仅仅是从主用 Egress PE ( PE4 ) 的上一跳节点切换到备用 Egress PE ( PE3 ), 经过主用 Egress PE到达虚拟 节点的主用隧道和经过备用 Egress PE到达虚拟节点的备用隧道,在 Ingress PE看来并未切换隧道。 如图 22所示, 采用两个虚拟节点, 使得一部分 PW采用虚拟节点 1 , 另外一部分采用虚拟节点 2可以使得流量分布较为均匀。
PE1、 PE2、 PE3、 PE4、 Pl、 P2均位于 MP S网络中, 其中 PE1、 PE2、 PE3、 PE4位于 MPLS网络的边缘。 CE1和 CE2属于一个 VPN,比如 VPN1 , CE3和 CE4属于一个 VPN, 比如 VPN2。 对于从 CE1到 CE2的报文来说, PE1为入节点, PE3和 PE4为出节点。对于从 CE3到 CE4的报文来说, PE1 为入节点, PE3和 PE4为出节点。 CE1依次经过 PE1->P1->PE3与 CE2通 信; CE3依次经过 PE1->PE2->P2->PE4与 CE4通信。
PE3上生成虚拟节点 1 , 该虚拟节点 1的地址为 νΝΗ1。 PE4上也生成 地址为 vNHl 的虚拟节点。 可以通过动态协商或者静态配置确定虚拟节点 的 vNHl ,动态协商 vNHl的方法可以参考图 4及对应的段落所描述的方法, 也可以参考图 5 ~ 11及对应的段落所描述的方法。 建立包括 PE3和 PE4的 第一冗余保护组。 假定该第一冗余保护组中 PE3为主用 PE ( Primary PE ), PE4为备用 PE ( Backup PE )„ 建立 PE1到虚拟节点的隧道, PE1到虚拟节 点的隧道包括主用路径和备用路径。 出节点 PE3和入节点 PE1之间建立第一 LDP session。 PE3为 VPN1,也 就是对应 CE2的 VPN发布第一 LDP mapping消息,采用虚拟节点 1的地址 vNHl作为该第一 LDP mapping消息中的 PW标签的下一跳, 即, PE3为 VPN1发布的 PW标签可以为 PW1->L1 , vNHl , 该 PW标签表示从 PE1到 PE3存在一条伪线 PW1 ,通过该伪线 PW1传输的 文在入节点 PE1将被加 上标签 L1 , 该报文的目的节点地址为 vNHl , 该报文在入节点 PE1加上标 签 L1后, 经 P1到达 PE3 , PE3根据自身的标签映射表确定该报文携带的 标签 L1对应伪线 PW1 , 则拆除标签 L1 , 并将该报文发送到 PW1的下一跳 CE2。 如果 PE3故障, 则自动把经过 PE3的 VPN1的报文切换到 PE4, 路径 调整为 PE1->P1->P2->PE4, 该 VPN1的报文仍然使用标签 L1 , 对于 VPN 业务来说, 该切换并不能感知, 由于该切换仅仅是从主用 Egress PE ( PE3 ) 的上一跳节点切换到备用 Egress PE ( PE4 ), 经过主用 Egress PE到达虚拟 节点 1的主用隧道和经过备用 Egress PE到达虚拟节点 1的备用隧道, 在 Ingress PE看来并未切换隧道。
PE3和 PE4还可以建立第二冗余保护组及生成对应的虚拟节点 2。 PE3 上生成虚拟节点 2,该虚拟节点 2的地址为 vNH2。 PE4上也生成地址为 vNH2 的虚拟节点 2。 可以通过动态协商或者静态配置确定虚拟节点 2的 vNH2, 动态协商 vNH2的方法可以参考图 4及对应的段落所描述的方法, 也可以 参考图 5 ~ 11及对应的段落所描述的方法。 假定该第二冗余保护组中 PE4 为主用 PE ( Primary PE ), PE3为备用 PE ( Backup PE )„ 出节点 PE4和入 节点 PE 1之间建立第二 LDP session。 PE4为 VPN2,也就是对应 CE4的 VPN 发布第二 LDP mapping消息,采用虚拟节点 2的地址 vNH2作为该第二 LDP mapping消息中的 PW标签的下一跳 ILM, 即 , PE4为 VPN2发布的 PW标 签可以为 PW2->L2, vNH2, 该 PW标签表示从 PE1到 PE4存在一条伪线 PW2, 通过该伪线 PW2传输的报文在入节点 PE1将被加上标签 L2, 该报 文的目的节点地址为 vNH2, 该报文在入节点 PE1 加上标签 L2后, 经 PE2->P2到达 PE4, PE4根据自身的标签映射表确定该报文携带的标签 L2 对应伪线 PW2 , 则拆除标签 L2 , 并将该艮文发送到 PW2的下一跳 CE4。 如果 PE4故障, 则自动把经过 PE4的 VPN2的报文切换到 PE3 , 路径 调整为 PE1->PE2->P2->P1->PE3 , 该 VPN2的报文仍然使用标签 L2, 对于 VPN 业务来说, 该切换并不能感知, 由于该切换仅仅是从主用 Egress PE ( PE4 )的上一跳节点切换到备用 Egress PE ( PE3 ), 经过主用 Egress PE到 达虚拟节点的主用隧道和经过备用 Egress PE到达虚拟节点的备用隧道,在 Ingress PE看来并未切换隧道。
实施例五 本发明实施例还提供一种网络系统, 该网络系统包括第一出接口运营 商边缘设备 Egress PE、第二 Egress PE和入接口运营商边缘设备 Ingress PE, 该第一 Egress PE与客户边缘设备 CE通信,该第二 Egress PE和所述 CE通 信,所述第一 Egress PE和第二 Egress PE位于包括所述第一 Egress PE和第 二 Egress PE的冗余保护组内, 其中所述第一 Egress PE为主用设备, 所述 第二 Egress PE为备用设备。如图 3所示,第一 Egress PE为 PE3 ,第二 Egress PE为 PE4, CE2分另' J与 PE3和 PE4通信。 如图 23所示, 所述第一 Egress PE包括: 第一虚拟节点生成模块 2301、 第一状态发布模块 2302、 第一虚拟节点状态发布模块 2303 , 其中: 第一虚拟节点生成模块 2301 ,用于在所述第一 Egress PE上生成虚拟节 点, 所述虚拟节点具有所述网络系统中全局唯一的 Router ID, 所述虚拟节 点用作所述第一 Egress PE 的下一跳节点, 所述虚拟节点用作所述第二 Egress PE的下一跳节点; 第一状态发布模块 2302, 用于发送第一链路状态消息给所述 Ingress PE , 所述第一链路状态消息包括: 所述第一 Egress PE的 Router ID和所述 第一 Egress PE到所述虚拟节点的链路的状态信息, 所述第一 Egress PE到 所述虚拟节点的链路的状态信息包括所述第一 Egress PE到所述虚拟节点的 链路的 cost值 M和所述虚拟节点的 Router ID; 第一虚拟节点状态发布模块 2303 , 用于发送第二链路状态消息给所述 Ingress PE, 所述第二链路状态消息包括: 所述虚拟节点的 Router ID、 所述 虚拟节点到所述第一 Egress PE的链路的状态信息和所述虚拟节点到所述第 二 Egress PE的链路的状态信息, 所述虚拟节点到所述第一 Egress PE的链 路的状态信息包括所述虚拟节点到所述第一 Egress PE的链路的 cost值 N 和所述第一 Egress PE的 Router ID , 所述虚拟节点到所述第二 Egress PE的 链路的状态信息包括所述虚拟节点到所述第二 Egress PE的链路的 cost值 T 和所述第二 Egress PE的 Router ID。 其中所述 N和所述 T为内部网关协议 IGP的最大 cost值。 所述第二 Egress PE包括: 第二虚拟节点生成模块 2304、第二状态发布 模块 2305、 第二虚拟节点状态发布模块 2306, 其中: 第二虚拟节点生成模块 2304,用于在所述第二 Egress PE上生成所述第 一虚拟 PE上生成的虚拟节点; 第二状态发布模块 2305 , 用于发送第三链路状态消息给所述 Ingress PE , 所述第三链路状态消息包括: 所述第二 Egress PE的 Router ID和所述 第二 Egress PE到所述虚拟节点的链路的状态信息, 所述第二 Egress PE到 所述虚拟节点的链路的状态信息包括所述第二 Egress PE到所述虚拟节点的 链路的 cost值 S和所述虚拟节点的 Router ID; 第二虚拟节点状态发布模块 2306, 用于发送第四链路状态消息给所述 Ingress PE, 所述第四链路状态消息包括: 所述虚拟节点的 Router ID、 所述 虚拟节点到所述第一 Egress PE的链路的状态信息和所述虚拟节点到所述第 二 Egress PE的链路的状态信息, 所述虚拟节点到所述第一 Egress PE的链 路的状态信息包括所述虚拟节点到所述第一 Egress PE的链路的 cost值 N 和所述第一 Egress PE的 Router ID , 所述虚拟节点到所述第二 Egress PE的 链路的状态信息包括所述虚拟节点到所述第二 Egress PE的链路的 cost值 T 和所述第二 Egress PE的 Router ID。 其中所述 N和所述 T为内部网关协议 IGP的最大 cost值。 所述 Ingress PE (比如 PE1 )收到所述第一链路状态消息、 所述第二链 路状态消息、 所述第三链路状态消息和所述第四链路状态消息后, 获得所 述虚拟节点的 vNH、 所述第一 Egress PE到所述虚拟节点的链路的 cost值 M和所述第二 Egress PE到所述虚拟节点的链路的 cost值 S。 根据网络中采用的隧道类型不同, 所述第一链路状态消息、 所述第二 链路状态消息、 所述第三链路状态消息和所述第四链路状态消息中的任何 一个还可能包括其他属性, 比如对 MPLS TE隧道,还包括带宽、亲和属性、 颜色等中的一个或多个。 所述链路的 cost值有多种设置方法, 比如对采用显式路由的 MPLS TE 隧道, 链路的 cost值 S和 M可以设置成任意合法的 IGP cost值。 也可以静 态配置链路的 cost值 S和 M。 所述第一 Egress PE和所述第二 Egress PE中的至少一个,按照方式( 1 ) 或( 2 )确定所述第一 Egress PE到所述虚拟节点的链路的 cost值 M以及所 述第二 Egress PE到所述虚拟节点的链路的 cost值 S , 并将确定的所述第一 Egress PE到所述虚拟节点的链路的 cost值 M以及所述第二 Egress PE到所 述虚拟节点的链路的 cost值 S同步到所述第一 Egress PE和所述第二 Egress PE所在的冗余保护组中:
( 1 ) S和 M满足:
Sxy4+S>Sxy3+M ① 和
C34+S>M ② 其中, Px为所述第一 Egress PE的任何邻居节点, Pxy为去掉所述第一
Egress PE后的网络中所述 Px的任意邻居节点, Sxy3为所述 Pxy到所述第 一 Egress PE的最短路径的 cost值 , Sxy4为所述 Pxy到所述第二 Egress PE 的最短路径的 cost值, C34为所述第一 Egress PE到所述第二 Egress PE的 最短路径的 cost值。 ( 2 ) S和 M满足:
X+M<Y+S ③ 其中 X为从所述 Ingress PE到所述第一 Egress PE的最短路径的 cost 值, Y为从所述 Ingress PE到所述第二 Egress PE的最短路径的 cost值。 对于方式(1 ), 求解同时满足上述不等式①和不等式②的 S和 M, 即, 求解同时满足不等式①和不等式②的 M-S对。 对于 Egress PE到虚拟节点的链路的 cost值的计算,冗余保护组中的每 个 Egress PE均可计算满足不等式①和不等式②的 M-S对,即冗余保护组中 的 PE3可以计算满足不等式①和不等式②的 M-S对, 冗余保护组中的 PE4 也可以计算满足不等式①和不等式②的 M-S对。 如果冗余保护组中的多个 Egress PE计算出了不同的 M-S对, 则多个 Egress PE 之间可以通过协商的方式确定最终部署在冗余保护组的所有 Egress PE上的 S。 可选地, 如果根据方式( 1 )或 (2 )获得多组满足条件的 M-S对, 则 选择 S最小的 M-S对或者 M最小的 M-S对, 并将选择的 M-S对同步到冗 余保护组的所有 Egress PE。 将选择的 M-S对中的 M携带在所述第一链路 状态信息中, 将选择的 M-S对中的 S携带在所述第三链路状态信息中。 可选地, 可以在冗余保护组中的任意一个 Egress PE上根据方式( 1 ) 或方式(2 )确定 M-S对, 并将确定的 M-S对同步到冗余保护组中的其他 Egress PE上。 可选地, 对于将确定的 M-S对同步到冗余保护组中的其他 Egress PE上, 可以通过同步协议实现。 可选地, 也可以直接按照方式(2 )在冗余保护组的所有 Egress PE上 配置 M和 S。 比如, 可以将 M设置为 1 , 将 S设置为 IGP协议中的 cost值 的最大值。 可选地,还可以在冗余保护组的多个 Egress PE上按照方式( 1 )或( 2 ) 计算 M和 S, 如果根据方式( 1 )或( 2 )获得多组满足条件的 M-S对, 则 选择 S最小的 M-S对或者 M最小的 M-S对, 当然, 也可以任选一组满足 不等式①和②的 M-S对。 将选择的 M-S对中的 M携带在所述第一链路状 态信息中, 将选择的 M-S对中的 S携带在所述第三链路状态信息中。 当网络中的各个设备之间运行 OSPF ( Open Shortest Path First, 开放式 最短路径优先 )协议时, PE3上生成虚拟节点后, PE3的链路状态及邻居关 系均发生了变化, 因此 PE3更新自身的链路状态和邻居关系, 构造第一链 路状态广播数据 LSA ( Link State Advertisement, LSA ), 并将该第一 LSA 洪泛到整个网络中 , 该第一 LSA包括: PE3的 Router ID和 PE3到该虚拟 节点的链路的状态信息, PE3到该虚拟节点的链路的状态信息包括 PE3到 该虚拟节点的链路的 cost值和该虚拟节点的 Router ID。 由于 PE3上生成了 该虚拟节点, PE3还会 "代表"该虚拟节点构造第二 LSA, 并将该第二 LSA 洪泛到整个网络中。 该第二 LSA包括: 该虚拟节点的 Router ID、 该虚拟节 点到 PE3的链路的状态信息和该虚拟节点到 PE4的链路的链路的状态信息。 该虚拟节点到 PE3的链路的状态信息包括该虚拟节点到 PE3的链路的 cost 值和 PE3的 Router ID,该虚拟节点到 PE4的链路的状态信息包括该虚拟节 点到 PE4的链路的 cost值和 PE4的 Router ID。 类似地, 冗余保护组中的其 他 Egress PE, 也构造相应的 LSA并将这些 LSA洪泛到整个 OSPF域中, 该 OSPF域可以是整个网络。 比如 PE4上生成该虚拟节点后, PE4的链路 状态及邻居关系均发生了变化, 因此 PE4更新自身的链路状态和邻居关系, 构造第三 LSA, 并将该第三 LSA洪泛到整个网络中。 该第三 LSA包括: PE4的 Router ID和 PE4到该虚拟节点的链路的状态信息, PE4到该虚拟节 点的链路的状态信息包括 PE4到该虚拟节点的链路的 cost值和该虚拟节点 的 Router ID。 由于 PE4上生成了该虚拟节点, PE4还会 "代表" 该虚拟节 点构造第四 LSA, 并将该第四 LSA洪泛到整个网络中, 该第四 LSA包括: 该虚拟节点的 Router ID、 该虚拟节点到 PE3的链路的状态信息、 该虚拟节 点到 PE4的链路的状态信息。 该虚拟节点到 PE3的链路的状态信息包括该 虚拟节点到 PE3的链路的 cost值和 PE3的 Router ID, 该虚拟节点到 PE4 的链路的状态信息包括该虚拟节点到 PE4的链路的 cost值和 PE4的 Router ID。 PE3和 PE4把这些 LSA泛洪到 OSPF域中 , 这样, 与 PE3和 PE4处于 同一 OSPF域内的其他节点, 比如 PE1就能 "看到" 该虚拟节点、 该虚拟 节点与 PE3之间的链路、 该虚拟节点与 PE4之间的链路, 从而能够建立从 PE1到该虚拟节点的 vNH的隧道。 链路状态就是路由器的 OSPF接口上的 描述信息,例如接口上的 IP地址、子网掩码、 网络类型、 cost值等等。 OSPF 路由器之间交换的并不是路由表, 而是链路状态, OSPF路由器(比如 PE1 ) 通过获得网络中所有的链路状态信息, 从而计算出到达每个目标精确的网 络路径。 当 PE3和 PE4之间运行 ISIS( Intermediate system to intermediate system , 中间系统到中间系统)协议时, PE3上生成虚拟节点后, PE3的链路状态及 邻居关系均发生了变化, 因此 PE3更新自身的链路状态和邻居关系, 构造 第一链路状态报文 LSP ( Link-state PDU ), 并将该第一 LSP洪泛到整个网 络中 ,该第一 LSP包括: PE3的 Router ID和 PE3到该虚拟节点的链路的状 态信息, PE3到该虚拟节点的链路的状态信息包括 PE3到该虚拟节点的链 路的 cost值和虚拟节点的 Router ID。 由于 PE3上生成了该虚拟节点, PE3 还会 "代表" 该虚拟节点构造第二 LSP, 并将该第二 LSP洪泛到整个网络 中, 该第二 LSP包括: 该虚拟节点的 Router ID、 该虚拟节点到 PE3的链路 的状态信息和该虚拟节点到 PE4的链路的链路的状态信息。 该虚拟节点到 PE3 的链路的状态信息包括该虚拟节点到 PE3 的链路的 cost值和 PE3 的 Router ID, 该虚拟节点到 PE4的链路的状态信息包括该虚拟节点到 PE4的 链路的 cost值和 PE4的 Router ID。类似地,冗余保护组中的其他 Egress PE, 比如也构造相应的 LSP并将这些 LSP洪泛到整个 ISIS域中, 该 ISIS域可 以是整个网络。 比如 PE4上生成虚拟节点后, PE4的链路状态及邻居关系 均发生了变化, 因此 PE4更新自身的链路状态和邻居关系, 构造第三 LSP, 并将该第三 LSP洪泛到整个网络中, 该第三 LSP包括: PE4的 Router ID 和 PE4到该虚拟节点的链路的状态信息, PE4到该虚拟节点的链路的状态 信息包括 PE4到该虚拟节点的链路的 cost值和该虚拟节点的 Router ID。 由 于 PE4上生成了该虚拟节点, PE4还会 "代表" 该虚拟节点构造第四 LSP, 并将该第四 LSP洪泛到整个网络中,该第四 LSP包括:该虚拟节点的 Router ID、 该虚拟节点到 PE3的链路的状态信息、 该虚拟节点到 PE4的链路的状 态信息。 该虚拟节点到 PE3的链路的状态信息包括该虚拟节点到 PE3的链 路的 cost值和 PE3的 Router ID,该虚拟节点到 PE4的链路的状态信息包括 该虚拟节点到 PE4的链路的 cost值和 PE4的 Router ID。 PE3和 PE4把这些 LSP泛洪到 ISIS域中,这样,与 PE3和 PE4处于同一 ISIS域内的其他节点, 比如 PE 1就能 "看到 " 该虚拟节点、 该虚拟节点与 PE3之间的链路、 该虚 拟节点与 PE4之间的链路,从而能够建立从 PE1到该虚拟节点的 vNH的隧 道。 生成的虚拟节点与冗余保护组中的 Egress PE 之间的链路的属性值 ( cost值)可以根据情况自动设置或者人工设置。 比如, 如果希望 PE3成 为隧道的主路径经过的节点, 而 PE4成为隧道的备用路径经过的节点, 则 可以把 PE3到虚拟节点的链路的 cost值设置为 1 , 把 PE4到虚拟节点的链 路的 cost值设置为 IGP的最大 cost值。根据 PE3和 PE4之间运行的不同的 IGP, 可以设置不同的链路最大 cost值, 比如该网络中运行 OSPF时, 链路 最大 cost值可以设置为 65535。 为了不让虚拟节点承担穿通流量(transit traffic ), 可以把虚拟节点到 PE3的链路的 cost值和虚拟节点到 PE4的链路 的 cost值都设置为 IGP最大 cost值。 为了避免穿通流量, 需要将虚拟节点 配置为 overload模式。 在 OSPF协议下可通过将该虚拟节点到 Egress PE节 点 PE3的链路的 cost值以及该虚拟节点到 PE4的链路的 cost值置为 IGP的 最大 cost值来实现。 在 ISIS协议下, 可以通过将所述第二 LSP和第四 LSP 的 overload bit位置 1来实现。在 IGP中,一个物理链路通常是双向的, IGP 里描述的链路都是有方向的, 每个方向需要单独描述。 一个物理链路在不 同方向上的 cost值可能不同, 也可能相同。 虚拟节点在物理上并不是真实存在的, 只是为了 IGP域内的其他节点 能够计算出一条经过 PE3的隧道而生成的。 PE3的上游节点 P1能计算出另 外一个到达 PE4的备用隧道, 比如 PE1->P1->P2->PE4, 该备用隧道不经过 PE3。 这样在 PE3故障时能通过 P 1把流量切换到备用隧道到达 PE4 , 从而 达到保护 PE3的目的。 因为 PE3和 PE4是对称的 , 也可以建立经过 PE4的主隧道 , 而在 PE4 的上一跳节点(比如图 3中的 P2 )建立经过 PE3且不经过 PE4的备用隧道, 比如 PE1->P2->P1->PE3 , 在 PE4故障时, 在 P2上把流量切换到备份隧道 上从而达到保护 PE4的目的。 可选地, 如图 24所示, 所述第一 Egress PE还可以包括第一虚拟节点 地址协商模块 2307,用于与所述第二 Egress PE协商确定相同的虚拟节点的 Router ID。 相应地 , 所述第二第一 Egress PE还可以包括第二虚拟节点地址 协商模块 2308, 用于与所述第一 Egress PE的虚拟节点地址协商模块 2307 协商确定相同的虚拟节点的 Router ID。 关于虚拟节点的 vNH的协商方法, 具体可以参考图 4及其对应的段落, 也可以参考图 5-10及其对应的段落。 可选地, 如图 25所示, 所述第一 Egress PE还可以包括第一标签协商 模块 2309, 用于与所述第二 Egress PE协商确定相同的标签。 相应地, 所述 第二 Egress PE还可以包括第二标签协商模块 2310,用于与所述第一 Egress PE协商确定相同的标签。 关于协商确定相同标签的方法, 具体可以参考图 12-17及其对应的段落。 可选地 , 该网络系统中还可以第三 Egress PE, 第三 Egress PE位于包 括所述第一 Egress PE和所述第二 Egress PE的冗余保护组中,第三 Egress PE 作为备用设备。 所述第一 Egress PE、 所述第二 Egress PE和第三 Egress PE 之间可以通过静态配置或动态协商来确定虚拟节点的 vNH, 动态协商 vNH 的方法可以参考图 4及其对应的段落,也可以参考图 5-10及其对应的段落。 所述第一 Egress PE、 所述第二 Egress PE和第三 Egress PE之间可以通过动 态协商来确定分配相同的标签。 关于协商确定相同标签的方法, 具体可以 参考图 12-17及其对应的段落。 可选地, 本发明实施例中的各个模块, 均可通过相应的硬件来实现。 所述网络系统、 所述第一 Egress PE、 所述第二 Egress PE可以应用于 L2VPN或 L3VPN。
实施例六 本发明实施例还提供了另一种网络系统, 该网络系统包括第一 PE设 备、 第二 PE设备和 Igress PE, 所述第一 PE设备和所述第二 PE设备作为 Egress PE , 所述第一 PE设备与客户边缘设备 CE通信, 所述第二 PE设备 与所述 CE通信。 所述第一 PE设备和所述第二 PE设备处于包括所述第一 PE设备和所述第二 PE设备的冗余保护组内,其中所述第一 PE设备为主用 设备, 所述第二 PE设备为备用设备。 所述第一 PE设备用于: 生成虚拟节点, 所述虚拟节点具有所述网络系统中全局唯一的 Router ID, 所述虚拟节点用作所述第一 PE设备的下一跳节点, 所述虚拟节点用作 所述第二 PE设备的下一跳节点; 发送第一链路状态消息给所述 Ingress PE, 所述第一链路状态消息包 括:所述第一 PE设备的 Router ID和所述第一 PE设备到所述虚拟节点的链 路的状态信息,所述第一 PE设备到所述虚拟节点的链路的状态信息包括所 述第一 PE设备到所述虚拟节点的链路的 cost值 M和所述虚拟节点的 Router ID; 发送第二链路状态消息给所述 Ingress PE, 所述第二链路状态消息包 括: 所述虚拟节点的 Router ID、 所述虚拟节点到所述第一 PE设备的链路 的状态信息和所述虚拟节点到所述第二 PE设备的链路的状态信息,所述虚 拟节点到所述第一 Egress PE的链路的状态信息包括所述虚拟节点到所述第 一 PE设备的链路的 cost值 N和所述第一 PE设备的 Router ID, 所述虚拟 节点到所述第二 Egress PE的链路的状态信息包括所述虚拟节点到所述第二 PE设备的链路的 cost值 T和所述第二 PE设备的 Router ID; 所述第二 PE设备用于: 生成所述虚拟节点, 发送第三链路状态消息给所述 Ingress PE, 所述第三链路状态消息包 括:所述第二 PE设备的 Router ID和所述第二 PE设备到所述虚拟节点的链 路的状态信息,所述第二 PE设备到所述虚拟节点的链路的状态信息包括所 述第二 PE设备到所述虚拟节点的链路的 cost值 S和所述虚拟节点的 Router ID; 发送第四链路状态消息给所述 Ingress PE, 所述第四链路状态消息包 括: 所述虚拟节点的 Router ID、 所述虚拟节点到所述第一 PE设备的链路 的状态信息和所述虚拟节点到所述第二 PE设备的链路的状态信息,所述虚 拟节点到所述第一 PE设备的链路的状态信息包括所述虚拟节点到所述第 一 PE设备的链路的 cost值 N和所述第一 PE设备的 Router ID, 所述虚拟 节点到所述第二 Egress PE的链路的状态信息包括所述虚拟节点到所述第二 PE设备的链路的 cost值 T和所述第二 PE设备的 Router ID; 所述第一 PE设备还用于为第一虚拟专用网络 VPN的第一转发等价类 分配第一标签, 并发送所述第一标签给所述 Ingress PE; 所述第二 PE设备还用于为所述第一 VPN的第一转发等价类分配所述 第一标签, 并发送所述第一标签给所述 Ingress PE。 当网络中的各个设备之间运行 0SPF ( Open Shortest Path First, 开放式 最短路径优先)协议时, 所述第一 PE设备上生成虚拟节点后, 所述第一 PE设备的链路状态及邻居关系均发生了变化, 因此第一 PE设备更新自身 的链路状态和邻居关系, 构造第一链路状态广播数据 LSA ( Link State Advertisement, LSA ), 并将该第一 LSA洪泛到整个网络中, 该第一 LSA 包括:所述第一 PE设备的 Router ID和所述第一 PE设备到该虚拟节点的链 路的状态信息,所述第一 PE设备到该虚拟节点的链路的状态信息包括所述 第一 PE设备到该虚拟节点的链路的 cost值和该虚拟节点的 Router ID。 由 于所述第一 PE设备上生成了该虚拟节点, 所述第一 PE设备还会 "代表" 该虚拟节点构造第二 LSA,并将该第二 LSA洪泛到整个网络中。该第二 LSA 包括: 该虚拟节点的 Router ID、 该虚拟节点到所述第一 PE设备的链路的 状态信息和该虚拟节点到所述第二 PE设备的链路的链路的状态信息。该虚 拟节点到所述第一 PE设备的链路的状态信息包括该虚拟节点到所述第一 PE设备的链路的 cost值和所述第一 PE设备的 Router ID, 该虚拟节点到所 述第二 PE设备的链路的状态信息包括该虚拟节点到所述第二 PE设备的链 路的 cost值和所述第二 PE设备的 Router ID。 类似地, 冗余保护组中的其 他 Egress PE, 也构造相应的 LSA并将这些 LSA洪泛到整个 0SPF域中, 该 0SPF域可以是整个网络。 比如所述第二 PE设备上生成该虚拟节点后, 所述第二 PE设备的链路状态及邻居关系均发生了变化, 因此所述第二 PE 设备更新自身的链路状态和邻居关系, 构造第三 LSA, 并将该第三 LSA洪 泛到整个网络中。 该第三 LSA包括: 所述第二 PE设备的 Router ID和所述 第二 PE设备到该虚拟节点的链路的状态信息, 所述第二 PE设备到该虚拟 节点的链路的状态信息包括所述第二 PE设备到该虚拟节点的链路的 cost 值和该虚拟节点的 Router ID。 由于所述第二 PE设备上生成了该虚拟节点, 所述第二 PE设备还会 "代表"该虚拟节点构造第四 LSA, 并将该第四 LSA 洪泛到整个网络中, 该第四 LSA包括: 该虚拟节点的 Router ID、 该虚拟节 点到所述第一 PE设备的链路的状态信息、 该虚拟节点到所述第二 PE设备 的链路的状态信息。该虚拟节点到所述第一 PE设备的链路的状态信息包括 该虚拟节点到所述第一 PE设备的链路的 cost值和所述第一 PE设备的 Router ID,该虚拟节点到所述第二 PE设备的链路的状态信息包括该虚拟节 点到所述第二 PE设备的链路的 cost值和所述第二 PE设备的 Router ID。所 述第一 PE设备和所述第二 PE设备把这些 LSA泛洪到 0SPF域中, 这样, 与所述第一 PE设备和所述第二 PE设备处于同一 0SPF域内的其他节点, 比如 PE1就能 "看到"该虚拟节点、 该虚拟节点与所述第一 PE设备之间的 链路、 该虚拟节点与所述第二 PE设备之间的链路, 从而能够建立从 PE1 到该虚拟节点的 vNH的隧道。 链路状态就是路由器的 OSPF接口上的描述 信息, 例如接口上的 IP地址、 子网掩码、 网络类型、 cost值等等。 OSPF 路由器之间交换的并不是路由表, 而是链路状态, OSPF路由器(比如 PE1 ) 通过获得网络中所有的链路状态信息, 从而计算出到达每个目标精确的网 络路径。 当所述第一 PE设备和所述第二 PE设备之间运行 ISIS ( Intermediate system to intermediate system, 中间系统到中间系统 )协议时, 所述第一 PE 设备上生成虚拟节点后,所述第一 PE设备的链路状态及邻居关系均发生了 变化, 因此所述第一 PE设备更新自身的链路状态和邻居关系, 构造第一链 路状态报文 LSP ( Link-state PDU ), 并将该第一 LSP洪泛到整个网络中, 该第一 LSP包括: 所述第一 PE设备的 Router ID和所述第一 PE设备到该 虚拟节点的链路的状态信息,所述第一 PE设备到该虚拟节点的链路的状态 信息包括所述第一 PE设备到该虚拟节点的链路的 cost值和虚拟节点的 Router ID。 由于所述第一 PE设备上生成了该虚拟节点, 所述第一 PE设备 还会 "代表" 该虚拟节点构造第二 LSP, 并将该第二 LSP洪泛到整个网络 中, 该第二 LSP包括: 该虚拟节点的 Router ID、该虚拟节点到所述第一 PE 设备的链路的状态信息和该虚拟节点到所述第二 PE设备的链路的链路的 状态信息。该虚拟节点到所述第一 PE设备的链路的状态信息包括该虚拟节 点到所述第一 PE设备的链路的 cost值和所述第一 PE设备的 Router ID,该 虚拟节点到所述第二 PE设备的链路的状态信息包括该虚拟节点到所述第 二 PE设备的链路的 cost值和所述第二 PE设备的 Router ID。 类似地, 冗余 保护组中的其他 Egress PE,比如也构造相应的 LSP并将这些 LSP洪泛到整 个 ISIS域中, 该 ISIS域可以是整个网络。 比如所述第二 PE设备上生成虚 拟节点后, 所述第二 PE设备的链路状态及邻居关系均发生了变化, 因此所 述第二 PE设备更新自身的链路状态和邻居关系, 构造第三 LSP, 并将该第 三 LSP洪泛到整个网络中,该第三 LSP包括:所述第二 PE设备的 Router ID 和所述第二 PE设备到该虚拟节点的链路的状态信息, 所述第二 PE设备到 该虚拟节点的链路的状态信息包括所述第二 PE设备到该虚拟节点的链路 的 cost值和该虚拟节点的 Router ID。 由于所述第二 PE设备上生成了该虚 拟节点, 所述第二 PE设备还会 "代表" 该虚拟节点构造第四 LSP, 并将该 第四 LSP洪泛到整个网络中, 该第四 LSP包括: 该虚拟节点的 Router ID、 该虚拟节点到所述第一 PE设备的链路的状态信息、该虚拟节点到所述第二 PE设备的链路的状态信息。 该虚拟节点到所述第一 PE设备的链路的状态 信息包括该虚拟节点到所述第一 PE设备的链路的 cost值和所述第一 PE设 备的 Router ID, 该虚拟节点到所述第二 PE设备的链路的状态信息包括该 虚拟节点到所述第二 PE设备的链路的 cost值和所述第二 PE设备的 Router ID。所述第一 PE设备和所述第二 PE设备把这些 LSP泛洪到 ISIS域中,这 样,与所述第一 PE设备和所述第二 PE设备处于同一 ISIS域内的其他节点, 比如 PE1就能 "看到"该虚拟节点、 该虚拟节点与所述第一 PE设备之间的 链路、 该虚拟节点与所述第二 PE设备之间的链路, 从而能够建立从 PE1 到该虚拟节点的 vNH的隧道。 生成的虚拟节点与冗余保护组中的 Egress PE 之间的链路的属性值 ( cost值)可以根据情况自动设置或者人工设置。 比如, 如果希望所述第一 PE设备成为隧道的主路径经过的节点, 而所述第二 PE设备成为隧道的备 用路径经过的节点, 则可以把所述第一 PE设备到虚拟节点的链路的 cost 值设置为 1 ,把 PE4到虚拟节点的链路的 cost值设置为 IGP的最大 cost值。 根据所述第一 PE设备和所述第二 PE设备之间运行的不同的 IGP, 可以设 置不同的链路最大 cost值, 比如该网络中运行 0SPF时, 链路最大 cost值 可以设置为 65535。 为了不让虚拟节点承担穿通流量(transit traffic ), 可以 把虚拟节点到所述第一 PE设备的链路的 cost值和虚拟节点到所述第二 PE 设备的链路的 cost值都设置为 IGP最大 cost值。 为了避免穿通流量, 需要 将虚拟节点配置为 overload模式。在 0SPF协议下可通过将该虚拟节点到所 述第一 PE设备的链路的 cost值以及该虚拟节点到所述第二 PE设备的链路 的 cost值置为 IGP的最大 cost值来实现。 在 ISIS协议下, 可以通过将所述 第二 LSP和第四 LSP的 overload bit位置 1来实现。在 IGP中,一个物理链 路通常是双向的, IGP里描述的链路都是有方向的,每个方向需要单独描述。 一个物理链路在不同方向上的 cost值可能不同, 也可能相同。 可选地, 所述第一 PE设备还可以包括第一虚拟节点地址协商模块, 用 于与所述第二 PE设备协商确定相同的虚拟节点的 Router ID。 相应地, 所 述第二 PE设备还可以包括第二虚拟节点地址协商模块, 用于与所述第一 PE设备的虚拟节点地址协商模块协商确定相同的虚拟节点的 Router ID。关 于虚拟节点的 Router ID协商方法, 具体可以参考图 4及其对应的段落, 也 可以参考图 5-10及其对应的段落。 可选地, 如图 25所示, 所述第一 PE设备还可以包括第一标签协商模 块, 用于与所述第二 PE设备协商确定相同的标签。 相应地, 所述第二 PE 设备还可以包括第二标签协商模块,用于与所述第一 PE设备协商确定相同 的标签。 关于协商确定相同标签的方法,具体可以参考图 12-17及其对应的 段落。
实施例七 本发明实施例还提供了另一种网络系统,该网络系统包括第一 PE设备 和第二 PE设备, 所述第一 PE设备和所述第二 PE设备作为 Egress PE, 分 别与客户边缘设备 CE通信。所述网络系统还包括第三 PE设备 ,作为 Ingress PE。 所述第一 PE设备和所述第二 PE设备处于包括所述第一 PE设备和所 述第二 PE设备的冗余保护组内, 其中所述第一 PE设备为主用设备, 所述 第二 PE设备为备用设备。 如图 26所示, 该第一 PE设备包括: 第一总线 2601 ; 以及连接到第一总线 2601的第一处理器 2602、 第一存储器 2603和 第一接口 2604, 该第一存储器 2603用于存储指令, 该第一处理器 2602用 于执行该指令执行如下操作: 在所述第一 PE设备生成虚拟节点,所述虚拟节点具有所述网络系统中 全局唯一的 Router ID , 所述虚拟节点用作所述第一 ΡΕ设备的下一跳节点, 所述虚拟节点用作所述第二 ΡΕ设备的下一跳节点; 触发第一接口 2604通过第一总线 2601发送第一链路状态消息给所述 Ingress PE, 所述第一链路状态消息包括: 所述第一 PE设备的 Router ID和 所述第一 PE设备到所述虚拟节点的链路的状态信息, 所述第一 PE设备到 所述虚拟节点的链路的状态信息包括所述第一 PE设备到所述虚拟节点的 链路的 cost值 M和所述虚拟节点的 Router ID; 触发第一接口 2604通过第一总线 2601发送第二链路状态消息给所述 Ingress PE, 所述第二链路状态消息包括: 所述虚拟节点的 Router ID、 所述 虚拟节点到所述第一 PE设备的链路的状态信息和所述虚拟节点到所述第 二 PE设备的链路的状态信息, 所述虚拟节点到所述第一 PE设备的链路的 状态信息包括所述虚拟节点到所述第一 PE设备的链路的 cost值 N和所述 第一 PE设备的 Router ID, 所述虚拟节点到所述第二 PE设备的链路的状态 信息包括所述虚拟节点到所述第二 PE设备的链路的 cost值 T和所述第二 PE设备的 ID; 其中所述 N和所述 T为内部网关协议 IGP的最大 cost值; 类似地, 所述第二 PE设备也可以包括第二总线; 以及连接到第二总线 的第二处理器、 第二存储器和第二接口, 该第二存储器用于存储指令, 该 第二处理器用于执行该指令执行如下操作: 在所述第二 PE设备生成所述虚拟节点; 触发所述第二接口通过所述第二总线发送第三链路状态消息给所述 Ingress PE, 所述第三链路状态消息包括: 所述第二 PE设备的 Router ID和 所述第二 PE设备到所述虚拟节点的链路的状态信息, 所述第二 PE设备到 所述虚拟节点的链路的状态信息包括所述第二 PE设备到所述虚拟节点的 链路的 cost值 S和所述虚拟节点的 Router ID; 触发所述第二接口通过所述第二总线发送第四链路状态消息给所述 Ingress PE, 所述第四链路状态消息包括: 所述虚拟节点的 Router ID、 所述 虚拟节点到所述第一 PE设备的链路的状态信息和所述虚拟节点到所述第 二 PE设备的链路的状态信息, 所述虚拟节点到所述第一 PE设备的链路的 状态信息包括所述虚拟节点到所述第一 PE设备的链路的 cost值 N和所述 第一 PE设备的 Router ID, 所述虚拟节点到所述第二 PE设备的链路的状态 信息包括所述虚拟节点到所述第二 PE设备的链路的 cost值 T和所述第二 PE设备的 Router ID。其中所述 N和所述 T为内部网关协议 IGP的最大 cost 值。 所述 Ingress PE收到所述第一链路状态消息、 所述第二链路状态消息、 所述第三链路状态消息和所述第四链路状态消息后, 获得所述虚拟节点的 vNH、 所述第一 PE设备到所述虚拟节点的链路的 cost值 M和所述第二 PE 设备到所述虚拟节点的链路的 cost值 S。 根据网络中采用的隧道类型不同, 所述第一链路状态消息、 所述第二 链路状态消息、 所述第三链路状态消息和所述第四链路状态消息中的任何 一个还可能包括其他属性, 比如对 MPLS TE隧道,还包括带宽、亲和属性、 颜色等中的一个或多个。 所述链路的 cost值有多种设置方法, 比如对采用显式路由的 MPLS TE 隧道, 链路 S或 M的 cost值可以设置成任意合法的 IGP cost值。 也可以静 态配置链路 S或 M的 cost值。 所述第一处理器和所述第二处理器中的至少一个,按照方式( 1 )或( 2 ) 确定所述第一 PE设备到所述虚拟节点的链路的 cost值 M以及所述第二 PE 设备到所述虚拟节点的链路的 cost值 S, 并将确定的所述第一 PE设备到所 述虚拟节点的链路的 cost值 M以及所述第二 PE设备到所述虚拟节点的链 路的 cost值 S同步到所述第一 PE设备和所述第二 PE设备所在的冗余保护 组中:
( 1 ) S和 M满足:
Sxy4+S>Sxy3+M ① 和
C34+S>M ② 其中, Px为所述第一 PE设备的任何邻居节点, Pxy为去掉所述第一 PE设备后的网络中所述 Px的任意邻居节点, Sxy3为所述 Pxy到所述第一 PE设备的最短路径的 cost值 , Sxy4为所述 Pxy到所述第二 Egress PE的最 短路径的 cost值, C34为所述第一 PE设备到所述第二 PE设备的最短路径 的 cost值。 ( 2 ) S和 M满足:
X+M<Y+S ③ 其中 X为从所述 Ingress PE到所述第一 Egress PE的最短路径的 cost 值, Y为从所述 Ingress PE到所述第二 Egress PE的最短路径的 cost值。 对于方式(1 ), 求解同时满足上述不等式①和不等式②的 S和 M, 即, 求解同时满足不等式①和不等式②的 M-S对。 对于 Egress PE到虚拟节点的链路的 cost值的计算,冗余保护组中的每 个 Egress PE均可计算满足不等式①和不等式②的 M-S对,即冗余保护组中 的 PE3可以计算满足不等式①和不等式②的 M-S对, 冗余保护组中的 PE4 也可以计算满足不等式①和不等式②的 M-S对。 如果冗余保护组中的多个 Egress PE计算出了不同的 M-S对, 则多个 Egress PE 之间可以通过协商的方式确定最终部署在冗余保护组的所有 Egress PE上的 S。 可选地, 如果根据方式( 1 )或 (2 )获得多组满足条件的 M-S对, 则 选择 S最小的 M-S对或者 M最小的 M-S对, 并将选择的 M-S对同步到冗 余保护组的所有 Egress PE。 将选择的 M-S对中的 M携带在所述第一链路 状态信息中, 将选择的 M-S对中的 S携带在所述第三链路状态信息中。 可选地, 可以在冗余保护组中的任意一个 Egress PE上根据方式( 1 ) 或方式(2 )确定 M-S对, 并将确定的 M-S对同步到冗余保护组中的其他 Egress PE上。 可选地, 对于将确定的 M-S对同步到冗余保护组中的其他 Egress PE上, 可以通过同步协议实现。 可选地, 也可以直接按照方式(2 )在冗余保护组的所有 Egress PE上 配置 M和 S。 比如, 可以将 M设置为 1 , 将 S设置为 IGP协议中的 cost值 的最大值。 可选地,还可以在冗余保护组的多个 Egress PE上按照方式( 1 )或( 2 ) M和 S, 如果根据方式( 1 )或( 2 )获得多组满足条件的 M-S对, 则 选择 S最小的 M-S对或者 M最小的 M-S对, 当然, 也可以任选一组满足 不等式①和②的 M-S对。 将选择的 M-S对中的 M携带在所述第一链路状 态信息中, 将选择的 M-S对中的 S携带在所述第三链路状态信息中。 当网络中的各个设备之间运行 OSPF ( Open Shortest Path First, 开放式 最短路径优先)协议时, 所述第一 PE设备上生成虚拟节点后, 所述第一 PE设备的链路状态及邻居关系均发生了变化, 因此第一 PE设备更新自身 的链路状态和邻居关系, 构造第一链路状态广播数据 LSA ( Link State Advertisement, LSA ), 并将该第一 LSA洪泛到整个网络中, 该第一 LSA 包括:所述第一 PE设备的 Router ID和所述第一 PE设备到该虚拟节点的链 路的状态信息,所述第一 PE设备到该虚拟节点的链路的状态信息包括所述 第一 PE设备到该虚拟节点的链路的 cost值和该虚拟节点的 Router ID。 由 于所述第一 PE设备上生成了该虚拟节点, 所述第一 PE设备还会 "代表" 该虚拟节点构造第二 LSA,并将该第二 LSA洪泛到整个网络中。该第二 LSA 包括: 该虚拟节点的 Router ID、 该虚拟节点到所述第一 PE设备的链路的 状态信息和该虚拟节点到所述第二 PE设备的链路的链路的状态信息。该虚 拟节点到所述第一 PE设备的链路的状态信息包括该虚拟节点到所述第一 PE设备的链路的 cost值和所述第一 PE设备的 Router ID, 该虚拟节点到所 述第二 PE设备的链路的状态信息包括该虚拟节点到所述第二 PE设备的链 路的 cost值和所述第二 PE设备的 Router ID。 类似地, 冗余保护组中的其 他 Egress PE, 也构造相应的 LSA并将这些 LSA洪泛到整个 0SPF域中, 该 0SPF域可以是整个网络。 比如所述第二 PE设备上生成该虚拟节点后, 所述第二 PE设备的链路状态及邻居关系均发生了变化, 因此所述第二 PE 设备更新自身的链路状态和邻居关系, 构造第三 LSA, 并将该第三 LSA洪 泛到整个网络中。 该第三 LSA包括: 所述第二 PE设备的 Router ID和所述 第二 PE设备到该虚拟节点的链路的状态信息, 所述第二 PE设备到该虚拟 节点的链路的状态信息包括所述第二 PE设备到该虚拟节点的链路的 cost 值和该虚拟节点的 Router ID。 由于所述第二 PE设备上生成了该虚拟节点, 所述第二 PE设备还会 "代表"该虚拟节点构造第四 LSA, 并将该第四 LSA 洪泛到整个网络中, 该第四 LSA包括: 该虚拟节点的 Router ID、 该虚拟节 点到所述第一 PE设备的链路的状态信息、 该虚拟节点到所述第二 PE设备 的链路的状态信息。该虚拟节点到所述第一 PE设备的链路的状态信息包括 该虚拟节点到所述第一 PE设备的链路的 cost值和所述第一 PE设备的 Router ID,该虚拟节点到所述第二 PE设备的链路的状态信息包括该虚拟节 点到所述第二 PE设备的链路的 cost值和所述第二 PE设备的 Router ID。所 述第一 PE设备和所述第二 PE设备把这些 LSA泛洪到 OSPF域中, 这样, 与所述第一 PE设备和所述第二 PE设备处于同一 OSPF域内的其他节点, 比如 PE1就能 "看到"该虚拟节点、 该虚拟节点与所述第一 PE设备之间的 链路、 该虚拟节点与所述第二 PE设备之间的链路, 从而能够建立从 PE1 到该虚拟节点的 vNH的隧道。 链路状态就是路由器的 OSPF接口上的描述 信息, 例如接口上的 IP地址、 子网掩码、 网络类型、 cost值等等。 OSPF 路由器之间交换的并不是路由表, 而是链路状态, OSPF路由器(比如 PE1 ) 通过获得网络中所有的链路状态信息, 从而计算出到达每个目标精确的网 络路径。 当所述第一 PE设备和所述第二 PE设备之间运行 ISIS ( Intermediate system to intermediate system, 中间系统到中间系统 )协议时, 所述第一 PE 设备上生成虚拟节点后,所述第一 PE设备的链路状态及邻居关系均发生了 变化, 因此所述第一 PE设备更新自身的链路状态和邻居关系, 构造第一链 路状态报文 LSP ( Link-state PDU ) , 并将该第一 LSP洪泛到整个网络中, 该第一 LSP包括: 所述第一 PE设备的 Router ID和所述第一 PE设备到该 虚拟节点的链路的状态信息,所述第一 PE设备到该虚拟节点的链路的状态 信息包括所述第一 PE设备到该虚拟节点的链路的 cost值和虚拟节点的 Router ID。 由于所述第一 PE设备上生成了该虚拟节点, 所述第一 PE设备 还会 "代表" 该虚拟节点构造第二 LSP, 并将该第二 LSP洪泛到整个网络 中, 该第二 LSP包括: 该虚拟节点的 Router ID、该虚拟节点到所述第一 PE 设备的链路的状态信息和该虚拟节点到所述第二 PE设备的链路的链路的 状态信息。该虚拟节点到所述第一 PE设备的链路的状态信息包括该虚拟节 点到所述第一 PE设备的链路的 cost值和所述第一 PE设备的 Router ID,该 虚拟节点到所述第二 PE设备的链路的状态信息包括该虚拟节点到所述第 二 PE设备的链路的 cost值和所述第二 PE设备的 Router ID。 类似地, 冗余 保护组中的其他 Egress PE,比如也构造相应的 LSP并将这些 LSP洪泛到整 个 ISIS域中, 该 ISIS域可以是整个网络。 比如所述第二 PE设备上生成虚 拟节点后, 所述第二 PE设备的链路状态及邻居关系均发生了变化, 因此所 述第二 PE设备更新自身的链路状态和邻居关系, 构造第三 LSP, 并将该第 三 LSP洪泛到整个网络中,该第三 LSP包括:所述第二 PE设备的 Router ID 和所述第二 PE设备到该虚拟节点的链路的状态信息, 所述第二 PE设备到 该虚拟节点的链路的状态信息包括所述第二 PE设备到该虚拟节点的链路 的 cost值和该虚拟节点的 Router ID。 由于所述第二 PE设备上生成了该虚 拟节点, 所述第二 PE设备还会 "代表" 该虚拟节点构造第四 LSP, 并将该 第四 LSP洪泛到整个网络中, 该第四 LSP包括: 该虚拟节点的 Router ID、 该虚拟节点到所述第一 PE设备的链路的状态信息、该虚拟节点到所述第二 PE设备的链路的状态信息。 该虚拟节点到所述第一 PE设备的链路的状态 信息包括该虚拟节点到所述第一 PE设备的链路的 cost值和所述第一 PE设 备的 Router ID, 该虚拟节点到所述第二 PE设备的链路的状态信息包括该 虚拟节点到所述第二 PE设备的链路的 cost值和所述第二 PE设备的 Router ID。所述第一 PE设备和所述第二 PE设备把这些 LSP泛洪到 ISIS域中,这 样,与所述第一 PE设备和所述第二 PE设备处于同一 ISIS域内的其他节点, 比如 PE1就能 "看到"该虚拟节点、 该虚拟节点与所述第一 PE设备之间的 链路、 该虚拟节点与所述第二 PE设备之间的链路, 从而能够建立从 PE1 到该虚拟节点的 vNH的隧道。 生成的虚拟节点与冗余保护组中的 Egress PE 之间的链路的属性值 ( cost值)可以根据情况自动设置或者人工设置。 比如, 如果希望所述第一 PE设备成为隧道的主路径经过的节点, 而所述第二 PE设备成为隧道的备 用路径经过的节点, 则可以把所述第一 PE设备到虚拟节点的链路的 cost 值设置为 1 ,把 PE4到虚拟节点的链路的 cost值设置为 IGP的最大 cost值。 根据所述第一 PE设备和所述第二 PE设备之间运行的不同的 IGP, 可以设 置不同的链路最大 cost值, 比如该网络中运行 0SPF时, 链路最大 cost值 可以设置为 65535。 为了不让虚拟节点承担穿通流量(transit traffic ), 可以 把虚拟节点到所述第一 PE设备的链路的 cost值和虚拟节点到所述第二 PE 设备的链路的 cost值都设置为 IGP最大 cost值。 为了避免穿通流量, 需要 将虚拟节点配置为 overload模式。在 0SPF协议下可通过将该虚拟节点到所 述第一 PE设备的链路的 cost值以及该虚拟节点到所述第二 PE设备的链路 的 cost值置为 IGP的最大 cost值来实现。 在 ISIS协议下, 可以通过将所述 第二 LSP和第四 LSP的 overload bit位置 1来实现。在 IGP中,一个物理链 路通常是双向的, IGP里描述的链路都是有方向的,每个方向需要单独描述。 一个物理链路在不同方向上的 cost值可能不同, 也可能相同。 可选地, 所述第一处理器还可以还可以执行该指令执行如下操作: 与 所述第二 PE设备协商确定相同的虚拟节点的 Router ID。 相应地, 所述第 二处理器还可以执行该指令执行如下操作:与所述第一 PE设备的第一处理 器协商确定相同的虚拟节点的 Router ID。关于虚拟节点的 Router ID协商方 法, 具体可以参考图 4及其对应的段落, 也可以参考图 5-10及其对应的段 落。 可选地, 所述第一处理器 2602还可以执行该指令执行如下操作: 与所 述第二 PE设备协商确定相同的标签。 相应地, 所述第二处理器还可以执行 该指令执行如下操作: 与所述第一 PE设备协商确定相同的标签。 关于协商 确定相同标签的方法, 具体可以参考图 12-17及其对应的段落。 可选地, 本发明实施例中的各个模块, 均可通过相应的硬件来实现。 所述网络系统、 所述第一 Egress PE、 所述第二 Egress PE可以应用于 L2VPN或 L3VPN。 本发明实施例中, 主用 Egress PE和备用 Egress PE发布 CE节点所属 的 VRF( Virtual Routing Forwarding,虚拟路由转发)路由时,主用 Egress PE 和备用 Egress PE分别为每个 VRF标签(比如第一 VRF标签 )分配相同的 VPN路由标签。 本发明实施例所述的方法、设备、 系统, 通过在冗余保护组中的 Egress PE上配置相同的虚拟下一跳, 并将该虚拟下一跳节点的地址发送给 Ingress PE, 从而 Ingress PE能够建立经过主用 Egress PE的主隧道, 以及依次经过 主用 Egress EP的上一跳节点、 备用 Egress PE的上一跳节点、 备用 Egress 的备用隧道, 当主用 Egress PE发生故障时, 可以直接切换到备用隧道, 该 切换所涉及的节点设备相对较少, 因而可以以较短的时间完成保护切换, 对该隧道上承载的上层业务来说, 该切换是无缝的、 不被上层业务感知的。 所属领域的技术人员可以清楚地了解到, 为描述的方便和简洁, 上述 描述的系统, 装置和单元的具体工作过程, 可以参考前述方法实施例中的 对应过程, 在此不再赘述。 在本申请所提供的几个实施例中, 应该理解到, 所揭露的系统, 装置 和方法, 可以通过其它的方式实现。 例如, 以上所描述的装置实施例仅仅 是示意性的, 例如, 所述单元的划分, 仅仅为一种逻辑功能划分, 实际实 现时可以有另外的划分方式, 例如多个单元或组件可以结合或者可以集成 到另一个系统, 或一些特征可以忽略, 或不执行。 另一点, 所显示或讨论 的相互之间的耦合或直接耦合或通信连接可以是通过一些接口, 装置或单 元的间接耦合或通信连接, 可以是电性, 机械或其它的形式。 所述作为分离部件说明的单元可以是或者也可以不是物理上分开的, 作为单元显示的部件可以是或者也可以不是物理单元, 即可以位于一个地 方, 或者也可以分布到多个网络单元上。 可以根据实际的需要选择其中的 部分或者全部单元来实现本实施例方案的目的。 另外, 在本发明各个实施例中的各功能单元可以集成在一个处理单元 中, 也可以是各个单元单独物理存在, 也可以两个或两个以上单元集成在 一个单元中。 上述集成的单元既可以采用硬件的形式实现, 也可以采用硬 件加软件功能单元的形式实现。 比如, 检测器、 发送器、 接收器、 获得单 元都可以通过通用中央处理器 CPU或专用集成电路 ( Application Specific Integrated Circuit, ASIC )或现场可编程门阵列 ( Field - Programmable Gate Array, FPGA )来实现。 上述以软件功能单元的形式实现的集成的单元, 可以存储在一个计算 机可读取存储介质中。 上述软件功能单元存储在一个存储介质中, 包括若 干指令用以使得一台计算机设备(可以是个人计算机, 服务器, 或者网络 设备等)执行本发明各个实施例所述方法的部分步骤。 而前述的存储介质 包括: U盘、 移动硬盘、 只读存储器(Read-Only Memory, 简称 ROM )、 随机存取存储器( Random Access Memory, 简称 RAM )、 磁碟或者光盘等 各种可以存储程序代码的介质。 最后应说明的是: 以上实施例仅用以说明本发明的技术方案, 而非对 其限制; 尽管参照前述实施例对本发明进行了详细的说明, 本领域的普通 技术人员应当理解: 其依然可以对前述各实施例所记载的技术方案进行修 改, 或者对其中部分技术特征进行等同替换; 而这些修改或者替换, 并不 使相应技术方案的本质脱离本发明各实施例技术方案的精神和范围。

Claims

权利要求
1、 一种网络系统, 其特征在于, 包括第一出口运营商边缘设备 Egress PE、 第二 Egress PE和入口运营商边缘设备 Ingress PE , 所述第一 Egress PE 与客户边缘设备 CE通信, 所述第二 Egress PE与所述 CE通信, 所述第一 Egress PE和所述第二 Egress PE位于包括所述第一 Egress PE 和所述第二 Egress PE的冗余保护组内, 其中所述第一 Egress PE为主用设 备, 所述第二 Egress PE为备用设备; 所述第一 Egress PE用于: 生成虚拟节点, 所述虚拟节点具有所述网络系统中全局唯一的 Router ID, 所述虚拟节点用作所述第一 Egress PE的下一跳节点, 所述虚拟节点用 作所述第二 Egress PE的下一跳节点; 发送第一链路状态消息给所述 Ingress PE, 所述第一链路状态消息包 括:所述第一 Egress PE的 Router ID和所述第一 Egress PE到所述虚拟节点 的链路的状态信息, 所述第一 Egress PE到所述虚拟节点的链路的状态信息 包括所述第一 Egress PE到所述虚拟节点的链路的 cost值 M和所述虚拟节 点的 Router ID; 发送第二链路状态消息给所述 Ingress PE, 所述第二链路状态消息包 括: 所述虚拟节点的 Router ID、所述虚拟节点到所述第一 Egress PE的链路 的状态信息和所述虚拟节点到所述第二 Egress PE的链路的状态信息, 所述 虚拟节点到所述第一 Egress PE的链路的状态信息包括所述虚拟节点到所述 第一 Egress PE的链路的 cost值 N和所述第一 Egress PE的 Router ID,所述 虚拟节点到所述第二 Egress PE的链路的状态信息包括所述虚拟节点到所述 第二 Egress PE的链路的 cost值 T和所述第二 Egress PE的 Router ID; 所述第二 Egress PE用于: 生成所述虚拟节点, 发送第三链路状态消息给所述 Ingress PE, 所述第三链路状态消息包 括:所述第二 Egress PE的 Router ID和所述第二 Egress PE到所述虚拟节点 的链路的状态信息, 所述第二 Egress PE到所述虚拟节点的链路的状态信息 包括所述第二 Egress PE到所述虚拟节点的链路的 cost值 S和所述虚拟节点 的 Router ID; 发送第四链路状态消息给所述 Ingress PE, 所述第四链路状态消息包 括: 所述虚拟节点的 Router ID和所述虚拟节点到所述第一 Egress PE的链 路的状态信息、 所述虚拟节点到所述第二 Egress PE的链路的状态信息, 所 述虚拟节点到所述第一 Egress PE的链路的状态信息包括所述虚拟节点到所 述第一 Egress PE的链路的 cost值 N和所述第一 Egress PE的 Router ID,所 述虚拟节点到所述第二 Egress PE的链路的状态信息包括所述虚拟节点到所 述第二 Egress PE的链路的 cost值 T和所述第二 Egress PE的 Router ID; 其中所述 N和所述 T为内部网关协议 IGP的最大 cost值,所述 S和所 述 M满足( 1 )或 ( 2 )
( 1 ) Sxy4+S>Sxy3+M ① 和
C34+S>M ② 其中, Px为所述第一 Egress PE的任何邻居节点 , Pxy为去掉所述第一 Egress PE后的网络中所述 Px的任意邻居节点, Sxy3为所述 Pxy到所述第 一 Egress PE的最短路径的 cost值 , Sxy4为所述 Pxy到所述第二 Egress PE 的最短路径的 cost值, C34为所述第一 Egress PE到所述第二 Egress PE的 最短路径的 cost值;
( 2 ) X+M<Y+S ③ 其中 X为从所述 Ingress PE到所述第一 Egress PE的最短路径的 cost 值, Y为从所述 Ingress PE到所述第二 Egress PE的最短路径的 cost值。
2、如权利要求 1所述的网络系统,其特征在于,所述虚拟节点的 Router ID为静态配置的 , 或者, 通过在所述第一 Egress PE和所述第二 Egress PE 之间动态协商得到。
3、 如权利要求 1或 2所述的网络系统, 其特征在于, 所述虚拟节点的 Router ID为环回标 i只 Loopback ID。
4、如权利要求 1-3中任一所述的网络系统,其特征在于,如果满足( 1 ) 或 (2 ) 的 M-S对有多组, 则选择 S最小的 M-S对或者 M最小的 M-S对, 将选择的 M-S对中的 M携带在所述第一链路状态信息中, 将选择的 M-S 对中的 S携带在所述第三链路状态信息中。
5、如权利要求 1-4中任一所述的网络系统,其特征在于,对于方式(2 ) 中, M=l , S为内部网关协议 IGP的最大 cost值。
6、 如权利要求 1-5中任一所述的网络系统, 其特征在于, 所述虚拟节 点的 Router ID为所述第一 Egress PE和第二 Egress PE中优先级高者所拥有 的且未被占用的网络协议 IP地址。
7、 一种网络系统, 其特征在于, 包括第一出口运营商边缘设备 Egress PE、 第二 Egress PE和入口运营商边缘设备 Ingress PE , 所述第一 Egress PE 与客户边缘设备 CE通信, 所述第二 Egress PE与所述 CE通信, 所述第一 Egress PE和所述第二 Egress PE位于包括所述第一 Egress PE 和所述第二 Egress PE的冗余保护组内, 其中所述第一 Egress PE为主用设 备, 所述第二 Egress PE为备用设备; 所述第一 Egress PE用于: 生成虚拟节点, 所述虚拟节点具有所述网络系统中全局唯一的 Router ID, 所述虚拟节点用作所述第一 Egress PE的下一跳节点, 所述虚拟节点用 作所述第二 Egress PE的下一跳节点; 发送第一链路状态消息给所述 Ingress PE, 所述第一链路状态消息包 括:所述第一 Egress PE的 Router ID和所述第一 Egress PE到所述虚拟节点 的链路的状态信息, 所述第一 Egress PE到所述虚拟节点的链路的状态信息 包括所述第一 Egress PE到所述虚拟节点的链路的 cost值 M和所述虚拟节 点的 Router ID; 发送第二链路状态消息给所述 Ingress PE, 所述第二链路状态消息包 括: 所述虚拟节点的 Router ID、所述虚拟节点到所述第一 Egress PE的链路 的状态信息和所述虚拟节点到所述第二 Egress PE的链路的状态信息, 所述 虚拟节点到所述第一 Egress PE的链路的状态信息包括所述虚拟节点到所述 第一 Egress PE的链路的 cost值 N和所述第一 Egress PE的 Router ID,所述 虚拟节点到所述第二 Egress PE的链路的状态信息包括所述虚拟节点到所述 第二 Egress PE的链路的 cost值 T和所述第二 Egress PE的 Router ID; 所述第二 Egress PE用于: 生成所述虚拟节点, 发送第三链路状态消息给所述 Ingress PE, 所述第三链路状态消息包 括:所述第二 Egress PE的 Router ID和所述第二 Egress PE到所述虚拟节点 的链路的状态信息, 所述第二 Egress PE到所述虚拟节点的链路的状态信息 包括所述第二 Egress PE到所述虚拟节点的链路的 cost值 S和所述虚拟节点 的 Router ID; 发送第四链路状态消息给所述 Ingress PE, 所述第四链路状态消息包 括: 所述虚拟节点的 Router ID、所述虚拟节点到所述第一 Egress PE的链路 的状态信息和所述虚拟节点到所述第二 Egress PE的链路的状态信息, 所述 虚拟节点到所述第一 Egress PE的链路的状态信息包括所述虚拟节点到所述 第一 Egress PE的链路的 cost值 N和所述第一 Egress PE的 Router ID,所述 虚拟节点到所述第二 Egress PE的链路的状态信息包括所述虚拟节点到所述 第二 Egress PE的链路的 cost值 T和所述第二 Egress PE的 Router ID; 所述第一 Egress PE还用于为第一虚拟专用网络 VPN的第一转发等价 类分配第一标签, 并发送所述第一标签和所述虚拟节点的 Router ID给所述 Ingress PE; 所述第二 Egress PE还用于为所述第一 VPN的所述第一转发等价类 配所述第一标签, 并发送所述第一标签和所述虚拟节点的 Router ID给所述 Ingress PE。
8、如权利要求 7所述的网络系统,其特征在于,所述虚拟节点的 Router ID为静态配置的, 或者, 通过所述第一 Egress PE和所述第二 Egress PE之 间动态协商得到。
9、 如权利要求 7或 8所述的网络系统, 其特征在于, 所述虚拟节点的 Router ID为环回标 i只 Loopback ID。
10、 如权利要求 7-9中任一所述的网络系统, 其特征在于, 所述虚拟节 点的 Router ID为所述第一 Egress PE所拥有的且未被占用的 IP地址或所述 第二 Egress PE所拥有的且未被占用的网络协议 IP地址。
11、 如权利要求 7-9中任一所述的网络系统, 其特征在于, 所述虚拟节 点的 Router ID为所述第一 Egress PE和第二 Egress PE中优先级高者所拥有 的且未被占用的网络协议 IP地址。
12、 如权利要求 7-11中任一所述的网络系统, 其特征在于, 所述第一 标签为静态配置的, 或者, 通过所述第一 Egress PE和第二 Egress PE之间 动态协商得到。
13、 一种建立隧道的方法, 其特征在于, 所述方法应用于网络系统, 所述网络系统包括第一出口运营商边缘设备 Egress PE、 第二 Egress PE和 入口运营商设备 Ingress PE, 所述第一 Egress PE与客户边缘设备 CE通信 , 所述第二 Egress PE与所述 CE通信 , 所述第一 Egress PE和第二 Egress PE 处于包括所述第一 Egress PE和所述第二 Egress PE的冗余保护组内, 其中 所述第一 Egress PE为主用设备, 所述第二 Egress PE为备用设备; 所述方法包括: 在所述第一 Egress PE生成虚拟节点, 所述虚拟节点具有所述网络系统 中全局唯一的 Router ID,所述虚拟节点用作所述第一 Egress PE的下一跳节 点, 所述虚拟节点用作所述第二 Egress PE的下一跳节点; 在所述第二 Egress PE上生成所述虚拟节点; 所述第一 Egress PE发送第一链路状态消息给所述 Ingress PE , 所述第 一链路状态消息包括:所述第一 Egress PE的 Router ID和所述第一 Egress PE 到所述虚拟节点的链路的状态信息, 所述第一 Egress PE到所述虚拟节点的 链路的状态信息包括所述第一 Egress PE到所述虚拟节点的链路的 cost值 M 和所述虚拟节点的 Router ID; 所述第一 Egress PE发送第二链路状态消息给所述 Ingress PE , 所述第 二链路状态消息包括: 所述虚拟节点的 Router ID、 所述虚拟节点到所述第 一 Egress PE的链路的状态信息和所述虚拟节点到所述第二 Egress PE的链 路的状态信息, 所述虚拟节点到所述第一 Egress PE的链路的状态信息包括 所述虚拟节点到所述第一 Egress PE的链路的 cost值 N和所述第一 Egress PE 的 Router ID,所述虚拟节点到所述第二 Egress PE的链路的状态信息包括所 述虚拟节点到所述第二 Egress PE的链路的 cost值 T和所述第二 Egress PE 的 Router ID; 所述第二 Egress PE发送第三链路状态消息给所述 Ingress PE , 所述第 三链路状态消息包括:所述第二 Egress PE的 Router ID和所述第二 Egress PE 到所述虚拟节点的链路的状态信息, 所述第二 Egress PE到所述虚拟节点的 链路的状态信息包括所述第二 Egress PE到所述虚拟节点的链路的 cost值 S 和所述虚拟节点的 Router ID; 所述第二 Egress PE发送第四链路状态消息给所述 Ingress PE , 所述第 四链路状态消息包括: 所述虚拟节点的 Router ID、 所述虚拟节点到所述第 一 Egress PE的链路的状态信息和所述虚拟节点到所述第二 Egress PE的链 路的状态信息, 所述虚拟节点到所述第一 Egress PE的链路的状态信息包括 所述虚拟节点到所述第一 Egress PE的链路的 cost值 N和所述第一 Egress PE 的 Router ID,所述虚拟节点到所述第二 Egress PE的链路的状态信息包括所 述虚拟节点到所述第二 Egress PE的链路的 cost值 T和所述第二 Egress PE 的 Router ID; 其中所述 N和所述 T为内部网关协议 IGP的最大 cost值,所述 S所述 M满足( 1 )或( 2 ) :
( 1 ) Sxy4+S>Sxy3+M ①和
C34+S>M ② 其中, Px为所述第一 Egress PE的任何邻居节点 , Pxy为去掉所述第一 Egress PE后的网络中所述 Px的任意邻居节点, Sxy3为所述 Pxy到所述第 一 Egress PE的最短路径的 cost值 , Sxy4为所述 Pxy到所述第二 Egress PE 的最短路径的 cost值, C34为所述第一 Egress PE到所述第二 Egress PE的 最短路径的 cost值;
( 2 ) X+M<Y+S ③ 其中 X为从所述 Ingress PE到所述第一 Egress PE的最短路径的 cost 值, Y为从所述 Ingress PE到所述第二 Egress PE的最短路径的 cost值。
14、 如权利要求 13所述的方法, 其特征在于, 在所述第一 Egress PE 和所述第二 Egress PE上生成虚拟节点, 包括: 所述第一 Egress PE和所述第二 Egress PE通过动态协商的方式生成所 述虚拟节点。
15、 如权利要求 14所述的方法, 其特征在于, 所述第一 Egress PE和 所述第二 Egress PE通过动态协商的方式生成所述虚拟节点, 包括: 所述第一 Egress PE和所述第二 Egress PE之间建立框间通信协议 ICCP 连接, 分别向对方发送自身的优先级, 选择优先级高的一方来确定所述虚 拟节点的 Router ID。
16、 如权利要求 15所述的方法, 其特征在于, 所述虚拟节点的 Router ID是所述第一 Egress PE和所述第二 Egress PE中优先级高的一方所拥有的 且未被占用的网络协议 IP地址。
17、 如权利要求 16所述的方法, 其特征在于, 如果所述第一 Egress PE 和所述第二 Egress PE的优先级相等, 则比较所述第一 Egress PE和所述第 二 Egress PE的地址,由所述第一 Egress PE和所述第二 Egress PE中地址较 大一方来确定所述虚拟节点的 Router ID。
18、 如权利要求 16所述的方法, 其特征在于, 如果所述第一 Egress PE 和所述第二 Egress PE的优先级相等, 则比较所述第一 Egress PE和所述第 二 Egress PE的地址,由所述第一 Egress PE和所述第二 Egress PE中地址较 小一方来确定所述虚拟节点的 Router ID。
19、 如权利要求 17或 18所述的方法, 其特征在于, 所述虚拟节点的 Router ID是所述第一 Egress PE和所述第二 Egress PE中地址较大一方的所 拥有且未使用的地址。
20、 如权利要求 17或 18所述的方法, 其特征在于, 所述虚拟节点的 Router ID是所述第一 Egress PE和所述第二 Egress PE中地址较小一方的所 拥有且未使用的地址。
21、如权利要求 14-20中任一所述的方法,其特征在于,所述第一 Egress PE和所述第二 Egress PE通过动态协商的方式生成所述虚拟节点, 包括: 通过在框间通信协议 ICCP报文中携带第一类型-长度-值 TLV, 所述第一 TLV包括 vNH字段和优先级字段, 所述优先级字段携带所述 ICCP报文的 发送方的优先级, 所述 vNH字段携带所述 ICCP报文的发送方的地址。
22、如权利要求 13-21中任一所述的方法,其特征在于,所述第一 Egress PE和所述第二 Egress PE分别为第一 VPN的所述第一转发等价类分配所述 所述第一标签 , 包括: 所述第一 Egress PE和所述第二 Egress PE通过动态 协商的方式来分配所述第一标签。
23、 如权利要求 22中所述的方法, 其特征在于, 所述第一 Egress PE 和所述第二 Egress PE通过动态协商的方式来分配所述第一标签, 包括: 所 述第一 Egress PE和所述第二 Egress PE之间建立 ICCP连接,分别向对方发 送自身的优先级, 选择优先级高的一方来确定所述第一标签。
24、 如权利要求 23所述的方法, 其特征在于, 如果所述第一 Egress PE 和所述第二 Egress PE的优先级相等, 则比较所述第一 Egress PE和所述第 二 Egress PE的地址,由所述第一 Egress PE和所述第二 Egress PE中地址较 大一方来确定所述第一标签。
25、 如权利要求 23所述的方法, 其特征在于, 如果所述第一 Egress PE 和所述第二 Egress PE的优先级相等, 则比较所述第一 Egress PE和所述第 二 Egress PE的地址,由所述第一 Egress PE和所述第二 Egress PE中地址较 小一方来确定所述第一标签。
26、如权利要求 22-25中任一所述的方法,其特征在于,所述第一 Egress PE和所述第二 Egress PE通过动态协商的方式来分配所述第一标签, 通过 在 ICCP报文中携带第二 TLV来实现, 所述第二 TLV包括 VPN label字段 和优先级字段, 所述优先级字段携带所述 ICCP报文的发送方的优先级, 所
27、 如权利要求 26所述的方法, 其特征在于, 所述第二 TLV还包括 可用标签上限字段和可用标签下限字段, 所述可用标签上限字段和所述可
28、 如权利要求 13-27中任一所述的方法, 其特征在于, 当所述 VPN 为 L3VPN时, 可以采用每 VPN标签分配方式, 也可以采用每路由标签分 配方式或者每接口标签分配方式。
29、 如权利要求 13-28中任一所述的方法, 其特征在于, 如果满足(1 ) 或 (2 ) 的 M-S对有多组, 则选择 S最小的 M-S对或者 M最小的 M-S对, 将选择的 M-S对中的 M携带在所述第一链路状态信息中, 将选择的 M-S 对中的 S携带在所述第三链路状态信息中。
30、 如权利要求 13-28中任一所述的方法, 其特征在于, 对于方式(2 ) 中, M=l , S为内部网关协议 IGP的最大 cost值。
31、 一种标签分配方法, 其特征在于, 所述方法应用于网络系统, 所 述网络系统包括第一出口运营商边缘设备 Egress PE、 第二 Egress PE和入 口运营商边缘设备 Ingress PE , 所述第一 Egress PE与客户边缘设备 CE通 信, 所述第二 Egress PE与所述 CE通信, 所述第一 Egress PE和所述第二 Egress PE位于包括所述第一 Egress PE和所述第二 Egress PE的冗余保护组 内, 其中所述第一 Egress PE为主用设备, 所述第二 Egress PE为备用设备; 所述方法包括: 在所述第一 Egress PE生成虚拟节点, 所述虚拟节点具有所述网络系统 中全局唯一的 Router ID,所述虚拟节点用作所述第一 Egress PE的下一跳节 点, 所述虚拟节点用作所述第二 Egress PE的下一跳节点; 在所述第二 Egress PE上生成所述虚拟节点; 所述第一 Egress PE发送第一链路状态消息给所述 Ingress PE , 所述第 一链路状态消息包括:所述第一 Egress PE的 Router ID和所述第一 Egress PE 到所述虚拟节点的链路的状态信息, 所述状态信息包括所述第一 Egress PE 到所述虚拟节点的链路的 cost值 M和所述虚拟节点的 Router ID; 所述第一 Egress PE发送第二链路状态消息给所述 Ingress PE , 所述第 二链路状态消息包括: 所述虚拟节点的 Router ID、 所述虚拟节点到所述第 一 Egress PE的链路的状态信息和所述虚拟节点到所述第二 Egress PE的链 路的状态信息, 所述虚拟节点到所述第一 Egress PE的链路的状态信息包括 所述虚拟节点到所述第一 Egress PE的链路的 cost值 N和所述第一 Egress PE 的 Router ID,所述虚拟节点到所述第二 Egress PE的链路的状态信息包括所 述虚拟节点到所述第二 Egress PE的链路的 cost值 T和所述第二 Egress PE 的 Router ID; 所述第二 Egress PE发送第三链路状态消息给所述 Ingress PE , 所述第 三链路状态消息包括:所述第二 Egress PE的 Router ID和所述第二 Egress PE 到所述虚拟节点的链路的状态信息, 所述第二 Egress PE到所述虚拟节点的 链路的状态信息包括所述第二 Egress PE到所述虚拟节点的链路的 cost值 S 和所述虚拟节点的 Router ID; 所述第二 Egress PE发送第四链路状态消息给所述 Ingress PE , 所述第 四链路状态消息包括: 所述虚拟节点的 Router ID、 所述虚拟节点到所述第 一 Egress PE的链路的状态信息和所述虚拟节点到所述第二 Egress PE的链 路的状态信息, 所述虚拟节点到所述第一 Egress PE的链路的状态信息包括 所述虚拟节点到所述第一 Egress PE的链路的 cost值 N和所述第一 Egress PE 的 Router ID,所述虚拟节点到所述第二 Egress PE的链路的状态信息包括所 述虚拟节点到所述第二 Egress PE的链路的 cost值 T和所述第二 Egress PE 的 Router ID; 所述第一 Egress PE为第一虚拟专用网络 VPN的第一转发等价类分配 第一标签,并发送所述第一标签和所述虚拟节点的 Router ID给所述 Ingress PE; 所述第二 Egress PE为所述第一 VPN的所述第一转发等价类分配所述 第一标签,并发送所述第一标签和所述虚拟节点的 Router ID给所述 Ingress PE。
32、 如权利要求 31所述的方法, 其特征在于, 在所述第一 Egress PE 和所述第二 Egress PE上生成所述虚拟节点, 包括: 所述第一 Egress PE和所述第二 Egress PE通过动态协商的方式生成所 述虚拟节点。
33、 如权利要求 32所述的方法, 其特征在于, 所述第一 Egress PE和 所述第二 Egress PE通过动态协商的方式生成所述虚拟节点, 包括: 所述第一 Egress PE和所述第二 Egress PE之间建立框间通信协议 ICCP 连接, 分别向对方发送自身的优先级, 选择优先级高的一方来确定所述虚 拟节点的 Router ID。
34、 如权利要求 31-33中任一所述的方法, 其特征在于, 所述虚拟节点 的 Router ID是所述第一 Egress PE和所述第二 Egress PE中优先级高的一方 所拥有的且未被占用的 IP地址。
35、如权利要求 33或 34所述的方法,其特征在于,如果所述第一 Egress PE和所述第二 Egress PE的优先级相等, 则比较所述第一 Egress PE和所述 第二 Egress PE的地址,由所述第一 Egress PE和所述第二 Egress PE中地址 较大一方来确定所述虚拟节点的 Router ID。
36、如权利要求 33或 34所述的方法,其特征在于,如果所述第一 Egress PE和所述第二 Egress PE的优先级相等, 则比较所述第一 Egress PE和所述 第二 Egress PE的地址,由所述第一 Egress PE和所述第二 Egress PE中地址 较小一方来确定所述虚拟节点的 Router ID。
37、 如权利要求 31-36中任一所述的方法, 其特征在于, 所述虚拟节点 的 Router ID是所述第一 Egress PE和所述第二 Egress PE中地址较大一方所 拥有的且未被占用的地址。
38、 如权利要求 31-36中任一所述的方法, 其特征在于, 所述虚拟节点 的 Router ID是所述第一 Egress PE和所述第二 Egress PE中地址较小一方所 拥有的且未被占用的地址。
39、如权利要求 31-38中任一所述的方法,其特征在于,所述第一 Egress PE和所述第二 Egress PE通过动态协商的方式生成所述虚拟节点, 包括: 通过在框间通信协议 ICCP报文中携带第一类型-长度-值 TLV, 所述第一 TLV包括 vNH字段和优先级字段, 所述优先级字段携带所述 ICCP报文的 发送方的优先级, 所述 vNH字段携带所述 CC报文的发送方的地址。
40、如权利要求 31-39中任一所述的方法,其特征在于,所述第一 Egress PE和所述第二 Egress PE分别为第一 VPN的所述第一转发等价类分配所述 所述第一标签 , 包括: 所述第一 Egress PE和所述第二 Egress PE通过动态 协商的方式来分配所述第一标签。
41、 如权利要求 40所述的方法, 其特征在于, 所述第一 Egress PE和 所述第二 Egress PE通过动态协商的方式来分配所述第一标签, 包括: 所述 第一 Egress PE和所述第二 Egress PE之间建立 ICCP连接,分别向对方发送 自身的优先级, 选择优先级高的一方来确定所述第一标签。
42、 如权利要求 41所述的方法, 其特征在于, 如果所述第一 Egress PE 和所述第二 Egress PE的优先级相等, 则比较所述第一 Egress PE和所述第 二 Egress PE的地址,由所述第一 Egress PE和所述第二 Egress PE中地址较 大一方来确定所述第一标签。
43、 如权利要求 41所述的方法, 其特征在于, 如果所述第一 Egress PE 和所述第二 Egress PE的优先级相等, 则比较所述第一 Egress PE和所述第 二 Egress PE的地址,由所述第一 Egress PE和所述第二 Egress PE中地址较 小一方来确定所述第一标签。
44、如权利要求 40-43中任一所述的方法,其特征在于,所述第一 Egress PE和所述第二 Egress PE通过动态协商的方式来分配所述第一标签, 通过 在 ICCP报文中携带第二 TLV来实现, 所述第二 TLV包括 VPN label字段 和优先级字段, 所述优先级字段携带所述 ICCP报文的发送方的优先级, 所
45、 如权利要求 44所述的方法, 其特征在于, 所述第二 TLV还包括 可用标签上限字段和可用标签下限字段, 所述可用标签上限字段和所述可
46、 如权利要求 31-45 中任一所述的方法, 其特征在于, 当所述 VPN 为 L3VPN时, 可以采用每 VPN标签分配方式, 也可以采用每路由标签分 配方式或者每接口标签分配方式。
47、 一种第一运营商边缘设备 PE, 其特征在于, 所述第一 PE位于包 括第二 PE、 入口运营商边缘设备 Ingess PE和所述第一 PE的网络系统内 , 所述第一 PE和所述第二 PE作为出口运营商边缘设备 Egress PE,所述第一 PE和所述第二 PE位于包括所述第一 PE和所述第二 PE的冗余保护组内, 所述第一 PE作为主用 PE,所述第二 PE作为备用 PE, 所述第一 PE与客户 边缘设备 CE通信, 所述第二 PE与所述 CE通信; 所述第一 PE包括: 第一虚拟节点生成模块、 第一状态发布模块、 第一 虚拟节点状态发布模块, 其中: 所述第一虚拟节点生成模块, 用于在所述第一 PE上生成虚拟节点, 所 述虚拟节点具有所述网络系统中全局唯一的 Router ID, 所述虚拟节点用作 所述第一 PE的下一跳节点, 所述虚拟节点用作所述所述第二 PE的下一跳 节点; 所述第一状态发布模块, 用于发送第一链路状态消息给所述 Ingress PE , 所述第一链路状态消息包括: 所述第一 ΡΕ的 Router ID和所述第一 PE 到所述虚拟节点的链路的状态信息,所述第一 PE到所述虚拟节点的链路的 状态信息包括所述第一 PE到所述虚拟节点的链路的 cost值 M和所述虚拟 节点的 Router ID; 所述第一虚拟节点状态发布模块, 还用于发送第二链路状态消息给所 述 Ingress PE, 所述第二链路状态消息包括: 所述虚拟节点的 Router ID、 所 述虚拟节点到所述第一 PE 的链路的状态信息和所述虚拟节点到所述第二 PE的链路的状态信息, 所述虚拟节点到所述第一 PE的链路的状态信息包 括所述虚拟节点到所述第一 PE的链路的 cost值 N和所述第一 PE的 Router ID,所述虚拟节点到所述第二 PE的链路的状态信息包括所述虚拟节点到所 述第二 PE的链路的 cost值 T和所述第二 PE的 Router ID, 其中所述 N和 所述 T为内部网关协议 IGP的最大 cost值, 所述 S和所述 M满足( 1 )或 ( 2 ) :
( 1 )
Sxy4+S>Sxy3+M ① 和
C34+S>M ② 其中, Px为所述第一 PE的任何邻居节点, Pxy为去掉所述第一 PE后 的网络中所述 Px的任意邻居节点, Sxy3为所述 Pxy到所述第一 PE的最短 路径的 cost值, Sxy4为所述 Pxy到所述第二 PE的最短路径的 cost值, C34 为所述第一 PE到所述第二 PE的最短路径的 cost值;
( 2 ) X+M<Y+S ③ 其中 X为从所述 Ingress PE到所述第一 PE的最短路径的 cost值, Y为 从所述 Ingress PE到所述第二 PE的最短路径的 cost值。
48、 如权利要求 47所述的第一 PE, 其特征在于, 还包括第一虚拟节 点地址协商模块, 用于与所述第二 PE协商确定相同的虚拟节点的 Router ID。
49、 如权利要求 47或 48所述的第一 PE, 其特征在于, 还包括所述第 一 PE还可以包括第一标签协商模块, 用于与所述第二 PE协商确定相同的 标签。
50、 如权利要求 47-49中任一所述的第一 PE, 其特征在于, 如果满足 ( 1 )或( 2 )的 M-S对有多组, 则选择 S最小的 M-S对或者 M最小的 M-S 对, 将选择的 M-S对中的 M携带在所述第一链路状态信息中, 将选择的 M-S对中的 S携带在所述第三链路状态信息中。
51、如权利要求 47-49中任一所述的第一 PE,其特征在于,对于方式(2 ) 中, M=l , S为 IGP的最大 cost值。
PCT/CN2013/078887 2013-07-05 2013-07-05 建立隧道的方法、分配标签的方法、设备及网络系统 WO2015000173A1 (zh)

Priority Applications (4)

Application Number Priority Date Filing Date Title
PCT/CN2013/078887 WO2015000173A1 (zh) 2013-07-05 2013-07-05 建立隧道的方法、分配标签的方法、设备及网络系统
EP13888861.5A EP3002913B1 (en) 2013-07-05 2013-07-05 Tunnel establishment method, label allocation method, device, and network system
CN201380077524.4A CN105379197B (zh) 2013-07-05 2013-07-05 建立隧道的方法、分配标签的方法、设备及网络系统
US14/986,144 US10003531B2 (en) 2013-07-05 2015-12-31 Method for establishing tunnel, method for allocating label, device and network system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2013/078887 WO2015000173A1 (zh) 2013-07-05 2013-07-05 建立隧道的方法、分配标签的方法、设备及网络系统

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US14/986,144 Continuation US10003531B2 (en) 2013-07-05 2015-12-31 Method for establishing tunnel, method for allocating label, device and network system

Publications (1)

Publication Number Publication Date
WO2015000173A1 true WO2015000173A1 (zh) 2015-01-08

Family

ID=52143041

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2013/078887 WO2015000173A1 (zh) 2013-07-05 2013-07-05 建立隧道的方法、分配标签的方法、设备及网络系统

Country Status (4)

Country Link
US (1) US10003531B2 (zh)
EP (1) EP3002913B1 (zh)
CN (1) CN105379197B (zh)
WO (1) WO2015000173A1 (zh)

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106169969A (zh) * 2016-08-31 2016-11-30 华为技术有限公司 建立虚拟专用网标签交换路径方法、相关设备和系统
CN109150566A (zh) * 2017-06-19 2019-01-04 中兴通讯股份有限公司 一种业务路径还原方法及装置
CN109787894A (zh) * 2019-03-27 2019-05-21 新华三技术有限公司 一种路由控制方法及装置
CN109873760A (zh) * 2017-12-01 2019-06-11 华为技术有限公司 处理路由的方法和装置、以及数据传输的方法和装置
CN110868352A (zh) * 2019-11-14 2020-03-06 迈普通信技术股份有限公司 一种私网应用识别系统、方法及sdn控制器、p设备
CN110912819A (zh) * 2018-09-14 2020-03-24 迈普通信技术股份有限公司 路由收敛的方法及装置
WO2023029902A1 (zh) * 2021-08-30 2023-03-09 华为技术有限公司 双归保护系统、双归保护方法以及相关设备

Families Citing this family (56)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9537718B2 (en) 2013-03-15 2017-01-03 Cisco Technology, Inc. Segment routing over label distribution protocol
CN104426763B (zh) * 2013-08-21 2018-10-26 南京中兴新软件有限责任公司 隧道切换方法、装置及交换机
WO2015035570A1 (en) 2013-09-11 2015-03-19 Telefonaktiebolaget L M Ericsson (Publ) Inter-chassis peer and method used therein
CN104579945B (zh) * 2013-10-18 2019-07-02 中兴通讯股份有限公司 一种冗余保护方法及装置
WO2015059123A1 (en) * 2013-10-21 2015-04-30 Telefonaktiebolaget L M Ericsson (Publ) Packet rerouting techniques in a packet-switched communication network
US20160301594A1 (en) * 2013-12-06 2016-10-13 Telefonaktiebolaget L M Ericsson (Publ) Inter-chassis peer and method used therein
US9647883B2 (en) 2014-03-21 2017-05-09 Nicria, Inc. Multiple levels of logical routers
JP6217029B2 (ja) * 2014-08-19 2017-10-25 村田機械株式会社 無線通信システム、及び、無線基地局
US10263861B2 (en) 2014-11-07 2019-04-16 Cisco Technology, Inc. Multi-path aware tracing and probing functionality at service topology layer
US11533255B2 (en) 2014-11-14 2022-12-20 Nicira, Inc. Stateful services on stateless clustered edge
US9787605B2 (en) 2015-01-30 2017-10-10 Nicira, Inc. Logical router with multiple routing components
US10341221B2 (en) 2015-02-26 2019-07-02 Cisco Technology, Inc. Traffic engineering for bit indexed explicit replication
US10230629B2 (en) 2015-08-11 2019-03-12 Nicira, Inc. Static route configuration for logical router
US10075363B2 (en) 2015-08-31 2018-09-11 Nicira, Inc. Authorization for advertised routes among logical routers
US10095535B2 (en) 2015-10-31 2018-10-09 Nicira, Inc. Static route types for logical routers
US10050855B1 (en) * 2015-12-17 2018-08-14 Juniper Networks, Inc. Maintaining a tunnel liveness session in a multi-chassis link aggregation group topology
US10263881B2 (en) * 2016-05-26 2019-04-16 Cisco Technology, Inc. Enforcing strict shortest path forwarding using strict segment identifiers
CN107547583A (zh) * 2016-06-24 2018-01-05 中兴通讯股份有限公司 一种应用连接的构建方法、装置及终端
US10153973B2 (en) 2016-06-29 2018-12-11 Nicira, Inc. Installation of routing tables for logical router in route server mode
CN109691026B (zh) * 2016-08-04 2022-06-10 瑞典爱立信有限公司 更新多个多协议标签切换双向转发检测会话的方法和装置
US10454758B2 (en) 2016-08-31 2019-10-22 Nicira, Inc. Edge node cluster network redundancy and fast convergence using an underlay anycast VTEP IP
US10341236B2 (en) 2016-09-30 2019-07-02 Nicira, Inc. Anycast edge service gateways
US10700960B2 (en) * 2016-11-17 2020-06-30 Nicira, Inc. Enablement of multi-path routing in virtual edge systems
US10263807B2 (en) * 2016-12-19 2019-04-16 Ciena Corporation Hierarchical statistics acceleration
US11228527B2 (en) * 2016-12-21 2022-01-18 Vmware, Inc. Load balancing between edge systems in a high availability edge system pair
CN108234305B (zh) * 2016-12-22 2021-08-31 上海诺基亚贝尔股份有限公司 一种跨机框链路冗余保护的控制方法及设备
US10554494B1 (en) * 2017-01-04 2020-02-04 Juniper Networks, Inc. Automatic ICCP provisioning and VLAN provisioning on an inter-chassis link in a MC-LAG
US10951584B2 (en) 2017-07-31 2021-03-16 Nicira, Inc. Methods for active-active stateful network service cluster
US11570092B2 (en) 2017-07-31 2023-01-31 Nicira, Inc. Methods for active-active stateful network service cluster
CN109429273B (zh) * 2017-09-01 2021-06-08 华为技术有限公司 一种资源分配的方法及装置
US10212075B1 (en) * 2017-09-22 2019-02-19 Cisco Technology, Inc. Convergence optimization of local switching for flexible cross-connect in ethernet virtual private network (EVPN) environments
US10305780B1 (en) * 2017-11-30 2019-05-28 Juniper Networks, Inc. Controlling accumulated interior gateway protocol (“AIGP”) attribute updates
CN108259331B (zh) * 2017-12-14 2021-03-02 新华三技术有限公司 路由发布方法及装置
US11153122B2 (en) 2018-02-19 2021-10-19 Nicira, Inc. Providing stateful services deployed in redundant gateways connected to asymmetric network
US10742487B2 (en) 2018-04-05 2020-08-11 Nokia Technologies Oy Border routers in multicast networks and methods of operating the same
US10771383B2 (en) 2018-06-26 2020-09-08 Juniper Networks, Inc. Coordinating pseudowire connection characteristics and multi-homed provider edge device capabilities
CN108924046B (zh) * 2018-07-16 2021-06-29 烽火通信科技股份有限公司 一种gre隧道承载业务的保护方法及系统
US11438279B2 (en) * 2018-07-23 2022-09-06 Pure Storage, Inc. Non-disruptive conversion of a clustered service from single-chassis to multi-chassis
US10812370B2 (en) * 2018-08-03 2020-10-20 Arista Networks, Inc. Unified control plane over MPLS and internet interfaces through BGP
US10931560B2 (en) 2018-11-23 2021-02-23 Vmware, Inc. Using route type to determine routing protocol behavior
US10797998B2 (en) 2018-12-05 2020-10-06 Vmware, Inc. Route server for distributed routers using hierarchical routing protocol
US10938788B2 (en) 2018-12-12 2021-03-02 Vmware, Inc. Static routes for policy-based VPN
WO2020167790A1 (en) * 2019-02-15 2020-08-20 Futurewei Technologies, Inc. System and method for interior gateway protocol (igp) fast convergence
US11425031B2 (en) * 2019-03-28 2022-08-23 Hewlett Packard Enterprise Development Lp Layer 3 multi-chassis link aggregation group
US11368394B2 (en) * 2019-04-26 2022-06-21 Hewlett Packard Enterprise Development Lp Using labels in a virtualized device environment
CN110545240B (zh) * 2019-08-02 2022-06-07 新华三大数据技术有限公司 基于分布式聚合系统的标签转发表的建立及报文转发方法
US11436047B2 (en) 2019-08-06 2022-09-06 Arista Networks, Inc. System and method for processing information hierarchy management
US11252081B2 (en) * 2019-08-06 2022-02-15 Arista Networks, Inc. Optimized programming of forwarding data in network device hardware
US11140074B2 (en) 2019-09-24 2021-10-05 Cisco Technology, Inc. Communicating packets across multi-domain networks using compact forwarding instructions
US11265257B2 (en) 2020-04-16 2022-03-01 Cisco Technology, Inc. Rapid network traffic telemetry exports with split templates and flow records
US11212221B1 (en) 2020-06-03 2021-12-28 Cisco Technology, Inc. Methods to improve ECMP for BGP services and BGP for provider edges with hybrid label distribution
EP3941006B1 (en) * 2020-07-16 2022-10-26 Anapaya Systems AG System and method for carrying and optimizing internet traffic over a source-selected path routing network
US11863350B2 (en) * 2021-09-09 2024-01-02 Ciena Corporation Fast convergence of E-Tree with a dual homed root node
CN114039905B (zh) * 2021-11-30 2023-03-31 烽火通信科技股份有限公司 节约保护资源的方法及装置
US11799761B2 (en) 2022-01-07 2023-10-24 Vmware, Inc. Scaling edge services with minimal disruption
US11962564B2 (en) 2022-02-15 2024-04-16 VMware LLC Anycast address for network address translation at edge

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102355402A (zh) * 2011-08-03 2012-02-15 华为技术有限公司 一种基于vpn路由建立lsp的方法、系统和路由器
CN102404199A (zh) * 2011-10-11 2012-04-04 中兴通讯股份有限公司 一种多段伪线的建立及恢复方法、装置和系统
WO2012106919A1 (zh) * 2011-07-22 2012-08-16 华为技术有限公司 一种三层虚拟专有网路由控制方法、装置及系统

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7567577B2 (en) * 2005-06-28 2009-07-28 Cisco Technology, Inc. Link state advertisements specifying dynamic routing metrics and associated variation metrics and selective distribution thereof
US7656857B2 (en) * 2005-10-18 2010-02-02 Cisco Technology, Inc. Directed acyclic graph computation by orienting shortest path links and alternate path links obtained from shortest path computation
US7693047B2 (en) * 2005-11-28 2010-04-06 Cisco Technology, Inc. System and method for PE-node protection
CN102041199A (zh) * 2009-10-16 2011-05-04 周建 汽车水箱除垢剂

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2012106919A1 (zh) * 2011-07-22 2012-08-16 华为技术有限公司 一种三层虚拟专有网路由控制方法、装置及系统
CN102355402A (zh) * 2011-08-03 2012-02-15 华为技术有限公司 一种基于vpn路由建立lsp的方法、系统和路由器
CN102404199A (zh) * 2011-10-11 2012-04-04 中兴通讯股份有限公司 一种多段伪线的建立及恢复方法、装置和系统

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
See also references of EP3002913A4 *

Cited By (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2018040614A1 (zh) * 2016-08-31 2018-03-08 华为技术有限公司 建立虚拟专用网标签交换路径方法、相关设备和系统
CN106169969B (zh) * 2016-08-31 2020-01-10 华为技术有限公司 建立虚拟专用网标签交换路径方法、相关设备和系统
CN106169969A (zh) * 2016-08-31 2016-11-30 华为技术有限公司 建立虚拟专用网标签交换路径方法、相关设备和系统
CN109150566B (zh) * 2017-06-19 2022-07-15 中兴通讯股份有限公司 一种业务路径还原方法及装置
CN109150566A (zh) * 2017-06-19 2019-01-04 中兴通讯股份有限公司 一种业务路径还原方法及装置
CN109873760A (zh) * 2017-12-01 2019-06-11 华为技术有限公司 处理路由的方法和装置、以及数据传输的方法和装置
CN109873760B (zh) * 2017-12-01 2020-08-07 华为技术有限公司 处理路由的方法和装置、以及数据传输的方法和装置
US11533249B2 (en) 2017-12-01 2022-12-20 Huawei Technologies Co., Ltd. Route processing method and apparatus, and data transmission method and apparatus
CN110912819A (zh) * 2018-09-14 2020-03-24 迈普通信技术股份有限公司 路由收敛的方法及装置
CN110912819B (zh) * 2018-09-14 2022-05-20 迈普通信技术股份有限公司 路由收敛的方法及装置
CN109787894A (zh) * 2019-03-27 2019-05-21 新华三技术有限公司 一种路由控制方法及装置
CN110868352A (zh) * 2019-11-14 2020-03-06 迈普通信技术股份有限公司 一种私网应用识别系统、方法及sdn控制器、p设备
CN110868352B (zh) * 2019-11-14 2022-04-15 迈普通信技术股份有限公司 一种私网应用识别系统、方法及sdn控制器、p设备
WO2023029902A1 (zh) * 2021-08-30 2023-03-09 华为技术有限公司 双归保护系统、双归保护方法以及相关设备

Also Published As

Publication number Publication date
CN105379197A (zh) 2016-03-02
CN105379197B (zh) 2019-01-11
EP3002913A1 (en) 2016-04-06
US10003531B2 (en) 2018-06-19
US20160119229A1 (en) 2016-04-28
EP3002913A4 (en) 2016-07-13
EP3002913B1 (en) 2017-10-25

Similar Documents

Publication Publication Date Title
US10003531B2 (en) Method for establishing tunnel, method for allocating label, device and network system
US11533249B2 (en) Route processing method and apparatus, and data transmission method and apparatus
Martini et al. Pseudowire setup and maintenance using the label distribution protocol (LDP)
EP3588872B1 (en) Evpn packet processing method, device, system, and computer program product
WO2019105462A1 (zh) 报文的发送、处理方法及装置,pe节点,节点
CN110635935B (zh) 为用户接口的相应服务接口使用多个evpn路由
US7733883B2 (en) Method for implementing a virtual leased line
US8059549B2 (en) Method and apparatus for supporting network communications using point-to-point and point-to-multipoint protocols
JP5385154B2 (ja) Ethernet及びMPLSネットワークを相互接続する方法及び装置
US7619966B2 (en) Hybrid virtual private LAN extensions
US8009674B2 (en) Transport networks supporting virtual private networks, and configuring such networks
US8737395B2 (en) Method for accessing a network and network access device
US9184935B2 (en) Network communication method and network node device
US20120287818A1 (en) Multipoint-to-multipoint service for a communications network
US20140010112A1 (en) Method and Apparatus for Provisioning a Network Element
WO2018058639A1 (zh) 伪线负载分担的方法和设备
JP5161298B2 (ja) 非マルチプルスパニングツリープロトコル制御プレーン群を識別するためのシステム及び方法
Martini et al. Segmented Pseudowire
WO2018040614A1 (zh) 建立虚拟专用网标签交换路径方法、相关设备和系统
EP2618526A1 (en) Method and network access device for accessing a virtual private network
WO2006056131A1 (fr) Procede de realisation d&#39;intercommunication entre les differents reseaux vpn l3
Joseph et al. Network convergence: Ethernet applications and next generation packet transport architectures
He et al. Pure mpls technology
CN103595609B (zh) Trill网络互联方法、系统及设备
Martini et al. RFC 8077: Pseudowire Setup and Maintenance Using the Label Distribution Protocol (LDP)

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 13888861

Country of ref document: EP

Kind code of ref document: A1

REEP Request for entry into the european phase

Ref document number: 2013888861

Country of ref document: EP

WWE Wipo information: entry into national phase

Ref document number: 2013888861

Country of ref document: EP

NENP Non-entry into the national phase

Ref country code: DE