Method and device for storing converting route table
A routing table and routing technology, applied in the field of network transmission, can solve the problems of high storage cost and insufficient capacity of the system, and achieve the effect that the forwarding performance will not be affected
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
Embodiment 1
[0100] see figure 1 , the present invention provides a method for forwarding routing table storage, the method optimizes the routing prefix by reducing the number of routing prefix bits, puts the optimized routing prefix in the non-linear table, and puts the remaining routing prefix information in the linear table. Assume that the route prefix optimization method is based on the route prefix minus 2 as the standard. The entry form of the forwarding routing table in this embodiment is shown in Table 3 and Table 4:
[0101] TCAM table:
[0102] TCAM index Optimizing route prefixes Optimizing route prefix length
[0103] table 3
[0104] Linear table:
[0105] linear part Next hop valid flag
[0106] Table 4
[0107] The specific steps of the method for storing the forwarding routing table are as follows:
[0108] Step 101: Obtain the routing information to be added, the routing information includes: routing prefix, prefix length and r...
Embodiment 2
[0130] see figure 2 , the present invention also provides a method for deleting routes. This embodiment is based on Embodiment 1 to delete the routes stored in the forwarding routing table that need to be deleted.
[0131] The specific steps of the method are as follows:
[0132] Step 201: Obtain entry deletion information: TCAM entry index, routing prefix and prefix length;
[0133] Step 202: find out the optimized routing prefix entry corresponding to the TCAM table according to the TCAM entry index, and then calculate the linear part of the route according to the routing prefix and the optimized routing prefix. The specific calculation method is the same as in Embodiment 1, and then according to the linear part Find the corresponding item in the linear table;
[0134] Step 203: After finding the corresponding item of the route in the linear part table item, judge whether the corresponding table item of the route is valid according to the corresponding value of the effect...
Embodiment 3
[0146] see image 3 , the present invention also provides a search method for forwarding routes, the method obtains the destination IP address of the route to be searched according to the forwarded message, combines nonlinear search and linear search, and performs message forwarding.
[0147] This embodiment searches forwarding routes based on Embodiment 1. This method applies the combined technology of nonlinear search and linear search. Non-linear search and linear search use different parts of the routing prefix value. Non-linear search gives a part of the results, and linear search gives a part of the results. The combination of the two is the final result. result.
[0148] The specific steps of the method are as follows:
[0149] Step 301: first give the IP address of the route to be forwarded;
[0150] Step 302: According to the longest matching principle of routing prefix (get the entry with the maximum length of all matched optimized routing prefixes), check the opt...
PUM
Login to View More Abstract
Description
Claims
Application Information
Login to View More 