Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

Navigation

Example: Configuring the Router to Push an Extra VLAN Tag onto Pseudowire Traffic Using Dynamic Profiles

This example shows how dynamic profiles can be used to add an extra VLAN tag to the traffic received from a customer edge (CE) interface toward the network core.

Requirements

This example uses the following hardware and software components:

  • MX Series 3D Universal Edge Routers
  • Junos OS Release 9.3 or later

Overview and Topology

A dynamic profile is a set of characteristics, defined in a type of template, that you can use to provide dynamic subscriber access and services for broadband applications. These services are assigned dynamically to interfaces. You can use dynamic profiles at ingress and egress to control the pseudowire behavior.

The topology used in this example for dynamically pushing an extra VLAN tag on to a pseudowire is shown in Figure 1. On the ingress, the pseudowire receives dual-tagged frames with an inner VLAN ID 100, and an outer VLAN ID 10. All other frames are dropped. The outer tag is stripped at the interface. On the egress, the dual-tagged frames are transmitted with the outer vlan tag set to 10.

Figure 1: Pushing an Extra VLAN Tag on a Pseudowire

Pushing an Extra VLAN
Tag on a Pseudowire

Configuration

CLI Quick Configuration

To quickly configure this example, copy the following commands, paste them into a text file, remove any line breaks, change any details necessary to match your network configuration, and then copy and paste the commands into the CLI at the [edit] hierarchy level.

set dynamic-profiles pw-tagged interfaces $junos-interface-ifd-name unit $junos-underlying-interface-unit vlan-tags inner 100 outer 10set routing-instances red instance-type vpls vlan-id 100 interface ge-0/0/0set routing-instances red protocols vpls associate-profile pw-tagged

Pushing an Additional VLAN Tag Over the Pseudowire

Step-by-Step Procedure

The following example requires that you navigate various levels in the configuration hierarchy. For information about navigating the CLI, see Using the CLI Editor in Configuration Mode in the Junos OS CLI User Guide.

Note: This is not a complete router configuration.

To push an additional VLAN tag over the pseudowire:

  1. Create a dynamic profile named pw-tagged.
    user@host#set dynamic-profiles pw-tagged
  2. Specify the variables $junos-interface-ifd-name and $junos-underlying-interface-unit to be used by the router to match the interface name and the unit value of the receiving interface.
    [edit dynamic-profiles pw-tagged]user@host# set interfaces $junos-interface-ifd-name unit $junos-underlying-interface-unit
  3. Specify the VLAN tag to receive dual-tagged frames with an inner VLAN ID 100 and an outer VLAN ID 10.
    [edit dynamic-profiles pw-tagged interfaces "$junos-interface-ifd-name" unit "$junos-underlying-interface-unit"]user@host# set vlan-tags inner 100 outer 10
  4. Create a routing instance named red.
    [edit ]user@host# set routing-instances red instance-type vpls vlan-id 100 interface ge-0/0/0
  5. Associate the profile with the routing instance.
    [edit routing-instances red]user@host# set protocols vpls associate-profile pw-tagged

Verification

Verifying the Dynamic Profile Configuration

Purpose

Make sure that the dynamic profile is configured correctly.

Action

From configuration mode, enter the show dynamic-profiles command.

user@host# show dynamic-profiles

pw-tagged {interfaces {"$junos-interface-ifd-name" {unit "$junos-underlying-interface-unit" { vlan-tags inner 100 outer 10;}}}}

From configuration mode, enter the show routing-instances command.

user@host# show routing-instances

red {instance-type vpls;interface ge-0/0/0.0;vlan-id 100;protocols {vpls {associate-profile pw-tagged;}}}

Meaning

In the ingress direction, the pseudowire receives dual-tagged frames with an inner VLAN ID 100, and an outer VLAN ID 10. All other frames are dropped and the outer tag is stripped at the interface. In the egress direction, dual-tagged frames are transmitted with an inner VLAN ID 100 and an outer VLAN ID 10.

Published: 2013-02-11