top of page
Search

Configuring an MPLS Network: A Step-by-Step Guide

  • Writer: Francisco Augusto Nascimento Antonio
    Francisco Augusto Nascimento Antonio
  • Dec 3, 2024
  • 6 min read

You are a Cisco Senior Engineer at Telco, you must configure an MPLS site following: 


  1. On the Router CE-R1 interface  Gig0/0 add ip address 192.168.1.1.1/24 connected to the Router  PE-R1’s interfaces Gig0/0, apply the command “no shutdown” on the interface Gig0/0/

  2. Configure Router CE-RA interface Gig2/0 add ip address 10.0.0.2/24 and apply the command “no shut”.

  3. Configure PE-R1 interface Gig2/0 ip address 10.0.0.1/24  to connect to CE-RA interface Gig2/0 ip address 10.0.0.2/24. On Router PE-R1 interface Gig1/0, create  3 subinterfaces with the following IP addresses  Gig1/0.1 ip address 172.16.0.1/24, Gig ip address 1/0.2 172.16.1.1/24, and Gig1/0.3 ip address  172.16.2.1/24. Apply the command “no shutdown” on interface Gig1/0.

  4. Configure PE-R1 interface Gig0/0 with ip address 192.168.1.2/24

  5. Configure router P-R2 interface Gig1/0, create 3 subinterfaces with the following IP addresses  Gig1/0.1 ip address 172.16.0.1/24, Gig1/0.2 ip address 172.16.1.1/24, and Gig1/0.3 ip address  172.16.2.1/24. Apply the command  “no shutdown” on the interface Gig1/0.

  6. Configure router P-R2 interface Gig0/0, create 3 subinterfaces with the following IP addresses  Gig0/0.1 ip address 172.17.0.1/24, Gig0/0.2 ip address 1/0.2 172.17.1.1/24, and Gig0/0.3 ip address  172.17.2.1/24. Apply the command “no shutdown” on the interface Gig0/0.

  7. On Router P-R3 configure the following subinterfaces on interface Gig0/0;  Configure router P-R2 interface Gig0/0, create 3 subinterfaces with the following IP addresses  Gig0/0.1 ip address 172.17.0.2/24, Gig0/0.2 ip address 172.17.1.2/24, and Gig0/0.3 ip address  172.17.2.2/24. 

  8. On the Router P-R3 configure 3 subinterfaces on interface Gig2/0 with the following IP addresses Gig2/0.1 ip address 172.18.0.1/24,  Gig2/0.2 ip address 172.18.1.1/24, and Gig2/0.3 ip address 172.18.2.1/24.


  1.  On the Router P-R4 interface Gig2/0 creates 3 subinterfaces with the following configuration; Gig2/0.1 ip address 173.18.0.2/24, Gig2/0.2 ip address 172.18.1.2/24, and Gig2/0.3 ip address 172.18.3.2/24. Apply the command “no shutdown” on interface Gig2/0

  2.  On the Router P-R4 interface Gig1/0  create 3 subinterfaces with the following configuration; Gig1/0.1 ip address 176.19.0.1/24, Gig1/0.2 ip address 176.19.1.1/24, and Gig1/0.3 ip address 176.19.2.1/24.

  3. On the Router P-R5 interface Gig1/0  create 3 subinterfaces with the following configuration; Gig1/0.1 ip address 176.19.0.2/24, Gig1/0.2 ip address 176.19.1.2/24, and Gig1/0.3 ip address 176.19.2.2/24. Apply the command “no shutdown” on the interface Gig1/0.

  4. On the Router P-R5 interface Gig0/0 with IP address 192.168.1.1/24, on interface Gig2/0 configure ip address 10.0.2.1/24. Apply the command “no shutdown” on the interface  Gig0/0 and Gig2/0

  5. On the Router CE-R2 interface, Gig0/0 configure IP address 192.168.1.2/24. apply the command “no shut” on the interface.

  6. On the Router CE-RB interface, Gig2/0 configures IP address 10.0.2.2/24 apply the command “no shut” on the interface.


      Create the interfaces VRFs Blue, Green, and Red, using the protocol OSPF and BGP. 




Configuring an MPLS Network: A Step-by-Step Guide

Understanding the Topology

Based on your provided topology, we have a basic MPLS network with multiple VPN instances.

Configuration Steps:

1. Basic Router Configuration:

  • Interface Configuration: Configure the physical interfaces on all routers with the appropriate IP addresses and enable them.

  • IP Routing: Configure IP routing protocols (e.g., OSPF, RIP, or BGP) to establish IP connectivity between routers.

2. MPLS Configuration:

On PE Routers (PE-R1, PE-R2, PE-R3, PE-R4, PE-R5):

Enable MPLS: router mpls


Configure LDP: mpls ldp neighbor <neighbor-ip-address> transport tcp


Configure VPN Instances: mpls vpn-instance Blue

  router-id <router-id>

  address-family ipv4 unicast

    route-target export 1:1

    route-target import 1:1


mpls vpn-instance Green

  router-id <router-id>

  address-family ipv4 unicast

    route-target export 2:2

    route-target import 2:2


