Example: Enabling MPLS

This example shows how to enable MPLS for packet-based processing. It also shows how to enable the MPLS family and MPLS process on all of the transit interfaces in the network.

Requirements

Before you begin, delete all configured security services. See Example: Deleting Security Services.

Overview

The instructions in this topic describe how to enable MPLS on the device. You must enable MPLS on the device before including a device running Junos OS in an MPLS network.

Configuration

CLI Quick Configuration

To quickly enable MPLS on the device, copy the following commands and paste them into the CLI.

[edit]set security forwarding-options family mpls mode packet-basedset interfaces ge-1/0/0 unit 0 family mpls set protocols mpls interface all

Step-by-Step Procedure

The following example requires you to navigate various levels in the configuration hierarchy. For instructions on how to do that, see Using the CLI Editor in Configuration Mode.

To enable MPLS:

  1. Enable MPLS for packet-based processing.
    [edit security forwarding-options]user@host# set family mpls mode packet-based
  2. Enable the MPLS family on each transit interface that you want to include in the MPLS network.
    [edit interfaces]user@host# set interfaces ge-1/0/0 unit 0 family mpls
  3. Enable the MPLS process on all of the transit interfaces in the MPLS network.
    [edit protocols mpls]user@host# set interface all

Results

From configuration mode, confirm your configuration by entering the show security forwarding-options command. If the output does not display the intended configuration, repeat the configuration instructions in this example to correct it.

Caution: If you disable MPLS and switch back to using the security services (flow-based processing), we recommend that you restart your router. Management sessions are reset, and transit traffic is interrupted.

[edit]user@host# show security forwarding-optionsfamily {mpls {mode packet-based;}}

If you are done configuring the device, enter commit from configuration mode.

Verification

To confirm that the configuration is working properly, perform these tasks:

Verifying MPLS Is Enabled at the Protocols Level

Purpose

Verify that MPLS is enabled at the protocols level.

Action

From operational mode, enter the show protocols command.

Verifying MPLS Is Enabled at the Interfaces Level.

Purpose

Verify that MPLS is enabled at the interfaces level.

Action

From operational mode, enter the show interfaces command.

Related Topics