MPLS: Access to the Internet via Global routing table (GRE)

Source: Internet
Author: User
Tags exit datetime log range split domain lookup

The topology is as follows:

The simple way to provide Internet access for the CE router is to let the interface on the PE connected to the CE router be in the global routing space, the PE router has a VRF interface pointing to the CE router, and an interface to the CE router but not the VRF. Then the CE router can send VPN traffic to the VPN interface and send the Internet traffic to the Global routing table interface.

The disadvantage of this method is the use of two links between PE and CE. A possible workaround is a FR or 802.1Q sub-interface, but sometimes the ISP is not allowed to encapsulate the second layer of sub-interfaces, and the GRE tunnel can be used to traverse the VRF interface.

The default route of the CE router points to the tunnel interface, and all imprecise matching routing traffic is sent to the tunnel port according to the default route to the global routing table, while the exact matching routing traffic is sent to the physical interface to reach the VRF. Traffic from the Internet to the user is forwarded to the tunnel port according to the static route of the PE router. The ISP forwards traffic from and to the Internet in the backbone network.

The configuration is as follows:

R5#show Run
Building configuration ...

Current configuration:891 bytes
!
Version 12.4
Service Timestamps Debug DateTime msec
Service Timestamps log datetime msec
No service password-encryption
!
Hostname R5
!
Boot-start-marker
Boot-end-marker
!
!
No AAA New-model
Memory-size Iomem 5
!
!
IP CEF
No IP domain Lookup
!
Interface Tunnel1
IP address 10.0.0.5 255.255.255.0
Tunnel Source FASTETHERNET0/1
Tunnel Destination 192.168.15.1
!
Interface fastethernet0/0
IP address 192.168.5.5 255.255.255.0
Duplex Auto
Speed auto
!
Interface FASTETHERNET0/1
IP address 192.168.15.5 255.255.255.0
Duplex Auto
Speed auto
!
!
Router RIP
Version 2
Network 192.168.5.0
Network 192.168.15.0
No auto-summary
!
No IP HTTP Server
No IP http secure-server
IP Route 0.0.0.0 0.0.0.0 Tunnel1
!

Control-plane
!
Line con 0
Exec-timeout 0 0
Logging synchronous
Line aux 0
Line vty 0 4
Login
!
!
End

-------------------------------Gorgeous split Line-------------------------------------------------

R1#sh Run
Building configuration ...

Current configuration:1867 bytes
!
Version 12.4
Service Timestamps Debug DateTime msec
Service Timestamps log datetime msec
No service password-encryption
!
Hostname R1
!
Boot-start-marker
Boot-end-marker
!
No AAA New-model
Memory-size Iomem 5
!
!
IP CEF
No IP domain Lookup
!
IP VRF R1
Rd 1:100
Route-target Export 1:100
Route-target Import 4:100
!
MPLS Label Range 100 199
MPLS Label Protocol LDP
!
Interface Loopback0
IP Address 1.1.1.1 255.255.255.255
!
Interface Tunnel1
IP address 10.0.0.1 255.255.255.0
Tunnel Source FASTETHERNET0/1
Tunnel Destination 192.168.15.5
Tunnel VRF R1
!
Interface fastethernet0/0
IP address 192.168.12.1 255.255.255.0
Duplex Auto
Speed auto
MPLS IP
!
Interface FASTETHERNET0/1
IP VRF forwarding R1
IP address 192.168.15.1 255.255.255.0
Duplex Auto
Speed auto
!
!
router OSPF 100
Router-id 1.1.1.1
Log-adjacency-changes
Network 1.1.1.1 0.0.0.0 Area 0
Network 192.168.12.0 0.0.0.255 Area 0
!
Router RIP
!
address-family IPv4 VRF R1
Redistribute BGP metric Transparent
Network 192.168.15.0
No auto-summary
Version 2
Exit-address-family
!
Router BGP 100
BGP Router-id 1.1.1.1
No BGP default Ipv4-unicast
BGP log-neighbor-changes
Neighbor 4.4.4.4 Remote-as 100
Neighbor 4.4.4.4 Update-source Loopback0
!
Address-family IPv4
Redistribute static
Neighbor 4.4.4.4 Activate
No auto-summary
No synchronization
Exit-address-family
!
Address-family vpnv4
Neighbor 4.4.4.4 Activate
Neighbor 4.4.4.4 Send-community Extended
Exit-address-family
!
address-family IPv4 VRF R1
Redistribute RIP
No synchronization
Exit-address-family
!
No IP HTTP Server
No IP http secure-server
IP Route 192.168.5.0 255.255.255.0 Tunnel1
!
MPLS LDP Router-id Loopback0
!
!
Control-plane
!

Line con 0
Exec-timeout 0 0
Logging synchronous
Line aux 0
Line vty 0 4
Login
!
!
End

----------------------------------Gorgeous split Line-----------------------------------

R2#sh Run
Building configuration ...

Current configuration:980 bytes
!
Version 12.4
Service Timestamps Debug DateTime msec
Service Timestamps log datetime msec
No service password-encryption
!
Hostname R2
!
Boot-start-marker
Boot-end-marker
!
!
No AAA New-model
Memory-size Iomem 5
!
!
IP CEF
No IP domain Lookup
!
!
MPLS Label Range 200 299
MPLS Label Protocol LDP
!
!
!
!interface Loopback0
IP address 2.2.2.2 255.255.255.255
!
Interface fastethernet0/0
IP address 192.168.12.2 255.255.255.0
Duplex Auto
Speed auto
MPLS IP
!
Interface FASTETHERNET0/1
IP address 192.168.23.2 255.255.255.0
Duplex Auto
Speed auto
MPLS IP
!
!
router OSPF 100
Router-id 2.2.2.2
Log-adjacency-changes
Network 2.2.2.2 0.0.0.0 Area 0
Network 192.168.12.0 0.0.0.255 Area 0
Network 192.168.23.0 0.0.0.255 Area 0
!
No IP HTTP Server
No IP http secure-server
!
MPLS LDP Router-id Loopback0
!
!
Control-plane
!
Line con 0
Exec-timeout 0 0
Logging synchronous
Line aux 0
Line vty 0 4
Login
!
!
End

Back to the column page: http://www.bianceng.cnhttp://www.bianceng.cn/Network/lyjs/

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.