dynamic routing

When adjacent routers communicate to inform each other of the network that each router is currently connected to, dynamic routing occurs.
Routers must use routing protocols to communicate, and there are many such routing protocols. There is a process on the router called the routing daemon, which runs the routing protocol and communicates with some of its neighboring routers. The routing daemon updates the routing table in the kernel based on the information it receives from the neighboring routers.

RIP: Routing Information Protocol
1. When starting a routing daemon, it first determines which interfaces are started, and sends a request message on each interface, asking other routers to send the complete routing table
2. Received a request, if it is a special request then send the complete routing table to the requester, otherwise, process each entry in the request: if there is a route connected to the specified address, set the metric to our value, otherwise set the metric to 16
3. Receive To the response. To make the response effective, the routing table may be updated. New entries may be added, existing entries may be modified, or existing entries may be deleted.
4. Regular routing update. Every 30 seconds, All or some routers will send their complete routing table to neighboring routers.
5. Trigger updates. Whenever a route's metric changes, it is updated. There is no need to send the full routing table, only those changes

Each route has a timer associated with it. If the system running RIP finds that a route has not been updated within 3 minutes, the metric of that route is set to infinity (16) and marked as deleted. This means The router that advertises the route has not received an update for 6 30-second update times. After another 60 seconds, the route will be deleted from the local routing table to ensure that the route's failure has been propagated.

OSPF: open shortest Path first, gradually replacing RIP
Unlike the RIP protocol that uses distance vectors, OSPF is a link state protocol. The distance vector means that the packets sent by RIP contain a distance vector (hop count). Each router is based on It receives these distance vectors from its neighbors to update its routing table.
In a link state protocol, each router actively tests the state of the link connected to its neighbors, sends this information to its other neighbors, and the neighbors propagate the information in the autonomous system. .Each router receives these link state information and builds a complete routing table.
OSPF uses IP directly. For the protocol field of the IP header, OSPF has its own value.
Its advantages:
1.OSPF can be used for each IP service type Calculate the respective routing table. This means that for any purpose, there can be multiple routing table entries, each entry corresponds to an IP service type
2. Assign a dimensionless fee to each interface. It can be calculated by throughput, Round-trip time, reliability, or other performance can be assigned. Each IP service type can be assigned a separate
fee , we call it traffic balancing.
4. OSPF supports subnets: a subnet mask is associated with each advertised route. This allows an IP address of any type to be divided into multiple subnets of different sizes. To a host's Routes are advertised with a subnet mask of all 1s. The default route is advertised with an IP address of 0.0.0.0 and a netmask of all 0s.
5. Point-to-point links between routers do not require an IP on each end Address , we call it
an unnumbered network It is an exterior gateway protocol that communicates between routers of different autonomous systems. The BGP system exchanges network reachable information with other BGP systems. This information includes all the paths in the autonomous system AS that the data must pass through to reach these networks. These The information is enough to construct an autonomous system connection diagram. Then, the routing loop can be deleted according to the connection diagram, and the routing strategy can be formulated





The difference between BGP and RIP and OSPF is that BGP uses TCP as its transport layer protocol. A TCP connection is established between two systems running BGP, and then the entire BGP routing table is exchanged. Keepalive messages are sent periodically to its neighbors to Detecting TCP connection link or host failure, BGP enumerates the route to each destination address (the sequence number of the autonomous system to the destination address). This eliminates some distance microprotocol issues

CIDR: Typeless Inter-
Domain Routing CIDR It is a method to prevent the expansion of Internet routing tables, also known as
supernet CIDR. The basic idea is to use a way of allocating multiple IP addresses so that it can sum up many entries in the routing table into a smaller number. For example, If you assign 16 class C addresses to a single site, assign the 16 addresses in a way that can be summed, so that all 16 addresses can refer to a single routing table entry on the Internet. Also, if there are 8 different The sites are connected to the Internet through the same connection point of the same Internet service provider, and the 8 different IP addresses assigned by these 8 sites can be summed up, then, for these 8 sites, on the Internet, only A single routing table entry
"untyped" means that the routing decision is now based on the mask operation of the entire 32-bit IP address, regardless of whether the IP address is class A, class B, or class C.

Guess you like

Origin http://10.200.1.11:23101/article/api/json?id=326944870&siteId=291194637