Configuration Du Reseau MPLS [PDF]

  • 0 0 0
  • Gefällt Ihnen dieses papier und der download? Sie können Ihre eigene PDF-Datei in wenigen Minuten kostenlos online veröffentlichen! Anmelden
Datei wird geladen, bitte warten...
Zitiervorschau

CONFIGURATION DU RESEAU MPLS 1. REPARTITION DU RESEAU EN ZONE

Les routeurs Siege, Monitoring, Datacenter Mbankolo, Datacenter 2, VSAT et internet provider constituent le noyau MPLS et exécutent OSPF avec tous les bouclages exécutant une adresse /32. Les routeurs du MPLS Core qui n’ont pas de connectivite complète, communiqueront avec MP-BGP (exemple : Datacenter Mbankolo et Datacenter 2). Pour la suite nous allons travailler avec cette disposition : R1 routeur Datacenter Mbankolo R2 routeur Siege R3 Monitoring R4 Datacenter 2 R5 VSAT R6 Internet router R7 routeur IMS/SIP

2. Configuration Cisco a. Adressage IP et OSPF

 R1 hostname R1 int lo0 ip add 1.1.1.1 255.255.255.255 ip ospf 1 area 0

int f0/0 ip add 10.0.10.1 255.255.255.0 no shut ip ospf 1 area 0

 R2 hostname R2 int lo0 ip add 2.2.2.2 255.255.255.255 ip ospf 1 are 0

int f0/0 ip add 10.0.10.2 255.255.255.0 no shut ip ospf 1 area 0

int f0/1 ip add 10.0.30.2 255.255.255.0 no shut ip ospf 1 area 0 int f1/0 ip add 10.0.40.2 255.255.255.0 no shut ip ospf 1 area 0

int f1/1 ip add 10.0.50.2 255.255.255.0 no shut ip ospf 1 area 0

int f1/2 ip add 10.0.60.2 255.255.255.0 no shut ip ospf 1 area 0

 R3 hostname R3 int lo0 ip add 3.3.3.3 255.255.255.255 ip ospf 1 are 0

int f0/0 ip add 10.0.30.3 255.255.255.0 no shut ip ospf 1 area 0

 R4 hostname R4 int lo0 ip add 4.4.4.4 255.255.255.255 ip ospf 1 are 0

int f0/0 ip add 10.0.40.4 255.255.255.0 no shut ip ospf 1 area 0

 R5 hostname R5

int lo0 ip add 5.5.5.5 255.255.255.255 ip ospf 1 are 0

int f0/0 ip add 10.0.50.5 255.255.255.0 no shut ip ospf 1 area 0  R6 Hostname R6 int lo0 ip add 6.6.6.6 255.255.255.255 ip ospf 1 are 0

int f0/0 ip add 10.0.60.6 255.255.255.0 no shut ip ospf 1 area 0

TEST:

Pour vérifier que les config ont été effectuées, on peut faire sur R2 : Ping 6.6.6.6

b. Configuration de LDP sur toutes les interfaces R1 router ospf 1 mpls ldp autoconfig

R2 router ospf 1 mpls ldp autoconfig

R3 router ospf 1 mpls ldp autoconfig

R4 router ospf 1 mpls ldp autoconfig

R5 router ospf 1 mpls ldp autoconfig

R6 router ospf 1 mpls ldp autoconfig

TEST:

Pour verifier les interfaces MPLS faire : Sh mpls interces Pour verifier les voisins LDP faire : Sh mpls ldp neigh Pour verifier que LDP fonctionne effectivement faire : Sur R1 ou R3 : trace 6.6.6.6

c. Configuration du MPLS BGP entre les routeurs : R1-R6, R1-R3, R3-R4, R4-R5 et R5-R6  Entre R1 et R3

R1# router bgp 1 neighbor 3.3.3.3 remote-as 1 neighbor 3.3.3.3 update-source Loopback0 no auto-summary ! address-family vpnv4 neighbor 3.3.3.3 activate

R3# router bgp 1 neighbor 1.1.1.1 remote-as 1 neighbor 1.1.1.1 update-source Loopback0 no auto-summary ! address-family vpnv4 neighbor 1.1.1.1 activate

 Entre R1 et R6

R1#

router bgp 2 neighbor 6.6.6.6 remote-as 2 neighbor 6.6.6.6 update-source Loopback0 no auto-summary ! address-family vpnv4 neighbor 6.6.6.6 activate