mpls vpn-instance Red

  router-id <router-id>

  address-family ipv4 unicast

    route-target export 3:3

    route-target import 3:3


Configure Route Redistribution: router bgp <AS-number>

  neighbor <neighbor-IP-address> remote-as <neighbor-AS>

  network <network-prefix>

  redistribute connected

  redistribute mpls vpn Blue

  redistribute mpls vpn Green

  redistribute mpls vpn Red


3. CE Router Configuration:

Enable MPLS: router mpls


Configure VPN Instances: mpls vpn-instance <VPN-instance-name>

  router-id <router-id>

  address-family ipv4 unicast

    route-target export <RT-export>

    route-target import <RT-import>


  • Configure Interfaces: Assign IP addresses to the interfaces and configure them to participate in the appropriate VPN instance.

4. Verification:

  • Check LDP Neighbor Relationships: Use the show mpls ldp neighbor command.

  • Verify VPN Instance Configuration: Use the show mpls vpn-instance command.

  • Check MPLS LSPs: Use the show mpls lsp command.

  • Verify Route Propagation: Use the show ip route command to check route propagation between PE and CE routers.

Additional Considerations:

  • MPLS Traffic Engineering: Configure TE policies to optimize traffic flow and improve network performance.

  • Security: Implement appropriate security measures, such as access control lists and encryption.

  • Monitoring: Monitor the MPLS network using tools like NetFlow and SNMP to identify and resolve issues.

Remember to adapt the specific configuration commands to your network topology and requirements.

Configuring the PE-R1 and P-R2 Routers

Understanding the Task:

Based on the provided configuration, we need to configure the PE-R1 and P-R2 routers with specific IP addresses and subinterfaces to establish MPLS VPN connections.

Configuration Steps:

PE-R1 Configuration

1. Interface Configuration:

interface GigabitEthernet0/0

  ip address 192.168.1.2 255.255.255.0

  no shutdown


interface GigabitEthernet1/0

  ip address 172.16.0.1 255.255.255.0

  ip address 172.16.1.1 255.255.255.0

  ip address 172.16.2.1 255.255.255.0

  no shutdown


P-R2 Configuration

1. Interface Configuration:

interface GigabitEthernet0/0

  ip address 172.17.0.1 255.255.255.0

  ip address 172.17.1.1 255.255.255.0

  ip address 172.17.2.1 255.255.255.0

  no shutdown


interface GigabitEthernet1/0

  ip address 172.16.0.1 255.255.255.0

  ip address 172.16.1.1 255.255.255.0

  ip address 172.16.2.1 255.255.255.0

  no shutdown


Additional Considerations:

  • MPLS Configuration: Ensure that MPLS is enabled on both routers and that LDP is configured for neighbor discovery and label distribution.

  • VPN Instance Configuration: Configure VPN instances with appropriate route-targets for each VPN.

  • Route Redistribution: Redistribute connected routes and VPN routes into BGP for inter-AS routing.

  • Security: Implement appropriate security measures, such as ACLs and firewall rules.

  • Monitoring: Use tools like SNMP and NetFlow to monitor network performance and troubleshoot issues.

Remember to adapt the specific configuration to your network topology and requirements.

On Router P-R3 configure the following subinterfaces on interface Gig0/0;  Configure router P-R2 interface Gig0/0, create 3 subinterfaces with the following IP addresses  Gig0/0.1 ip address 172.17.0.2/24, Gig0/0.2 ip address 172.17.1.2/24, and Gig0/0.3 ip address  172.17.2.2/24. 

On the Router P-R3 configure 3 subinterfaces on interface Gig2/0 with the following IP addresses Gig2/0.1 ip address 172.18.0.1/24,  Gig2/0.2 ip address 172.18.1.1/24, and Gig2/0.3 ip address 172.18.2.1/24.


 On the Router P-R4 interface Gig2/0 creates 3 subinterfaces with the following configuration; Gig2/0.1 ip address 173.18.0.2/24, Gig2/0.2 ip address 172.18.1.2/24, and Gig2/0.3 ip address 172.18.3.2/24. Apply the command “no shutdown” on interface Gig2/0

 On the Router P-R4 interface Gig1/0  create 3 subinterfaces with the following configuration; Gig1/0.1 ip address 176.19.0.1/24, Gig1/0.2 ip address 176.19.1.1/24, and Gig1/0.3 ip address 176.19.2.1/24.

Configuring P-R5, CE-R2, and CE-RB Routers

P-R5 Configuration

interface GigabitEthernet1/0

  ip address 176.19.0.2 255.255.255.0

  ip address 176.19.1.2 255.255.255.0

  ip address 176.19.2.2 255.255.255.0

  no shutdown


interface GigabitEthernet0/0

  ip address 192.168.1.1 255.255.255.0

  ip address 10.0.2.1 255.255.255.0

  no shutdown


CE-R2 Configuration

interface GigabitEthernet0/0

  ip address 192.168.1.2 255.255.255.0

  no shutdown


CE-RB Configuration

