Thursday, 29 May 2014

Routing Protocols And Types of Routing?

Routing Protocols
Routing protocols were created for routers. These protocols have been designed to allow the exchange of routing tables, or known networks, between routers. There are a lot of different routing protocols, each one designed for specific network sizes.

Classifying Routing Protocols 

Routing protocols can be classified into different groups according to their characteristics. Specifically, routing protocols can be classified by their:
  • Purpose: Interior Gateway Protocol (IGP) or Exterior Gateway Protocol (EGP)
  • Operation: Distance vector protocol, link-state protocol, or path-vector protocol
  • Behavior: Classful (legacy) or classless protocol
For example, IPv4 routing protocols are classified as follows:
  • RIPv1 (legacy): IGP, distance vector, classful protocol
  • IGRP (legacy): IGP, distance vector, classful protocol developed by Cisco (deprecated from 12.2 IOS and later)
  • RIPv2: IGP, distance vector, classless protocol
  • EIGRP: IGP, distance vector, classless protocol developed by Cisco
  • OSPF: IGP, link-state, classless protocol
  • IS-IS: IGP, link-state, classless protocol
  • BGP: EGP, path-vector, classless protocol
The classful routing protocols, RIPv1 and IGRP, are legacy protocols and are only used in older networks. These routing protocols have evolved into the classless routing protocols, RIPv2 and EIGRP, respectively. Link-state routing protocols are classless by nature.

Figure 3-9


IGP and EGP Routing Protocols 

An autonomous system (AS) is a collection of routers under a common administration such as a company or an organization. An AS is also known as a routing domain. Typical examples of an AS are a company’s internal network and an ISP’s network.
The Internet is based on the AS concept; therefore, two types of routing protocols are required:
  • Interior Gateway Protocols (IGP): Used for routing within an AS. It is also referred to as intra-AS routing. Companies, organizations, and even service providers use an IGP on their internal networks. IGPs include RIP, EIGRP, OSPF, and IS-IS.
  • Exterior Gateway Protocols (EGP): Used for routing between autonomous systems. It is also referred to as inter-AS routing. Service providers and large companies may interconnect using an EGP. The Border Gateway Protocol (BGP) is the only currently viable EGP and is the official routing protocol used by the Internet.
The example in Figure 3-10 provides simple scenarios highlighting the deployment of IGPs, BGP, and static routing.
Figure 3-10
Figure  3-10 IGP versus EGP Routing Protocols
There are five individual autonomous systems in the scenario:
  • ISP-1: This is an AS and it uses IS-IS as the IGP. It interconnects with other autonomous systems and service providers using BGP to explicitly control how traffic is routed.
  • ISP-2: This is an AS and it uses OSPF as the IGP. It interconnects with other autonomous systems and service providers using BGP to explicitly control how traffic is routed.
  • AS-1: This is a large organization and it uses EIGRP as the IGP. Because it is multihomed (i.e., connects to two different service providers), it uses BGP to explicitly control how traffic enters and leaves the AS.
  • AS-2: This is a medium-sized organization and it uses OSPF as the IGP. It is also multihomed; therefore, it uses BGP to explicitly control how traffic enters and leaves the AS.
  • AS-3: This is a small organization with older routers within the AS; it uses RIP as the IGP. BGP is not required because it is single-homed (i.e., connects to one service provider). Instead, static routing is implemented between the AS and the service provider.

Distance Vector Routing Protocols 

Distance vector means that routes are advertised by providing two characteristics:
  • Distance: Identifies how far it is to the destination network and is based on a metric such as the hop count, cost, bandwidth, delay, and more
  • Vector: Specifies the direction of the next-hop router or exit interface to reach the destination
For example, in Figure 3-11, R1 knows that the distance to reach network 172.16.3.0/24 is one hop and that the direction is out of the interface Serial 0/0/0 toward R2.
Figure 3-11
Figure 3-11 The Meaning of Distance Vector
A router using a distance vector routing protocol does not have the knowledge of the entire path to a destination network. Distance vector protocols use routers as sign posts along the path to the final destination. The only information a router knows about a remote network is the distance or metric to reach that network and which path or interface to use to get there. Distance vector routing protocols do not have an actual map of the network topology.
There are four distance vector IPv4 IGPs:
  • RIPv1: First generation legacy protocol
  • RIPv2: Simple distance vector routing protocol
  • IGRP: First generation Cisco proprietary protocol (obsolete and replaced by EIGRP)
  • EIGRP: Advanced version of distance vector routing

