1. Introduction
Noaways, the Internet is a rich environment that provides several services and resources. However, as the Internet has grown, it has become more complex and hard to manage.
In this way, networked communication now requires complex strategies of path selection and several network functions processing to enable network traffic from the source to reach its destination. In particular, routers executing routing protocols are crucial elements in this process.
There are two categories of routing protocols: Interior Gateway Protocols (IGP) and External Gateway Protocols (EGP). In this tutorial, we’ll explore both IGP and EGP. Initially, we’ll review routing and understand what autonomous systems are in the context of networking. Thus, we’ll in-depth study IGP and EGP. Finally, we’ll compare these routing protocol categories in a systematic summary.
2. Routing
In short, the routing process means moving data from an origin point (the source) to another one (the destination). In the Internet scenario, this process interconnects different networks and is performed by routers.
Routing relies on protocols that enable routers to identify the source and destination points. These protocols provide addresses that uniquely identify a particular networked entity in a network. An example of these protocols is the Internet Protocol (IP).
Moreover, routers must decide which paths to use among the available ones for forwarding data in order to achieve the proper destination. A router takes this decision based on routing protocols.
We can divide these protocols into two categories: Internal Gateway Protocol (IGP) and External Gateway Protocol (EGP). These categories, in turn, indicate scenarios for using particular protocols according to the position of the source and destination entity in terms of networked autonomous systems.
So, before studying what IGP and EGP are, we should have a clear understanding of what an autonomous system is in a network. We’ll investigate this concept in the following section.
3. Autonomous Systems
In the networking scenario, an autonomous system means a network (represented by a group of IP addresses) under the control of the same organization or group of operators, with a single and clearly defined routing policy enforced.
For different Internet Service Providers (ISP) to identify and communicate with each other, they need exclusive autonomous system numbers provided by the Internet Assigned Numbers Authority (IANA).
These autonomous system numbers are extensively employed, for example, by the Border Gateway Protocol (BGP) that correlates them with specific network routes, thus being able to successfully steer network traffic between sources and destinations that do not belong to the same autonomous system.
The following figure depicts a simple example of four Autonomous Systems (AS) with their respective number on the Internet:
Notably, as the networks get popular and the Internet grows, the complexity of managing the increasing number of autonomous systems also grows. So, routing network traffic over the Internet becomes more challenging daily.
In this context, the IGP and EGP protocols emerge to tackle particular challenges of the routing task. These protocols enable networked entities to communicate internally and externally to the autonomous system they belong to.
We’ll have details about IGP and EGP and how they correlate with autonomous systems in the following sections.
4. Interior Gateway Protocols
In short, interior gateway protocols are tailored to route traffic between entities in the same autonomous system. So, their design does not tackle the specific challenges of external network traffic routing between entities belonging to different autonomous systems.
The following figure shows, in red, which kind of traffic routing IGP is responsible for:
The most popular IGP protocols are Open Shortest Path First (OSPF), Intermediate System to Intermediate System (IS-IS), Routing Information Protocol (RIP), and Enhanced Interior Gateway Routing Protocol (EIGRP). Let’s briefly introduce each one of them:
- OSPF: a link-state routing protocol that uses the Dijkstra algorithm to find the best routes based on bandwidth and other cost metrics
- IS-IS: a link-state routing protocol that employs a variant of the Dijkstra algorithm looking for suitable paths for routing traffic
- RIP: a distance vector protocol that runs the Bellman-Ford algorithm on the information of a routing table to define optimized paths
- EIGRP: a distance vector protocol that employs the diffusing update algorithm searching for the best path based on reliability, load, bandwidth, and delays
So, according to each particular scenario, the network administrators and operators can choose one strategy or another to tackle the internal routing of an autonomous system.
5. External Gateway Protocols
Unlike interior gateway protocols, exterior gateway protocols route traffic among autonomous systems. Thus, we can say that they focus on the challenges of finding the particular autonomous system a networked entity belongs to, not the entity itself.
The figure next depicts with red lines the traffic routing of which EGP protocols work with:
The most prominent EGP protocol is called Border Gateway Protocol (BGP), and, as we already commented, the current Internet infrastructure (based on autonomous systems) strongly relies on it.
BGP is a path vector protocol that employs the best path algorithm and can work with very large networks to find optimized routes based on a large set of attributes. Examples of potentially considered attributes are weight, local preference, path length between autonomous systems, and shortest IGP path to find border gateways, among many others.
Although its apparent complexity, the BGP presents an easy to moderate difficulty level for executing and maintaining its basic configuration. Furthermore, the computing resource consumption of BGP is directly proportional to the size of the routing table running with it.
6. Systematic Summary
Routing is an essential operation that enables connected entities in different networks to communicate. In particular, we can divide routing protocols into two categories in the modern Internet: Internal Gateway Protocols and External Gateways Protocols.
These routing protocol categories regard how routing protocols relate to autonomous systems on the Internet. Autonomous systems, in turn, mean a network under the control of a specific organization.
So, the IGP category indicates protocols that route network traffic between entities in the same autonomous system. On the other hand, the EGP category consists of protocols responsible for routing traffic between different autonomous systems.
The following table summarizes some similarities and differences between IGP and EGP:
Interior Gateway Protocols
External Gateway Protocols
Task
Network Traffic Routing
Network Traffic Routing
Operation
Internal to an autonomous system
External to autonomous systems
Examples
OSPF, IS-IS, RIP, EIGRP
BGP
It is relevant to note that there exist different options for interior gateway protocols. In the Internet, each autonomous system can choose a protocol to route traffic between its connected entities. Thus, heterogeneous autonomous systems are not required to agree to use the same interior protocol.
Border routers of different autonomous systems, in turn, agree on using BGP to route traffic through the Internet.
7. Conclusion
In this tutorial, we studied interior and external gateway protocols. First, we had a brief review of routing. Then, we understood the concept of autonomous systems. So, we investigated the characteristics of IGP and EGP and, finally, summarized and compared them in a systematic summary.
We can conclude that both IGP and EGP are crucial for routing network traffic and enable us to communicate efficiently over specific networks and the Internet.