R6# router bgp 2 neighbor 1.1.1.1 remote-as 2 neighbor 1.1.1.1 update-source Loopback0 no auto-summary ! address-family vpnv4 neighbor 1.1.1.1 activate

 Entre R3 et R4

R3# router bgp 3 neighbor 4.4.4.4 remote-as 3 neighbor 4.4.4.4 update-source Loopback0 no auto-summary ! address-family vpnv4 neighbor 4.4.4.4 activate

R4#

router bgp 3 neighbor 3.3.3.3 remote-as 3 neighbor 3.3.3.3 update-source Loopback0 no auto-summary ! address-family vpnv4 neighbor 3.3.3.3 activate

 Entre R4 et R5

R4# router bgp 4 neighbor 5.5.5.5 remote-as 4 neighbor 5.5.5.5 update-source Loopback0 no auto-summary ! address-family vpnv4 neighbor 3.3.3.3 activate

R5# router bgp 4 neighbor 4.4.4.4 remote-as 4 neighbor 4.4.4.4 update-source Loopback0 no auto-summary ! address-family vpnv4 neighbor 4.4.4.4 activate

 Entre R5 et R6

R5# router bgp 5 neighbor 6.6.6.6 remote-as 5 neighbor 6.6.6.6 update-source Loopback0 no auto-summary ! address-family vpnv4 neighbor 6.6.6.6 activate

R6# router bgp 5 neighbor 5.5.5.5 remote-as 5 neighbor 5.5.5.5 update-source Loopback0 no auto-summary ! address-family vpnv4 neighbor 5.5.5.5 activate

TEST: pour verifier l’existence d’une session entre deux routeurs(ex R1 et R6), faire sur R6 : sh bgp vpnv4 unicast all

d. Ajoutons les routeurs au MPLS Core et configurons le VRF Ici il n’y a que 02 routeurs à ajouter, d’après le schéma du départ, ceux de L’IMS/SIP 1 et 2… Tous les autres ajouts ne sont que des serveurs. Nous allons les nommer comme suit et leur attribuer les adresses suivantes : Routeur IMS/SIP 1 : R7 Adresse IP :192.168.1.7 Adresse Loopback :7.7.7.7

Routeur IMS/SIP 2 : R8 Adresse IP :192.168.3.8 Adresse Loopback : 8.8.8.8

Le Routeur R7 sera ajouté au réseau via le routeur R1 et le Routeur R8 sera ajouté au réseau via le routeur R3. C’est donc sur les routeurs R1 et R3 qu’on va implémenter le VRF.

 Ajout de R7 On configure les adresses IP et Loopback. Et on active l’OSPF entre R7 et R1

R7 int lo0 ip add 7.7.7.7 255.255.255.255 ip ospf 2 area 2 int f0/0 ip add 192.168.1.7 255.255.255.0 ip ospf 2 area 2 no shut

R1 int f0/1 no shut ip add 192.168.1.1 255.255.255.0

Maintenant on configure R1 pour qu’il fasse le VRF

R1 ip vrf RED rd 4:4 route-target both 4:4

Maintenant on met F0/1 de R1 sur le VRF R1 int f0/1 ip vrf forwarding RED Ensuite refaire: R1 int f0/1 ip address 192.168.1.1 255.255.255.0

Test: Pour verifier faire: R1: Sh run int f0/1 Vérifier les différentes tables de routage : sh ip route sh ip route vrf RED

Maintenant on active OSPF R1 int f0/1 ip ospf 2 area 2

 Ajout de R8 On configure les adresses IP et Loopback. Et on configure l’OSPF entre R8 et R3

R8 int lo0 ip add 8.8.8.8 255.255.255.255 ip ospf 2 area 2 int f0/0 ip add 192.168.3.8 255.255.255.0 ip ospf 2 area 2 no shut

R3 int f0/1 no shut ip add 192.168.3.1 255.255.255.0

Maintenant on configure R3 pour qu’il fasse le VRF

R3 ip vrf RED rd 4:4 route-target both 4:4

Maintenant on met F0/1 de R3 sur le VRF R3 int f0/1 ip vrf forwarding RED Ensuite refaire: R3 int f0/1 ip address 192.168.3.1 255.255.255.0

Test: Pour verifier faire: R3: Sh run int f0/1 Vérifier les différentes tables de routage : sh ip route sh ip route vrf RED

Maintenant on active OSPF R3 int f0/1 ip ospf 2 area 2

 DANS LES ROUTEURS R1 ET R3 ON FAIT LES REDISTRIBUTIONS

