Juniper vMX – Segment Routing L3VPN

You will need a trial license from Juniper for this lab, which can be obtained from the below URL.

https://www.juniper.net/gb/en/dm/vmx-trial-download.html

BGP is used between the CE & PE devices. Could use OSPF but would then need a sham link between CE devices to stop routes being shown as external routes.

https://www.juniper.net/gb/en/research-topics/what-is-segment-routing.html

PE1

set chassis network-services enhanced-ip
set interfaces ge-0/0/0 unit 0 family inet address 10.1.1.1/24
set interfaces ge-0/0/1 unit 0 family inet
set interfaces ge-0/0/2 unit 0 family inet address 1.1.1.1/30
set interfaces ge-0/0/2 unit 0 family iso
set interfaces ge-0/0/2 unit 0 family mpls
set interfaces lo0 unit 0 family inet address 5.5.5.5/32
set interfaces lo0 unit 0 family iso address 49.0000.5555.5555.5555.00
set interfaces lo0 unit 0 family mpls
set routing-options router-id 5.5.5.5
set routing-options autonomous-system 65400
set protocols mpls interface all
set protocols bgp group internal type internal
set protocols bgp group internal local-address 5.5.5.5
set protocols bgp group internal family inet unicast
set protocols bgp group internal family inet-vpn unicast
set protocols bgp group internal neighbor 8.8.8.8
set protocols isis source-packet-routing srgb start-label 800000
set protocols isis source-packet-routing srgb index-range 9000
set protocols isis source-packet-routing node-segment ipv4-index 500
set protocols isis level 1 disable
set protocols isis level 2 wide-metrics-only
set protocols isis interface ge-0/0/2.0
set protocols isis interface lo0.0
set routing-instances cust1 instance-type vrf
set routing-instances cust1 interface ge-0/0/0.0
set routing-instances cust1 route-distinguisher 5.5.5.5:1
set routing-instances cust1 vrf-target target:65400:1
set routing-instances cust1 vrf-table-label
set routing-instances cust1 protocols bgp group cust1 type external
set routing-instances cust1 protocols bgp group cust1 as-override
set routing-instances cust1 protocols bgp group cust1 neighbor 10.1.1.254 peer-as 65444

P1

set chassis network-services enhanced-ip
set interfaces ge-0/0/0 unit 0 family inet address 1.1.1.2/30
set interfaces ge-0/0/0 unit 0 family iso
set interfaces ge-0/0/0 unit 0 family mpls
set interfaces ge-0/0/1 unit 0 family inet address 2.2.2.1/30
set interfaces ge-0/0/1 unit 0 family iso
set interfaces ge-0/0/1 unit 0 family mpls
set interfaces lo0 unit 0 family inet address 6.6.6.6/32
set interfaces lo0 unit 0 family iso address 49.0000.6666.6666.6666.00
set interfaces lo0 unit 0 family mpls
set protocols mpls interface all
set protocols isis source-packet-routing srgb start-label 800000
set protocols isis source-packet-routing srgb index-range 9000
set protocols isis source-packet-routing node-segment ipv4-index 501
set protocols isis level 1 disable
set protocols isis level 2 wide-metrics-only
set protocols isis interface ge-0/0/0.0
set protocols isis interface ge-0/0/1.0
set protocols isis interface lo0.0

P2

set chassis network-services enhanced-ip
set interfaces ge-0/0/0 unit 0 family inet address 2.2.2.2/30
set interfaces ge-0/0/0 unit 0 family iso
set interfaces ge-0/0/0 unit 0 family mpls
set interfaces ge-0/0/1 unit 0 family inet address 3.3.3.1/30
set interfaces ge-0/0/1 unit 0 family iso
set interfaces ge-0/0/1 unit 0 family mpls
set interfaces lo0 unit 0 family inet address 33.33.33.33/32
set interfaces lo0 unit 0 family iso address 49.0000.3333.3333.0000.00
set interfaces lo0 unit 0 family mpls
set protocols mpls interface all
set protocols isis source-packet-routing srgb start-label 800000
set protocols isis source-packet-routing srgb index-range 9000
set protocols isis source-packet-routing node-segment ipv4-index 502
set protocols isis level 1 disable
set protocols isis level 2 wide-metrics-only
set protocols isis interface ge-0/0/0.0
set protocols isis interface ge-0/0/1.0
set protocols isis interface lo0.0

P3

set chassis network-services enhanced-ip
set interfaces ge-0/0/0 unit 0 family inet address 3.3.3.2/30
set interfaces ge-0/0/0 unit 0 family iso
set interfaces ge-0/0/0 unit 0 family mpls
set interfaces ge-0/0/1 unit 0 family inet address 4.4.4.1/30
set interfaces ge-0/0/1 unit 0 family iso
set interfaces ge-0/0/1 unit 0 family mpls
set interfaces lo0 unit 0 family inet address 7.7.7.7/32
set interfaces lo0 unit 0 family iso address 49.0000.7777.7777.7777.00
set interfaces lo0 unit 0 family mpls
set protocols mpls interface all
set protocols isis source-packet-routing srgb start-label 800000
set protocols isis source-packet-routing srgb index-range 9000
set protocols isis source-packet-routing node-segment ipv4-index 503
set protocols isis level 1 disable
set protocols isis level 2 wide-metrics-only
set protocols isis interface ge-0/0/0.0
set protocols isis interface ge-0/0/1.0
set protocols isis interface lo0.0

PE2

set chassis network-services enhanced-ip
set interfaces ge-0/0/0 unit 0 family inet address 10.10.10.1/24
set interfaces ge-0/0/2 unit 0 family inet address 4.4.4.2/30
set interfaces ge-0/0/2 unit 0 family iso
set interfaces ge-0/0/2 unit 0 family mpls
set interfaces lo0 unit 0 family inet address 8.8.8.8/32
set interfaces lo0 unit 0 family iso address 49.0000.8888.8888.8888.00
set interfaces lo0 unit 0 family mpls
set routing-options autonomous-system 65400
set protocols mpls interface all
set protocols bgp group internal type internal
set protocols bgp group internal local-address 8.8.8.8
set protocols bgp group internal family inet unicast
set protocols bgp group internal family inet-vpn unicast
set protocols bgp group internal neighbor 5.5.5.5
set protocols isis source-packet-routing srgb start-label 800000
set protocols isis source-packet-routing srgb index-range 9000
set protocols isis source-packet-routing node-segment ipv4-index 504
set protocols isis level 1 disable
set protocols isis interface ge-0/0/2.0
set protocols isis interface lo0.0
set routing-instances cust1 instance-type vrf
set routing-instances cust1 interface ge-0/0/0.0
set routing-instances cust1 route-distinguisher 8.8.8.8:1
set routing-instances cust1 vrf-target target:65400:1
set routing-instances cust1 vrf-table-label
set routing-instances cust1 protocols bgp group cust1 type external
set routing-instances cust1 protocols bgp group cust1 as-override
set routing-instances cust1 protocols bgp group cust1 neighbor 10.10.10.254 peer-as 65444

The L3VPN will now be up and the CE devices receiving routes from each other. You may need to reboot the vMX devices before you see the routes.

Leave a Reply

Your email address will not be published. Required fields are marked *