Directory
Routing Protocol features
Illustration
Default route
Specific Host Routing
Route table information
Group forwarding algorithm
Dynamic Routing
Ideal Routing Algorithm
Hierarchical routing protocol
Autonomous System
There are two types of routing protocols for the Internet
Forwarding and Route Selection
Routing Protocol features
There is no absolute optimal routing algorithm. The so-called "best" can only be a more reasonable choice than a specific requirement.
The actual routing selection algorithm should be as close as possible to the ideal Algorithm
Routing selection is a complex problem and the result of coordination between all nodes in the network.
The environment of route selection is constantly changing, and such changes are sometimes unknown in advance.
Illustration
Default route
Definition: The router can make a selection when there is no matching table item between the route table and the destination address of the package.
Applicability: A host is connected to a small network, and this network only uses one vro to connect to the Internet. In this case, it is very suitable to use the default route.
Advantages: Reduce the space occupied by the route table and the time used to search the route table
Specific Host Routing
Definition: Specify a route for a specific target host
Advantages: Enables network administrators to easily control networks and test networks. You can also use this host route when you need to consider certain security issues.
Route table information
Destination Network
Next Hop
Measurement
Group forwarding algorithm
Features:
- IP datagram can eventually find the vro on the destination network where the target host is located (it may need to be delivered through multiple indirect deliveries)
- Direct delivery to the target host is attempted only when the last vro is reached
Forwarding condition:
- Forwarding:
- There is a matching entry
- No matching entry but default route exists
- Discard:
- Directly Connected Network
- No matching entries or default routes
Steps:
Dynamic Routing
Definition:
Vro dynamically shares the Rule Set Based on Its Routing Protocol
Category:
- Route information protocol (RIP)
- Enhanced Internal Gateway Routing Protocol (VPN)
- Open Shortest Path First (OSPF)
Ideal Routing Algorithm
The algorithm must be correct and complete.
Algorithm should be simple in computing
Self-adaptability(Adapt to changes in traffic and network topology)
Category:
- Static route selection policy-- Non-adaptive routing is characterized by simplicity and low overhead, but cannot adapt to changes in network status in a timely manner.
- Dynamic Route Selection Policy-- Adaptive route selection is a feature that can better adapt to changes in the network status, but the implementation is complicated and overhead is also relatively large.
Method should be stable
The algorithm should be fair.
The algorithm should be the best
Hierarchical routing protocol
Cause:
- The Internet is very large, and millions of routers are connected to each other.
- Many organizations do not want to know the layout details of their networks and the routing protocols adopted by their respective departments, but they also want to connect to the Internet.
Autonomous System
Definition:
A group of routers under a single technical management, and these routers use an as internal routing selection protocol and a common measurement to determine the routes grouped in the, in addition, a routing protocol between as is used to determine the routing between groups in.
Status quo:
Although an as uses a variety of internal routing selection protocols and metrics, it is important that an as shows a single and consistent routing strategy for other.
Illustration:
There are two types of routing protocols for the Internet
Internal Gateway Protocol IGP (interior gateway protocol)
Summary:
The routing protocol used in an autonomous system. Currently, this type of routing is used most frequently, such as Rip and OSPF.
Basic Ideas:
- Can it be delivered directly?
- Seek help from neighbors
- Who can help me better?
Rip:
Summary:
Based on the distance vector routing selection Protocol, each vro in the network must maintain the distance record from itself to each other destination network.
Baotou:
Command Field:1 indicates a request, 2 indicates a response, and two additional commands (3 and 4) are discarded. Two informal commands are available: Round Robin (5) and round robin (6)
Distance:
-
- The distance from a vro to a directly connected network is defined as 1.
- The distance from a router to a non-directly connected network is defined as the number of routers plus 1
- A maximum of 15 vrouters can be contained in a single path.
- When the maximum value is 16, it is equivalent to not reachable.
Three key points:
-
- Exchange information with adjacent routers only
- The information exchanged is all information that the current vro knows.
- Exchange route information at fixed intervals
Method for handling the route table:
Advantages:
Simple implementation with low overhead
Disadvantages:
This means that the good news spreads fast, while the bad news spreads slowly.
OSPF:
Three key points:
-
- Send information to all vrouters in the autonomous system. The general method is used here.
- The sent information is the link status of all routers adjacent to the current vro, but this is only part of the information that the vro knows. "link status" indicates which routers are adjacent to the vro and the "measurement" (metric) of the link)
- The router sends this information to all routers in flood mode only when the link status changes. The link status in the database needs to be refreshed once every time.
Advantages:
-
- Fast convergence in the update process
- Supports classless Inter-Domain Routing (CIDR) and classless Inter-Domain Routing (CIDR ).
Data Packets:
Features:
Instead of UDP, IP datagram is directly used for transmission and the datagram is short.
Illustration:
Region:
Purpose:
OSPF can be used for a large network to divide an autonomous system into several smaller ranges, called regions.
Requirements:
The region cannot be too large. It is recommended that there be no more than 200 vrouters in one region.
Advantages:
The range of link state information exchange by flood method is limited to every region rather than the entire autonomous system, which reduces the traffic on the entire network.
Trunk region:
-
-
- The identifier must be set to 0.0.0.0.
- The router knows the complete network topology.
- Used to connect other lower-layer areas
Non-trunk zone:
-
-
- The vro inside the vro only knows the complete network topology of the local region, but does not know the network topology of other regions.
- At least one regional border router is required
Five grouping types:
-
- Greeting (Hello) Group
- Database description Group
- Link State request Group
- Link State update group, which uses the flooding method to update the link status of the entire network.
- Link State Acknowledgment
External gateway protocol EGP (external Gateway Protocol)
Summary:
If the source station and the target station are in different autonomous systems, when the datagram is transmitted to the boundary of an autonomous system, a protocol is required to transmit the routing selection information to another autonomous system. This Protocol is the external gateway protocol EGP. BGP-4 is currently the most used in external gateway protocols
BGP:
Summary:
BGP is a protocol for exchanging routing information between vrouters of different Autonomous Systems.
Exchange route information:
First, establish a TCP connection and use the TCP connection to exchange route information between the two BGP spokespersons.
Then exchange BGP packets on this connection to establish a BGP session)
Exchange route information using BGP sessions
Bgp spokesman:
The BGP spokesman is usually a BGP border router, but it can also be a BGP border router. The two BGP spokespersons are connected through a shared network.
Illustration:
Features:
The node order of the BGP protocol to exchange route information is the magnitude of the number of autonomous systems.
The number of BGP spokespersons (or virtual border routers) in each autonomous system is very small.
BGP supports CIDR. Therefore, the BGP Route table should include the destination network prefix, the next hop router, and the autonomous system sequence to be passed to the destination network.
When BGP is just running, the BGP neighbor switches the entire BGP Route table. however, you only need to update the changed part in the future. this will benefit both network bandwidth saving and router processing overhead.
BGP can only be used to find a route that can reach the target network (not in circles), rather than finding the best route.
Process:
Header:
Four types of packets:
An open packet is used to establish a relationship with another adjacent BGP speaker.
Update messages are used to send information about a route entry and list multiple routes to undo.
Keepalive messages are used to confirm the Enable message and periodically confirm the relationship between neighboring sites.
Notification messages are used to send detected errors.
Forwarding and Route Selection
Forward)That is, the router forwards the user's IP datagram from the appropriate port according to the forwarding table.
Routing)Based on the distributed algorithm, the selected route is dynamically changed based on the changes in the network topology obtained from each adjacent router.
(Network Layer) Routing Protocol