-

On redistribue MP-BGP dans OSPF sur R1

R1 router bgp 1

address-family ipv4 vrf RED redistribute ospf 2

-

On redistribue MP-BGP dans OSPF sur R3

R3 router bgp 1 address-family ipv4 vrf RED redistribute ospf 2

TEST : Vérifions les routes sur R1 et R3 : sh ip bgp vpnv4 vrf RED

 Récupérons les routes du MPLS dans l’OSPF R1 router ospf 2 redistribute bgp 1 subnets

R3 router ospf 2 redistribute bgp 1 subnets

e. TESTS FINAUX Ici on va essayer de joindre les deux Routeurs R7 et R8 Sur R8 :

Sh ip route Ping 7.7.7.7 Trace 7.7.7.7

Sur R7 : Sh ip route Ping 8.8.8.8 Trace 8.8.8.8

3. CONVERSION DU CODE CISCO Vers MIKROTIK Tables de conversion Cisco (gauche) et Mikrotik (droite)pour la config de MPLS :

show mpls ldp neighbor

mpls ldp neighbor print

show mpls interfaces

mpls ldp interface print

show mpls forwarding-table

mpls forwarding-table print

show mpls binding

mpls remote-bindings print

sh mpls ip binding local

mpls local-bindings print

sh mpls label range

mpls print

sh mpls ldp parameters

mpls ldp print

interface GigabitEthernet0/1 mpls ip

/mpls ldp interface add interface=ether1

mpls ldp router-id Loopback0

/mpls ldp set enabled=yes lsr-id=10.1.1.3

Tables de conversion Cisco (gauche) et Mikrotik (droite)pour la config de l’OSPF :

show ip ospf neighbor

routing ospf neighbor print

show ip ospf interface

routing ospf interface print

show ip ospf 1

routing ospf instance print detail

show ip ospf database

routing ospf lsa print

show ip route ospf

ip route print where ospf=yes

show ip ospf rib

routing ospf route print

show ip ospf border-routers

routing ospf area-border-router print

show ip ospf border-routers

routing ospf as-border-router print

Cisco(config)#router ospf 1

/routing ospf instance

Cisco(config-router)#router-id 203.0.113.1

/routing ospf instance set 0 router-id=203.0.113.2

Cisco(config-router)#network 203.0.113.1 0.0.0.0 area 0

/routing ospf network add area=backbone network=203.0.113.2/32

Cisco(config-router)#network

/routing ospf network

203.0.113.128 0.0.0.7 area 0

add area=backbone network=203.0.113.128/29

Cisco(config-router)#interface GigabitEthernet0/0 Cisco(config-if)# ip ospf network point-to-point Cisco(config-if)# ip ospf deadinterval 4 Cisco(config-if)# ip ospf hellointerval 1

/routing ospf interface add dead-interval=4s hellointerval=1s interface=ether1 network-type=point-topoint

Tables de conversion Cisco (gauche) et Mikrotik (droite)pour la config de BGP : show ip bgp summary

routing bgp peer print brief

show ip bgp neighbor

routing bgp peer print status

show ip bgp neighbor 1.1.1.1 advertised-routes

routing bgp advertisements print peer=peer_name

show ip bgp neighbor 1.1.1.1 receivedroutes

ip route print where received-from=peer_name

show ip route bgp

ip route print where bgp=yes

clear ip bgp 172.31.254.2 soft in

routing bgp peer refresh peer1

clear ip bgp 172.31.254.2 soft out

routing bgp peer resend peer1

BGP-Cisco(config)#router bgp 1

/routing bgp instance set default as=2

BGP-Cisco(config-router)#neighbor 172.31.254.2 remote-as 2

/routing bgp peer add name=peer1 remote-address=172.31.254.1 remote-as=1

BGP-Cisco(config-router)#network

/routing bgp network

 

100.99.98.0 mask 255.255.255.0 BGP-Cisco(config-router)#network 100.99.97.0 mask 255.255.255.0 BGP-Cisco(config-router)#network 100.99.96.0 mask 255.255.255.0

add network=100.89.88.0/24 add network=100.89.87.0/24 add network=100.89.86.0/24

BGP-Cisco(config)#router bgp 1 BGP-Cisco(config-router)#neighbor 172.31.254.2 default-originate

/routing bgp peer add default-originate=always name=peer1 remote-address=172.31.254.1 remote-as=1