interface GigabitEthernet2/0

  ip address 10.0.2.2 255.255.255.0

  no shutdown


MPLS Configuration on PE Routers

For PE routers (PE-R1, PE-R2, PE-R3, PE-R4, PE-R5), you'll need to configure MPLS, LDP, VPN instances, and route redistribution.

Here's a basic example:

router mpls

 mpls ldp neighbor <neighbor-IP> transport tcp


mpls vpn-instance Blue

  router-id <router-ID>

  address-family ipv4 unicast

    route-target export 1:1

    route-target import 1:1


mpls vpn-instance Green

  router-id <router-ID>

  address-family ipv4 unicast

    route-target export 2:2

    route-target import 2:2


mpls vpn-instance Red

  router-id <router-ID>

  address-family ipv4 unicast

    route-target export 3:3

    route-target import 3:3


router bgp <AS-number>

  neighbor <neighbor-IP> remote-as <neighbor-AS>

  network <network-prefix>

  redistribute connected

  redistribute mpls vpn Blue

  redistribute mpls vpn Green

  redistribute mpls vpn Red


Remember to:

  • Configure LDP: Ensure proper LDP neighbor relationships between PE routers.

  • Configure VPN Instances: Create VPN instances for each VPN service (Blue, Green, Red) and assign appropriate route-targets.

  • Configure Route Redistribution: Redistribute connected and VPN routes into BGP.

  • Verify Connectivity: Use ping and traceroute commands to verify connectivity between different devices and VPN instances.

Additional Considerations:

  • MPLS Traffic Engineering: Configure TE policies to optimize traffic flow and improve network performance.

  • Security: Implement appropriate security measures, such as ACLs and encryption.

  • Monitoring: Use tools like SNMP and NetFlow to monitor network performance and troubleshoot issues.



PE-R1 Configuration:

interface GigabitEthernet0/0

  ip address 192.168.1.2 255.255.255.0

  no shutdown


interface GigabitEthernet1/0

  ip address 172.16.0.1 255.255.255.0

  ip address 172.16.1.1 255.255.255.0

  ip address 172.16.2.1 255.255.255.0

  no shutdown


interface GigabitEthernet2/0

  ip address 10.0.0.1 255.255.255.0

  no shutdown


router mpls

  mpls ldp neighbor <neighbor-IP> transport tcp


mpls vpn-instance Blue

  router-id <router-ID>

  address-family ipv4 unicast

    route-target export 1:1

    route-target import 1:1


mpls vpn-instance Green

  router-id <router-ID>

  address-family ipv4 unicast

    route-target export 2:2

    route-target import 2:2


mpls vpn-instance Red

  router-id <router-ID>

  address-family ipv4 unicast

    route-target export 3:3

    route-target import 3:3


router bgp <AS-number>

  neighbor <neighbor-IP> remote-as <neighbor-AS>

  network <network-prefix>

  redistribute connected

  redistribute mpls vpn Blue

  redistribute mpls vpn Green

  redistribute mpls vpn Red


CE-R1 Configuration:

interface GigabitEthernet0/0

  ip address 192.168.1.1 255.255.255.0

  no shutdown


router mpls

  mpls ldp neighbor <neighbor-IP> transport tcp


mpls vpn-instance Blue

  router-id <router-ID>

  address-family ipv4 unicast

    route-target export 1:1

    route-target import 1:1


router bgp <AS-number>

  neighbor <neighbor-IP> remote-as <neighbor-AS>

  network <network-prefix>

  redistribute connected

  redistribute mpls vpn Blue


CE-RA Configuration:

interface GigabitEthernet2/0

  ip address 10.0.0.2 255.255.255.0

  no shutdown


router mpls

  mpls ldp neighbor <neighbor-IP> transport tcp


mpls vpn-instance Blue

  router-id <router-ID>

  address-family ipv4 unicast

    route-target export 1:1

    route-target import 1:1


router bgp <AS-number>

  neighbor <neighbor-IP> remote-as <neighbor-AS>

  network <network-prefix>

  redistribute connected

  redistribute mpls vpn Blue


P-R2, P-R3, P-R4, and P-R5 configurations will follow a similar pattern, with appropriate interface and VPN configurations.

Remember to:

  • Adjust IP addresses and AS numbers to match your specific network topology.

  • Configure LDP: Ensure LDP neighbor relationships are established between PE routers.

  • Configure VPN Instances: Create VPN instances for each VPN service and assign appropriate route-targets.

  • Configure Route Redistribution: Redistribute connected and VPN routes into BGP.

  • Verify Connectivity: Use ping and traceroute commands to verify connectivity between different devices and VPN instances.

  • Implement Security: Use ACLs and other security measures to protect your network.

  • Monitor Network Performance: Use tools like SNMP and NetFlow to monitor network performance and troubleshoot issues.

By following these steps and considering the specific requirements of your network, you can successfully configure an MPLS network to provide VPN services to your customers.


 
 
 

Recent Posts

See All

Comments


Post: Blog2_Post

Subscribe Form

©2020 by Compute Science - Network Routing, Switching & Storage. Proudly created with Wix.com

bottom of page