Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

 
 

maximum-prefixes

Syntax

Hierarchy Level

Description

Configure a limit for the number of routes installed in a routing table based upon the route prefix.

Using a prefix limit, you can curtail the number of prefixes received from a CE router in a VPN. Prefix limits apply only to dynamic routing protocols and are not applicable to static, programmed, or interface routes.

Note:

Static, programmed [that is, programmable routing protocol process (prpd) configured], and interface routes contribute to the overall route total count used in the maximum-prefix calculation. The number of such routes affects the number of dynamic routes that are accepted in to the virtual routing instance. In the configuration example shown below, if VRF1 contains 98 static routes and 2 interface routes, then a maximum of 900 BGP routes (that is, 1000 - 98 - 2 = 900) are allowed, with a syslog warning shown at a total of 800 dynamic routes, which is 80%.

If the number of static, programmed, or interface routes increases, then it can affect the maximum number of dynamic routes that are accepted. Note that the static, programmed, or interface routes are not subject to the configured maximum-prefixes limit and can have a negative or undesired effect on the dynamic routes.

The maximum-prefixes statement is similar to the maximum-paths statement. The maximum-prefixes statement limits the number of unique destinations in a routing instance. For example, suppose a routing instance has the following routes:

These are two routes, but only one destination (prefix). The maximum-paths limit applies the total number of routes (two). The maximum-prefixes limit applies to the total number of unique prefixes (one).

Options

log-interval seconds—(Optional) Minimum time interval (in seconds) between log messages.

  • Range: 5 through 86,400

log-only—(Optional) Sets the prefix limit as an advisory limit. An advisory limit triggers only a warning, and additional routes are not rejected.

prefix-limit—Maximum number of route prefixes. If this limit is reached, a warning is triggered and any additional routes are rejected.

  • Range: 1 through 4,294,967,295

  • Default: No default

threshold value—(Optional) Percentage of the maximum number of prefixes that starts triggering a warning. You can configure a percentage of the prefix-limit value that starts triggering the warnings.

  • Range: 1 through 100

Note:

When the number of routes reaches the threshold value, routes are still installed into the routing table while warning messages are sent. When the number of routes reaches the prefix-limit value, then additional routes are rejected.

Required Privilege Level

routing—To view this statement in the configuration.

routing-control—To add this statement to the configuration.

Release Information

Statement introduced in Junos OS Release 8.0.