Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

Navigation
Guide That Contains This Content
[+] Expand All
[-] Collapse All

    Using MPLS Stitching with BGP to Connect Virtual Machines

    The stitching feature of Junos OS provides connectivity between virtual machines VMs) that reside either on opposite sides of data center routers or in different data centers. An external controller, programmed in the data-plane, assigns MPLS labels to both VMs and servers. Then, the signaled MPLS labels are used between the data center routers, generating static label-switched paths (LSPs), resolved over either BGP labeled unicast, RSVP or LDP, to provide the routes dictated by the labels.

    Requirements

    This example uses the following hardware and software components:

    • Two QFX5100 top-of-rack switches named Baby Dutchmen
    • Two MX480 routers named Coleman and Taxes
    • Two VMs configured on servers located on either side of the topology
    • Junos OS Release 14.1X53-D25

    Before you begin, be sure you have:

    • Configured VMs, one on each of two servers. The servers are located on either side of the topology as shown in Figure 1.
    • Installed two routers and two top-of-rack switches as shown in the topology shown in Figure 1.

    Overview

    This example shows MPLS stitching resolved over BGP from top-of-rack switch Baby to the top-of-rack switch Dutchmen through the routers named Coleman and Taxes.

    Table 1: Topology Components for Top-of-Rack Named Baby

    Interface

    Description

    ge-8/1/2

    Port on the switch Baby connected to the router Taxes

    ge-8/1/3

    Port on the switch Baby connected to the router Coleman

    ge-8/2/4

    Port on the switch Baby connected to a VM

    Table 2: Topology Components for Top-of-Rack Switch Dutchmen

    Interface

    Description

    ge-0/0/0

    Port on the top-of-rack switch Dutchmen connected to a VM

    ge-0/1/0

    Port on the top-of-rack switch Dutchmen connected to the router named R2

    ge-0/2/0

    Port on the top-of-rack switch Dutchmen connected to the router named R2

    Table 3: Topology Components for MX Series Router Named Coleman

    Interface

    Description

    ge-2/0/0

    Port on router named Coleman connected to top-of-rack switch named Baby

    ge-2/0/1

    Port on router named Coleman connected to top-of-rack switch named Baby

    ge-2/0/5

    Port on router named Coleman connected to top-of-rack switch named Dutchmen

    ge-2/0/6

    Port on router named Coleman connected to top-of-rack switch named Dutchmen

    Table 4: Topology Components for MX Series Router Named Taxes

    Interface

    Description

    ge-0/0/3

    Port on router named Taxes connected to router named Coleman

    ge-1/0/0

    Port on router named Taxes connected to router named Coleman

    ge-1/0/2

    Port on router named Taxes connected to top-of-rack switch named Dutchmen

    ge-1/2/0

    Port on router named Taxes connected to top-of-rack switch named Dutchmen

    Topology

    Figure 1: MPLS Stitching to Connect Virtual Machines

    MPLS Stitching to Connect
