Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

 
 

Example: Building a VPLS From Router 1 to Router 3 to Validate Label Blocks

This example illustrates how VPLS label blocks are allocated for a specific configuration. It is organized in the following sections:

Requirements

This configuration example requires three Juniper Networks routers.

Overview and Topology

In the network shown in Figure 1 Router 1 is establishing a pseudowire to Router 3

Figure 1: Router 1 to Router 3 TopologyRouter 1 to Router 3 Topology

Each PE filters the VPLS NLRI contained in the BGP update messages based on route target communities. Those VPLS NLRI instances that match the route target (in this case 8717:2000:2:1) are imported for further processing. The NLRI for Router 1 and Router 3 is shown in Table 1.

Table 1: NLRI Exchange Between for Router 1 and Router 3

Router 1 NLRI Advertisement to Router 3

Router 3 NLRI Advertisement to Router 1

RD - 8717:1000

RD - 8717:1000

VE ID - 1

VE ID - 2

VE Block Offset - 1

VE Block Offset - 1

VE Block Size - 8

VE Block Size - 8

Label Base - 262161

Label Base - 262153

To set up a pseudowire to Router 3, Router 1 must select a label to use to send traffic to Router 3 and also select a label that it expects Router 3 to use to send traffic to itself. The site ID contained in the VPLS NLRI from Router 3 is 2.

Router 1 learns of the existence of site ID 2 in the same VPLS domain. Using the equation VBO <= Local Site ID < (VBO +VBS), Router 1 checks if the route advertised by site ID 2 fits in the label block and block offset that it previously advertised to Router 3. In this example it does fit, so the site ID 2 is mapped by the VPLS NLRI advertised by Router 1, and Router 1 is ready to set up a pseudowire to Router 3.

To select the label to reach Router 3, Router 1 looks at the label block advertised by Router 3 and performs a calculation. The calculation a PE router uses to check if its site ID is mapped in the label block from the remote peer is VBO <= Local Site ID < (VBO +VBS). So, Router 1 selects label (262153 + (1 -1)) = 262153 to send traffic to Router 3. Using the same equation, Router 1 looks at its own label block that it advertised and selects label (262161 + (2 - 1)) = 262162 to receive traffic from Router 3. Router 1 programs its forwarding state such that any traffic destined to Router 3 carries the pseudowire label 262153 and any traffic coming from Router 3 is expected to have the pseudowire label 262162. This completes the operations on the VPLS NLRI received from Router 3. Router 1 now has a pseudowire set up to Router 3.

Router 3 operation is very similar to the Router 1 operation. Since the Router 3 site ID of 2 fits in the label block and block offset advertised by Router 1, Router 3 selects label (262161 + (2 - 1)) = 262162 to send traffic to Router 1. Router 3 looks at its own label block that it advertised and selects label (262153 + (1 - 1)) = 262153 to receive traffic from Router 1. This completes the creation of a pseudowire to Router 1.

By default, for VPLS operation Junos OS uses a virtual tunnel (VT) loopback interface to represent a pseudowire. This example uses a label-switched interface (LSI) instead of a VT interface because there is no change in the VPLS control plane operation. Thus, for an MX platform, if there is a tunnel physical interface card (PIC) configured, it is mandatory to include the no-tunnel-services statement at the [edit routing-instances routing-instance-name protocols vpls] hierarchy level.

Configuration

The following sections present the steps to configure and verify the example in Figure 1.

Configuring Router 1

Step-by-Step Procedure

  1. Configure Router 1. Create the edut routing instance. Specify the vpls instance type. Configure the route distinguisher and specify the value 8717:1000. Configure the route target and specify the value 8717:100 Configure the VPLS protocol. Specify 10 as the site range. Specify 1 as the site ID. Include the no-tunnel-services statement.

Configuring Router 3

Step-by-Step Procedure

  1. Configure Router 3. Create the edut routing instance. Specify the vpls instance type. Configure the route distinguisher and specify the value 8717:2000. Configure the route target and specify the value 8717:200 Configure the VPLS protocol. Specify 10 as the site range. Specify 2 as the site ID. Include the no-tunnel-services statement.

Verifying the VPLS Label Allocations

Step-by-Step Procedure

  1. As shown in the figure and the configuration, Site A is attached to Router 1. Site A is assigned a site ID of 1. Before Router 1 can announce its membership to VPLS edut using a BGP update message, Router 1 needs to allocate a default label block. In this example, the label base of the label block allocated by Router 1 is 262161. Since Router 1’s site ID is 1, Router 1 associates the assigned label block with block offset of 1. The following messages aresent from Router 1 to Router 3 and displayed using the monitor traffic interface interface-name command:

  2. As shown in the figure and the configuration, Site B is attached to Router 3. Site B is assigned a site ID of 2. Before Router 3 can announce its membership to VPLS edut using a BGP update message, Router 3 assigns a default label block with the label base of 262153. The block offset for this label block is 1 because its own site ID of 2 fits in the block being advertised. The following messages are sent from Router 3 to Router 1 and displayed using the monitor traffic interface interface-name command:

  3. Verify the connection status messages for Router 1 using the show vpls connections command. Notice the base label is 262161, the incoming label from Router 3 is 262162, and the outgoing label to Router 3 is 262153.

  4. Verify the connection status messages for Router 3 using the show vpls connections command. Notice the base label is 262153, the incoming label from Router 1 is 262153, and the outgoing label to Router 1 is 262162.