Supported Platforms
Related Documentation
- ACX, EX, M, MX, PTX, QFX, T Series
- family
- ACX, EX, M, MX, PTX, SRX, T Series
- local-as
- EX, M, MX, PTX, QFX, T Series
- autonomous-system
loops
Syntax
Hierarchy Level
Release Information
Statement introduced in Junos OS Release 9.6.
Description
Globally, for the local-AS BGP attribute, or the specified address family, allow the local device’s AS number to be in the received AS paths, and specify the number of times detection of the local device’s AS number in the AS_PATH attribute causes the route to be discarded or hidden. For example, if you configure loops 1, the route is hidden if the local device’s AS number is detected in the path one or more times. This prevents routing loops and is the default behavior. If you configure loops 2, the route is hidden if the local device’s AS number is detected in the path two or more times.
Some examples of BGP address families are as follows:
- inet unicast
- inet-vpn multicast
- inet6 any
- l2vpn auto-discovery-only
- ...
This list is truncated for brevity. For a complete list of protocol families for which you can specify the loops statement, enter the help apropos loops configuration command at the [edit protcols bgp] hierarchy level on your device.
[edit protocols bgp]
user@host# help apropos loops
set family inet unicast loops Allow local AS in received AS paths set family inet unicast loops <loops> AS-Path loop count set family inet multicast loops Allow local AS in received AS paths set family inet multicast loops <loops> AS-Path loop count set family inet flow loops Allow local AS in received AS paths set family inet flow loops <loops> AS-Path loop count set family inet any loops Allow local AS in received AS paths set family inet any loops <loops> AS-Path loop count set family inet labeled-unicast loops Allow local AS in received AS paths ...
![]() | Note: When you configure the loops statement for a specific BGP address family, that value is used to evaluate the AS path for routes received by a BGP peer for the specified address family, rather than the loops value configured for the global AS number with the loops statement at the [edit routing-options autonomous-system as-number] hierarchy level. |
Options
number—Number of times detection of the AS number in the AS_PATH attribute causes the route to be discarded or hidden.
Range: 1 through 10
Default: 1
Required Privilege Level
routing—To view this statement in the configuration.
routing-control—To add this statement to the configuration.
Related Documentation
- ACX, EX, M, MX, PTX, QFX, T Series
- family
- ACX, EX, M, MX, PTX, SRX, T Series
- local-as
- EX, M, MX, PTX, QFX, T Series
- autonomous-system
Published: 2012-09-09
Supported Platforms
Related Documentation
- ACX, EX, M, MX, PTX, QFX, T Series
- family
- ACX, EX, M, MX, PTX, SRX, T Series
- local-as
- EX, M, MX, PTX, QFX, T Series
- autonomous-system