If you want to deploy Border Gateway Protocol (BGP) throughout your network, you have to run it on all core routers (and there are a number of reasons why you should)... or at least that was the traditional wisdom.
With the introduction of MPLS, you can run BGP only on the network's edges, reducing the memory requirements and CPU load on your core routers, while at the same time making them more stable.
To understand why MPLS technology has such an impact on your network, let's review the basic facts of BGP routing. When BGP advertises a route between routers in the same network -- the same Autonomous System (AS), the next-hop of the route remains an IP address outside of the AS, as shown in the diagram below. Note: Most other routing protocols make the next hop of the route the IP address of the adjacent router.
Consequently, when the routing tables are built on the routers in your autonomous system, all entries for IP prefix 10.1.2.0 point to the same next hop: the IP address of the X1 router (see diagram below).
If a Label Switch Path (LSP) were established between the routers' POP and Internet Exchange Point (IXP) for the IP destination X1, the packets toward the network 10.1.2.0 would travel across the network encapsulated in MPLS headers, and the core router would not need to have the BGP route toward the destination network (see diagram below).
The LSPs for all non-BGP destinations are built automatically once you enable MPLS with Label Distribution Protocol (LDP) in your network (unless you've configured LDP filters). The LSP between the POP and the IXP router is thus created automatically, and the POP router starts using it to send packets toward the IP network 10.1.2.0 as soon as it's created. BGP is thus no longer needed on the core router, as it never receives a non-MPLS-encapsulated IP packet for the network 10.1.2.0.
Once you decide to rely on MPLS to provide the edge-to-edge transport across you network core, however, BGP has to be deployed on all edge routers (similar to the MPLS VPN designs). You can no longer use default routing toward an IXP or toward your network core, as your core routers cannot forward IP packets toward Internet destinations anymore. If you would like to retain default routing on the low-end access routers, you could use the following design:
- The core routers run only MPLS and core IGP. These routers should never have to forward non-labelled IP packets toward external destinations. The only IP traffic they should handle is the routing protocol updates and network management queries.
- The distribution layer routers run BGP and provide end-to-end transport across label switched paths established in the network core.
- The distribution layer routers advertise default route toward those access routers that do not run BGP.
- Access routers might have full BGP routing table (needed for multi-homed customer), partial BGP routing table (for example, only the routes toward your customers) or no BGP at all (in which case they would use the default route toward the closes distribution layer router for most of the traffic).
This design is very similar to IP-over-ATM designs used in early high-speed Internet backbones (when ATM was the only high-speed technology available). The only difference is in the backbone infrastructure, where ATM switches have been replaced with routers, significantly reducing per-port and per-switched-Gbps costs.
Before you rush to reconfigure your routers and remove BGP from your core, you have to consider the following caveat: The MPLS-only network core will perform its duties only if the LSPs established across the core with LDP always follow the shortest paths computed by the IP routing protocols. If a backbone router is restarted and becomes a hop on the shortest path across the core network before it has exchanged the LDP labels with its neighbours, the LSPs across the network will break and the transit traffic will be blackholed.
To remove the risk of broken core LSPs, you could deploy MPLS Traffic Engineering between the distribution-layer routers. If you enable MPLS TE in your network, the routers prefer MPLS TE paths over paths computed by your routing protocol) or you could configure slow IGP startup on your backbone routers (available only if you use OSPF or IS-IS as your core routing protocol).