Maintaining the Routing Management Module
Context
The number of route prefixes that can be added to a routing table is limited. If the value exceeds the limit, new prefixes cannot be added to the routing table, which may interrupt services. To address this problem, configure an alarm threshold for the number of route prefixes.
If the device imports a large number of routes, system performance may be affected when services are being processed because the routes consume a lot of system resources. To improve system reliability, configure a limit on the number of public route prefixes. When the number of public route prefixes exceeds the limit, an alarm is generated, prompting you to check whether unnecessary public route prefixes exist.
Procedure
- Configure two thresholds (one alarm threshold and one clear
alarm threshold) for the number of route prefixes on a device.
Run system-view
The system view is displayed.
- Run either of the following commands as required:
Run ip prefix-limit system threshold-alarm upper-limit upper-limit-value lower-limit lower-limit-value
Two thresholds (one alarm threshold and one clear alarm threshold) for the number of IPv4 route prefixes are configured on the device.
By default, the alarm threshold for IPv4 route prefixes is 80%, and the clear alarm threshold for IPv4 route prefixes is 70%.
Run ipv6 prefix-limit system threshold-alarm upper-limit upper-limit-value lower-limit lower-limit-value
Two thresholds (one alarm threshold and one clear alarm threshold) for the number of IPv6 route prefixes are configured on the device.
By default, the alarm threshold for IPv6 route prefixes is 80%, and the clear alarm threshold for IPv6 route prefixes is 70%.
When you configure upper-limit-value and lower-limit-value, note the following suggestions:- Set a value smaller than or equal to 95 for upper-limit-value.
- lower-limit-value must be smaller than upper-limit-value. Set lower-limit-value to a value at least 10 smaller than upper-limit-value to prevent alarms from being frequently generated and cleared due to route flapping.
Run commit
The configuration is committed.
- Configure a limit on the number of public route prefixes.
Run system-view
The system view is displayed.
- Run either of the following commands as required:
Run ip prefix-limit number { alert-percent [ route-unchanged ] | simply-alert }
A limit on the number of IPv4 public route prefixes is configured.
By default, the maximum number of IPv4 public route prefixes is not limited.
Run ipv6 prefix-limit number { alert-percent [ route-unchanged ] | simply-alert }
A limit on the number of IPv6 public route prefixes is configured.
By default, the maximum number of IPv6 public route prefixes is not limited.
alert-percent indicates the percentage of the maximum number of public route prefixes that are supported. If you specify alert-percent in the command, an alarm is generated when the number of public route prefixes exceeds the value calculated by the following formula:
(number x alert-percent)/100
New public route prefixes can still be added to the routing table until the number of public route prefixes reaches the value of number. Subsequent route prefixes are then discarded.
If you specify simply-alert in the command, new public route prefixes can still be added to the routing table and only an alarm is generated after the number of public route prefixes exceeds the value of number. However, when the total number of private and public route prefixes reaches the limit on the number of unicast route prefixes specified in the PAF file, subsequent public route prefixes are discarded.
If you decrease the value of alert-percent after the number of public route prefixes exceeds the value of number, whether the routing table remains unchanged is determined by route-unchanged.If you specify route-unchanged in the command, the routing table remains unchanged.
If you do not specify route-unchanged in the command, the system deletes all the routes from the routing table and re-adds routes.
After the number of public route prefixes exceeds the limit, note the following rules:- If you run the ip prefix-limit command to increase the value of number or run the undo ip prefix-limit command to delete the limit, the device relearns IPv4 public route prefixes.
- If you run the ipv6 prefix-limit command to increase the value of number or run the undo ipv6 prefix-limit command to delete the limit, the device relearns IPv6 public route prefixes.
- Direct and static routes can still be added to the IP routing table.
Run commit
The configuration is committed.