Link-State Routing Protocols 

In contrast to distance vector routing protocol operation, a router configured with a link-state routing protocol can create a complete view or topology of the network by gathering information from all of the other routers.
To continue our analogy of sign posts, using a link-state routing protocol is like having a complete map of the network topology. The sign posts along the way from source to destination are not necessary, because all link-state routers are using an identical map of the network. A link-state router uses the link-state information to create a topology map and to select the best path to all destination networks in the topology.
RIP-enabled routers send periodic updates of their routing information to their neighbors. Link-state routing protocols do not use periodic updates. After the network has converged, a link-state update is only sent when there is a change in the topology. For example, in Figure 3-12, the link-state update is sent when the 172.16.3.0 network goes down.
Figure 3-12
Figure 3-12 Link-State Protocol Operation
Link-state protocols work best in situations where:
  • The network design is hierarchical, usually occurring in large networks
  • Fast convergence of the network is crucial
  • The administrators have good knowledge of the implemented link-state routing protocol
There are two link-state IPv4 IGPs:
  • OSPF: Popular standards-based routing protocol
  • IS-IS: Popular in provider networks

Classful Routing Protocols 

The biggest distinction between classful and classless routing protocols is that classful routing protocols do not send subnet mask information in their routing updates. Classless routing protocols include subnet mask information in the routing updates.
The two original IPv4 routing protocols developed were RIPv1 and IGRP. They were created when network addresses were allocated based on classes (i.e., class A, B, or C). At that time, a routing protocol did not need to include the subnet mask in the routing update, because the network mask could be determined based on the first octet of the network address.
The fact that RIPv1 and IGRP do not include subnet mask information in their updates means that they cannot provide variable-length subnet masks (VLSMs) and Classless Inter-Domain Routing (CIDR).
Classful routing protocols also create problems in discontiguous networks. A discontiguous network is when subnets from the same classful major network address are separated by a different classful network address.
To illustrate the shortcoming of classful routing, refer to the topology in Figure 3-13.
Figure 3-13
Figure 3-13 R1 Forwards a Classful Update to R2
Notice that the LANs of R1 (172.16.1.0/24) and R3 (172.16.2.0/24) are both subnets of the same class B network (172.16.0.0/16). They are separated by different classful network addresses (192.168.1.0/30 and 192.168.2.0/30).
When R1 forwards an update to R2, RIPv1 does not include the subnet mask information with the update; it only forwards the class B network address 172.16.0.0.
R2 receives and processes the update. It then creates and adds an entry for the class B 172.16.0.0/16 network in the routing table, as shown in Figure 3-14.
Figure 3-14
Figure 3-14 R2 Adds the Entry for 172.16.0.0 via R1
When R3 forwards an update to R2, it also does not include the subnet mask information and therefore only forwards the classful network address 172.16.0.0.
R2 receives and processes the update and adds another entry for the classful network address 172.16.0.0/16 to its routing table, as shown in Figure 3-15. When there are two entries with identical metrics in the routing table, the router shares the load of the traffic equally among the two links. This is known as load balancing.
Figure 3-15
Figure 3-15 R2 Adds the Entry for 172.16.0.0 via R3
Discontiguous networks have a negative impact on a network. For example, a ping to 172.16.1.1 would return “U.U.U” because R2 would forward the first ping out its Serial 0/0/1 interface toward R3, and R3 would return a Destination Unreachable (U) error code to R2. The second ping would exit out of R2’s Serial 0/0/0 interface toward R1, and R1 would return a successful code (.). This pattern would continue until the ping command is done.

Classless Routing Protocols 

