The tunneling technology provides a mechanism of encapsulating packets of a protocol into packets of another protocol. This allows packets to be transmitted over heterogeneous networks. The channel for transmitting heterogeneous packets is called a tunnel. Tunnels are mandatory for VPNs to transparently transmit VPN data from one VPN site to another.
MPLS VPNs support the following types of tunnels:
Generic Routing Encapsulation (GRE) tunnel: GRE-encapsulated data packets are transparently transmitted over the public IP network.
Generally, MPLS VPNs use LSPs or CR-LSPs as public network tunnels. If the core routers (Ps) on the backbone network, however, provide only the IP functionality and not MPLS functionality, whereas the PEs at the network edge have the MPLS functionality, the LSPs or CR-LSPs cannot be used as public network tunnels. In this situation, GRE tunnels can be used for MPLS VPNs.
A tunnel policy determines the tunnel type to be used for a VPN. By default, a VPN uses LSPs to forward data. To change the tunnel type or configure tunnel load balancing for VPN services, apply a tunnel policy to the VPN and run the tunnel select-seq command in the tunnel policy view to configure the priority sequence of tunnels and the number of tunnels used for load balancing.
The priority of a tunnel type depends on its configuration sequence. The earlier a tunnel type is configured, the higher its priority is. Assume that the following command has been run in a tunnel policy:
tunnel select-seq cr-lsp lsp load-balance-number 2
If a tunnel policy has been configured for a VPN to select only LSPs, three types of LSPs are available: LDP LSPs, BGP LSPs, and static LSPs, which can be selected in descending order of priority.
If a tunnel policy has been configured for a VPN to select only CR-LSPs, two types of CR-LSPs are available: RSVP-TE CR-LSPs and static CR-LSPs, which can be selected in descending order of priority.
Tunnel load balancing and route load balancing are different in the following aspects:
Routes used for load balancing must have equal costs, whereas tunnels used for load balancing can have unequal costs.
On the network shown in Figure 1, assume that all links have the same route cost. If two routes are available from PE1 to PE2 for load balancing, these two routes must have the same cost. If two tunnels are available from PE1 to PE2 for load balancing, these tunnels can have unequal route costs.
Routes used for load balancing must go over different paths, whereas tunnels used for load balancing can go over the same path.
On the network shown in Figure 2, if two routes are available from PE1 to PE2 for load balancing, these two routes must go over different paths. If two tunnels are available from PE1 to PE2 for load balancing, these tunnels can go over the same path.