Got it

IP network-Routing forwarding features

Latest reply: Jul 26, 2021 13:36:31 358 9 5 0 0

On the Internet, a network connecting devices such as hubs, bridges, switches, and routers control traffic and ensure data transmission quality. Each of these devices serves a different role, but for a common purpose: forming a functioning network. The following describes a router's role in a network and the purpose and nature of routes.

A router selects routes and forwards packets. Upon receiving a packet, a router selects a proper path, which may have one or multiple hops, to send the packet to the next router according to the destination address in the packet. The last router is responsible for sending the packet to the destination host.

A route is a path along which packets are sent from the source to the destination. When multiple routes are available to send packets from a router to the destination, the router can select the optimal route from an IP routing table. Optimal route selection depends on routing protocol preferences and metrics of routes. When multiple routes have the same routing protocol preference and metric, load balancing can be implemented among these routes to relieve network pressure. When multiple routes have different routing protocol preferences and metrics, route backup can be implemented among these routes to improve network reliability.

1. Router packet forwarding process

Extract the IP address D of the destination host from the header of the data packet to obtain the destination network address N.

If N is the address of a network directly connected to the router, the router is delivered directly.

If a specific host route with destination address D exists in the routing table, the datagram is sent to the next-hop router specified in the routing table.

If a route to network N exists in the routing table, the datagram is transmitted to the next-hop router specified in the routing table.

If there is a default route in the routing table, the datagram is sent to the default router specified in the routing table.

Report forwarding group error.

2. Routing Protocol

Routing protocols are adaptive and adapt to changes in network traffic and topology.

The Internet can be divided into much small ASs. One AS can use a different routing protocol than other ASs.


Routing protocols can be classified into two categories:

Routing within an AS: RIP and OSPF

Inter-AS route selection: BGP

RIP Fundamentals

RIP is based on the Distance-Vector (DV) algorithm. RIP uses hop count (HC) to measure the distance to the destination. The distance is called the metric value. In RIP, the default HC from a router to its directly connected network is 0, and the HC from a router to a reachable network through another router is 1. That is, the HC equals the number of routers passed from the local network to the destination network. To speed up network convergence, RIP defines the HC as an integer that ranges from 0 to 15. An HC 16 or greater is defined as infinity, that is, the destination network or the host is unreachable. For this reason, RIP is not applied to large-scale networks.

RIP Routing Table

When RIP starts on a router, the RIP routing table contains only the routes to the directly connected interfaces. After neighboring routers on different network segments learn the routing entries from each other, they can communicate with each other.

RIP routing table generation

1

Shows the process of RIP routing table generation.

  • RIP starts, and then RouterA broadcasts Request packets to neighboring routers.

  • When receiving the Request packet, RouterB encapsulates its own RIP routing table into the Response packet and broadcasts the Response packet to the network segment connected to the interface receiving the Request packet.

  • RouterA generates a routing table based on the Response packet sent from RouterB.

RIP Update and Maintenance

RIP uses four timers to update and maintain routing information:

  • Update timer: When this timer expires, a router immediately sends an Update packet.

  • Age timer: If a RIP device does not receive an Update packet from a neighbor within the aging time, the RIP device considers the route unreachable.

  • Garbage-collect timer: If a RIP device does not receive an Update packet of an unreachable route within the timeout interval, the device deletes the routing entry from the RIP routing table.

  • Suppress timer: When a RIP device receives an Update packet with the Cost field being 16 from a neighbor, the route is suppressed and the suppress timer starts. To avoid route flapping, the RIP device does not accept any Update packet before the suppress timer expires even if the Cost field in an Update packet is smaller than 16. After the suppress timer expires, the RIP device accepts new Update packets.

Relationships between RIP routes and timers:

  • The interval for sending Update packets is determined by the Update timer, which is 30 seconds by default.

  • Each routing entry has two timers: age timer and garbage-collect timer. When a RIP device adds a learned route to the local RIP routing table, the aging timer starts for the routing entry. If the RIP device does not receive an Update packet from the neighbor within the aging time, the RIP device sets the cost value of the route to 16 (unreachable, indicating that the route will be deleted from the RIP routing table), start the garbage-collect timer, and sends a packet for requesting the update of this unreachable route. If the RIP device still does not receive any Update packet within the garbage-collect timer, the device deletes the route from the RIP database.

Triggered Update

When routing information changes, a device immediately sends an Update packet to its neighbors, without waiting for Update timer expiration. This function avoids loops.

Triggered update

2

As shown, the routerC first learns that network 10.4.0.0 is unreachable.

  • If RouterC does not support triggered updates when detecting a link fault, it has to wait until the Update timer expires. If RouterC receives an Update packet from RouterB before its Update timer expires, RouterC learns a wrong route to network 10.4.0.0. In this case, the next hops of the routes from RouterB or RouterC to network 10.4.0.0 are RouterC and RouterB respectively. A routing loop is generated.

  • If RouterC supports triggered updates when detecting a link fault, RouterC immediately sends an Update packet to RouterB so that a routing loop is prevented.

understanding OSPF routing forwarding 

understanding BGP routing forwarding 



The post is synchronized to: HCIA - Datacom class notes

IndianKid
Moderator Author Created Jul 19, 2021 08:42:00

Thanks for sharing Jason, very good information
View more
  • x
  • convention:

Note with thanks
View more
  • x
  • convention:

good
View more
  • x
  • convention:

interesting
View more
  • x
  • convention:

Great share
View more
  • x
  • convention:

Thanks for sharing
View more
  • x
  • convention:

Thank you for sharing and keep up the good work!
View more
  • x
  • convention:

IP network-Routing forwarding features-4046667-1
View more
  • x
  • convention:

Very useful. Thanks for sharing
View more
  • x
  • convention:

Comment

You need to log in to comment to the post Login | Register
Comment

Notice: To protect the legitimate rights and interests of you, the community, and third parties, do not release content that may bring legal risks to all parties, including but are not limited to the following:
  • Politically sensitive content
  • Content concerning pornography, gambling, and drug abuse
  • Content that may disclose or infringe upon others ' commercial secrets, intellectual properties, including trade marks, copyrights, and patents, and personal privacy
Do not share your account and password with others. All operations performed using your account will be regarded as your own actions and all consequences arising therefrom will be borne by you. For details, see " User Agreement."

My Followers

Login and enjoy all the member benefits

Login

Block
Are you sure to block this user?
Users on your blacklist cannot comment on your post,cannot mention you, cannot send you private messages.
Reminder
Please bind your phone number to obtain invitation bonus.