hostname R1
interface GigabitEthernet 0/0
no switchport
ip address 12.0.0.1 255.255.255.0
interface GigabitEthernet 0/2
interface Loopback 0
ip address 1.1.1.1 255.255.255.255
router bgp 1
bgp log-neighbor-changes
bgp graceful-restart restart-time 120
bgp graceful-restart stalepath-time 360
bgp graceful-restart
neighbor 12.0.0.2 remote-as 100
address-family ipv4
network 1.1.1.1 mask 255.255.255.255
neighbor 12.0.0.2 activate
exit-address-family
hostname R2
ip vrf 1
rd 1:100
route-target export 100:200
route-target import 200:100
mpls ip
interface GigabitEthernet 0/0
no switchport
ip vrf forwarding 1
ip address 12.0.0.2 255.255.255.0
interface GigabitEthernet 0/1
no switchport
ip address 23.0.0.2 255.255.255.0
ip ospf 100 area 0
mpls ip
label-switching
interface Loopback 0
ip address 2.2.2.2 255.255.255.255
ip ospf 100 area 0
router bgp 100
bgp log-neighbor-changes
bgp graceful-restart restart-time 120
bgp graceful-restart stalepath-time 360
bgp graceful-restart
neighbor 4.4.4.4 remote-as 100
neighbor 4.4.4.4 update-source Loopback 0
neighbor 7.7.7.7 remote-as 200
neighbor 7.7.7.7 ebgp-multihop 255
neighbor 7.7.7.7 update-source Loopback 0
address-family ipv4
neighbor 4.4.4.4 activate
neighbor 4.4.4.4 next-hop-self
neighbor 4.4.4.4 send-label
no neighbor 7.7.7.7 activate
exit-address-family
address-family vpnv4 unicast
neighbor 7.7.7.7 activate
neighbor 7.7.7.7 send-community extended
exit-address-family
address-family ipv4 vrf 1
network 1.1.1.1 mask 255.255.255.255
neighbor 12.0.0.1 remote-as 1
neighbor 12.0.0.1 activate
exit-address-family
router ospf 100
graceful-restart
mpls router ldp
ldp router-id interface Loopback 0
graceful-restart
hostname R3
mpls ip
interface GigabitEthernet 0/0
no switchport
ip address 23.0.0.3 255.255.255.0
ip ospf 100 area 0
mpls ip
label-switching
interface GigabitEthernet 0/1
no switchport
ip address 34.0.0.3 255.255.255.0
ip ospf 100 area 0
mpls ip
label-switching
interface Loopback 0
ip address 3.3.3.3 255.255.255.255
ip ospf 100 area 0
router ospf 100
graceful-restart
mpls router ldp
ldp router-id interface Loopback 0
graceful-restart
hostname R4
mpls ip
interface GigabitEthernet 0/0
no switchport
ip address 34.0.0.4 255.255.255.0
ip ospf 100 area 0
mpls ip
label-switching
interface GigabitEthernet 0/1
no switchport
ip address 45.0.0.4 255.255.255.0
label-switching
interface Loopback 0
ip address 4.4.4.4 255.255.255.255
ip ospf 100 area 0
router bgp 100
bgp log-neighbor-changes
bgp graceful-restart restart-time 120
bgp graceful-restart stalepath-time 360
bgp graceful-restart
neighbor 2.2.2.2 remote-as 100
neighbor 2.2.2.2 update-source Loopback 0
neighbor 45.0.0.5 remote-as 200
address-family ipv4
network 2.2.2.2 mask 255.255.255.255
neighbor 2.2.2.2 activate
neighbor 2.2.2.2 next-hop-self
neighbor 2.2.2.2 send-label
neighbor 45.0.0.5 activate
neighbor 45.0.0.5 send-label
exit-address-family
router ospf 100
graceful-restart
mpls router ldp
ldp router-id interface Loopback 0
graceful-restart
hostname R5
mpls ip
interface GigabitEthernet 0/0
no switchport
ip address 45.0.0.5 255.255.255.0
label-switching
interface GigabitEthernet 0/1
no switchport
ip address 56.0.0.5 255.255.255.0
ip router isis 200
mpls ip
label-switching
interface Loopback 0
ip address 5.5.5.5 255.255.255.255
ip router isis 200
router bgp 200
bgp log-neighbor-changes
bgp graceful-restart restart-time 120
bgp graceful-restart stalepath-time 360
bgp graceful-restart
neighbor 7.7.7.7 remote-as 200
neighbor 7.7.7.7 update-source Loopback 0
neighbor 45.0.0.4 remote-as 100
address-family ipv4
network 7.7.7.7 mask 255.255.255.255
neighbor 7.7.7.7 activate
neighbor 7.7.7.7 next-hop-self
neighbor 7.7.7.7 send-label
neighbor 45.0.0.4 activate
neighbor 45.0.0.4 send-label
exit-address-family
router isis 200
net 49.0050.0500.5005.00
graceful-restart
mpls router ldp
ldp router-id interface Loopback 0
graceful-restart
hostname R6
mpls ip
interface GigabitEthernet 0/0
no switchport
ip address 56.0.0.6 255.255.255.0
ip router isis 200
mpls ip
label-switching
interface GigabitEthernet 0/1
no switchport
ip address 67.0.0.6 255.255.255.0
ip router isis 200
mpls ip
label-switching
interface Loopback 0
ip address 6.6.6.6 255.255.255.255
ip router isis 200
router bgp 200
bgp log-neighbor-changes
bgp graceful-restart restart-time 120
bgp graceful-restart stalepath-time 360
bgp graceful-restart
address-family ipv4
exit-address-family
router isis 200
net 49.0060.0600.6006.00
graceful-restart
mpls router ldp
ldp router-id interface Loopback 0
graceful-restart
hostname R7
ip vrf 1
rd 200:8
route-target export 200:100
route-target import 100:200
mpls ip
interface GigabitEthernet 0/0
no switchport
ip address 67.0.0.7 255.255.255.0
ip router isis 200
mpls ip
label-switching
interface GigabitEthernet 0/1
no switchport
ip vrf forwarding 1
ip address 78.0.0.7 255.255.255.0
interface GigabitEthernet 0/9
interface Loopback 0
ip address 7.7.7.7 255.255.255.255
ip router isis 200
router bgp 200
bgp log-neighbor-changes
bgp graceful-restart restart-time 120
bgp graceful-restart stalepath-time 360
bgp graceful-restart
neighbor 2.2.2.2 remote-as 100
neighbor 2.2.2.2 ebgp-multihop 255
neighbor 2.2.2.2 update-source Loopback 0
neighbor 5.5.5.5 remote-as 200
neighbor 5.5.5.5 update-source Loopback 0
address-family ipv4
no neighbor 2.2.2.2 activate
neighbor 5.5.5.5 activate
neighbor 5.5.5.5 next-hop-self
neighbor 5.5.5.5 send-label
exit-address-family
address-family vpnv4 unicast
neighbor 2.2.2.2 activate
neighbor 2.2.2.2 send-community extended
exit-address-family
address-family ipv4 vrf 1
network 8.8.8.8 mask 255.255.255.255
neighbor 78.0.0.8 remote-as 8
neighbor 78.0.0.8 activate
exit-address-family
router isis 200
net 49.0070.0700.7007.00
graceful-restart
mpls router ldp
ldp router-id interface Loopback 0
graceful-restart
hostname R8
interface GigabitEthernet 0/0
no switchport
ip address 78.0.0.8 255.255.255.0
interface Loopback 0
ip address 8.8.8.8 255.255.255.255
router bgp 8
bgp log-neighbor-changes
bgp graceful-restart restart-time 120
bgp graceful-restart stalepath-time 360
bgp graceful-restart
neighbor 78.0.0.7 remote-as 200
address-family ipv4
network 8.8.8.8 mask 255.255.255.255
neighbor 78.0.0.7 activate
exit-address-family