Modern networks no longer use classful IP addressing and the subnet mask cannot be determined by the value of the first octet. The classless IPv4 routing protocols (RIPv2, EIGRP, OSPF, and IS-IS) all include the subnet mask information with the network address in routing updates. Classless routing protocols support VLSM and CIDR.
IPv6 routing protocols are classless. The distinction whether a routing protocol is classful or classless typically only applies to IPv4 routing protocols. All IPv6 routing protocols are considered classless because they include the prefix-length with the IPv6 address.
Figures 3-16 through 3-18 illustrate how classless routing solves the issues created with classful routing.
Figure 3-16
Figure 3-16 R1 Forwards a Classless Update to R2
Figure 3-17
Figure 3-17 R2 Adds the Entry for the 172.16.1.0/24 Network via R1
Figure 3-18
Figure 3-18 Entry for the 172.16.2.0/24 Network via R3
In the discontiguous network design of Figure 3-16, the classless protocol RIPv2 has been implemented on all three routers. When R1 forwards an update to R2, RIPv2 includes the subnet mask information with the update 172.16.1.0/24.
In Figure 3-17, R2 receives, processes, and adds two entries in the routing table. The first line displays the classful network address 172.16.0.0 with the /24 subnet mask of the update. This is known as the parent route. The second entry displays the VLSM network address 172.16.1.0 with the exit and next-hop address. This is referred to as the child route. Parent routes never include an exit interface or next-hop IP address.
When R3 forwards an update to R2, RIPv2 includes the subnet mask information with the update 172.16.2.0/24.
R2 receives, processes, and adds another child route entry 172.16.2.0/24 under the parent route entry 172.16.0.0, as shown in Figure 3-18.
A ping from R2 to 172.16.1.1 would now be successful.

Routing Protocol Characteristics 

Routing protocols can be compared based on the following characteristics:
  • Speed of convergence: Speed of convergence defines how quickly the routers in the network topology share routing information and reach a state of consistent knowledge. The faster the convergence, the more preferable the protocol. Routing loops can occur when inconsistent routing tables are not updated due to slow convergence in a changing network.
  • Scalability: Scalability defines how large a network can become, based on the routing protocol that is deployed. The larger the network is, the more scalable the routing protocol needs to be.
  • Classful or classless (use of VLSM): Classful routing protocols do not include the subnet mask and cannot support variable-length subnet mask (VLSM). Classless routing protocols include the subnet mask in the updates. Classless routing protocols support VLSM and better route summarization.
  • Resource usage: Resource usage includes the requirements of a routing protocol such as memory space (RAM), CPU utilization, and link bandwidth utilization. Higher resource requirements necessitate more powerful hardware to support the routing protocol operation, in addition to the packet forwarding processes.
  • Implementation and maintenance: Implementation and maintenance describes the level of knowledge that is required for a network administrator to implement and maintain the network based on the routing protocol deployed.
Table 3-4 summarizes the characteristics of each routing protocol.

Table 3-4 Comparing Routing Protocols

Distance Vector
Link-State
RIPv1
RIPv2
IGRP
EIGRP
OSPF
IS-IS
Speed of Convergence
Slow
Slow
Slow
Fast
Fast
Fast
Scalability – Size of Network
Small
Small
Small
Large
Large
Large
Use of VLSM
No
Yes
No
Yes
Yes
Yes
Resource Usage
Low
Low
Low
Medium
High
High
Implementation and Maintenance
Simple
Simple
Simple
Complex
Complex
Complex

Routing Protocol Metrics 

There are cases when a routing protocol learns of more than one route to the same destination. To select the best path, the routing protocol must be able to evaluate and differentiate between the available paths. This is accomplished through the use of routing metrics.
A metric is a measurable value that is assigned by the routing protocol to different routes based on the usefulness of that route. In situations where there are multiple paths to the same remote network, the routing metrics are used to determine the overall “cost” of a path from source to destination. Routing protocols determine the best path based on the route with the lowest cost.
Different routing protocols use different metrics. The metric used by one routing protocol is not comparable to the metric used by another routing protocol. Two different routing protocols might choose different paths to the same destination.
For example, assume that PC1 wants to send a packet to PC2. In Figure 3-19, the RIP routing protocol has been enabled on all routers and the network has converged. RIP makes a routing protocol decision based on the least number of hops. Therefore, when the packet arrives on R1, the best route to reach the PC2 network would be to send it directly to R2 even though the link is much slower that all other links.
Figure 3-19
Figure 3-19 RIP Uses Shortest Hop Count Path
In Figure 3-20, the OSPF routing protocol has been enabled on all routers and the network has converged. OSPF makes a routing protocol decision based on the best bandwidth. Therefore, when the packet arrives on R1, the best route to reach the PC2 network would be to send it to R3, which would then forward it to R2.
Figure 3-20

-------------------END----------

No comments:

Post a Comment