Virtual Machines

    Configuration

    To configure MPLS stitching, perform these tasks:

    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, copy and paste the commands into the CLI at the [edit] hierarchy level, and then enter commit from configuration mode.

    Configure the top-of-rack switch named Baby:

    set interfaces ge-8/1/2 unit 0 family inet address 2.1.1.1/24set interfaces ge-8/1/2 unit 0 family mplsset interfaces ge-8/1/3 unit 0 family inet address 2.1.2.1/24 set interfaces ge-8/1/3 unit 0 family mplsset interfaces ge-8/2/4 unit 0 family inet address 1.1.1.1/24 set interfaces ge-8/2/4 unit 0 family mplsset routing-options interface-routes rib-group inet inet0toinet3 set routing-options rib-groups inet0toinet3 import-rib inet.0 set routing-options rib-groups inet0toinet3 import-rib inet.3 set routing-options router-id 10.9.82.49 set routing-options autonomous-system 100set routing-options forwarding-table export pplbset protocols mpls static-label-switched-path static-to-ToR2 transit 1000000 next-hop 10.9.82.47 set protocols mpls static-label-switched-path static-to-ToR2 transit 1000000 stitch set protocols mpls interface all set protocols mpls interface fxp0.0 disable set protocols bgp group ibgp-R1 type internal set protocols bgp group ibgp-R1 local-address 10.9.82.49 set protocols bgp group ibgp-R1 family inet labeled-unicast rib inet.3 set protocols bgp group ibgp-R1 export advLo set protocols bgp group ibgp-R1 neighbor 10.9.82.46 set protocols ospf traffic-engineering set protocols ospf area 0.0.0.0 interface all set protocols ospf area 0.0.0.0 interface fxp0.0 disableset policy-options policy-statement advLo term lo0 from protocol direct set policy-options policy-statement advLo term lo0 from route-filter 10.9.82.49/32 exact set policy-options policy-statement advLo term lo0 then next-hop 2.1.1.1 set policy-options policy-statement advLo term lo0 then accept set policy-options policy-statement advLo term other then reject set policy-options policy-statement pplb then load-balance per-packet set policy-options policy-statement pplb then accept

    Configure the top-of-rack switch Dutchmen:

    set interfaces ge-0/0/0 unit 0 family inet address 5.1.1.1/24 set interfaces ge-0/0/0 unit 0 family mpls set interfaces ge-0/1/0 unit 0 family inet address 4.1.1.2/24 set interfaces ge-0/1/0 unit 0 family mpls set interfaces ge-0/2/0 unit 0 family inet address 4.1.2.2/24 set interfaces ge-0/2/0 unit 0 family mplsset routing-options interface-routes rib-group inet inet0toinet3 set routing-options rib-groups inet0toinet3 import-rib inet.0 set routing-options rib-groups inet0toinet3 import-rib inet.3 set routing-options router-id 10.9.82.47 set routing-options autonomous-system 102 set routing-options forwarding-table export pplbset protocols mpls static-label-switched-path to-server transit 1000001 next-hop 5.1.1.2 set protocols mpls static-label-switched-path to-server transit 1000001 pop set protocols mpls interface all set protocols mpls interface fxp0.0 disable set protocols bgp group ibgp-R2 type internal set protocols bgp group ibgp-R2 local-address 10.9.82.47 set protocols bgp group ibgp-R2 family inet labeled-unicast rib inet.3 set protocols bgp group ibgp-R2 export advLo set protocols bgp group ibgp-R2 neighbor 10.9.82.48 set protocols ospf traffic-engineering set protocols ospf area 0.0.0.0 interface all set protocols ospf area 0.0.0.0 interface fxp0.0 disableset policy-options policy-statement advLo term lo0 from protocol direct set policy-options policy-statement advLo term lo0 from route-filter 10.9.82.47/32 exact set policy-options policy-statement advLo term lo0 then next-hop 4.1.1.2 set policy-options policy-statement advLo term lo0 then accept set policy-options policy-statement advLo term other then reject set policy-options policy-statement pplb then load-balance per-packet set policy-options policy-statement pplb then accept

    Configure the MX Series router named Coleman:

    set interfaces ge-2/0/0 unit 0 family inet address 2.1.1.2/24 set interfaces ge-2/0/0 unit 0 family mpls set interfaces ge-2/0/1 unit 0 family inet address 2.1.2.2/24 set interfaces ge-2/0/5 unit 0 family inet address 3.1.1.1/24 set interfaces ge-2/0/5 unit 0 family mpls set interfaces ge-2/0/6 unit 0 family inet address 3.1.2.1/24 set interfaces ge-2/0/6 unit 0 family mplsset routing-options interface-routes rib-group inet inet0toinet3 set routing-options rib-groups inet0toinet3 import-rib inet.0 set routing-options rib-groups inet0toinet3 import-rib inet.3 set routing-options router-id 10.9.82.46 set routing-options autonomous-system 100 set routing-options forwarding-table export pplbset protocols mpls interface all set protocols mpls interface fxp0.0 disable set protocols bgp group ibgp-ToR1 type internal set protocols bgp group ibgp-ToR1 accept-remote-nexthop set protocols bgp group ibgp-ToR1 local-address 10.9.82.46 set protocols bgp group ibgp-ToR1 family inet labeled-unicast rib inet.3 set protocols bgp group ibgp-ToR1 export advToR2 set protocols bgp group ibgp-ToR1 export advLo set protocols bgp group ibgp-ToR1 neighbor 10.9.82.49 set protocols bgp group ebgp-R2 type external set protocols bgp group ebgp-R2 local-address 3.1.2.1 set protocols bgp group ebgp-R2 family inet labeled-unicast rib inet.3 set protocols bgp group ebgp-R2 peer-as 102 set protocols bgp group ebgp-R2 local-as 100 set protocols bgp group ebgp-R2 neighbor 3.1.2.2 as-override set protocols ospf traffic-engineering set protocols ospf area 0.0.0.0 interface all set protocols ospf area 0.0.0.0 interface fxp0.0 disable

    Configure the MX Series router named Taxes:

    set interfaces ge-0/0/3 unit 0 family inet address 3.1.1.2/24 set interfaces ge-0/0/3 unit 0 family mpls set interfaces ge-1/0/0 unit 0 family inet address 3.1.2.2/24 set interfaces ge-1/0/0 unit 0 family mpls set interfaces ge-1/0/2 unit 0 family inet address 4.1.1.1/24 set interfaces ge-1/0/2 unit 0 family mpls set interfaces ge-1/2/0 unit 0 family inet address 4.1.2.1/24 set interfaces ge-1/2/0 unit 0 family mplsset routing-options interface-routes rib-group inet inet0toinet3 set routing-options rib-groups inet0toinet3 import-rib inet.0 set routing-options rib-groups inet0toinet3 import-rib inet.3 set routing-options router-id 10.9.82.48 set routing-options autonomous-system 102 set routing-options forwarding-table export pplbset protocols mpls interface all set protocols mpls interface fxp0.0 disable set protocols bgp group ebgp-R1 type external set protocols bgp group ebgp-R1 local-address 3.1.2.2 set protocols bgp group ebgp-R1 family inet labeled-unicast rib inet.3 set protocols bgp group ebgp-R1 peer-as 100 set protocols bgp group ebgp-R1 local-as 102 set protocols bgp group ebgp-R1 neighbor 3.1.2.1 as-override set protocols bgp group ibgp-ToR2 type internal set protocols bgp group ibgp-ToR2 local-address 10.9.82.48 set protocols bgp group ibgp-ToR2 family inet labeled-unicast rib inet.3 set protocols bgp group ibgp-ToR2 export advToR2 set protocols bgp group ibgp-ToR2 export advLo set protocols bgp group ibgp-ToR2 neighbor 10.9.82.47 set protocols ospf traffic-engineering set protocols ospf area 0.0.0.0 interface all set protocols ospf area 0.0.0.0 interface fxp0.0 disableset policy-options policy-statement advLo term lo0 from protocol direct set policy-options policy-statement advLo term lo0 from route-filter 10.9.82.48/32 exact set policy-options policy-statement advLo term lo0 then next-hop 4.1.1.1 set policy-options policy-statement advLo term lo0 then accept set policy-options policy-statement advLo term other then reject set policy-options policy-statement advToR2 term ToR2lo from protocol bgp set policy-options policy-statement advToR2 term ToR2lo from route-filter 10.9.82.48/32 exact set policy-options policy-statement advToR2 term ToR2lo then accept set policy-options policy-statement pplb then load-balance per-packet set policy-options policy-statement pplb then accept

    Configuring Stitching on Top-of-Rack Switch Named Baby

    Step-by-Step Procedure

    To configure stitching on the top-of-rack switch named Baby, follow these steps:

    1. Configure three MPLS interfaces on top-of-rack switch named Baby.
      user@baby# [edit interfaces]user@baby# set ge-8/1/2 unit 0 family inet address 2.1.1.1/24 user@baby# set ge-8/1/2 unit 0 family mplsuser@baby# set ge-8/1/3 unit 0 family inet address 2.1.2.1/24 user@baby# set ge-8/1/3 unit 0 family mplsuser@baby# set ge-8/2/4 unit 0 family inet address 1.1.1.1/24 user@baby# set ge-8/2/4 unit 0 family mpls
    2. Configure routing options on top-of-rack switch named Baby.
      user@baby# [edit routing-options] user@baby# set interface-routes rib-group inet inet0toinet3 user@baby# set rib-groups inet0toinet3 import-rib inet.0user@baby# set rib-groups inet0toinet3 import-rib inet.3user@baby# set router-id 10.9.82.49user@baby# set autonomous-system 100user@baby# set forwarding-table export pplb
    3. Configure the protocols MPLS, BGP, and OSPF on top-of-rack switch named Baby.
      user@baby# edit [protocols mpls]user@baby# set static-label-switched-path static-to-ToR2 transit 1000000 next-hop 10.9.82.47user@baby# set static-label-switched-path static-to-ToR2 transit 1000000 next-hop 10.9.82.47user@baby# set static-label-switched-path static-to-ToR2 transit 1000000 stitchset interface all set mpls interface fxp0.0 disableuser@baby# edit [protocols bgp group ibgp-R1] user@baby# set type internaluser@baby# set local-address 10.9.82.49user@baby# set family inet labeled-unicast rib inet.3user@baby# set export advLouser@baby# set neighbor 10.9.82.46user@baby# edit [protocols ospf] user@baby#set traffic-engineeringuser@baby# set area 0.0.0.0 interface alluser@baby# set area 0.0.0.0 interface fxp0.0 disable
    4. Configure policy options on top-of-rack switch named Baby.
      user@baby# [edit policy-options policy-statement advLo] user@baby# set term lo0 from protocol direct user@baby# set term lo0 from route-filter 10.9.82.49/32 exactuser@baby# set term lo0 then next-hop 2.1.1.1user@baby# set term lo0 then acceptuser@baby# set term other then reject user@baby# [edit policy-options policy-statement pplb]user@baby# set then load-balance per-packet user@baby# set then accept

    Configuring Stitching on Top-of-Rack Switch Named Dutchmen

    Step-by-Step Procedure

    To configure stitching on the top-of-rack switch named Dutchmen, follow these steps:

    1. Configure three MPLS interfaces on the top-of-rack switch Dutchmen.
      user@dutchmen# [edit interfaces] user@dutchmen# set ge-0/0/0 unit 0 family inet address 5.1.1.1/24user@dutchmen# set ge-0/0/0 unit 0 family mplsuser@dutchmen# set ge-0/1/0 unit 0 family inet address 4.1.1.2/24user@dutchmen# set ge-0/1/0 unit 0 family mpls user@dutchmen# set ge-0/2/0 unit 0 family inet address 4.1.2.2/24user@dutchmen# set ge-0/2/0 unit 0 family mpls
    2. Configure routing options on the top-of-rack switch Dutchmen.
      user@dutchmen# [edit routing-options] user@dutchmen# set interface-routes rib-group inet inet0toinet3user@dutchmen# set rib-groups inet0toinet3 import-rib inet.0 user@dutchmen# set rib-groups inet0toinet3 import-rib inet.3user@dutchmen# set router-id 10.9.82.47user@dutchmen# set autonomous-system 102user@dutchmen# set forwarding-table export pplb
    3. Configure the protocols MPLS, BGP, and OSPF on the top-of-rack switch Dutchmen.
      user@dutchmen# edit [protocols mpls] user@dutchmen# set static-label-switched-path to-server transit 1000001 next-hop 5.1.1.2user@dutchmen# set static-label-switched-path to-server transit 1000001 popuser@dutchmen# set interface alluser@dutchmen# set interface fxp0.0 disableuser@dutchmen# edit [protocols bgp group ibgp-R2] user@dutchmen# set type internaluser@dutchmen# set local-address 10.9.82.47user@dutchmen# set family inet labeled-unicast rib inet.3user@dutchmen# set export advLouser@dutchmen# set neighbor 10.9.82.48user@dutchmen# edit [protocols ospf] user@dutchmen# set traffic-engineering user@dutchmen# set area 0.0.0.0 interface all user@dutchmen# set area 0.0.0.0 interface fxp0.0 disable
    4. Configure policy options on the top-of-rack switch Dutchmen.
      user@dutchmen# edit [policy-options policy-statement advLo] user@dutchmen# set term lo0 from protocol directuser@dutchmen# set term lo0 from route-filter 10.9.82.47/32 exactuser@dutchmen# set term lo0 then next-hop 4.1.1.2user@dutchmen# set term lo0 then acceptuser@dutchmen# set term other then rejectuser@dutchmen# edit [policy-options policy-statement pplb] set then load-balance per-packet set then accept

    Step-by-Step Procedure

    To configure the MX Series router named Coleman, follow these steps:

    1. Configure four interfaces on the router named Coleman.
      [edit interfaces] user@coleman# set ge-2/0/0 unit 0 family inet address 2.1.1.2/24user@coleman# set ge-2/0/0 unit 0 family mplsuser@coleman# set ge-2/0/1 unit 0 family inet address 2.1.2.2/24user@coleman# set ge-2/0/5 unit 0 family inet address 3.1.1.1/24user@coleman# set ge-2/0/5 unit 0 family mplsuser@coleman# set ge-2/0/6 unit 0 family inet address 3.1.2.1/24user@coleman# set ge-2/0/6 unit 0 family mpls
    2. Configure routing options on the router named Coleman.
      [edit routing-options] user@coleman# set interface-routes rib-group inet inet0toinet3user@coleman# set rib-groups inet0toinet3 import-rib inet.0user@coleman# set rib-groups inet0toinet3 import-rib inet.3user@coleman# set router-id 10.9.82.46user@coleman# set autonomous-system 100 set routing-options forwarding-table export pplb
    3. Configure the protocols MPLS, BGP, and OSPF on on the router named Coleman.
      [edit protocols mpls] user@coleman# set interface alluser@coleman# set interface fxp0.0 disable[edit protocols bgp group ibgp-ToR1] user@coleman# set type internaluser@coleman# set accept-remote-nexthopuser@coleman# set local-address 10.9.82.46user@coleman# set family inet labeled-unicast rib inet.3user@coleman# set export advToR2user@coleman# set export advLouser@coleman# set neighbor 10.9.82.49[edit protocols bgp group ebgp-R2] user@coleman# set type external user@coleman# set local-address 3.1.2.1user@coleman# set family inet labeled-unicast rib inet.3user@coleman# set peer-as 102user@coleman# set local-as 100user@coleman# set neighbor 3.1.2.2 as-override[edit protocols ospf] user@coleman# set traffic-engineeringuser@coleman# set area 0.0.0.0 interface alluser@coleman# set area 0.0.0.0 interface fxp0.0 disable
    4. Configure the policy options on the router named Coleman.
      [edit policy-options policy-statement advLo] user@coleman# set term lo0 from protocol directuser@coleman# set term lo0 from route-filter 10.9.82.46/32 exactuser@coleman# set term lo0 then next-hop 2.1.1.2user@coleman# set term lo0 then acceptuser@coleman# set term other then reject
      [edit policy-options policy-statement advToR2 ] user@coleman# set term ToR2lo from protocol bgpuser@coleman# set term ToR2lo from protocol bgp then acceptuser@coleman# set term ToR2lo from route-filter 10.9.82.47/32 exactuser@coleman# set term ToR2lo then accept
      [edit policy-options policy-statement pplb] user@coleman# set then load-balance per-packetuser@coleman# set then accept

    Configuring MX Series Router Named Taxes

    Step-by-Step Procedure

    To configure the MX Series router named Taxes, follow these steps:

    1. Configure four MPLS interfaces on the router named Taxes.
      user@taxes# [edit interfaces] user@taxes# set ge-0/0/3 unit 0 family inet address 3.1.1.2/24user@taxes# set ge-0/0/3 unit 0 family mpls user@taxes# set ge-1/0/0 unit 0 family inet address 3.1.2.2/24user@taxes# set ge-1/0/0 unit 0 family mplsuser@taxes# set ge-1/0/2 unit 0 family inet address 4.1.1.1/24user@taxes# set ge-1/0/2 unit 0 family mplsuser@taxes# set ge-1/2/0 unit 0 family inet address 4.1.2.1/24user@taxes# set ge-1/2/0 unit 0 family mpls
    2. Configure routing options on the router named Taxes.
      [edit routing-options] user@taxes#set interface-routes rib-group inet inet0toinet3user@taxes#set rib-groups inet0toinet3 import-rib inet.0 user@taxes#set rib-groups inet0toinet3 import-rib inet.3user@taxes#set router-id 10.9.82.48user@taxes#set autonomous-system 102user@taxes#set forwarding-table export pplb
    3. Configure the protocols MPLS, BGP, and OSPF on the router named Taxes.
      user@taxes# [edit protocols mpls]user@taxes# set interface alluser@taxes# set interface fxp0.0 disableuser@taxes# [edit protocols bgp group ebgp-R1]user@taxes# set type externaluser@taxes# set local-address 3.1.2.2user@taxes# set family inet labeled-unicast rib inet.3user@taxes# set peer-as 100user@taxes# set local-as 102user@taxes# set neighbor 3.1.2.1 as-overrideuser@taxes# [edit protocols bgp group ibgp-ToR2]user@taxes# set type internaluser@taxes# set local-address 10.9.82.48user@taxes# set family inet labeled-unicast rib inet.3user@taxes# set export advToR2 user@taxes# set export advLo user@taxes# set neighbor 10.9.82.47user@taxes# [edit protocols ospf]user@taxes# set traffic-engineeringuser@taxes# set area 0.0.0.0 interface alluser@taxes# set area 0.0.0.0 interface fxp0.0 disable
    4. Configure policy options on the router named Taxes.
      user@taxes# [edit policy-options policy-statement advLo] user@taxes# set term lo0 from protocol direct user@taxes# set term lo0 from route-filter 10.9.82.48/32 exactuser@taxes# set term lo0 then next-hop 4.1.1.1user@taxes# set term lo0 then accept user@taxes# set term other then rejectuser@taxes# [edit policy-options policy-statement pplb]user@taxes# set then load-balance per-packetuser@taxes# set then accept

    Results

    Check the MPLS configuration on the top-of-rack switch Baby by using the show mpls protocol command.

    user@baby# show mpls protocol
    interfaces {
        ge-8/1/2 {
            unit 0 {
                family inet {
                    address 2.1.1.1/24;
                }
                family mpls;
            }
        }
        ge-8/1/3 {
            unit 0 {
                family inet {
                    address 2.1.2.1/24;
                }
                family mpls;
            }
        }
        ge-8/2/4 {
            unit 0 {
                family inet {
                    address 1.1.1.1/24;
                }
                family mpls;
            }
        }
    }
    routing-options {
        interface-routes {
            rib-group inet inet0toinet3;
        }
        rib-groups {
            inet0toinet3 {
                import-rib [ inet.0 inet.3 ];
            }
        }
        router-id 10.9.82.49;
        autonomous-system 100;
        forwarding-table {
            export pplb;
        }
    }
    protocols {
        mpls {
            static-label-switched-path static-to-ToR2 {
                transit 1000000 {
                    next-hop 10.9.82.47;
                    stitch;
                }
            }
            interface all;
            interface fxp0.0 {
                disable;
            }
        }
        bgp {
            group ibgp-R1 {
                type internal;
                local-address 10.9.82.49;
                family inet {
                    labeled-unicast {
                        rib {
                            inet.3;
                        }
                    }
                }
                export advLo;
                neighbor 10.9.82.46;
            }
        }
        ospf {
            traffic-engineering;
            area 0.0.0.0 {
                interface all;
                interface fxp0.0 {
                    disable;
                }
            }
        }
    }
    policy-options {
        policy-statement advLo {
            term lo0 {
                from {
                    protocol direct;
                    route-filter 10.9.82.49/32 exact;
                }
                then {
                    next-hop 2.1.1.1;
                    accept;
                }
            }
            term other {
                then reject;
            }
        }
        policy-statement pplb {
            then {
                load-balance per-packet;
                accept;
            }
        }
    }
    

    Check the MPLS configuration on the top-of-rack switch Coleman by using the show mpls protocol command.

    user@coleman# show mpls protocol
    interfaces {
        ge-2/0/0 {
            unit 0 {
                family inet {
                    address 2.1.1.2/24;
                }
                family mpls;
            }
        }
        ge-2/0/1 {
            unit 0 {
                family inet {
                    address 2.1.2.2/24;
                }
            }
        }
        ge-2/0/5 {
            unit 0 {
                family inet {
                    address 3.1.1.1/24;
                }
                family mpls;
            }
        }
        ge-2/0/6 {
            unit 0 {
                family inet {
                    address 3.1.2.1/24;
                }
                family mpls;
            }
        }
    }
    routing-options {
        interface-routes {
            rib-group inet inet0toinet3;
        }
        rib-groups {
            inet0toinet3 {
                import-rib [ inet.0 inet.3 ];
            }
        }
        router-id 10.9.82.46;
        autonomous-system 100;
        forwarding-table {
            export pplb;
        }
    }
    protocols {
        mpls {
            interface all;
            interface fxp0.0 {
                disable;
            }
        }
        bgp {
            group ibgp-ToR1 {
                type internal;
                accept-remote-nexthop;
                local-address 10.9.82.46;
                family inet {
                    labeled-unicast {
                        rib {
                            inet.3;
                        }
                    }
                }
                export [ advToR2 advLo ];
                neighbor 10.9.82.49;
            }
            group ebgp-R2 {
                type external;
                local-address 3.1.2.1;
                family inet {
                    labeled-unicast {
                        rib {
                            inet.3;
                        }
                    }
                }
                peer-as 102;
                local-as 100;
                neighbor 3.1.2.2 {
                    as-override;
                }
            }
        }
        ospf {
            traffic-engineering;
            area 0.0.0.0 {
                interface all;
                interface fxp0.0 {
                    disable;
                }
            }
        }
    }
    policy-options {
        policy-statement advLo {
            term lo0 {
                from {
                    protocol direct;
                    route-filter 10.9.82.46/32 exact;
                }
                then {
                    next-hop 2.1.1.2;
                    accept;
                }
            }
            term other {
                then reject;
            }
        }
        policy-statement advToR2 {
            term ToR2lo {
                from {
                    protocol bgp;
                    route-filter 10.9.82.47/32 exact;
                }
                then accept;
            }
        }
        policy-statement pplb {
            then {
                load-balance per-packet;
                accept;
            }
        }
    }
    
    

    Check the MPLS configuration on the router named Taxes by using the show mpls protocols command:

    user@taxes# show mpls protocol
    interfaces {
        ge-0/0/3 {
            unit 0 {
                family inet {
                    address 3.1.1.2/24;
                }
                family mpls;
            }
        }
        ge-1/0/0 {
            unit 0 {
                family inet {
                    address 3.1.2.2/24;
                }
                family mpls;
            }
        }
        ge-1/0/2 {
            unit 0 {
                family inet {
                    address 4.1.1.1/24;
                }
                family mpls;
            }
        }
        ge-1/2/0 {
            unit 0 {
                family inet {
                    address 4.1.2.1/24;
                }
                family mpls;
            }
        }
    }
    routing-options {
        interface-routes {
            rib-group inet inet0toinet3;
        }
        rib-groups {
            inet0toinet3 {
                import-rib [ inet.0 inet.3 ];
            }
        }
        router-id 10.9.82.48;
        autonomous-system 102;
        forwarding-table {
            export pplb;
        }
    }
    protocols {
        mpls {
            interface all;
            interface fxp0.0 {
                disable;
            }
        }
        bgp {
            group ebgp-R1 {
                type external;
                local-address 3.1.2.2;
                family inet {
                    labeled-unicast {
                        rib {
                            inet.3;
                        }
                    }
                }
                peer-as 100;
                local-as 102;
                neighbor 3.1.2.1 {
                    as-override;
                }
            }
            group ibgp-ToR2 {
                type internal;
                local-address 10.9.82.48;
                family inet {
                    labeled-unicast {
                        rib {
                            inet.3;
                        }
                    }
                }
                export [ advToR2 advLo ];
                neighbor 10.9.82.47;
            }
        }
        ospf {
            traffic-engineering;
            area 0.0.0.0 {
                interface all;
                interface fxp0.0 {
                    disable;
                }
            }
        }
    }
    policy-options {
        policy-statement advLo {
            term lo0 {
                from {
                    protocol direct;
                    route-filter 10.9.82.48/32 exact;
                }
                then {
                    next-hop 4.1.1.1;
                    accept;
                }
            }
            term other {
                then reject;
            }
        }
        policy-statement advToR2 {
            term ToR2lo {
                from {
                    protocol bgp;
                    route-filter 10.9.82.47/32 exact;
                }
                then accept;
            }
        }
        policy-statement pplb {
            then {
                load-balance per-packet;
                accept;
            }
        }
    }
    

    Check the MPLS configuration on the router named Dutchmen by using the show mpls protocols command:

    user@dutchmen# show mpls protocol
    interfaces {
        ge-0/0/0 {
            unit 0 {
                family inet {
                    address 5.1.1.1/24;
                }
                family mpls;
            }
        }
        ge-0/1/0 {
            unit 0 {
                family inet {
                    address 4.1.1.2/24;
                }
                family mpls;
            }
        }
        ge-0/2/0 {
            unit 0 {
                family inet {
                    address 4.1.2.2/24;
                }
                family mpls;
            }
        }
    }
    routing-options {
        interface-routes {
            rib-group inet inet0toinet3;
        }
        rib-groups {
            inet0toinet3 {
                import-rib [ inet.0 inet.3 ];
            }
        }
        router-id 10.9.82.47;
        autonomous-system 102;
        forwarding-table {
            export pplb;
        }
    }
    protocols {
        mpls {
            static-label-switched-path to-server {
                transit 1000001 {
                    next-hop 5.1.1.2;
                    pop;
                }
            }
            interface all;
            interface fxp0.0 {
                disable;
            }
        }
        bgp {
            group ibgp-R2 {
                type internal;
                local-address 10.9.82.47;
                family inet {
                    labeled-unicast {
                        rib {
                            inet.3;
                        }
                    }
                }
                export advLo;
                neighbor 10.9.82.48;
            }
        }
        ospf {
            traffic-engineering;
            area 0.0.0.0 {
                interface all;
                interface fxp0.0 {
                    disable;
                }
            }
        }
    }
    policy-options {
        policy-statement advLo {
            term lo0 {
                from {
                    protocol direct;
                    route-filter 10.9.82.47/32 exact;
                }
                then {
                    next-hop 4.1.1.2;
                    accept;
                }
            }
            term other {
                then reject;
            }
        }
        policy-statement pplb {
            then {
                load-balance per-packet;
                accept;
            }
        }
    }
    

    Check the MPLS configuration on the top-of-rack switch Coleman by using the show mpls command.

    user@coleman# show mpls protocol
    interfaces {
        ge-2/0/0 {
            unit 0 {
                family inet {
                    address 2.1.1.2/24;
                }
                family mpls;
            }
        }
        ge-2/0/1 {
            unit 0 {
                family inet {
                    address 2.1.2.2/24;
                }
            }
        }
        ge-2/0/5 {
            unit 0 {
                family inet {
                    address 3.1.1.1/24;
                }
                family mpls;
            }
        }
        ge-2/0/6 {
            unit 0 {
                family inet {
                    address 3.1.2.1/24;
                }
                family mpls;
            }
        }
    }
    routing-options {
        interface-routes {
            rib-group inet inet0toinet3;
        }
        rib-groups {
            inet0toinet3 {
                import-rib [ inet.0 inet.3 ];
            }
        }
        router-id 10.9.82.46;
        autonomous-system 100;
        forwarding-table {
            export pplb;
        }
    }
    protocols {
        mpls {
            interface all;
            interface fxp0.0 {
                disable;
            }
        }
        bgp {
            group ibgp-ToR1 {
                type internal;
                accept-remote-nexthop;
                local-address 10.9.82.46;
                family inet {
                    labeled-unicast {
                        rib {
                            inet.3;
                        }
                    }
                }
                export [ advToR2 advLo ];
                neighbor 10.9.82.49;
            }
            group ebgp-R2 {
                type external;
                local-address 3.1.2.1;
                family inet {
                    labeled-unicast {
                        rib {
                            inet.3;
                        }
                    }
                }
                peer-as 102;
                local-as 100;
                neighbor 3.1.2.2 {
                    as-override;
                }
            }
        }
        ospf {
            traffic-engineering;
            area 0.0.0.0 {
                interface all;
                interface fxp0.0 {
                    disable;
                }
            }
        }
    }
    policy-options {
        policy-statement advLo {
            term lo0 {
                from {
                    protocol direct;
                    route-filter 10.9.82.46/32 exact;
                }
                then {
                    next-hop 2.1.1.2;
                    accept;
                }
            }
            term other {
                then reject;
            }
        }
        policy-statement advToR2 {
            term ToR2lo {
                from {
                    protocol bgp;
                    route-filter 10.9.82.47/32 exact;
                }
                then accept;
            }
        }
        policy-statement pplb {
            then {
                load-balance per-packet;
                accept;
            }
        }
    }
    
    

    Check the MPLS configuration on the router Taxes by using the show mpls protocols command:

    user@taxes# show mpls protocol
    interfaces {
        ge-0/0/3 {
            unit 0 {
                family inet {
                    address 3.1.1.2/24;
                }
                family mpls;
            }
        }
        ge-1/0/0 {
            unit 0 {
                family inet {
                    address 3.1.2.2/24;
                }
                family mpls;
            }
        }
        ge-1/0/2 {
            unit 0 {
                family inet {
                    address 4.1.1.1/24;
                }
                family mpls;
            }
        }
        ge-1/2/0 {
            unit 0 {
                family inet {
                    address 4.1.2.1/24;
                }
                family mpls;
            }
        }
    }
    routing-options {
        interface-routes {
            rib-group inet inet0toinet3;
        }
        rib-groups {
            inet0toinet3 {
                import-rib [ inet.0 inet.3 ];
            }
        }
        router-id 10.9.82.48;
        autonomous-system 102;
        forwarding-table {
            export pplb;
        }
    }
    protocols {
        mpls {
            interface all;
            interface fxp0.0 {
                disable;
            }
        }
        bgp {
            group ebgp-R1 {
                type external;
                local-address 3.1.2.2;
                family inet {
                    labeled-unicast {
                        rib {
                            inet.3;
                        }
                    }
                }
                peer-as 100;
                local-as 102;
                neighbor 3.1.2.1 {
                    as-override;
                }
            }
            group ibgp-ToR2 {
                type internal;
                local-address 10.9.82.48;
                family inet {
                    labeled-unicast {
                        rib {
                            inet.3;
                        }
                    }
                }
                export [ advToR2 advLo ];
                neighbor 10.9.82.47;
            }
        }
        ospf {
            traffic-engineering;
            area 0.0.0.0 {
                interface all;
                interface fxp0.0 {
                    disable;
                }
            }
        }
    }
    policy-options {
        policy-statement advLo {
            term lo0 {
                from {
                    protocol direct;
                    route-filter 10.9.82.48/32 exact;
                }
                then {
                    next-hop 4.1.1.1;
                    accept;
                }
            }
            term other {
                then reject;
            }
        }
        policy-statement advToR2 {
            term ToR2lo {
                from {
                    protocol bgp;
                    route-filter 10.9.82.47/32 exact;
                }
                then accept;
            }
        }
        policy-statement pplb {
            then {
                load-balance per-packet;
                accept;
            }
        }
    }
    

    Check the MPLS configuration on the router Dutchmen by using the show mpls protocols command:

    show mpls protocol??
    interfaces {
        ge-0/0/0 {
            unit 0 {
                family inet {
                    address 5.1.1.1/24;
                }
                family mpls;
            }
        }
        ge-0/1/0 {
            unit 0 {
                family inet {
                    address 4.1.1.2/24;
                }
                family mpls;
            }
        }
        ge-0/2/0 {
            unit 0 {
                family inet {
                    address 4.1.2.2/24;
                }
                family mpls;
            }
        }
    }
    routing-options {
        interface-routes {
            rib-group inet inet0toinet3;
        }
        rib-groups {
            inet0toinet3 {
                import-rib [ inet.0 inet.3 ];
            }
        }
        router-id 10.9.82.47;
        autonomous-system 102;
        forwarding-table {
            export pplb;
        }
    }
    protocols {
        mpls {
            static-label-switched-path to-server {
                transit 1000001 {
                    next-hop 5.1.1.2;
                    pop;
                }
            }
            interface all;
            interface fxp0.0 {
                disable;
            }
        }
        bgp {
            group ibgp-R2 {
                type internal;
                local-address 10.9.82.47;
                family inet {
                    labeled-unicast {
                        rib {
                            inet.3;
                        }
                    }
                }
                export advLo;
                neighbor 10.9.82.48;
            }
        }
        ospf {
            traffic-engineering;
            area 0.0.0.0 {
                interface all;
                interface fxp0.0 {
                    disable;
                }
            }
        }
    }
    policy-options {
        policy-statement advLo {
            term lo0 {
                from {
                    protocol direct;
                    route-filter 10.9.82.47/32 exact;
                }
                then {
                    next-hop 4.1.1.2;
                    accept;
                }
            }
            term other {
                then reject;
            }
        }
        policy-statement pplb {
            then {
                load-balance per-packet;
                accept;
            }
        }
    }
    

    Modified: 2016-12-07