OcNOS-SP : Layer 3 Guide : Border Gateway Protocol Command Reference : BGP Commands
BGP Commands
This chapter describes the BGP configuration commands.
address-family
Use the address family command to enter the IPv4 or VPNv4 address family mode allowing configuration of address-family specific parameters. To leave the address family mode and return to the Configure mode use the exit-address-family command.
This command configures the routing exchange between Provider Edge (PE) and Customer Edge (CE) devices. The BGP sessions between PE routers can carry different types of routes (VPN-IPv4 and IPv4 routes). Address families are used to control the type of BGP session. Configure a BGP address family for each VRF configured on the PE router and a separate address family to carry VPN-IPv4 routes between PE routers. All non VPN BGP neighbors are defined using router mode. All VPN BGP neighbors are defined under its associated address family mode. The BGP process with no address-family specified is the default address-family, where any sessions are configured that either are not associated with a VRF or are used to carry IPv4 routes.
Use the no parameter with this command to disable the address-family configurations.
Command Syntax
address-family ipv4
address-family ipv4 (unicast|multicast)
address-family ipv4 vrf NAME
address-family l2vpn evpn
address-family rtfilter unicast
address-family vpn4
address-family vpn4 unicast
no address-family ipv4 vrf NAME
no address-family ipv4 (unicast|multicast)
no address-family l2vpn evpn
no address-family rtfilter unicast
no address-family vpnv4
no address-family vpnv4 unicast
Parameters
ipv4
IPv4 address family
unicast
Unicast address prefixes
multicast
Multicast address prefixes
vrf
Virtual Private Network (VPN) routing/forwarding instance
NAME
VPN routing/forwarding instance name
unicast
Unicast address prefixes
l2vpn evpn
Layer 2 VPN routing sessions with EVPN endpoint information distributed to BGP peers
rtfilter
Route target filter: on an iBGP peer or Route Reflector (RR), only send IPv4 and IPv6 prefixes to PE routers when a PE has a VRF that imports those specific prefixes.
unicast
Unicast address prefixes
vpnv4
VPN version 4 address family
unicast
Unicast address prefixes
Applicability
No default value is specified
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 7657
(config-router)#neighbor 3ffe:506::1 remote-as 7657
(config-router)#neighbor 3ffe:506::1 interface eth1
 
#configure terminal
(config)#router bgp 7657
(config-router)#address-family ipv4 unicast
(config-router-af)#neighbor 3ffe:506::1 activate
(config-router-af)#exit-address-family
aggregate-address
Use this command to configure BGP aggregate entries.
Aggregates are used to minimize the size of routing tables. Aggregation combines the characteristics of several different routes and advertises a single route.The aggregate-address command creates an aggregate entry in the BGP routing table if any more-specific BGP routes are available in the specified range. Using the summary-only parameter advertises the prefix only, suppressing the more-specific routes to all neighbors. In the following example Router1 will propagate network 172.0.0.0 and suppresses the more specific route 172.10.0.0.
The as-set parameter creates an aggregate entry advertising the path for this route, consisting of all elements contained in all paths being summarized. Use this parameter to reduce the size of path information by listing the AS number only once, even if it was included in multiple paths that were aggregated. The as-set parameter is useful when aggregation of information results in an incomplete path information.
Use the no parameter with this command to disable this function.
Command Syntax
aggregate-address A.B.C.D/M
aggregate-address A.B.C.D/M as-set
aggregate-address A.B.C.D/M as-set summary-only
aggregate-address A.B.C.D/M summary only
aggregate-address A.B.C.D/M summary-only as-set
no aggregate-address A.B.C.D/M
Parameters
A.B.C.D/M
Aggregate prefix
as-set
Generate AS set path information
summary-only
Filter more specific routes from updates
Default
By default, aggregate address A.B.C.D/M is disabled
Command Mode
Address Family mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 100
(config-router)#address-family ipv4 unicast
(config-router-af)#aggregate-address 10.0.0.0/8 as-set summary-only
 
(config)#router bgp 100
(config-router)#address-family ipv4 unicast
(config-router-af)#no aggregate-address 10.0.0.0/8
auto-summary
Use this command to enable sending summarized routes by a BGP speaker to its peers in the router configuration mode or in the address-family configuration mode. Auto-summary is used by a BGP router to advertise summarized routes to its peers. Auto-summary can be enabled if certain routes have already been advertised: in this case, configuring auto-summary advertises the summarized routes first, then corresponding non-summarized routes are withdrawn. If certain routes have already been advertised, and auto-summary is disabled, non-summarized routes are first advertised, then the corresponding summarized routes are withdrawn from all the connected peers.
Use the no parameter with this command to disable this function.
Command Syntax
auto-summary
no auto-summary
Parameters
None
Default
By default, auto-summary is disabled
Command Mode
Address Family mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 11
(config-router)#address-family ipv4 unicast
(config-router-af)#auto-summary
 
 
 
bgp aggregate-nexthop-check
Use this command to set the BGP option to perform aggregation only when next-hop matches the specified IP address.
Use the no parameter with this command to disable this functionality.
Command Syntax
bgp aggregate-nexthop-check
no bgp aggregate-nexthop-check
Parameters
None
Default
By default, bgp aggregate nexthop check is disabled
Command Mode
Configure mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#bgp aggregate-nexthop-check
bgp always-compare-med
Use this command to compare the Multi Exit Discriminator (MED) for paths from neighbors in different autonomous systems. Multi Exit Discriminator (MED) is used in best path selection by BGP. MED is compared after BGP attributes weight, local preference, AS-path and origin have been compared and are equal. MED comparison is done only among paths from the same autonomous system (AS). Use bgp always-compare-med command to allow comparison of MEDs from different ASs. The MED parameter is used to select the best path. A path with lower MED is preferred. If the bgp table shows the following and the always-compare-med is enabled:
Route1: as-path 400, med 300
Route2: as-path 200, med 200
Route3: as-path 400, med 250
Route1 is compared to Route2. Route2 is best of the two (lower MED). Next, Route2 is compared to Route3 and Route2 is chosen best path again (lower MED). If always-compare-med was disabled, MED is not taken into account when Route1 and Route2 are compared, because of different ASs and MED is compared for only Route1 and Route3. In this case, Route3 would be the best path. The selected route is also affected by the bgp deterministic-med command. Please see bgp deterministic-med command for details. If this command is used to compare MEDs for all paths, it should be configured on every BGP router in the AS.
Use the no parameter with this command to disallow the comparison.
Command Syntax
bgp always-compare-med
no bgp always-compare-med
Parameters
None
Default
By default, bgp always compare med is disabled
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 100
(config-router)#bgp always-compare-med
bgp as-local-count
Use this command to set the number of times the local-AS (Autonomous System) is to be prepended.
Use the no parameter with this command to stop prepending the local AS count.
Command Syntax
bgp as-local-count <2-64>
no bgp as-local-count <2-64>
Parameter
<2-64>
The number of times the local-AS is to be prepended
Default
By default, bgp as local count is disabled
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 100
(config-router)#bgp as-local-count 55
 
(config)#router bgp 100
(config-router)#no bgp as-local-count 55
bgp bestpath as-path ignore
Use this command to prevent the router from considering the autonomous system (AS) path length as a factor in the algorithm for choosing a best path route.
Use the no parameter with this command to allow the router to consider the AS path length in choosing a best path route.
Command Syntax
bgp bestpath as-path ignore
no bgp bestpath as-path ignore
Parameters
None
Default
By default, bgp bestpath as-path ignore is disabled
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 100
(config-router)#bgp bestpath as-path ignore
 
(config)#router bgp 100
(config-router)#no bgp bestpath as-path ignore
bgp bestpath as-path multipath-relax
Use this command to relax the “same AS-Path” requirement so any candidate eBGP AS-Path with the same AS-path length might be used for eBGP load-balancing.
Note: This feature does not load-balance between eBGP and iBGP paths.
Normally eBGP load-balancing requires the candidate routes to be equal-cost paths with identical BGP attributes having the same weight, Local-Pref, AS-Path (both the AS numbers and the AS path length), origin, MED, and different next-hop.
Use the no parameter with this command to return to normal operation.
Command Syntax
bgp bestpath as-path multipath-relax
no bgp bestpath as-path multipath-relax
Parameters
None
Default
By default, as-path multipath-relax is disabled
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 100
(config-router)#bgp bestpath as-path multipath-relax
 
(config)#router bgp 100
(config-router)#no bgp bestpath as-path multipath-relax
bgp bestpath compare-confed-aspath
Use this command to allow comparing of the confederation AS path length. This command specifies that the AS confederation path length must be used when available in the BGP best path decision process. It is effective only when bgp bestpath as-path ignore command has not been used.
Use the no parameter with this command to ignore consideration of AS confederation path length in BGP best path selection.
Command Syntax
bgp bestpath compare-confed-aspath
no bgp bestpath compare-confed-aspath
Parameters
None
Default
BGP receives routes with identical eBGP paths from eBGP peers and selects the first route received as the best path.
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 100
(config-router)#bgp bestpath compare-confed-aspath
 
(config)#router bgp 100
(config-router)#no bgp bestpath compare-confed-aspath
bgp bestpath compare-routerid
Use this command to compare router IDs for identical eBGP paths. When comparing similar routes from peers, the BGP router does not consider the router ID of the routes. By default, it selects the first received route. Use this command to include router ID in the selection process; similar routes are compared and the route with the lowest router ID is selected. The router IS is the highest IP address on the router, with preference given to loopback addresses. Router ID can be manually set by using the bgp router-id command.
Use the no parameter with this command to disable this functionality.
Command Syntax
bgp bestpath compare-routerid
no bgp bestpath compare-routerid
Parameters
None
Default
BGP receives routes with identical eBGP paths from eBGP peers and selects the first route received as the best path.
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 100
(config-router)#bgp bestpath compare-routerid
 
(config)#router bgp 100
(config-router)#no bgp bestpath compare-routerid
bgp bestpath dont-compare-originator-id
Use this command to change the default bestpath selection by not comparing an originator-ID for an identical EBGP path.
Use the no parameter with this command to disable this functionality.
Command Syntax
bgp bestpath dont-compare-originator-id
no bgp bestpath dont-compare-originator-id
Parameters
None
Default
BGP receives routes with identical eBGP paths from eBGP peers and selects the first route received as the best path.
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 100
(config-router)#bgp bestpath dont-compare-originator-id
 
(config)#router bgp 100
(config-router)#no bgp bestpath dont-compare-originator-id
bgp bestpath med
Use this command to specify two MED (Multi Exit Discriminator) attributes, confed and missing-as-worst.
The confed attribute enables MED comparison along paths learned from confederation peers. The MEDs are compared only if there is no external Autonomous System (an AS not within the confederation) in the path. If there is an external autonomous system in the path, the MED comparison is not made. For example in the following paths, the MED is not compared with Route3 as it is not in the confederation. MED is compared for Route1 and Route2 only.
Path1 = 32000 32004, med=4
Path2 = 32001 32004, med=2
Path3 = 32003 1, med=1
The missing-as-worst attribute to consider a missing MED attribute in a path as having a value of infinity, making the path without a MED value the least desirable path. If missing-as-worst is disabled, the missing MED is assigned the value of 0, making the path with the missing MED attribute the best path.
Use the no parameter with this command to prevent BGP from considering the MED attribute in comparing paths.
Command Syntax
bgp bestpath med confed missing-as-worst
bgp bestpath med (confed|missing-as-worst|remove-recv-med|remove-send-med)
bgp bestpath med missing-as-worst confed
no bgp bestpath med confed missing-as-worst
no bgp bestpath med (confed|missing-as-worst|remove-recv-med|remove-send-med)
no bgp bestpath med missing-as-worst confed
Parameters
confed
Compare MED along confederation paths
missing-as-worst
 
Treat missing MED as the least preferred one
remove-recv-med
Remove received MED attribute
remove-send-med
 
Remove sent MED attribute
Command Mode
Router mode
Default
By default, MED value is zero.
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 100
(config-router)#bgp bestpath med missing-as-worst
 
(config)#router bgp 100
(config-router)#bgp bestpath med remove-recv-med
(config-router)#no bgp bestpath med remove-recv-med
 
(config)#router bgp 100
(config-router)#bgp bestpath med remove-send-med
(config-router)#no bgp bestpath med remove-send-med
bgp bestpath tie-break-on-age
Use this command to always select a preferred older route even when the bgp bestpath compare-routerid command is configured.
Use the no parameter with this command to disable this functionality.
Command Syntax
bgp bestpath tie-break-on-age
no bgp bestpath tie-break-on-age
Parameters
None
Default
By default, tie-break-on-age is disabled
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 100
(config-router)#bgp bestpath tie-break-on-age
 
(config)#router bgp 100
(config-router)#no bgp bestpath tie-break-on-age
bgp client-to-client reflection
Use this command to configure routers as route reflectors. Route reflectors are used when all Interior Border Gateway Protocol (iBGP) speakers are not fully meshed. If the clients are fully meshed the route reflector is not required, use no bgp client-to-client reflection command to disable the client-to-client route reflection.
Use the no parameter with this command to turn off client-to-client reflection.
Command Syntax
bgp client-to-client reflection
no bgp client-to-client reflection
Parameters
None
Default
When a router is configured as a route reflector, client-to-client reflection is enabled by default.
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 100
(config-router)#bgp client-to-client reflection
 
(config)#router bgp 100
(config-router)#no bgp client-to-client reflection
bgp cluster-id
Use this command to configure the cluster ID if the BGP cluster has more than one route reflector. A cluster includes route reflectors and its clients. Usually, each cluster is identified by the router ID of its single route reflector but to increase redundancy sometimes a cluster may have more than one route reflector. All router reflectors in such a cluster are then identified by a cluster ID. The bgp cluster-id command is used to configure the 4 byte cluster ID for clusters with more than one route reflectors.
Use the no parameter with this command (without any arguments) to remove a previously configured route reflector cluster ID.
Command Syntax
bgp cluster-id <1-4294967295>
bgp cluster-id A.B.C.D
no bgp cluster-id
Parameters
<1-4294967295>
Route reflector ID as a 32-bit quantity
A.B.C.D
Route reflector ID in an IPv4 address format
Default
By default, cluster id is set bgp cluster id
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
The following configuration creates a cluster-id 5 including two route-reflector-clients.
#configure terminal
(config)#router bgp 100
(config-router)#neighbor 2.2.2.2 remote-as 200
(config-router)#neighbor 3.3.3.3 remote-as 200
(config-router)#neighbor 5.5.5.5 remote-as 200
(config-router)#neighbor 6.6.6.6 remote-as 200
(config-router)#bgp cluster-id 5
(config-router)#address-family ipv4 unicast
(config-router-af)#neighbor 3.3.3.3 route-reflector-client
(config-router-af)#neighbor 5.5.5.5 route-reflector-client
bgp confederation identifier
Use this command to specify a BGP confederation identifier.
Use the no parameter with this command to remove a BGP confederation identifier.
Command Syntax
bgp confederation identifier <1-65535>
no bgp confederation identifier
Parameter
<1-65535>
Routing domain confederation AS number
Default
No default value is specified
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 100
(config-router)#bgp confederation identifier 1
bgp confederation peers
Use this command to configure the Autonomous Systems (AS) that belong to a confederation. A confederation allows an AS to be divided into several ASs. The AS is given a confederation identifier. External BGP (eBGP) routers view only the whole confederation as one AS. Each AS is fully meshed within itself and is visible internally to the confederation.
Use the no parameter with this command to remove an autonomous system from the confederation.
Command Syntax
bgp confederation peers <1-65535>
no bgp confederation peers <1-65535>
Parameter
<1-65535>
AS numbers of eBGP peers that are in the same confederation
Default
No default value is specified
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
In the following configuration example, the neighbor 172.210.30.2 and 172.210.20.1 have iBGP connection within AS 100, neighbor 173.213.30.1 is a BGP connection with a confederation peer 200 and neighbor 6.6.6.6 has an eBGP connection to external AS 300.
#configure terminal
(config)#router bgp 100
(config-router)#bgp confederation identifier 300
(config-router)#bgp confederation peers 200
(config-router)#neighbor 172.210.30.2 remote-as 100
(config-router)#neighbor 172.210.20.1 remote-as 100
(config-router)#neighbor 173.213.30.1 remote-as 200
(config-router)#neighbor 6.6.6.6 remote-as 300
In this configuration, the neighbor 5.5.5.4 has an eBGP connection to confederation 300.
#configure terminal
(config)#router bgp 500
(config-router)#neighbor 5.5.5.4 remote-as 300
bgp config-type
Use this command to set the BGP configuration to the standard type. After setting the configuration to the standard type, use the neighbor send-community command to send out BGP community attributes. The zebos configuration type is the default and requires no specific configuration for sending out BGP standard community and extended community attributes.
For the standard type, the no synchronization command is always shown in the configuration, whereas for the zebos type, this command is the default.
Use the no parameter with this command to remove this configuration.
Command Syntax
bgp config-type (standard|zebos)
no bgp config-type
Parameters
standard
Standard style configuration
zebos
OcNOS style configuration
Default
The default configuration type is: bgp config-type zebos
Command Mode
Configure mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#bgp config-type standard
bgp dampening
Use this command to enable BGP route dampening and set various parameters. Route dampening minimizes the instability caused by route flapping. A penalty is added for every flap in a flapping route. As soon as the total penalty reaches the suppress limit the advertisement of the route is suppressed. This penalty is decayed according to the configured half time value. Once the penalty is lower than the reuse limit, the route advertisement is un-suppressed. The dampening information is purged from the router once the penalty becomes less than half of the reuse limit.
Use the no parameter with this command to unset BGP dampening parameters.
Command Syntax
bgp dampening
bgp dampening <1-45>
bgp dampening <1-45> <1-20000> <1-20000> <1-255>
bgp dampening <1-45> <1-20000> <1-20000> <1-255> <1-45>
bgp dampening route-map WORD
no bgp dampening
Parameters
<1-45>
Reachability half-life time for the penalty in minutes. The time for the penalty to decrease to one-half of its current value.
<1-20000>
Value to start reusing a route. When the penalty for a suppressed route decays below the reuse value, the routes become unsuppressed.
<1-20000>
Value to start suppressing a route. When the penalty for a route exceeds the suppress value, the route is suppressed
<1-255>
Maximum duration to suppress a stable route in minutes.
<1-45>
Un-reachability half-life time for the penalty in minutes.
route-map
Route map to specify criteria for dampening.
WORD
Route-map name.
Defaults
The default reachability half-life is 15 minutes.
The default reuse limit is 750.
The default suppress limit is 2000.
The default max-suppress value is 4 times the half-life time, or 60 minutes.
Command Mode
Address Family mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 11
(config-router)#address-family ipv4 unicast
(config-router-af)#bgp dampening 20 800 2500 80 25
bgp default local-preference
Use this command to change the default local preference value.Local preference indicates the preferred path when there are multiple paths to the same destination. The path having a higher preference is preferred. The preference is sent to all routers and access servers in the local autonomous system.
Use the no parameter with this command to revert to the default value for local preference.
Command Syntax
bgp default local-preference <0-4294967295>
no bgp default local-preference
no bgp default local-preference <0-4294967295>
Parameter
<0-4294967295>
Local preference value
Default
By default, local preference value is 100
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 100
(config-router)#bgp default local-preference 2345555
bgp deterministic-med
Use this command to compare the Multi Exit Discriminator (MED) variable when choosing among routes advertised by different peers in the same autonomous system. MED is compared after BGP attributes weight, local preference, AS-path and origin have been compared and are equal.
For a correct comparison result, enable this command on all routers in a local AS. After enabling this command, all paths for the same prefix are grouped together and arranged according to their MED value. Based on this comparison, the best path is then chosen. This command compares MED variable when choosing routes advertised by different peers in the same AS, to compare MED, when choosing routes from neighbors in different ASs use the bgp always-compare-med command.
When the bgp deterministic-med command is enabled, routes from the same AS are grouped together, and the best routes of each group are compared. If the BGP table showed:
Route1: as-path 200, med 300, internal
Route2: as-path 400, med 200, internal
Route3: as-path 400, med 250, external
BGP would have a group of Route1 and a second group of Route2 and Route3 (the same ASs). The best of each group is compared. Route1 is the best of its group because it is the only route from AS 200. Route1 is compared to the Route2, the best of group AS 400 (the lower MED). Since the two routes are not from the same AS, the MED is not considered in the comparison. The external BGP route is preferred over the internal BGP route, making Route3 the best route; the preferred route would be different if always-compare-med command is enabled (See always-compare-med command).
Use the no parameter with this command to disallow this setting.
Command Syntax
bgp deterministic-med
no bgp deterministic-med
Parameters
None
Default
By default, bgp deterministic med is disabled
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 100
(config-router)#bgp deterministic-med
 
(config)#router bgp 100
(config-router)#no bgp deterministic-med
bgp enforce-first-as
Use this command to enforce the first AS for eBGP routes. This command specifies that any updates received from an external neighbor that do not have the neighbor’s configured Autonomous System (AS) at the beginning of the AS_PATH in the received update must be denied. Enabling this feature adds to the security of the BGP network by not allowing traffic from unauthorized systems.
Using the no parameter with this command to disable this feature.
Command Syntax
bgp enforce-first-as
no bgp enforce-first-as
Parameters
None
Default
By default, enforce-first-as is disabled
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 100
(config-router)#bgp enforce-first-as
 
(config)#router bgp 100
(config-router)#no bgp enforce-first-as
bgp extended-asn-cap
Use this command to configure a BGP router to send 4-octet ASN capabilities. If attempting to change the AS capability from 2 to 4 or 4 to 2, a prompt occurs to remove the VRF configuration (if it exists), and reconfiguration is required, because the route distinguisher (RD) configuration would have been created with the current (2 octet or 4 octet) capability, and must be reconfigured before attempting to change the capability.
While loading from a saved configuration with AS4 capability and BGP VRF configuration, the capability will not be changed because of the above described reason.
Use the no parameter with this command to prevent a BGP router from sending 4-octet ASN capabilities.
Command Syntax
bgp extended-asn-cap
no bgp extended-asn-cap
Parameters
None
Default
By default, the bgp extended ASN capability and Four-octet capabilities are disabled.
Command Mode
Configure mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#bgp extended-asn-cap
bgp fast-external-failover
Use this command to reset a BGP session immediately, if the interface used for BGP connection goes down.
Use the no parameter with this command to disable this feature.
Command Syntax
bgp fast-external-failover
no bgp fast-external-failover
Parameters
None
Default
By default, fast-external failover is enabled
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
#configure terminal
(config)#router bgp 100
(config-router)#bgp fast-external-failover
bgp graceful-restart
Use this command to enable BGP graceful-restart capabilities. The restart-time parameter is used for setting the maximum time that a graceful-restart neighbor waits to come back up after a restart. This value is applied to all neighbors unless you explicitly override it by configuring the corresponding value on the neighbor. The stalepath-time parameter is used to set the maximum time to preserve stale paths from a gracefully restarted neighbor. All stalepaths, unless reinstated by the neighbor after a re-establishment, will be deleted at the expiration of this timer.
Use the no parameter with this command to restore the router to its default state.
Command Syntax
bgp graceful-restart
bgp graceful-restart graceful-reset
bgp graceful-restart restart-time <1-3600>
bgp graceful-restart stalepath-time <1-3600>
no bgp graceful-restart
no bgp graceful-restart graceful-reset
no bgp graceful-restart restart-time
no bgp graceful-restart stalepath-time
Parameters
graceful-reset
The BGP daemon is not restarted, so that any changes in network configurations that cause BGP reset do not affect packet forwarding.
restart-time
Maximum time needed for neighbors to restart. Default is 90 seconds.
<1-3600>
Delay value in seconds.
stalepath-time
Maximum time to retain stale paths from restarting neighbors. Default is 360 seconds.
<1-3600>
Delay value in seconds.
Default
By default, the maximum time for neighbors to restart is 90 seconds.
By default, the maximum time to retain stale paths from restarting neighbors is 360 seconds.
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 10
(config-router)#bgp graceful-restart
 
#configure terminal
(config)#router bgp 10
(config-router)#no bgp graceful-restart
bgp g-shut
Use this command to gracefully shut down all BGP IPv4 sessions under this router. The BGP graceful shutdown feature reduces packet loss during maintenance activity.
Use the no parameter with this command to bring up all the sessions under this router after completion of maintenance activity using the bgp g-shut command.
Command Syntax
bgp g-shut
no bgp g-shut
Parameters
None
Default
By default, bgp g-shut is disabled
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 100
(config-router)#bgp g-shut
 
#configure terminal
(config)#router bgp 100
(config-router)#no bgp g-shut
bgp g-shut-capable
Use this command to enable the graceful shutdown capability at the router level and make available the graceful-shutdown related commands at the router and BGP neighbor levels.
Use the no parameter with this command to disable the graceful shutdown capability on a router.
Note: The graceful shutdown capability cannot be disabled on a router that is in a graceful shutdown state until it comes out this state--after the graceful shutdown has been initiated and the impacted BGP sessions are up again.
Command Syntax
bgp g-shut-capable
no bgp g-shut-capable
Parameters
None
Default
By default, the graceful shutdown capability is disabled at the router level
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 100
(config-router)#bgp g-shut-capable
 
#configure terminal
(config)#router bgp 100
(config-router)#no bgp g-shut-capable
bgp g-shut-local-preference
Use this command to sets the local preference of the router to use during graceful shutdown. The local preference value indicates the preferred path when there are multiple paths to the same destination in a single routing database. The path with a higher preference value is the preferred one. The preferred path is sent to all routers and access servers in the local autonomous system.
Use the no parameter with this command to revert to the default setting.
Command Syntax
bgp g-shut-local-preference <0-4294967295>
no bgp g-shut-local-preference
Parameters
<0-4294967295>
Local preference value
Default
By default, the local preference value is set to 0
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 100
(config-router)#bgp g-shut-local-preference 22
bgp log-neighbor-changes
Use this command to enable logging of status change messages without turning on debug bgp commands. OcNOS has many logging services for neighbor status, including debug bgp fsm and debug bgp events. However, these commands cause system performance degradation. If you need to log neighbor status changes only, IP Infusion Inc. recommends turning off all debug commands and using the bgp log-neighbor-changes command instead. A sample output of the log is:
%Protocol-Severity-Events: Message-text
A sample output of the log for an interface down event is:
%BGP-5-ADJCHANGE: neighbor 10.10.0.24 Down Interface flap
This command logs the following events:
BGP Notification Received
Erroneous BGP Update Received
User reset request
Peer time-out
Peer Closing down the session
Interface flap
Router ID changed
Neighbor deleted
Member added to peer group
Administrative shutdown
Remote AS changed
RR client configuration modification
Soft reconfiguration modification
Use the no parameter with this command to disable this feature.
Command Syntax
bgp log-neighbor-changes
no bgp log-neighbor-changes
Parameters
None
Default
By default, bgp log neighbor changes is disabled
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
(config)#router bgp 100
(config-router)#bgp log-neighbor-changes
 
mpls-nexthop-tracking
Use this command to register and track nexthops of BGP prefixes for MPLS reachability resolution.
Use “no” form of this command to deactivate MPLS nexthop tracking for BGP routes.
Note: bgp nexthop-trigger enable must be configured to enable mpls-nexthop-tracking
Command Syntax
mpls-nexthop-tracking
no mpls-nexthop-tracking
Parameters
None
Command Mode
BGP mode
Applicability
This command is introduced in OcNOS version 5.0 and is updated in OcNOS version 6.4.0
MPLS NHT can be used to track nexthop LSP's of BGP prefixes, MPLS NHT supports BGP IPv4 Labeled Unicast, VPNv4, VPNv6 (6VPE), 6PE routes.
Examples
#configure terminal
(config)#bgp nexthop-trigger enable
(config)#router bgp 100
(config-router)#mpls-nexthop-tracking
 
bgp nexthop-trigger delay
Use this command to set the delay time for nexthop address tracking. This command configures the delay interval between routing table walks for nexthop delay tracking, after which BGP does a routing table scan on receiving a nexthop change trigger from NSM. The time period determines how long BGP waits before it walks the full BGP table to determine which prefixes are affected by the nexthop changes, after it receives the trigger from NSM about one or more nexthop changes.
Use the no parameter with this command to reset the timer value to the default value.
Command Syntax
bgp nexthop-trigger delay <1-100>
no bgp nexthop-trigger delay
Parameter
<1-100>
Nexthop trigger delay interval in seconds
Default
By default, nexthop-trigger delay time is 5 seconds
Command Mode
Configure mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#bgp nexthop-trigger delay 6
 
#configure terminal
(config)#no bgp nexthop-trigger delay
bgp nexthop-trigger enable
Use this command to enable nexthop address tracking. Nexthop address tracking is an event-driven notification system that monitors the status of routes installed in the Routing Information Base (RIB) and reports nexthop changes that affect internal BGP (iBGP) or external BGP (eBGP) prefixes directly to the BGP process. This improves the overall BGP convergence time, by allowing BGP to respond rapidly to nexthop changes for routes installed in the RIB.
If nexthop tracking is enabled after certain routes are learned, the registration of all nexthops for selected BGP routes is done after the nexthop tracking feature is enabled. If nexthop tracking is disabled, and if there are still some selected BGP routes, BGP de-registers the nexthops of all selected BGP routes from NSM.
Use the no parameter with this command to disable this feature. If the no command is given when nexthop tracking is in the process of execution, an error appears and nexthop tracking is not disabled. However, if the nexthop tracking timer is running at the time of negation, the nexthop tracking timer is stopped, and nexthop tracking is disabled.
Command Syntax
bgp nexthop-trigger enable
no bgp nexthop-trigger enable
Parameters
None
Default
By default, nexthop address tracking is disabled
Command Mode
Configure mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#bgp nexthop-trigger enable
bgp rfc1771-path-select
Use this command to set RFC 1771 compatible path selection.
Use the no parameter with this command to revert this setting.
Command Syntax
bgp rfc1771-path-select
no bgp rfc1771-path-select
Parameters
None
Default
Standard compatible path selection mechanism.
Command Mode
Configure mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#bgp rfc1771-path-select
bgp rfc1771-strict
Use this command to set the origin path attribute to “IGP” when the origin is a protocol such as RIP, OSPF, or ISIS as specified in RFC 1771. Otherwise, the origin is always set to “incomplete” which is the industry standard.
Use the no parameter with this command to revert this setting.
Command Syntax
bgp rfc1771-strict
no bgp rfc1771-strict
Parameters
None
Default
By default, bgp rfc1771 strict is disabled
Command Mode
Configure mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#bgp rfc1771-strict
bgp router-id
Use this command to manually configure a fixed router ID as a BGP router identifier. When this command is used to configure a fixed router ID, the current router identifier is overridden and the peers are reset.
Use the no parameter with this command to remove a manually configured fixed router ID.
Command Syntax
bgp router-id A.B.C.D
no bgp router-id
no bgp router-id A.B.C.D
Parameter
A.B.C.D
Router ID in an IPv4 address format
Default
Once the BGP router-id is elected, it may be re-elected in the following cases:
a. When an explicit BGP router-id is configured/un-configured
b. When the router's (global) router-id is set/unset (holds true when (a) is not applicable),
c. When the BGP process is cleared (holds true when both (a) & (b) are not applicable and the IP address(es) on the active interfaces are updated, which may result in a change in the router's router-id).
If no loopback interface is configured, the highest IP address is the BGP router-id.
When a loopback interface is configured, the BGP router-id is set to the IP address of the loopback interface.
Note: IP Infusion Inc. recommends that you always configure a router identifier to avoid unpredictable behavior if the address of a loopback interface changes.
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 100
(config-router)#bgp router-id 10.1.2.7
 
(config)#router bgp 100
(config-router)#no bgp router-id 10.1.2.7
bgp scan-time
Use this command to configure scanning intervals of BGP routers. This interval is the period after which router checks the validity of the routes in its database. To disable BGP scanning, set the scan-time interval to 0 seconds.
Use the no parameter with this command to disable this function.
Command Syntax
bgp scan-time <0-60>
no bgp scan-time
no bgp scan-time <0-60>
Parameter
<0-60>
Scanning interval in seconds
Default
By default, scan-time interval is 60 seconds.
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 100
(config-router)#bgp scan-time 10
bgp table-map
Use this command to enable or disable suppression/modification of incoming BGP updates to IP RIB/FIB table installation.
In a dedicated route reflector, all the routes it receives may not be required to be stored or only few selected routes need to be stored, because it may not lie in the data path.
Table maps are particularly useful to attain this restriction. Table-map command can be used in two ways:
When a simple table-map command is given, the route map referenced in the table-map command shall be used to set certain properties (such as the traffic index) of the routes for installation into the RIB. The route is always downloaded, regardless of whether it is permitted or denied by the route map.
When the option ‘filter’ is given in the table map command, the route map referenced is used to control whether a BGP route is to be downloaded to the IP RIB (hence the filter). A BGP route is not downloaded to the RIB if it is denied by the route map.
Use this command in Address Family mode to set the table map rule per an IPv4 or IPv6 family.
Use the no parameter with this command to remove the table-map rule.
Command Syntax
table-map WORD (|filter)
Parameter
WORD
Specify the route-map name to apply.
filter
Filer the routes. If present, the incoming routes are pruned as per the rule specified in route-map-name. If not, it is used to alter the incoming packet information.
Default
All BGP routes will be downloaded to IP RIB
Command Mode
Address Family IPv4 mode, and Address Family IPv6 mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
The following example shows how to set the table-map command without filter for BGP for all address families.
#configure terminal
(config)#router bgp 100
(config-router)#address-family ipv4 unicast
(config-router-af)#table-map abc
The following example shows how to set the table-map command with filter for BGP for all address families.
#configure terminal
(config)#router bgp 100
(config-router)#address-family ipv4 unicast
(config-router-af)#table-map abc filter
The following example shows how to set the table-map command without filter for BGP for an IPv6 address family.
(config)#router bgp 100
(config-router)#address-family ipv6
(config-router-af)#table-map abc
The following example shows how to set the table-map command with filter for BGP for an IPv6 address family.
(config)#router bgp 100
(config-router)#address-family ipv6
(config-router-af)#table-map abc filter
bgp update-delay
Use this command to set the update delay for a graceful-restart capable router. The update-delay value is the maximum time a graceful-restart capable router, which is restarting, will defer route-selection and advertisements to all its graceful-restart capable neighbors. This maximum time starts from the instance the first neighbor attains established state after restart. The restarting router prematurely terminates this timer when end-of-RIB markers are received from all its graceful-restart capable neighbors.
Use the no form of this command to set to the update delay to its default value.
Command Syntax
bgp update-delay <1-3600>
no bgp update-delay
no bgp update-delay <1-3600>
Parameters
<1-3600>
Delay interval in seconds
Default
By default, update-delay value is 120 seconds
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
#configure terminal
(config)#router bgp 10
(config-router)#bgp update-delay 345
clear bgp (A.B.C.D|X:X::X:X)
Use this command to reset a BGP neighbor address.
Command Syntax
clear bgp (A.B.C.D|X:X::X:X|WORD)
clear bgp (A.B.C.D|X:X::X:X) in
clear bgp (A.B.C.D|X:X::X:X) in prefix-filter
clear bgp (A.B.C.D|X:X::X:X) out
Parameters
A.B.C.D
IPv4 neighbor address.
X:X::X:X
IPv6 neighbor address.
WORD
Interface name
in
Clear incoming advertised routes.
prefix-filter
 
Push out prefix-list ORF and do inbound soft reconfig.
out
Clear outgoing advertised routes.
Command Mode
Privileged Exec mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
#clear bgp 3.3.3.3
clear bgp *
Use this command to reset the BGP connection for all peers.
Command Syntax
clear bgp *
clear bgp * in
clear bgp * in prefix-filter
clear bgp * out
clear bgp * soft
clear bgp * soft in
clear bgp * soft out
clear ip bgp *
clear ip bgp * in
clear ip bgp * in prefix-filter
clear ip bgp * out
clear ip bgp * soft
clear ip bgp * soft in
clear ip bgp * soft out
clear ip bgp * ipv4 (unicast|multicast) in
clear ip bgp * ipv4 (unicast|multicast) in prefix-filter
clear ip bgp * ipv4 (unicast|multicast) out
clear ip bgp * ipv4 (unicast|multicast) soft
clear ip bgp * ipv4 (unicast|multicast) soft in
clear ip bgp * ipv4 (unicast|multicast) soft out
Parameters
in
Incoming advertised routes should be cleared.
prefix-filter
 
Push out prefix-list ORF and do inbound soft reconfig.
out
Clear outgoing advertised routes.
soft
Clear both incoming and outgoing routes.
in
Soft reconfig inbound update.
out
Soft reconfig outbound update.
ipv4
Clear incoming advertised routes.
multicast
Multicast prefixes.
unicast
Unicast prefixes.
in
Clear incoming advertised routes.
prefix-filter
 
Push out prefix-list ORF and do inbound soft reconfig.
out
Clear outgoing advertised routes.
soft
Clear both incoming and outgoing routes.
in
Soft reconfig inbound update.
out
Soft reconfig outbound update.
Command Mode
Privileged Exec mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#clear bgp *
#clear ip bgp * ipv4 unicast in prefix-filter
clear bgp * l2vpn evpn
Use this command to reset the BGP L2VPN EVPN connection for all the BGP peers.
Command Syntax
clear bgp * l2vpn evpn soft (in | out | )
Parameters
 
soft
Clear both incoming and outgoing routes.
in
Soft reconfig inbound update.
out
Soft reconfig outbound update.
Default
None.
Command Mode
Privileged Exec mode.
Applicability
This command was introduced in OcNOS version 6.4.2.
Examples
OcNOS#clear bgp * l2vpn evpn soft
OcNOS#clear bgp * l2vpn evpn soft in
 
 
clear bgp <1-4294967295>
Use this command to reset a BGP connection for all peers in a specified Autonomous System.
Command Syntax
clear bgp <1-4294967295>
clear bgp <1-4294967295> in
clear bgp <1-4294967295> in prefix-filter
clear bgp <1-4294967295> out
clear bgp <1-4294967295> soft
clear bgp <1-4294967295> soft in
clear bgp <1-4294967295> soft out
clear ip bgp <1-4294967295>
clear ip bgp <1-4294967295> in
clear ip bgp <1-4294967295> in prefix-filter
clear ip bgp <1-4294967295> out
clear ip bgp <1-4294967295> soft
clear ip bgp <1-4294967295> soft in
clear ip bgp <1-4294967295> soft out
clear ip bgp <1-4294967295> ipv4 (unicast|multicast) in
clear ip bgp <1-4294967295> ipv4 (unicast|multicast) in prefix-filter
clear ip bgp <1-4294967295> ipv4 (unicast|multicast) out
clear ip bgp <1-4294967295> ipv4 (unicast|multicast) soft
clear ip bgp <1-4294967295> ipv4 (unicast|multicast) soft in
clear ip bgp <1-4294967295> ipv4 (unicast|multicast) soft out
Parameters
in
Clear incoming advertised routes.
prefix-filter
 
Push out prefix-list ORF and do inbound soft reconfig.
out
Clear outgoing advertised routes.
soft
Clear both incoming and outgoing routes.
in
Soft reconfig inbound update.
out
Soft reconfig outbound update.
ipv4
Clear incoming advertised routes.
multicast
Multicast prefixes.
unicast
Unicast prefixes.
Clear incoming advertised routes.
in
Clear incoming advertised routes.
prefix-filter
 
Push out prefix-list ORF and do inbound soft reconfig.
out
Clear outgoing advertised routes.
soft
Clear both incoming and outgoing routes.
in
Soft reconfig inbound update.
out
Soft reconfig outbound update.
Command Mode
Privileged Exec mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#clear bgp 4294967277
#clear ip bgp 4294967277
clear bgp <1-4294967295> l2vpn evpn
Use this command to reset the session for neighbors with a specific Autonomous System Number (ASN) for L2VPN EVPN.
Command Syntax
clear bgp <1-4294967295> l2vpn evpn soft (in | out | )
Parameters
 
soft
Clear both incoming and outgoing routes.
in
Soft reconfig inbound update.
out
Soft reconfig outbound update.
Default
None.
Command Mode
Privileged Exec mode.
Applicability
This command was introduced in OcNOS version 6.4.2.
Examples
OcNOS#clear bgp 100 l2vpn evpn soft
OcNOS#clear bgp 100 l2vpn evpn soft in
clear bgp A.B.C.D l2vpn evpn
Use this command to reset the BGP session for neighbor with IPv4 address for L2VPN EVPN.
Command Syntax
clear bgp A.B.C.D l2vpn evpn soft (in | out | )
Parameters
 
soft
Clear both incoming and outgoing routes.
in
Soft reconfig inbound update.
out
Soft reconfig outbound update.
Default
None.
Command Mode
Privileged Exec mode.
Applicability
This command was introduced in OcNOS version 6.4.2.
Examples
OcNOS#clear bgp 3.3.3.3 l2vpn evpn soft
OcNOS#clear bgp 3.3.3.3 l2vpn evpn soft in
 
 
clear bgp dampening
Use this command to reset BGP route flap dampening information.
Command Syntax
clear bgp ipv4 (unicast|multicast) dampening
clear bgp ipv4 (unicast|multicast) dampening A.B.C.D/M
clear ip bgp dampening
clear ip bgp dampening A.B.C.D/M
clear ip bgp ipv4 (unicast|multicast) dampening
clear ip bgp ipv4 (unicast|multicast) dampening A.B.C.D/M
Parameters
ipv4
IPv4 address family.
multicast
Multicast prefixes
unicast
Unicast prefixes
A.B.C.D/M
IP prefix (network/length), for example, 35.0.0.0/8
Command Mode
Privileged Exec mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#clear ip bgp dampening 10.10.0.121/24
#clear ip bgp ipv4 unicast dampening
clear bgp external
Use this command to reset the BGP connection for all external peers.
Command Syntax
clear bgp external
clear bgp external in
clear bgp external in prefix-filter
clear bgp external out
clear bgp external soft
clear bgp external soft in
clear bgp external soft out
clear ip bgp external
clear ip bgp external in
clear ip bgp external in prefix-filter
clear ip bgp external out
clear ip bgp external soft
clear ip bgp external soft in
clear ip bgp external soft out
clear ip bgp external ipv4 (unicast|multicast) in
clear ip bgp external ipv4 (unicast|multicast) in prefix-filter
clear ip bgp external ipv4 (unicast|multicast) out
clear ip bgp external ipv4 (unicast|multicast) soft
clear ip bgp external ipv4 (unicast|multicast) soft in
clear ip bgp external ipv4 (unicast|multicast) soft out
Parameters
in
Clear incoming advertised routes.
prefix-filter
 
Push out prefix-list ORF and do inbound soft reconfig.
out
Clear outgoing advertised routes.
soft
Clear both incoming and outgoing routes.
in
Soft reconfig inbound update.
out
Soft reconfig outbound update.
ipv4
Clear incoming advertised routes.
multicast
Multicast prefixes.
unicast
Unicast prefixes.
in
Clear incoming advertised routes.
prefix-filter
 
Push out prefix-list ORF and do inbound soft reconfig.
out
Clear outgoing advertised routes.
soft
Clear both incoming and outgoing routes.
in
Soft reconfig inbound update.
out
Soft reconfig outbound update.
Command Mode
Privileged Exec mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
#clear ip bgp external
clear bgp flap-statistics
Use this command to reset BGP flap statistics.
Command Syntax
clear bgp ipv4 (unicast|multicast) flap-statistics
clear bgp ipv4 (unicast|multicast) flap-statistics A.B.C.D/M vrf (all | default | VRFNAME )
clear bgp ipv4 (unicast|multicast) flap-statistics A.B.C.D/M
clear ip bgp flap-statistics
clear ip bgp flap-statistics A.B.C.D/M
clear ip bgp ipv4 (unicast|multicast) flap-statistics
clear ip bgp ipv4 (unicast|multicast) flap-statistics A.B.C.D/M vrf (all | default | VRFNAME )
clear ip bgp ipv4 (unicast|multicast) flap-statistics A.B.C.D/M
Parameters
ipv4
IPv4 address family.
multicast
Multicast prefixes.
unicast
Unicast prefixes.
A.B.C.D/M
IP prefix (network/length), for example, 35.0.0.0/8
VRFNAME
VPN routing or forwarding instance name
all
All VRF’s
default
Default VRF
Command Mode
Privileged Exec mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#clear ip bgp flap-statistics
#clear ip bgp ipv4 unicast flap-statistics
clear bgp peer-group
Use this command to reset the BGP connection for all members of a peer group.
Command Syntax
clear bgp peer-group WORD
clear bgp peer-group WORD in
clear bgp peer-group WORD in prefix-filter
clear bgp peer-group WORD out
clear bgp peer-group WORD soft
clear bgp peer-group WORD soft in
clear bgp peer-group WORD soft out
clear ip bgp peer-group WORD
clear ip bgp peer-group WORD in
clear ip bgp peer-group WORD in prefix-filter
clear ip bgp peer-group WORD out
clear ip bgp peer-group WORD soft
clear ip bgp peer-group WORD soft in
clear ip bgp peer-group WORD soft out
clear ip bgp peer-group WORD ipv4 (unicast|multicast) in
clear ip bgp peer-group WORD ipv4 (unicast|multicast) in prefix-filter
clear ip bgp peer-group WORD ipv4 (unicast|multicast) out
clear ip bgp peer-group WORD ipv4 (unicast|multicast) soft
clear ip bgp peer-group WORD ipv4 (unicast|multicast) soft in
clear ip bgp peer-group WORD ipv4 (unicast|multicast) soft out
Parameters
WORD
BGP peer-group name.
in
Clear incoming advertised routes.
prefix-filter
 
Push out prefix-list ORF and do inbound soft reconfig.
out
Clear outgoing advertised routes.
soft
Clear both incoming and outgoing routes.
in
Soft reconfig inbound update.
out
Soft reconfig outbound update.
ipv4
Clear incoming advertised routes.
multicast
Multicast prefixes.
unicast
Unicast prefixes.
Clear incoming advertised routes.
in
Clear incoming advertised routes.
prefix-filter
 
Push out prefix-list ORF and do inbound soft reconfig.
out
Clear outgoing advertised routes.
soft
Clear both incoming and outgoing routes.
in
Soft reconfig inbound update.
out
Soft reconfig outbound update.
Command Mode
Privileged Exec mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#clear ip bgp peer-group P1
clear bgp peer-group WORD l2vpn evpn
Use this command to reset the BGP L2VPN EVPN connection for all members of a BGP peer group.
Command Syntax
clear bgp peer-group WORD l2vpn evpn soft (in | out | )
Parameters
 
soft
Clear both incoming and outgoing routes.
in
Soft reconfig inbound update.
out
Soft reconfig outbound update.
Default
None.
Command Mode
Privileged Exec mode.
Applicability
This command was introduced before OcNOS version 6.4.2.
Examples
OcNOS#clear bgp peer-group GRP1 l2vpn evpn soft
OcNOS#clear bgp peer-group GRP1 l2vpn evpn soft in
 
 
clear bgp statistics
Use this command to reset all BGP statistics.
Command Syntax
clear bgp statistics
Parameters
None
Command Mode
Privileged Exec mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#clear bgp statistics
clear ip bgp * (description LINE|)*
Use this command to reset the BGP connection for all peers.
Command Syntax
clear ip bgp * (description LINE|)
Parameters
description
Administratively reset communication msg to neighbor
Command Mode
Privileged Exec mode
Applicability
This command is introduced in OcNOS version 6.0.0.
Examples
#clear bgp *
#clear bgp * description peer reset done for refresh
clear ip bgp (A.B.C.D|X:X::X:X|WORD) (description LINE|)
Use this command to reset the BGP connection for peer.
Command Syntax
clear ip bgp (A.B.C.D|X:X::X:X|WORD) (description LINE|)
Parameters
 
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
description
Administratively reset communication msg to neighbor
Command Mode
Privileged Exec mode
Applicability
This command is introduced in OcNOS version 6.0.0.
Examples
#clear ip bgp 40.1.1.2
#clear ip bgp 40.1.1.2 description peer reset is done
 clear ip bgp A.B.C.D
Use this command to reset an IPv4 BGP neighbor address.
Command Syntax
clear ip bgp (A.B.C.D|WORD) in
clear ip bgp A.B.C.D in prefix-filter
clear ip bgp (A.B.C.D|WORD) out
clear ip bgp (A.B.C.D|WORD) soft
clear ip bgp (A.B.C.D|WORD) soft in
clear ip bgp (A.B.C.D|WORD) soft out
clear ip bgp A.B.C.D ipv4 (unicast|multicast) in
clear ip bgp A.B.C.D ipv4 (unicast|multicast) in prefix-filter
clear ip bgp A.B.C.D ipv4 (unicast|multicast) out
clear ip bgp A.B.C.D ipv4 (unicast|multicast) soft
clear ip bgp A.B.C.D ipv4 (unicast|multicast) soft in
clear ip bgp A.B.C.D ipv4 (unicast|multicast) soft out
Parameters
A.B.C.D
IPv4 address
WORD
Interface name
in
Clear incoming advertised routes.
prefix-filter
 
Push out prefix-list ORF and do inbound soft reconfig.
out
Clear outgoing advertised routes.
soft
Clear both incoming and outgoing routes.
in
Soft reconfig inbound update.
out
Soft reconfig outbound update.
ipv4
Clear incoming advertised routes.
multicast
Multicast prefixes.
unicast
Unicast prefixes.
in
Clear incoming advertised routes.
prefix-filter
 
Push out prefix-list ORF and do inbound soft reconfig.
out
Clear outgoing advertised routes.
soft
Clear both incoming and outgoing routes.
in
Soft reconfig inbound update.
out
Soft reconfig outbound update.
Command Mode
Privileged Exec mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#clear ip bgp 35.0.0.1 in
clear ip bgp A.B.C.D vrf
Use this command to reset the VPN Routing/Forwarding (VRF) instance for a peer address.
Command Syntax
clear ip bgp A.B.C.D vrf WORD
clear ip bgp A.B.C.D vrf WORD in
clear ip bgp A.B.C.D vrf WORD out
clear ip bgp A.B.C.D vrf WORD soft
clear ip bgp A.B.C.D vrf WORD soft in
clear ip bgp A.B.C.D vrf WORD soft out
Parameters
A.B.C.D
IPv4 address
WORD
VPN routing/forwarding instance name
in
Clear incoming advertised routes
out
Clear outgoing advertised routes
soft
Clear both incoming and outgoing routes
in
Soft reconfig inbound update
out
Soft reconfig outbound update
Command Mode
Privileged Exec mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#clear ip bgp 35.0.0.1 vrf
clear ip bgp all vrf (VRFNAME|all|default) (description LINE|)
Use this command to reset the BGP connection for vrf peer.
Command Syntax
clear ip bgp all vrf (VRFNAME|all|default) (description LINE|)
Parameters
VRFNAME
VPN routing/forwarding instance name
all
All VRFs
default
Default VRF
description
Administratively reset communication msg to neighbor
Command Mode
Privileged Exec mode
Applicability
This command is introduced in OcNOS version 6.0.0
Examples
#clear ip bgp all vrf vrf1
#clear ip bgp all vrf all description all peer refresh is done
clear ip bgp table-map
Use this command to apply the modified table map or route map rules to the BGP routes in the existing IP routing table.
Command Syntax
clear ip bgp table-map (vrf (VRFNAME|all|default))
clear ip bgp ipv4 (unicast | multicast) table-map(vrf (VRFNAME|all|default))
Parameters
vrf
Select a VPN Routing/Forwarding Instance.
VRFNAME
Specify a VPN Routing/Forwarding instance name.
all
Select all VRFs.
default
Select default VRFs.
unicast
Unicast prefixes.
multicast
Multicast prefixes.
Command Mode
Privileged Exec mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#clear ip bgp table-map vrf all
clear ip bgp vrf WORD (A.B.C.D|X:X::X:X|WORD) (description LINE|)
Use this command to reset the BGP connection for vrf peer.
Command Syntax
clear ip bgp vrf WORD (A.B.C.D|X:X::X:X|WORD) (description LINE|)
Parameters
WORD
VPN routing/forwarding instance name
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
description
Administratively reset communication msg to neighbor
Command Mode
Privileged Exec mode
Applicability
This command is introduced in OcNOS version 6.0.0
Examples
#clear ip bgp vrf vrf1 10.1.1.2
#clear ip bgp vrf vrf1 10.1.1.2 description peer reset is done
debug bgp
Use this command to enable all BGP troubleshooting functions. Use this command without any parameters to turn on normal bgp debug information.
Use the no parameter with this command to disable this function.
Command Syntax
debug bgp (all|)
debug bgp bfd
debug bgp dampening
debug bgp events
debug bgp filters
debug bgp fsm
debug bgp keepalives
debug bgp mpls
debug bgp nht
debug bgp nsm
debug bgp updates
debug bgp updates (in|out)
debug bgp vpls
no debug bgp (all|)
no debug bgp bfd
no debug bgp dampening
no debug bgp events
no debug bgp filters
no debug bgp fsm
no debug bgp keepalives
no debug bgp mpls
no debug bgp nht
no debug bgp nsm
no debug bgp updates
no debug bgp vpls
undebug bgp (all|)
undebug bgp bfd
undebug bgp dampening
undebug bgp events
undebug bgp filters
undebug bgp fsm
undebug bgp keepalives
undebug bgp mpls
undebug bgp nht
undebug bgp nsm
undebug bgp updates
undebug bgp vpls
Parameters
all
Used only with the no form; turns off all debugging for BGP
bfd
Enable debugging for BGP Bidirectional Forwarding Detection
dampening
Enable debugging for BGP dampening
events
Enable debugging for BGP events
filters
Enable debugging for BGP filters
fsm
Enable debugging for BGP Finite State Machine (FSM)
keepalives
Enable debugging for BGP keepalives
mpls
Enable debugging for BGP Multiprotocol Label Switching (MPLS)
nht
Enable debugging for BGP NHT
nsm
Enable debugging for NSM messages
updates
Enable debugging for BGP updates
in
Debug inbound updates
out
Debug outbound updates
vpls
Enable debugging for BGP Virtual Private LAN Service (VPLS)
Command Mode
Privileged Exec mode and Configure Mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#debug bgp
#debug bgp events
distance bgp
Use this command to set BGP administrative distances. The administrative distance rates the trustworthiness of a routing information source. A higher distance value means a lower trust rating. For example, an administrative distance of 255 means that the routing information source cannot be trusted and should be ignored.
Use the no form of this command to restore the default value (110).
Command Syntax
distance <1-255>
distance <1-255> A.B.C.D/M (WORD|)
no distance <1-255>
no distance <1-255> A.B.C.D/M (WORD|)
Parameters
<1-255>
Distance for BGP routes
A.B.C.D/M
Distance for routes to prefixes whose nexthop matches this address.
WORD
Name of access list to apply to route updates.
Command Mode
Router BGP mode
Defaults
None
Applicability
This command was introduced in OcNOS version 6.0.0.
Examples
#configure terminal
(config)#router bgp 100
(config-router)#distance 100 10.10.10.10/30
exit-address-family
Use this command to exit Address-Family-vrf, Address-Family-vpnv4 mode.
For information on how to enter the address family mode (IPv4, VPNv4), see address-family.
Command Syntax
exit-address-family
Parameters
None
Default
No default value is specified
Command Mode
Address Family-vrf and Address Family-vpnv4 mode.
Applicability
This command was introduced before OcNOS version 1.3.
Examples
The following examples shows the change in the prompt after using this command.
#configure terminal
(config)#router bgp 100
(config-router)#address-family ipv4 multicast
(config-router-af)#exit-address-family
(config-router)#
 
ip as-path access-list
Use this command to define a BGP Autonomous System (AS) path access list. A named community list is a filter based on regular expressions. If the regular expression matches the specified string representing the AS path of the route, then the permit or deny condition applies. Use this command to define the BGP access list globally; use the neighbor router configuration command to apply a specific access list.
Use the no parameter with this command to disable use of the access list.
Command Syntax
ip as-path access-list WORD (deny|permit) LINE
no ip as-path access-list WORD (deny | permit) LINE
Parameters
WORD
Access list name
deny
Reject packets
permit
Forward packets
LINE
An ordered list as a regular expression
Default
No default value is specified
Command Mode
Configure mode
Applicability
This command was introduced before OcNOS version 1.3 and updated in OcNOS version 6.4.0.
Examples
#configure terminal
(config)#ip as-path access-list mylist deny ^65535$
ip community-list <1-99>
Use this command to specify a standard community list (1 to 99) that specifies BGP community attributes.
Use the no parameter with this command to delete the community list entry.
Command Syntax
ip community-list <1-99> (deny|permit)
ip community-list <1-99> (deny|permit) [AA:NN|internet|local-AS|no-advertise|no-export]
no ip community-list <1-99> (deny|permit)
no ip community-list <1-99> (deny|permit) [AA:NN|internet|local-AS|no-advertise|no-export]
Parameters
deny
Reject the community
permit
Accept the community
AA:NN
Community number
internet
Advertise routes to the internet community
local-AS
Do not advertise routes to external BGP peers
no-advertise
Do not advertise routes to other BGP peers
no-export
Do not advertise routes outside of Autonomous System boundary
Default
By default, ip community list is disabled
Command Mode
Configure mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#ip community-list 55 permit 7675:80 7675:90
 
(config)#no ip community-list 55 permit 7675:80 7675:90
ip community-list <100-500>
Use this command to specify an expanded community list (100 to 500) that specifies BGP community attributes.
Use the no parameter with this command to delete the community list entry.
Command Syntax
ip community-list <100-500> (deny|permit)
ip community-list <100-500> (deny|permit) LINE
no ip community-list <100-500>
no ip community-list <100-500> (deny|permit) LINE
Parameters
deny
Reject community
permit
Accept community
LINE
An ordered list as a regular expression
Default
By default, ip community list is disabled
Command Mode
Configure mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#ip community-list 225 permit 6789906
(config)#ip community-list expanded CLIST permit .*
ip community-list expanded
Use the community-lists to specify BGP community attributes. The community attribute is used for implementing policy routing. It is an optional, transitive attribute and facilitates transfer of local policies through different autonomous systems. It includes community values that are 32-bits long.
There are two kinds of community-lists: expanded and standard. The standard community-list defines the community attributes in a specified format and not with regular expressions. The expanded community-list defines the community attributes with regular expressions.Use the no parameter with this command to delete the community list entry.
Command Syntax
ip community-list expanded WORD (deny|permit) LINE
no ip community-list expanded WORD
no ip community-list expanded WORD (deny|permit) LINE
Parameters
WORD
Community list name
deny
Reject community
permit
Accept community
LINE
An ordered list as a regular expression
Default
By default, ip community list is disabled
Command Mode
Configure mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#ip community-list 125 permit 6789906
(config)#ip community-list expanded CLIST permit .*
ip community-list standard
Use the community-lists to specify BGP community attributes. The community attribute is used for implementing policy routing. It is an optional, transitive attribute and facilitates transfer of local policies through different autonomous systems. It includes community values that are 32-bits long. There are two kinds of community-lists: expanded and standard. The standard community-list defines the community attributes in a specified format without regular expressions. The expanded community-list defines the community attributes with regular expressions.
Use this command to add a standard community-list entry. The standard community-list is compiled into binary format and is directly compared with the BGP communities attribute in the BGP updates. The comparison is faster than the expanded community-list. Any community value that does not match the standard community value is automatically treated as expanded.
Use the no parameter with this command to delete the standard community-list entry.
Command Syntax
ip community-list standard WORD (deny|permit)
ip community-list standard WORD (deny|permit) [AA:NN|internet|local-AS|no-advertise|no-export]
no ip community-list standard WORD (deny|permit) [AA:NN|internet|local-AS|no-advertise|no-export]
Parameters
WORD
Community list name
deny
Reject the community
permit
Accept the community
AA:NN
Community number
internet
Advertise routes to the internet community
local-AS
Do not advertise routes to external BGP peers
no-advertise
Do not advertise routes to other BGP peers
no-export
Do not advertise routes outside of Autonomous System boundary
Default
By default, ip community list is disabled
Command Mode
Configure mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#ip community-list standard CLIST permit 7675:80 7675:90 no-export
(config)#ip community-list 34 permit 5675:50 no-advertise
ip community-list WORD
Use the community-list commands to specify BGP community attributes. The community attribute is used for implementing policy routing. It is an optional, transitive attribute and facilitates transfer of local policies through different autonomous systems. There are two kinds of community-lists: the expanded and standard. The standard community-list defines the community attributes in a specified format and not with regular expressions. The expanded community-list defines the community attributes with regular expressions.
Use the no parameter with this command to delete the community list entry.
Command Syntax
ip community-list WORD (deny|permit)
ip community-list WORD (deny|permit) [AA:NN|internet|local-AS|no-advertise|no-export]
no ip community-list WORD
no ip community-list WORD (deny|permit) [AA:NN|internet|local-AS|no-advertise|no-export]
Parameters
WORD
Community list name
deny
Reject the community
permit
Accept the community
AA:NN
Community number
internet
Advertise routes to the internet community
local-AS
Do not advertise routes to external BGP peers
no-advertise
Do not advertise routes to other BGP peers
no-export
Do not advertise routes outside of Autonomous System boundary
Default
By default, ip community list is disabled
Command Mode
Configure mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#ip community-list mylist permit 7675:80 7675:90
 
(config)#no ip community-list mylist permit 7675:80 7675:90
ip extcommunity-list <1-99>
Use this command to create an entry for a standard extended community list.
Use the no parameter with this command to delete the community-list entry.
Command Syntax
ip extcommunity-list <1-99> (deny|permit) LINE (rt|soo)
no ip extcommunity-list <1-99> (deny|permit) LINE (rt|soo)
Parameters
deny
Reject community
permit
Accept community
LINE
One of the following:
rt
Route target extended community in aa:nn or IPaddr:nn format
soo
Site-of-origin extended community in aa:nn or IPaddr:nn format
Default
By default, ip extcommunity list is disabled
Command Mode
Configure mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#ip extcommunity-list 3 permit rt 10.10.23.123:67
 
(config)#ip extcommunity-list 25 deny soo 1465:22
ip extcommunity-list <100-500>
Use this command to create an extended community list.
Use the no parameter with this command to delete the community-list entry.
Command Syntax
ip extcommunity-list <100-500> (deny|permit) LINE
no ip extcommunity-list <100-500> (deny|permit) LINE
Parameters
<100-500>
Extended community list number (expanded)
deny
Reject the community
permit
Accept the community
LINE
Any regular expression:
Default
By default, ip extcommunity list is disabled
Command Mode
Configure mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#ip extcommunity-list 125 permit 4567:335
 
(config)#ip extcommunity-list 231 deny *.
ip extcommunity-list expanded
Use this command to create an expanded community list. The expanded community-list defines the community attributes with regular expressions. The expanded community-list match will happen based on input given for regular expressions.
Use the no parameter with this command to delete the expanded community-list entry.
Command Syntax
ip extcommunity-list expanded WORD
ip extcommunity-list expanded WORD (deny|permit) LINE
no ip extcommunity-list expanded WORD
no ip extcommunity-list expanded WORD (deny|permit) LINE
Parameters
WORD
Expanded community list name
deny
Reject the community
permit
Accept the community
LINE
One of the following:
rt
Route target extended community in aa:nn or IPaddr:nn format
soo
Site-of-origin extended community in aa:nn or IPaddr:nn format
Default
By default, ip extcommunity list is disabled
Command Mode
Configure mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#ip extcommunity-list e1 permit 2001:1 300:1
(config)#ip extcommunity-list expanded CLIST permit ^[2001:1 300:1]$
ip extcommunity-list standard
Use this command to create and delete a standard extended-community list. The extended community attribute is 8 bytes in 2 formats. The sub-type can be route target (rt) or site of origin (soo). Thus, the sub-type of each community must be specified when creating the extended community list. Regarding the formats, an extended community is based on a 6-byte value. These 6-bytes are represented in 4-btye:2-byte format, and may be entered in one of the following forms:
Format 1, aa.nn: The 16-bit value of the AS (aa) number is represented in the higher-order 4-bytes. If the extended ASN capability is enabled, the AS number is represented using higher-order 4-bytes. The nn assigned value is represented in the low-order 2-bytes in both cases.
Format 2, IPaddr:nn: In this format, the higher-order 4-bytes are used to represent the IP address, and the low-order 2-bytes are used to represent the assigned value.
Use the no parameter with this command to delete the extended-community-list entry.
Command Syntax
ip extcommunity-list standard WORD (deny|permit) (rt|soo) (aa:nn)
no ip extcommunity-list standard WORD (deny|permit) (rt|soo) (aa:nn)
Parameters
WORD
Extended community list name
deny
Reject the community
permit
Accept the community
rt
Route target extended community in aa:nn or IPaddr:nn format
soo
Site-of-origin extended community in aa:nn or IPaddr:nn format
Default
By default, ip extcommunity list is disabled
Command Mode
Configure mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#ip extcommunity-list standard 36 permit rt 5675:50
(config)#ip extcommunity-list standard CLIST permit soo 10.10.32.15:70
l2vpn-unnumbered-mode
Use this command to configure the unnumbered peer with all the neighbor configs applicable in L2VPN EVPN address family.
Use the exit parameter with this command to leave L2VPN unnumbered mode.
Command Syntax
bgp l2vpn-unnumbered-mode
exit-l2vpn-unnumbered-mode
Parameters
None
Applicability
No default value is specified
Command Mode
Address-family IPv4 Unicast Mode
Applicability
This command was introduced in OcNOS-OTN version 4.2.
Examples
#configure terminal
(config)#router bgp 100
(config-router)#address-family l2vpn evpn
(config-router-af)#bgp l2vpn-unnumbered-mode
(config-router-l2vpn-unnum)#
match ip peer
Use this command to apply policies based on the route source of which the BGP TCP/IP session formed using an IPv4 address in the update message.
Use the no parameter with this command to disable this function.
Command Syntax
match ip peer (<1-199>|<1300-2699>|WORD)
no match ip peer (<1-199>|<1300-2699>|WORD)
Parameters
<1-199>
IP access-list number
<1300-2699>
IP access-list number (expanded range)
WORD
Access-list name
Default
By default, import bgp route is disabled
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#route-map in-A permit 10
(route-map)#match ip peer 1
match large-community
Use this command to match the large community.
Command Syntax
match large-community XXX:YYYY:ZZZ
no match large-community XXX:YYYY:ZZZ
Parameters
XXX:YYYY:ZZZ
Large community number
Default
By default send-community large is enabled for peer
Command Mode
Route-map mode
Applicability
This command was introduced in OcNOS version 6.1.0.
Examples
(config)#route-map R1 permit 10
(config-route-map)#match large-community 1111:2222:33333
(config-route-map)#
 
max-paths
Use this command to set the number of equal-cost multi-path (ECMP) routes for eBGP or iBGP. You can install multiple BGP paths to the same destination to balance the load on the forwarding path.
Use the no parameter with this command to disable this feature.
Command Syntax
max-paths (ebgp|ibgp|) <2-64>
no max-paths ebgp (<2-64>|)
no max-paths ibgp (<2-64>|)
Parameters
ebgp
eBGP ECMP session
ibgp
iBGP ECMP session
<2-64>
Number of routes
Default
Available for the IPv4 and IPv6 unicast addresses.
Command Mode
Address Family mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
The following example configures 7 routes for ECMP for iBGP.
#configure terminal
(config)#router bgp 11
(config-router)#address-family ipv4 unicast
(config-router-af)#max-paths ibgp 7
 
max-paths eigbp
Use this command to set the number of equal-cost multi-path (ECMP) routes for both eBGP and iBGP. This feature allows you to configure multipath load balancing with both external BGP (eBGP) and internal BGP (iBGP) paths in BGP networks.
Use the no parameter with this command to disable this feature and set the BGP path selection to the default single best path.
Command Syntax
max-paths eibgp <2-64>
no max-paths eibgp (<2-64>|)
Parameters
<2-64>
Number of routes
Default
Not applicable
Command Mode
IPv4 and IPv6 unicast address-family mode
Applicability
This command was introduced in OcNOS version 5.0.
Exception with Administrative Distance
Administrative distance (AD) is the feature that routers use to select the best path when there are two or more different routes to the same destination from two different routing protocols.
In OcNOS, AD is per route. With max-paths eibgp, BGP programs the AD(200)/AD20 for eiBGP routes. If there is a route from IGP with a lower AD, it will be preferred and get installed in the FIB.
A BGP route cannot have a different AD for each path. Multipath candidates of eibgp max-paths can be programmed either with AD20 or AD200.
Currently AD20/AD200 will be programmed for all eiBGP routes as per best path selected by BGP. For example, if the best path is learned via iBGP peering, then AD200 is programmed for all the installed multipaths (including paths from eBGP peering) or If the best path is learned via eBGP peering, then AD20 is programmed for all the installed multipaths (including paths from iBGP peering).
Example
This example configures the number of parallel iBGP and eBGP routes that can be installed into a routing table.
(config)#router bgp 100
(config-router)#neighbor 11.0.0.2 remote-as 100
(config-router)#neighbor 12.0.0.1 remote-as 200
(config-router)#neighbor 1101::2 remote-as 200
(config-router)#neighbor 1201::1 remote-as 100
(config-router)#address-family ipv4 unicast
(config-router-af)#max-paths eibgp 2
(config-router-af)#network 11.0.0.2 activate
(config-router-af)#network 12.0.0.1 activate
(config-router-af)#exit-address-family
(config-router)#address-family ipv6 unicast
(config-router-af)#max-paths eibgp 3
(config-router-af)#network 1101::2 activate
(config-router-af)#network 1201::1 activate
(config-router-af)#exit-address-family
 
neighbor activate
Use this command to enable the exchange of specific address family routes with a neighboring router. After a TCP connection is opened with a neighboring router, use this command to enable or disable the exchange of address family information. To enable the exchange of multicast and VPNv4 address prefix types, activate neighbors using this command in address family mode.
Use the no parameter with this command to disable exchange of information with a neighbor.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) activate
no neighbor (A.B.C.D|X:X::X:X|WORD) activate
For L2VPN-unnumbered mode:
neighbor WORD activate
no neighbor WORD activate
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
Default
By default activate is disabled. For all address-families, use this command to enable a neighbor to exchange routing information of a specific address-family with a neighbor.
Command Mode
Address Family mode and l2vpn-unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 100
(config-router)#address-family vpnv4 unicast
(config-router-af)#neighbor 10.10.20.1 activate
 
(config)#router bgp 100
(config-router)#address-family l2vpn evpn
(config-router-af)#bgp l2vpn-unnumbered-mode
(config-router-l2vpn-unnum)#neighbor eth1 activate
 
neighbor advertisement-interval
Use this command to set a minimum interval between the sending of BGP routing updates. To reduce the flapping of routes, set a minimum advertisement interval so that the BGP routing updates are sent only per interval seconds. BGP dampening can also be used to control the effects of flapping routes.
Use the no parameter with this command to set the interval time to default.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) advertisement-interval <0-65535>
no neighbor (A.B.C.D|X:X::X:X|WORD) advertisement-interval
no neighbor (A.B.C.D|X:X::X:X|WORD) advertisement-interval <0-65535>
For BGP ununbered mode:
neighbor WORD advertisement-interval <0-65535>
no neighbor WORD advertisement-interval
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
<0-65535>
Advertisement interval value in seconds
Default
By default, neighbor value for ebgp peer is 30 seconds and IBGP peer is 5 seconds
Command Mode
Router mode and BGP unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
#configure terminal
(config)#router bgp 10
(config-router)#neighbor 10.10.0.3 advertisement-interval 45
For unnumbered peer this configuration is given in BGP unnumbered-mode.
(config)#router bgp 100
(config-router)#bgp unnumbered-mode
(config-router-unnum)#neighbor eth1 advertisement-interval 20
neighbor allowas-in
Use this command to advertise prefixes (routes) even when the source of the prefixes is from the same Autonomous System (AS) number.
Use this command in a scenario where two routers at different locations use the same Autonomous System number and are connected via an ISP. Once prefixes arrive from one branch at the ISP, they are tagged with the customer’s AS number. By default, when the ISP passes the prefixes to the other router, the prefixes are dropped if the other router uses the same AS number. Use this command to advertise the prefixes at the other side. Control the number of times an AS number is advertised by specifying a number.
In a hub and spoke configuration in a VPN, a PE (Provider Edge) router advertises all prefixes containing duplicate AS numbers. Use this command to configure two VRFs on each PE router to receive and advertise prefixes. One of the VRFs receives prefixes with AS numbers from all PE routers and then advertises them to neighboring PE routers. The other VRF receives prefixes with AS numbers from the CE (Customer Edge) router and advertises them to all PE routers in the hub and spoke configuration.
Use the no parameter with this command to remove the configuration.
For unnumbered peer IPv4 unicast mode commands are configured under v4-unnumbered-mode.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) allowas-in <1-10>
no neighbor (A.B.C.D|X:X::X:X|WORD) allowas-in
For v4-unnumbered mode:
neighbor WORD allowas-in
neighbor WORD allowas-in <1-10>
no neighbor WORD allowas-in
Parameters
A.B.C.D
IPv4 neighbor address.
X:X::X:X
IPv6 neighbor address.
WORD
Name of peer group.
Note: For information on how to create peer groups, refer to the neighbor peer-group and neighbor remote-as commands. When this parameter is used with a command, the command applies on all peers in the specified group.
<1-10>
Number of times to allow the advertisement of an AS number
Default
No default value is specified.
Command Mode
This CLI command is available to configure in all Address-family modes (v4-unnumbered mode, IPv4 unicast, IPv6 unicast, IPv4 labeled-unicast, IPv6 labeled-unicast, VPNv4 unicast, VPNv6 unicast, IPv4/IPv6 VRF, L2VPN EVPN)
Applicability
This command was introduced before OcNOS version 1.3.
Example
#configure terminal
(config)#router bgp 7657
(config-router)#address-family ipv4 vrf VRF_A
(config-router-af)#neighbor 10.10.0.1 allowas-in 3
 
#configure terminal
(config)#router bgp 7657
(config-router)#address-family ipv6 vrf VRF_A
(config-router-af)#neighbor 3ffe:15:15:15:15::0 allowas-in 3
 
#con terminal
(config)#router bgp 100
(config-router)#address-family ipv4 unicast
(config-router-af)#bgp v4-unnumbered-mode
(config-router-v4-unnum)#neighbor eth1 allowas-in 6
 
For unnumbered peer configs in L2vpn evpn mode are configured under l2vpn-unnumbered-mode.
(config)#router bgp 100
(config-router)#address-family l2vpn evpn
(config-router-af)#neighbor eth1 allowas-in 7
neighbor as-origination-interval
Use this command to set the minimum interval between sending of AS-origination routing updates.
Use the no parameter with this command to disable this function.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) as-origination-interval <1-65535>
no neighbor (A.B.C.D|X:X::X:X|WORD) as-origination-interval
no neighbor (A.B.C.D|X:X::X:X|WORD) as-origination-interval <1-65535>
For BGP unnumbered mode:
neighbor WORD as-origination-interval interval <0-65535>
no neighbor WORD as-origination-interval
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
<1-65535>
AS origination interval in seconds
Default
By default, neighbor as origination interval is 15 seconds
Command Mode
Router mode and BGP unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
#configure terminal
(config)#router bgp 10
(config-router)#neighbor 10.10.0.75 as-origination-interval 555
 
For unnumbered peer this configuration is given in BGP unnumbered-mode.
(config)#router bgp 100
(config-router)#bgp unnumbered-mode
(config-router-unnum)#neighbor eth1 as-origination-interval 50
 
neighbor attribute-unchanged
Use this command to advertise unchanged BGP attributes to the specified neighbor.
Use the no parameter with this command to disable this function.
For unnumbered peer IPv4 unicast mode commands are configured under v4-unnumbered-mode.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) attribute-unchanged ({ as-path|next-hop|med }|)
no neighbor (A.B.C.D|X:X::X:X|WORD) attribute-unchanged (({ as-path|next-hop|
med }|)
For v4-unnumbered mode:
neighbor WORD attribute-unchanged ({ as-path|next-hop|med }|)
no neighbor WORD attribute-unchanged (({ as-path|next-hop|med }|)
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
as-path
AS path attribute
next-hop
Nexthop attribute
med
Multi-exit discriminator attribute
Default
By default, the neighbor attribute-unchanged is disabled
Command Mode
Address Family mode and v4-unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
#configure terminal
(config)#router bgp 10
(config-router)#address-family ipv4 unicast
(config-router-af)#neighbor 10.10.0.75 attribute-unchanged as-path med
 
(config)#router bgp 100
(config-router)#address-family ipv4 unicast
(config-router-af)#bgp v4-unnumbered-mode
(config-router-v4-unnum)#OcNOS(config-router-v4-unnum)#neighbor eth1 attribute-unchanged as-path
neighbor authentication-key
Use this command to enable message digest5 (MD5) authentication on a TCP connection between two BGP peers. Configuring MD5 authentication between two BGP peers, means that each segment sent on the TCP connection between the peers is verified. MD5 authentication must be configured with the same password on both BGP peers; otherwise, the connection between them will not be established.
Use the no parameter with this command to delete the MD5 authentication.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) authentication-key (0 | 1 |) <WORD>
<WORD> plain text password
neighbor (A.B.C.D|X:X::X:X|WORD) authentication-key <WORD>
<WORD> encrypted password
no neighbor (A.B.C.D|X:X::X:X|WORD) authentication-key <WORD>
<WORD> encrypted password
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of the BGP peer group
0
Unencrypted password
WORD
Unencrypted password (maximum length 80 characters)
1
Encrypted password (default)
WORD
Encrypted password (maximum length 162 characters)
Default
Not applicable
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
#configure terminal
(config)#router bgp 11
(config-router)#neighbor 10.10.0.73 authentication-key 0 myPass
(config-router)#no neighbor 10.10.0.73 authentication-key 0xba76ef302e2f20af
For unnumbered peer below configuration is given in BGP unnumbered-mode.
(config)#router bgp 100
(config-router)#bgp unnumbered-mode
(config-router-unnum)#neighbor eth1 authentication-key 0 key1
neighbor capability graceful-restart
Use this command to advertise the graceful restart capability to its neighbor. This configuration indicates that the BGP speaker has the ability to preserve its forwarding state for the address family when BGP restarts.
You must first specify a neighbor’s remote-as identification number assigned by the neighbor router.
Note: The graceful restart capability is advertised only when the graceful restart capability has been enabled using the bgp graceful-restart command.
Use the no parameter with this command to not advertise the graceful restart capability to its neighbor.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) capability graceful-restart
no neighbor (A.B.C.D|X:X::X:X|WORD) capability graceful-restart
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
Default
By default, the graceful-restart is disabled
Command Mode
Address Family mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 10
(config-router)#address-family ipv4 unicast
(config-router-af)#neighbor 10.10.10.50 capability graceful-restart
neighbor capability orf prefix-list
Use this command to enable Outbound Router Filtering (ORF) and advertise the ORF capability to its neighbors. The ORFs send and receive capabilities to lessen the number of updates exchanged between neighbors. By filtering updates, this option minimizes generating and processing of updates.
The two routers exchange updates to maintain the ORF for each router:
The local router advertises the ORF capability in send mode.
The remote router receives the ORF capability in receive mode, applying the filter as outbound policy.
Only an individual router or a peer group can be configured to be in receive or send mode. A peer-group member cannot be configured to be in receive or send mode.
Use the no parameter with this command to disable this function.
For unnumbered peer, IPv4 unicast mode commands are configured under v4-unnumbered-mode.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) capability orf prefix-list (both|receive|send)
no neighbor (A.B.C.D|X:X::X:X|WORD) capability orf prefix-list (both|receive|send)
For v4-unnumbered mode:
neighbor WORD capability orf prefix-list (both|receive|send)
no neighbor WORD capability orf prefix-list (both|receive|send)
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
both
The local router can send ORF entries to its peer, as well as receive ORF entries from its peer.
receive
The local router is willing to receive ORF entries from its peer
send
The local router is willing to send ORF entries to its peer
Default
By default, the orf prefix-list is disabled
Command Mode
Router Address Family (IPv4 unicast, IPv4 multicast, IPv6, v4-unnumbered) mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 10
(config-router)#address-family ipv4 unicast
(config-router-af)#neighbor 10.10.0.5 capability orf prefix-list both
(config-router-af)#neighbor effe:2897::0003:3ed5 capability orf prefix-list receive
 
(config)#router bgp 100
(config-router)#address-family ipv4 unicast
(config-router-af)#bgp v4-unnumbered-mode
(config-router-v4-unnum)#neighbor eth1 capability orf prefix-list both
 
neighbor collide-established
Use this command to include a neighbor already in an established state for conflict resolution when a TCP connection collision is detected. This command is not required for most network deployments, so users should only use this command when required.
Note: The associated functionality of including an “established” neighbor into TCP connection collision conflict resolution is automatically enabled when a neighbor is configured for BGP graceful-restart.
Use the no option with this command to turn this feature off.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) collide-established
no neighbor (A.B.C.D|X:X::X:X|WORD) collide-established
For BGP unnumbered mode:
neighbor WORD collide-established
no neighbor WORD collide-established
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
Default
By default, neighbor collide is disabled
Command Mode
Router mode and BGP unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
#configure terminal
(config)#router bgp 10
(config-router)#neighbor 3.3.3.3 collide-established
 
For unnumbered peer below configuration is given in BGP unnumbered-mode.
(config)#router bgp 100
(config-router)#bgp unnumbered-mode
(config-router-unnum)#neighbor eth1 collide-established
 
neighbor de-activate
Use this command to disable the exchange of specific address family routes with a neighboring router for peer-group member. After a TCP connection is opened with a neighboring router, use this command to enable or disable the exchange of address family information for peer-group member.
Use the no parameter with this command to inherit the properties of peer-group. i.e., If peer-group is activated in the given address-family, no of this command will activate the peer member as peer-group is activated in address-family..
Command Syntax
neighbor (A.B.C.D|X:X::X:X) de-activate
no neighbor (A.B.C.D|X:X::X:X) de-activate
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
Default
By default de-activate is disabled for all peer-group members. For all address-families, Use this command to disable a neighbor to exchange routing information of a specific address-family with a neighbor.
Command Mode
Address Family mode
Applicability
This command is introduced in OcNOS version 6.0.0. This command is applicable only to neighbor which is a member of peer-group.
Examples
#configure terminal
router bgp 100
neighbor pg1 peer-group
neighbor pg1 remote-as 100
neighbor 10.1.1.2 peer-group pg1
neighbor 20.1.1.2 peer-group pg1
neighbor 30.1.1.2 remote-as 100
!
address-family ipv4 unicast
neighbor pg1 activate
neighbor 30.1.1.2 activate
exit-address-family
!
(config-router-af)#neighbor 10.1.1.2 de-activate
(config-router-af)#show running-config bgp
!
router bgp 100
neighbor pg1 peer-group
neighbor pg1 remote-as 100
neighbor 10.1.1.2 peer-group pg1
neighbor 20.1.1.2 peer-group pg1
neighbor 30.1.1.2 remote-as 100
!
address-family ipv4 unicast
neighbor pg1 activate
neighbor 10.1.1.2 de-activate
neighbor 30.1.1.2 activate
exit-address-family
!
(config-router-af)#no neighbor 10.1.1.2 de-activate
(config-router-af)#commit
(config-router-af)#
(config-router-af)#show running-config bgp
!
router bgp 100
neighbor pg1 peer-group
neighbor pg1 remote-as 100
neighbor 10.1.1.2 peer-group pg1
neighbor 20.1.1.2 peer-group pg1
neighbor 30.1.1.2 remote-as 100
!
address-family ipv4 unicast
neighbor pg1 activate
neighbor 30.1.1.2 activate
exit-address-family
!
neighbor default-originate
Use this command to allow a BGP local router to send the default route 0.0.0.0 to a neighbor to use as a default route. This command can be used with standard or extended access lists.
Use the no parameter with this command to send no route as a default.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) default-originate
neighbor (A.B.C.D|X:X::X:X|WORD) default-originate route-map WORD
no neighbor (A.B.C.D|X:X::X:X|WORD) default-originate
no neighbor (A.B.C.D|X:X::X:X|WORD) default-originate route-map WORD
For v4-unnumbered mode:
neighbor WORD default-originate
neighbor WORD default-originate route-map WORD
no neighbor WORD default-originate
no neighbor WORD default-originate route-map WORD
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
WORD
Route map name
Default
By default, neighbor default originate is disabled
Command Mode
Route Address Family mode and v4-unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 10
(config-router)#address-family ipv4 unicast
(config-router-af)#neighbor 10.10.10.1 default-originate route-map myroute
For unnumbered peer, IPv4 unicast mode commands are configured under v4-unnumbered-mode.
#con terminal
(config)#router bgp 100
(config-router)#address-family ipv4 unicast
(config-router-af)#bgp v4-unnumbered-mode
(config-router-v4-unnum)#neighbor eth1 default-originate
neighbor description
Use this command to associate a description with a neighbor. This command helps to identify a neighbor quickly. This command is useful for an ISP that has multiple neighbor relationships.
Use the no parameter with this command to remove the description.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) description LINE
no neighbor (A.B.C.D|X:X::X:X|WORD) description
no neighbor (A.B.C.D|X:X::X:X|WORD) description LINE
For BGP unnumbered mode:
neighbor WORD description LINE
no neighbor WORD description
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
LINE
Neighbor description (up to 80 characters)
Default
By default, the neighbor description is disabled
Command Mode
Router mode and Address Family and BGP unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 10
(config-router)#neighbor 1.2.3.4 description Backup router for sales
 
(config)#router bgp 100
(config-router)#address-family ipv6 vrf VRF_A
(config-router-af)#neighbor 3ffe:15:15:15:15::0 description Bank of America
 
For unnumbered peer below configuration is given in BGP unnumbered-mode.
(config)#router bgp 100
(config-router)#bgp unnumbered-mode
(config-router-unnum)#neighbor eth1 description unnbered-peer1
neighbor disallow-infinite-holdtime
Use this command to disallow configuration of infinite hold-time. This command enables the local BGP speaker to reject a hold-time of “0” seconds from a peer (during exchange of open messages) or a user (during configuration).
The no form of this command allows the BGP speaker to accept a hold-time of “0” from a peer or during configuration.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) disallow-infinite-holdtime
no neighbor (A.B.C.D|X:X::X:X|WORD) disallow-infinite-holdtime
For BGP unnumbered mode:
neighbor WORD disallow-infinite-holdtime
no neighbor WORD disallow-infinite-holdtime
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
Default
By default, neighbor disallow infinite holdtime is disabled
Command Mode
Router mode and BGP unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
(config-router)#neighbor 10.11.4.26 disallow-infinite-holdtime
(config-router)#neighbor 3ffe::45 disallow-infinite-holdtime
 
For unnumbered peer below configuration is given in BGP unnumbered-mode.
(config)#router bgp 100
(config-router)#bgp unnumbered-mode
(config-router-unnum)#neighbor eth1 disallow-infinite-holdtime
neighbor distribute-list
Use this command to filter route updates from a particular BGP neighbor. Use only one distribute list per BGP neighbor.
Use the no parameter with this command to remove an entry.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) distribute-list (<1-199>|<1300-2699>|WORD) (in|out)
no neighbor (A.B.C.D|X:X::X:X|WORD) distribute-list (<1-199>|<1300-2699>|WORD) (in|out)
For v4-unnumbered mode:
neighbor WORD distribute-list (<1-199>|<1300-2699>|WORD) (in|out)
no neighbor WORD distribute-list (<1-199>|<1300-2699>|WORD) (in|out)
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
<1-199>
IP access-list number
<1300-2699>
IP access-list number (expanded-range)
WORD
Access-list name
in
Filter incoming advertised routes
out
Filter outgoing advertised routes
Default
By default, neighbor distribute list is disabled
Command Mode
Address Family mode and v4-unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 10
(config-router)#address-family ipv4 unicast
(config-router-af)#neighbor 1.2.3.4 distribute-list mylist out
For unnumbered peer, IPv4 unicast mode commands are configured under v4-unnumbered-mode.
(config)#router bgp 100
(config-router)#address-family ipv4 unicast
(config-router-af)#bgp v4-unnumbered-mode
(config-router-v4-unnum)#neighbor eth1 distribute-list list1 in
neighbor dont-capability-negotiate
Use this command to disable capability negotiation. This command is used to allow compatibility with older BGP versions that have no capability parameters used in open messages between peers.
Use the no parameter with this command to enable capability negotiation.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) dont-capability-negotiate
no neighbor (A.B.C.D|X:X::X:X|WORD) dont-capability-negotiate
For BGP unnumbered mode:
neighbor WORD dont-capability-negotiate
no neighbor WORD dont-capability-negotiate
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
Default
By default, capability negotiation is disabled
Command Mode
Router mode and BGP unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 10
(config-router)#neighbor 10.10.0.34 dont-capability-negotiate
 
For unnumbered peer below configuration is given in BGP unnumbered-mode.
(config)#router bgp 100
(config-router)#bgp unnumbered-mode
(config-router-unnum)#neighbor eth1 dont-capability-negotiate
 
neighbor ebgp-multihop
Use this command to accept and try BGP connections to external peers on indirectly connected networks. Multihop is not established if the only route to the multihop peer is a default route. This avoids loop formation.
Use the no parameter with this command to return to the default.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) ebgp-multihop
neighbor (A.B.C.D|X:X::X:X|WORD) ebgp-multihop <1-255>
no neighbor (A.B.C.D|X:X::X:X|WORD) ebgp-multihop
no neighbor (A.B.C.D|X:X::X:X|WORD) ebgp-multihop <1-255>
For BGP unnumbered mode:
neighbor WORD ebgp-multihop
neighbor WORD ebgp-multihop <1-255>
no neighbor WORD ebgp-multihop
no neighbor WORD ebgp-multihop <1-255>
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
<1-255>
Maximum hop count
Default
By default, maximum hop count is 255
Command Mode
Router mode and BGP unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 10
(config-router)#neighbor 10.10.10.34 remote-as 20
(config-router)#neighbor 10.10.10.34 ebgp-multihop 5
For unnumbered peer below configuration is given in BGP unnumbered-mode.
(config)#router bgp 100
(config-router)#bgp unnumbered-mode
(config-router-unnum)#neighbor eth1 ebgp-multihop
neighbor enforce-multihop
Use this command to enforce BGP neighbors to perform multihop.
Use the no parameter with this command to turn off this feature.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) enforce-multihop
no neighbor (A.B.C.D|X:X::X:X|WORD) enforce-multihop
For BGP unnumbered mode:
neighbor WORD enforce-multihop
no neighbor WORD enforce-multihop
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
Default
By default, the maximum hop count is 255
Command Mode
Router mode and BGP unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 10
(config-router)#neighbor 10.10.0.34 remote-as 20
(config-router)#neighbor 10.10.0.34 enforce-multihop
For unnumbered peer below configuration is given in BGP unnumbered-mode.
(config)#router bgp 100
(config-router)#bgp unnumbered-mode
(config-router-unnum)#neighbor eth1 enforce-multihop
neighbor extended-optional-param
Use this command enable extended optional parameter length for BGP OPEN messages as specified in RFC 9072.
Use the no form of this command to disable extended optional parameter length.
Command Syntax
neighbor A.B.C.D|X:X::X:X|WORD extended-optional-param
no neighbor A.B.C.D|X:X::X:X|WORD extended-optional-param
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command.
When you specify this parameter, the command applies to all peers in the group.
Default
Extended optional parameter length is disabled by default.
Command Mode
BGP router mode
Applicability
This command was introduced in OcNOS version 6.0.0.
Example
(config)#router bgp 100
(config-router)#neighbor 1.1.1.1 extended-optional-param
(config-router)#commit
(config-router)#show run bgp
!
router bgp 100
bgp router-id 11.11.11.11
neighbor 1.1.1.1 remote-as 100
neighbor 1.1.1.1 extended-optional-param
neighbor fall-over bfd
Use this command to enable the BFD for BGP peers.
Use the no form of the command to disable the BFD option for BGP peers.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) fall-over bfd (multihop|)
no neighbor (A.B.C.D|X:X::X:X|WORD) fall-over bfd (multihop|)
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format.
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
multihop
Enable multihop
Default
Bidirectional Forwarding Detection for BGP peers is disabled by default.
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
(config)#router bgp 100
(config-router)#neighbor 10.2.3.4 fall-over bfd
(config-router)#
(config-router)#neighbor 10.2.3.4 fall-over bfd multihop
neighbor filter-list
Use this command to set up a BGP filter. This command specifies an access list filter on updates based on the BGP autonomous system paths. Each filter is an access list based on regular expressions.
Use the no parameter with this command to disable this function.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) filter-list WORD (in|out)
no neighbor (A.B.C.D|X:X::X:X|WORD) filter-list WORD (in|out)
For v4-unnumbered mode:
neighbor WORD filter-list WORD (in|out)
no neighbor WORD filter-list WORD (in|out)
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
WORD
Name of an autonomous system path access list
in
Filter incoming advertised routes
out
Filter outgoing advertised route
Default
By default, filter list is disabled
Command Mode
Address Family mode and v4-unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 10
(config-router)#neighbor 10.10.0.34 remote-as 20
(config-router)#address-family ipv4 unicast
(config-router-af)#neighbor 10.10.0.34 filter-list out in
For unnumbered peer, IPv4 unicast mode commands are configured under v4-unnumbered-mode.
(config)#router bgp 100
(config-router)#address-family ipv4 unicast
(config-router-af)#bgp v4-unnumbered-mode
(config-router-v4-unnum)#neighbor eth1 filter-list list2 in
neighbor g-shut
Use this command to start a graceful shutdown for the BGP session of the specified BGP neighbor. The BGP session for this neighbor is shut down after the graceful shutdown timer expires.
If there is no alternate path available for traffic to flow prior the actual shutdown of the BGP session, this path is made available for 60 seconds or for configured time after which the path is no longer available and traffic is dropped.
Use the no parameter with this command to bring up the session again for the specified BGP neighbor whose BGP session had been shut down using the neighbor g-shut command.
Note: The graceful shutdown capability is not supported on iBGP sessions.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) g-shut
no neighbor (A.B.C.D|X:X::X:X|WORD) g-shut
Parameters
A.B.C.D
Neighbor IPv4 address
X:X::X:X|
Neighbor IPv6 address
WORD
Neighbor tag
Default
By default, neighbor g-shut is disabled
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 100
(config-router)#neighbor 1.1.1.2 g-shut
 
#configure terminal
(config)#router bgp 100
(config-router)#no neighbor 1.1.1.2 g-shut
 
 
neighbor g-shut-timer
Use this command to configure the value of the graceful shutdown timer. After the timer expires, the BGP session initiated for graceful shutdown is shut down.
Use the no parameter with this command to revert to the default setting.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) g-shut-timer <10-65535>
no neighbor (A.B.C.D|X:X::X:X|WORD) g-shut-timer <10-65535>
Parameters
A.B.C.D
Neighbor IPv4 address
X:X::X:X
Neighbor IPv6 address
WORD
Neighbor tag
<10-65535>
Graceful shutdown timer in seconds
Default
By default, the timer value is set to 60 seconds
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 100
(config-router)#neighbor 1.1.1.2 g-shut-timer 120
neighbor limit
Use this command to specify the maximum number of peers that can be configured in the BGP dynamic peer-group.
Use the no parameter with this command to disable this function.
Command Syntax
neighbor WORD limit <1-200>
no neighbor WORD (limit <1-200>|)
Parameters
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command.
<1-200>
The maximum number of peers that can be configured in a BGP dynamic peer-group.
Default
By default, neighbor word limit is disabled
Command Mode
Router mode and Address Family VRF mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
#configure terminal
(config)#router bgp 11
(config-router)#neighbor group1 limit 120
neighbor local-as
Use this command to specify an AS (autonomous system) number to use with BGP neighbor.
Use the no parameter with this command to disable this command.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) local-as <1-4294967295> (no-prepend|) (replace-as|)
no neighbor (A.B.C.D|X:X::X:X|WORD) local-as <1-4294967295>
no neighbor (A.B.C.D|X:X::X:X|WORD) local-as <1-4294967295> no-prepend
no neighbor (A.B.C.D|X:X::X:X|WORD) local-as <1-4294967295> replace-as
 
For BGP unnumbered mode:
neighbor WORD local-as <1-4294967295> (no-prepend|) (replace-as|)
no neighbor WORD local-as <1-4294967295>
no neighbor WORD local-as <1-4294967295> no-prepend
no neighbor WORD local-as <1-4294967295> replace-as
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
<1-4294967295>
 
Neighbor’s AS number when extended capabilities are configured
no-prepend
Do not prepend local-as to updated from ebgp peers
replace-as
Replace real AS with local-as in the EBGP updates
Note: The AS number 23456 is a reserved 2-byte AS number. An old BGP speaker (2-byte implementation) should be configured with 23456 as its remote AS number while peering with a non-mappable new BGP speaker (4-byte implementation).
Default
By default, local-as is disabled.
Command Mode
Router mode and Address Family-vrf mode and BGP unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3. The new version of the command with “no-prepend” and “replace-as“ option
is introduced in OcNOS version 6.4.1.
Example
#configure terminal
(config)#router bgp 100
(config-router)#neighbor 20.1.1.3 remote-as 300
(config-router)#neighbor 20.1.1.3 local-as 200 no-prepend replace-as
 
(config)#router bgp 100
(config-router)#address-family ipv6 vrf VRF_A
(config-router-af)#neighbor 3ffe:15:15:15:15::0 remote-as 300
(config-router-af)#neighbor 3ffe:15:15:15:15::0 local-as 200
 
For unnumbered peer below configuration is given in BGP unnumbered-mode.
(config)#router bgp 100
(config-router)#bgp unnumbered-mode
(config-router-unnum)#neighbor eth1 local-as 300
neighbor maximum-prefix
Use this command to set the number of prefixes that can be received from a neighbor.
Use the no parameter with this command to disable this function.
Note: For unnumbered peer, IPv4 unicast mode commands are configured under v4-unnumbered-mode.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) maximum-prefix <1-4294967295> <1-100|>
neighbor (A.B.C.D|X:X::X:X|WORD) maximum-prefix <1-4294967295> stop-update
neighbor (A.B.C.D|X:X::X:X|WORD) maximum-prefix <1-4294967295> warning-only
neighbor (A.B.C.D|X:X::X:X|WORD) maximum-prefix <1-4294967295> <1-100> warning-only
no neighbor (A.B.C.D|X:X::X:X) maximum-prefix <1-4294967295>
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
<1-4294967295>
 
Maximum number of prefixes accepted from this peer
stop-update
Stop installing routes when the maximum number of prefixes is exceeded.
<1-100>
Threshold value percent <1-100>
warning-only
Only give a warning message when the limit is exceeded. When this parameter is not specified and extra prefixes are received, the router ends the peering. A terminated peer remains down until the  clear ip bgp A.B.C.D command is given.
Default
By default, neighbor maximum prefix is disabled
Command Mode
Address Family mode ad v4-unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 10
(config-router)#address-family ipv4 unicast
(config-router-af)#neighbor 10.10.0.72 maximum-prefix 1244 warning-only
 
(config)#router bgp 100
(config-router)#address-family ipv4 unicast
(config-router-af)#bgp v4-unnumbered-mode
(config-router-v4-unnum)#neighbor eth1 maximum-prefix 3
neighbor next-hop-self
Use this command to make the router the next hop for a BGP-speaking neighbor or peer group. This command allows a BGP router to change the nexthop information that is sent to the iBGP peer. The nexthop information is set to the IP address of the interface used to communicate with the neighbor.
Use the no parameter with this command to disable this feature.
For unnumbered peer, IPv4 unicast mode commands are configured under v4-unnumbered-mode.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) next-hop-self
no neighbor (A.B.C.D|X:X::X:X|WORD) next-hop-self
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
Default
By default, next hop self is disabled
Command Mode
Address Family mode and v4-unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 10
(config-router)#neighbor 10.10.0.72 remote-as 100
(config-router)#address-family ipv4 unicast
(config-router-af)#neighbor 10.10.0.72 next-hop-self
 
(config)#router bgp 100
(config-router)#address-family ipv4 unicast
(config-router-af)#bgp v4-unnumbered-mode
(config-router-v4-unnum)#neighbor eth1 next-hop-self
 
neighbor optional-as
Use this command to specify an AS (autonomous system) number to use with BGP dynamic peer-group.
Use the no parameter with this command to disable this function.
Command Syntax
neighbor WORD optional-as <1-4294967295>
no neighbor WORD optional-as <1-4294967295>
Parameters
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
<1-4294967295>
The range from which the optional AS number must be configured.
 
Default
By default, neighbor optional as is disabled
Command Mode
Router mode and Address Family VRF mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 12
(config-router)#neighbor group1 optional-as 400
neighbor override-capability
Use this command to ignore received capabilities and use locally configured values.
Use the no parameter with this command to disable this function.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) override-capability
no neighbor (A.B.C.D|X:X::X:X|WORD) override-capability
For BGP unnumbered mode:
neighbor WORD override-capability
no neighbor WORD override-capability
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
Default
By default, override-capability is disabled
Command Mode
Router mode and BGP unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 12
(config-router)#neighbor 10.10.10.10 override-capability
For unnumbered peer below configuration is given in BGP unnumbered-mode.
(config)#router bgp 100
(config-router)#bgp unnumbered-mode
(config-router-unnum)#neighbor eth1 override-capability
 
neighbor passive
Use this command to make a BGP neighbor passive.
Use the no parameter with this command to disable this function.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) passive
no neighbor (A.B.C.D|X:X::X:X|WORD) passive
For BGP unnumbered mode:
neighbor WORD passive
no neighbor WORD passive
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
Default
By default, neighbor passive is disabled
Command Mode
Router mode and BGP unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 12
(config-router)#neighbor 10.10.10.10 passive
 
For unnumbered peer below configuration is given in BGP unnumbered-mode.
(config)#router bgp 100
(config-router)#bgp unnumbered-mode
(config-router-unnum)#neighbor eth1 passive
 
neighbor peer-group
Use this command to add a neighbor to an existing peer group. Neighbors with the same update policies are grouped into peer groups. This facilitates the updates of various policies, such as distribute and filter lists. The peer group is then configured easily with any of the neighbor commands. Any changes made to the peer group affect all members.
See Usage below for when a peer group and a neighbor have conflicting attribute configurations.
To create a peer group, use the neighbor WORD peer-group command, and then use this command to add neighbors to the group.
Use the no parameter with this command to remove a neighbor from a named peer group.
Command Syntax
neighbor (A.B.C.D|X:X::X:X) peer-group WORD
no neighbor (A.B.C.D|X:X::X:X) peer-group WORD
For BGP unnumbered mode:
neighbor WORD peer-group WORD
no neighbor WORD peer-group WORD
Parameters
A.B.C.D
Address of the BGP neighbor in IPv4 format
X:X::X:X
Address of the BGP neighbor in IPv6 format
WORD
Peer group name
Default
No default value is specified
Command Mode
Router mode and BGP unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
#configure terminal
(config)#router bgp 10
(config-router)#neighbor group1 peer-group
 
For unnumbered peer below configuration is given in BGP unnumbered-mode.
Note: For unnumbered peer we use peergroup key word to bind the unnumbered peer in group.
(config)#router bgp 100
(config-router)#bgp unnumbered-mode
(config-router-unnum)#neighbor eth1 peergroup ipi
 
Usage
When a peer group and a peer (neighbor) have conflicting attribute configurations the following rules apply:
Outbound attribute configurations of a peer group replace peer member configurations of the same attributes when a peer becomes member of that peer group. Outbound attribute modifications to group members are not allowed.
A peer group member’s inbound attribute configurations take precedence over the peer group configuration.
These commands control outbound attribute updates:
neighbor distribute-list with an access-list number and the out parameter
neighbor filter-list with the out parameter
neighbor prefix-list with an access-list name and the out parameter
neighbor route-map with the out parameter
These commands control inbound attribute updates:
neighbor distribute-list with an access-list number and the in parameter
neighbor filter-list with the in parameter
neighbor prefix-list with an access-list name and the in parameter
neighbor route-map with the in parameter
neighbor WORD peer-group range
Use this command to create a dynamic peer group.
Use the no parameter with this command to remove a peer group.
Command Syntax
neighbor WORD peer-group range (A.B.C.D/M|X:X::X:X/M)
no neighbor WORD peer-group range (A.B.C.D/M|X:X::X:X/M)
Parameters
A.B.C.D/M
IP Prefix
X:X::X:X/M
IPv6 Prefix
WORD
Peer group name
Default
No default value is specified
Command Mode
Router mode and Address Family VRF mode.
Applicability
This command was introduced before OcNOS version 1.3.
Example
#configure terminal
(config)#router bgp 10
(config-router)#neighbor group1 peer-group range 10.10.10.0/24
neighbor port
Use this command to set the BGP port number of a neighbor.
Use the no parameter with this command to remove a port number from a BGP neighbor.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) port <0-65535>
no neighbor (A.B.C.D|X:X::X:X|WORD) port
no neighbor (A.B.C.D|X:X::X:X|WORD) port <0-65535>
For BGP unnumbered mode:
neighbor WORD port <0-65535>
no neighbor WORD port
no neighbor WORD port <0-65535>
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
<0-65535>
Port number
Default
By default, neighbor port is disabled
Command Mode
Router mode and BGP unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 12
(config-router)#neighbor 10.10.10.10 port 643
For unnumbered peer below configuration is given in BGP unnumbered-mode.
(config)#router bgp 100
(config-router)#bgp unnumbered-mode
(config-router-unnum)#neighbor eth1 port 500
 
neighbor prefix-list
Use this command to specify a prefix list for filtering BGP advertisements.
Filtering by prefix list matches the prefixes of routes with those listed in the prefix list. If there is a match, the route is used. An empty prefix list permits all prefixes. If a given prefix does not match any entries of a prefix list, the route is denied access. When multiple entries of a prefix list match a prefix, the entry with the smallest sequence number is considered to be a real match.
The router begins the search at the top of the prefix list, with the sequence number 1. Once a match or deny occurs, the router does not need to go through the rest of the prefix list. For efficiency the most common matches or denies are listed at the top. The neighbor distribute-list command is an alternative to this command and only one of them can be used to filter the same neighbor in any direction.
Use the no parameter with this command to remove an entry.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) prefix-list WORD (in|out)
no neighbor (A.B.C.D|X:X::X:X|WORD) prefix-list WORD (in|out)
For v4-unnumbered mode:
neighbor WORD prefix-list WORD (in|out)
no neighbor WORD prefix-list WORD (in|out)
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
WORD
Name of an access list
in
Apply access list to incoming advertisements
out
Apply access list to outgoing advertisements
Default
By default, neighbor prefix list is disabled
Command Mode
Address Family mode and v4-unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#ip prefix-list list1 deny 30.0.0.0/24
(config)#router bgp 12
(config-router)#address-family ipv4 unicast
(config-router-af)#neighbor 10.10.10.10 prefix-list list1 in
 
For unnumbered peer, IPv4 unicast mode commands are configured under v4-unnumbered-mode.
(config)#router bgp 100
(config-router)#address-family ipv4 unicast
(config-router-af)#bgp v4-unnumbered-mode
(config-router-v4-unnum)#neighbor eth1 prefix-list list2 out
 
neighbor remote-as
Use this command to establish a BGP peering relationship with a customer edge router.
The specified neighbor only exchanges unicast address prefixes, unless the neighbor is also activated using the neighbor activate command, which allows the exchange of other routing information.
Use the no parameter with this command to delete this peering.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) remote-as (<1-4294967295>|internal|external)
no neighbor (A.B.C.D|X:X::X:X|WORD) remote-as (<1-4294967295>|internal|external)
For BGP unnumbered mode:
neighbor WORD remote-as (internal|external)
no neighbor WORD remote-as (internal|external)
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
For an unnumbered interface (RFC 5549), specify an interface name configured with neighbor discovery or an IPv4 address with /31 or /30.
<1-4294967295>
 
Neighbor’s autonomous system number (ASN) when extended capabilities are configured. If the specified ASN matches the ASN number specified in the router BGP global configuration, the neighbor is identified as internal. If the ASN does no match, the neighbor is identified as external to the local AS.
internal
iBGP peer.
external
eBGP peer.
Default
By default, neighbor remote is disabled
Command Mode
Router mode and Address Family-vrf mode and BGP unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3 and updated in OcNOS version 1.3.6.
Example
#configure terminal
(config)#router bgp 11
(config-router)#neighbor 10.10.0.73 remote-as 345
(config-router)#neighbor 11.11.0.74 remote-as 23456
Note: The last command in the example above should be used when the local speaker is OBGP and the neighbor is NBGP with a 4-octet ASN.
(config)#router bgp 100
(config-router)#address-family ipv4 vrf VRF_A
(config-router-af)#neighbor 10.10.0.1 remote-as 65000
 
(config)#router bgp 100
(config-router)#address-family ipv6 vrf VRF_A
(config-router-af)#neighbor 3ffe:15:15:15:15::0 remote-as 65000
 
(config-router)#bgp unnumbered-mode
(config-router-unnum)#neighbor eth1 remote-as internal
(config-router-unnum)#show running bgp
 
router bgp 100
!
bgp unnumbered-mode
neighbor eth1 remote-as internal
neighbor eth2 remote-as external
exit-unnumbered-mode
!
 
neighbor remove-private-AS
Use this command to remove the private autonomous system number (ASN) from outbound updates. Private ASNs are not advertised to the Internet. This command is used with external BGP peers only. The router removes the ASNs only if the update includes private ASNs. If the update includes both private and public ASNs, the system treats it as an error.
Use the no parameter with this command to revert to default.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) remove-private-AS
no neighbor (A.B.C.D|X:X::X:X|WORD) remove-private-AS
For v4-unnumbered mode:
neighbor WORD remove-private-AS
no neighbor WORD remove-private-AS
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
Default
By default, neighbor remove private AS is disabled
Command Mode
Address Family mode and v4-unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
#configure terminal
(config)#router bgp 10
(config-router)#address-family ipv4 unicast
(config-router-af)#neighbor 10.10.0.63 remove-private-AS
 
For unnumbered peer, IPv4 unicast mode commands are configured under v4-unnumbered-mode.
(config)#router bgp 100
(config-router)#address-family ipv4 unicast
(config-router-af)#bgp v4-unnumbered-mode
(config-router-v4-unnum)#neighbor eth1 remove-private-AS
 
neighbor restart-time
Use this command to set a different restart-time than the global restart-time configured using the bgp graceful-restart command.
Use the no parameter with this command to restore the router to its default state.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) restart-time <1-3600>
no neighbor (A.B.C.D|X:X::X:X|WORD) restart-time <1-3600>
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
<1-3600>
The maximum time that a graceful-restart neighbor waits to come back up after a restart. Make sure that this value does not exceed the stalepath-time specified in router mode.
Default
By default, restart time is 90 seconds
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
#configure terminal
(config)#router bgp 10
(config-router)#neighbor 3.3.3.3 restart-time 45
neighbor route-map
Use this command to apply a route map to incoming or outgoing routes. This command filters updates and modifies attributes. A route map is applied to inbound or outbound updates. Only the routes that pass the route map are sent or accepted in updates.
Use the no parameter with this command to a route map.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) route-map WORD (in|out)
no neighbor (A.B.C.D|X:X::X:X|WORD) route-map WORD (in|out)
For v4-unnumbered mode:
neighbor WORD route-map WORD (in|out)
no neighbor WORD route-map WORD (in|out)
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
WORD
Name of the route map
in
Apply access list to incoming advertisements
out
Apply access list to outgoing advertisements
Default
No default value is specified
Command Mode
Address Family mode and v4-unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
The following example shows the configuration of the route map named rmap2 and then the use of this map name in the neighbor route-map command.
#configure terminal
(config)#route-map rmap2 permit 6
(config-route-map)#match origin incomplete
(config-route-map)#set metric 100
(config-route-map)#exit
(config)#router bgp 12
(config-router)#address-family ipv4 unicast
(config-router-af)#neighbor 10.10.10.10 route-map rmap2 in
 
For unnumbered peer, IPv4 unicast mode commands are configured under v4-unnumbered-mode.
(config)#router bgp 100
(config-router)#address-family ipv4 unicast
(config-router-af)#bgp v4-unnumbered-mode
(config-router-v4-unnum)#neighbor eth1 route-map rmap1 in
 
neighbor route-reflector-client
Use this command to make the router a BGP route reflector and set a specified neighbor as its client.
Using route reflectors reduces the number of iBGP peers within an AS. An AS can have more than one route reflector. A route reflector treats other route reflectors as other iBGP speakers.
Use the no parameter with this command to indicate that the neighbor is not a client.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) route-reflector-client
no neighbor (A.B.C.D|X:X::X:X|WORD) route-reflector-client
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
Default
No default value is specified
Command Mode
This command is supported in all Address Family modes.
Applicability
This command was introduced before OcNOS version 1.3.
Examples
In the following configuration, Router1 is the route reflector for clients 3.3.3.3 and 2.2.2.2; it also has a non-client peer 6.6.6.6.
#configure terminal
(config)#router bgp 200
(config-router)#neighbor 3.3.3.3 remote-as 200
(config-router)#neighbor 2.2.2.2 remote-as 200
(config-router)#neighbor 6.6.6.6 remote-as 200
(config-router)#address-family ipv4 unicast
(config-router-af)#neighbor 3.3.3.3 route-reflector-client
(config-router-af)#neighbor 2.2.2.2 route-reflector-client
For unnumbered peer, IPv4 unicast mode commands are configured under v4-unnumbered-mode.
(config)#router bgp 100
(config-router)#address-family ipv4 unicast
(config-router-af)#bgp v4-unnumbered-mode
(config-router-v4-unnum)#neighbor eth1 route-reflector-client
For unnumbered peer, configs in L2vpn EVPN mode are configured under l2vpn-unnumbered-mode.
(config)#router bgp 100
(config-router)#address-family l2vpn evpn
(config-router-af)#neighbor eth1 route-reflector-client
neighbor route-server-client
Use this command to make a neighbor a route server client.
Use the no parameter with this command to remove the configuration of a neighbor as route server client.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) route-server-client
no neighbor (A.B.C.D|X:X::X:X|WORD) route-server-client
For v4-unnumbered mode:
neighbor WORD route-server-client
no neighbor WORD route-server-client
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
Default
No default value is specified
Command Mode
Address Family mode and v4-unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
#configure terminal
(config)#router bgp 10
(config-router)#address-family ipv4 unicast
(config-router-af)#neighbor 10.10.0.72 route-server-client
 
#configure terminal
(config)#router bgp 10
(config-router)#address-family ipv4 unicast
(config-router-af)#no neighbor 10.10.0.72 route-server-client
 
For unnumbered peer, IPv4 unicast mode commands are configured under v4-unnumbered-mode.
(config)#router bgp 100
(config-router)#address-family ipv4 unicast
(config-router-af)#bgp v4-unnumbered-mode
(config-router-v4-unnum)#neighbor eth1 route-server-client
 
neighbor send-community
Use this command to send that a community attribute to a BGP neighbor.
The community attribute groups destinations in a certain community and applies routing decisions according to those communities. On receiving community attributes, the router reannounces them to the neighbor.
By default, both standard and extended community attributes are sent to a neighbor. To explicitly send only the standard or extended community attribute, run the bgp config-type command with the standard parameter before running this command.
Use the no parameter with this command to not announce community attributes to the neighbor. Use the extended and no parameters to remove extended communities. Specifying no other parameter with no removes standard communities only.
Command Syntax
no neighbor (A.B.C.D|X:X::X:X|WORD) send-community
no neighbor (A.B.C.D|X:X::X:X|WORD) send-community (both|extended|standard)
neighbor (A.B.C.D|X:X::X:X|WORD) send-community
neighbor (A.B.C.D|X:X::X:X|WORD) send-community (both|extended|standard)
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
both
Send Standard and Extended Community attributes
extended
Send Extended Community attributes
standard
Send Standard Community attributes
Default
By default, both communities (standard and extended) are sent to every BGP neighbor.
Command Mode
Address Family mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
(config)#router bgp 100
(config-router)#address-family ipv4 vrf VRF_A
(config-router-af)#neighbor 10.10.10.1 remote-as 200
(config-router-af)#no neighbor 10.10.0.1 send-community extended
neighbor send-community large
Use this command to send that a community attribute to a BGP neighbor.
Use the no parameter with this command to not announce community attributes to the neighbor.
Command Syntax
neighbor A.B.C.D send-community large
no neighbor A.B.C.D send-community large
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
Default
By default send-community large is enabled for peer
Command Mode
Address Family mode
Applicability
This command was introduced before OcNOS version 6.1.0.
Examples
(config)#router bgp 100
(config-router)#address-family ipv4 unicast
(config-router-af)#neighbor 1.1.1.1 activate
(config-router-af)#neighbor 1.1.1.1 send-community large
 
neighbor shutdown
Use this command to terminate active sessions for a specified neighbor and clear all related routing information.
If a peer group is specified, a large number of peering sessions might be terminated. The show ip bgp summary command displays a summary of BGP neighbors and their connections.
Use description option for operators to transmit a short free-form message to describe why a BGP session was shut down.
Use the no parameter with this command to re-enable a neighbor.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) shutdown (description LINE|)
no neighbor (A.B.C.D|X:X::X:X|WORD) shutdown
Foe BGP unnumbered mode:
neighbor WORD shutdown (description LINE|)
no neighbor WORD shutdown
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
description
Administratively shutdown communication msg to neighbor.
Default
By default, neighbor shutdown is disabbled
Command Mode
Router mode and Address Family-vrf mode and BGP unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3. The new version of the command with “description” option is introduced in OcNOS version 6.0.0.
Examples
#configure terminal
(config)#router bgp 10
(config-router)#neighbor 10.10.0.72 shutdown
 
(config)#router bgp 100
(config-router)#address-family ipv6 vrf VRF_A
(config-router-af)#neighbor 3ffe:15:15:15:15::0 shutdown description software upgrade; back in 2 hours
 
For unnumbered peer below configuration is given in BGP unnumbered-mode.
(config)#router bgp 100
(config-router)#bgp unnumbered-mode
(config-router-unnum)#neighbor eth1 shutdown
 
neighbor strict-capability-match
Use this command to close the BGP connection if a capability value does not match the remote peer.
Use the no parameter with this command to disable this function.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) strict-capability-match
no neighbor (A.B.C.D|X:X::X:X|WORD) strict-capability-match
For BGP unnumbered mode:
neighbor WORD strict-capability-match
no neighbor WORD strict-capability-match
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
Default
By default, strict capability match is disabled
Command Mode
Router mode and BGP unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 12
(config-router)#neighbor 10.10.10.10 strict-capability-match
For unnumbered peer below configuration is given in BGP unnumbered-mode.
(config)#router bgp 100
(config-router)#bgp unnumbered-mode
(config-router-unnum)#neighbor eth1 strict-capability-match
neighbor tcp-mss
Use this command to set the BGP TCP MSS of a neighbor.
Use the no parameter with this command to remove a TCP MSS setting from a BGP neighbor.
For more information, refer to the command reference page for neighbor tcp-mss in the TCP MSS configuration for BGP neighbors section of the OcNOS Key Feature document, Release 6.4.1.
 
 
 
neighbor timers
Use this command to set the timers for a specific BGP neighbor.
Use the no parameter with this command to clear the timers for a BGP neighbor.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) timers <0-65535> <0-65535>
neighbor (A.B.C.D|X:X::X:X|WORD) timers connect <1-65535>
no neighbor (A.B.C.D|X:X::X:X|WORD) timers
no neighbor (A.B.C.D|X:X::X:X|WORD) timers connect
For BGP unnumbered mode:
neighbor WORD timers <0-65535> <0-65535>
neighbor WORD timers connect <1-65535>
no neighbor WORD timers
no neighbor WORD timers connect
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
<0-65535>
Keepalive interval. Keepalive messages are sent by a router to inform another router that the BGP connection between the two is still active. The keepalive interval is the period of time between each keepalive message sent by the router.
<0-65535>
Holdtime interval which is the time the router waits to receive a keepalive message. If the router does not receive a message in this period, the router declares the neighbor dead. The holdtime value should be at least 3 times the keepalive time.
connect
BGP connect timer
<1-65535>
Connect timer
Defaults
By default, keepalive timer value is 30 seconds
Command Mode
Router mode and BGP unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 12
(config-router)#neighbor 10.10.10.10 timers 60 230
(config-router)#neighbor 10.10.10.10 timers connect 10
 
(config-router)#no neighbor 10.10.10.10 timers
 
For unnumbered peer below configuration is given in BGP unnumbered-mode.
(config)#router bgp 100
(config-router)#bgp unnumbered-mode
(config-router-unnum)#neighbor eth1 timers 40 120
(config)#router bgp 100
(config-router)#bgp unnumbered-mode
(config-router-unnum)#neighbor eth1 timers connect 50
 
neighbor unsuppress-map
Use this command to selectively leak more-specific routes to a particular neighbor.
When the aggregate-address command is used with the summary-only option, the more-specific routes of the aggregate are suppressed to all neighbors. Use the neighbor unsuppress-map command to selectively leak more-specific routes to a particular neighbor.
Use the no parameter with this command to restore the setting to the default level.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) unsuppress-map WORD
no neighbor (A.B.C.D|X:X::X:X|WORD) unsuppress-map WORD
For v4-unnumbered mode:
neighbor WORD unsuppress-map WORD
no neighbor WORD unsuppress-map WORD
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
WORD
Name of the route map used to select routes to unsuppress
Default
By default, neighbor unsuppress map is disabled
Command Mode
Address Family mode and v4-unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
#configure terminal
(config)#router bgp 10
(config-router)#address-family ipv4 unicast
(config-router-af)#neighbor 10.10.0.70 unsuppress-map mymap
For unnumbered peer, IPv4 unicast mode commands are configured under v4-unnumbered-mode.
(config)#router bgp 100
(config-router)#address-family ipv4 unicast
(config-router-af)#bgp v4-unnumbered-mode
(config-router-v4-unnum)#neighbor eth1 unsuppress-map map2
neighbor update-source
Use this command to allow internal BGP sessions to use any operating interface for TCP connections.
A loopback interface is most commonly used with this command. The use of loopback interface eliminates a dependency and BGP does not have to rely on the availability of a particular interface for making TCP connections.
Use the no parameter with this command to restore the interface assignment to the closest interface.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) update-source WORD
no neighbor (A.B.C.D|X:X::X:X|WORD) update-source
For BGP unnumbered mode:
neighbor WORD update-source WORD
no neighbor WORD update-source
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
WORD
Interface name
Default
By default, neighbor update source is disabled
Command Mode
Router mode and BGP unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 10
(config-router)#neighbor 10.10.0.72 update-source myif
 
For unnumbered peer below configuration is given in BGP unnumbered-mode.
(config)#router bgp 100
(config-router)#bgp unnumbered-mode
(config-router-unnum)#neighbor eth1 update-source myif
 
neighbor version
Use this command to accept only a particular BGP version.
By default, the system uses BGP version 4 and on request dynamically negotiates down to version 2. Using this command disables the router’s version-negotiation capability and forces the router to use only a specified version with the neighbor.
Use the no parameter with this command to use the default version level of a neighbor.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) version 4
no neighbor (A.B.C.D|X:X::X:X|WORD) version
For BGP unnumbered mode:
neighbor WORD version 4
no neighbor WORD version
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
4
BGP version number
Default
By default, the system uses BGP version 4 and on request dynamically negotiates down to version 2
Command Mode
Router mode and BGP unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 12
(config-router)#neighbor 10.10.10.10 version 4
 
(config)#router bgp 12
(config-router)#no neighbor 10.10.10.10 version
For unnumbered peer below configuration is given in BGP unnumbered-mode.
(config)#router bgp 100
(config-router)#bgp unnumbered-mode
(config-router-unnum)#neighbor eth1 version 4
neighbor weight
Use this command to specify a weight value, per address-family, for all routes learned from a neighbor.
The route with the highest weight gets preference when the same prefix is learned from more than one peer. Unlike the local-preference attribute, the weight attribute is relevant only to the local router. The weights assigned using the set weight command override the weights assigned using this command.
Use this command in router mode to specify a weight value for all address families. Use this command in address family mode to specify a weight value per IPv4/IPv6/VPNv4/6PE address family,
When the weight is set for a peer group, all members of the peer group get the same weight. This command can also be used to assign a different weight to an individual peer-group member. When an individually-configured weight of a peer-group member is removed, its weight is reset to its peer group’s weight.
Use the no parameter with this command to remove a weight assignment.
Command Syntax
neighbor (A.B.C.D|X:X::X:X|WORD) weight <0-65535>
no neighbor (A.B.C.D|X:X::X:X|WORD) weight
no neighbor (A.B.C.D|X:X::X:X|WORD) weight <0-65535>
For v4-unnumbered mode:
neighbor WORD weight <0-65535>
no neighbor WORD weight
no neighbor WORD weight <0-65535>
Parameters
A.B.C.D
Address of the BGP neighbor in an IPv4 format
X:X::X:X
Address of the BGP neighbor in an IPv6 format
WORD
Name of a BGP peer group created with the neighbor WORD peer-group command. When you specify this parameter, the command applies to all peers in the group.
<0-65535>
Weight value
Default
By default, neighbor weight value is 0
Command Mode
Router Address-Family mode and v4-unnumbered mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 12
(config-router)#address-family ipv4 unicast
(config-router-af)#neighbor 10.10.10.10 weight 60
 
(config-router-af)#no neighbor 10.10.10.10 weight 60
For unnumbered peer, IPv4 unicast mode commands are configured under v4-unnumbered-mode.
(config)#router bgp 100
(config-router)#address-family ipv4 unicast
(config-router-af)#bgp v4-unnumbered-mode
(config-router-v4-unnum)#neighbor eth1 weight 44
neighbor WORD peer-group
Use this command to create a peer group.
Use the no parameter with this command to remove a peer group.
Command Syntax
neighbor WORD peer-group
no neighbor WORD peer-group
Parameters
WORD
Name of BGP peer group
Default
No default value is specified
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
This example shows how to create a peer group named group1.
#configure terminal
(config)#router bgp 10
(config-router)#neighbor group1 peer-group
network
Use this command to specify the networks to be advertised by the BGP routing process. A unicast network address without a mask is accepted if it falls into the natural boundary of its class. A class-boundary mask is derived if the address matches its natural class-boundary.
Use the backdoor parameter to specify a backdoor route to a BGP border router that will provide better information about the network. For data to be advertised by BGP, its routing table must include a route to the specified network. This command specifies the networks to be advertised. The network command works if the network being advertised is known to the router.
The backdoor parameter enables a route to be the preferred route even if it has a greater distance. A network that is specified as a backdoor network is dynamically assigned an administrative distance of 200 ensuring that IGP learned routes are preferred. If a backdoor network is not sourced by the local router, the network is learned from the external routers. If the route is learned from eBGP for a backdoor network, the distance is set to 20 or 200.
Use the no form of this command to remove a network route entry.
Command Syntax
network A.B.C.D (backdoor|)
network A.B.C.D/M (backdoor|)
network A.B.C.D mask A.B.C.D (backdoor|)
network A.B.C.D mask A.B.C.D route-map WORD (backdoor|)
network A.B.C.D route-map WORD (backdoor|)
network A.B.C.D/M route-map WORD (backdoor|)
no network A.B.C.D
no network A.B.C.D/M
Parameters
A.B.C.D
IP prefix <network>, for example, 35.0.0.0
A.B.C.D/M
IP prefix <network>/<length>, for example., 35.0.0.0/8
backdoor
BGP backdoor route
routemap
Route map used to modify the attributes
WORD
Name of the route map
mask
Network mask, for example, 255.255.0.0
A.B.C.D
Network mask, e.g., 255.255.0.0
Default
No default value is specified
Command Mode
Router Address-family mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
The following example illustrates a Class-A address configured as a network route. The natural Class-A network prefix mask length of 8 is internally derived, that is, 2.0.0.0/8.
(config)#router bgp 1
(config-router)#address-family ipv4 unicast
(config-router-af)#network 2.0.0.0
network synchronization
Use this command to enable IGP synchronization for BGP static network routes.
Use this no parameter with this command to disable synchronization of BGP static routes.
Command Syntax
network synchronization
no network synchronization
Parameters
None
Default
By default, network synchronization is disabled
Command Mode
Address Family mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
The following example enables IGP synchronization of BGP static network routes in the router configuration mode.
#configure terminal
(config)#router bgp 11
(config-router)#address-family ipv4 unicast
(config-router-af)#network synchronization
The following example enables IGP synchronization of BGP static network routes in the IPv6 unicast address-family mode.
#configure terminal
(config)#router bgp 11
(config)#address-family ipv6 unicast
(config-router-af)#network synchronization
redistribute
Use this command to inject routes from one routing process into another. Redistribution is used by routing protocols to advertise routes that are learned by some other means, such as by another routing protocol or by static routes. Since all internal routes are dumped into BGP, careful filtering is applied to make sure that only routes to be advertised reach the internet, not everything. This command allows redistribution by injecting prefixes from one routing protocol into another routing protocol.
Use the no parameter with this command to disable this function.
Command Syntax
redistribute [connected|isis|kernel|ospf|rip|static]
redistribute [connected|isis|kernel|ospf|rip|static] route-map WORD
no redistribute [connected|isis|kernel|ospf|rip|static]
no redistribute [connected|isis|kernel|ospf|rip|static] route-map
no redistribute [connected|isis|kernel|ospf|rip|static] route-map WORD
Parameters
connected
Redistribute connected routes
isis
Redistribute connected ISO IS-IS routes
kernel
Redistribute connected kernel routes
ospf
Redistribute OSPFv2 routes
rip
Redistribute RIP routes
static
Redistribute static routes
route-map
Route map reference
WORD
Route map entries
Default
By default, redistribute is disabled
Command Mode
Address Family mode and Address Family-vrf mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
The following example shows the configuration of the route-map name rmap1 and then the use of this map name in the redistribute route-map command.
#configure terminal
(config)#route-map rmap1 permit 1
(config-route-map)#match origin incomplete
(config-route-map)#set metric 100
(config-route-map)#exit
(config)#router bgp 12
(config-router)#address-family ipv4 unicast
(config-router-af)#redistribute ospf route-map rmap1
 
(config)#router bgp 100
(config-router)#address-family ipv4 vrf VRF_A
(config-router-af)#redistribute static
 
(config)#router bgp 100
(config-router)#address-family ipv6 vrf VRF_A
(config-router-af)#redistribute static
 
restart bgp graceful
Use this command to enable a BGP-speaker router for graceful restart. This command stops the whole BGP process and makes OcNOS retain the BGP routes and mark them as stale. Receiving BGP speakers, retain and mark as stale all BGP routes received from the restarting speaker for all address families received in the Graceful Restart Capability exchange.
Command Syntax
restart bgp graceful
Parameters
None
Default
By default, bgp graceful is disabled
Command Mode
Privileged Exec mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#restart bgp graceful
% Warning : BGP process will stop and needs to restart manually,
You may loose ospf configuration, if not saved
Proceed for graceful restart? (y/n):y
router bgp
Use this command to start a BGP process.
Use the no parameter with this command to disable an existing routing process.
Command Syntax
router bgp <1-4294967295>
no router bgp <1-4294967295>
Parameters
<1-4294967295>
 
Associate the routing process with this autonomous system number
Default
No default value is specified
Command Mode
Configure mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 12
(config-router)#
set large-community
Use this command to set the large community.
Command Syntax
set large-community XXX:YYYY:ZZZ
no set large-community XXX:YYYY:ZZZ
Parameters
XXX:YYYY:ZZZ
Large community number
Default
By default send-community large is enabled for peer
Command Mode
Route-map mode
Applicability
This command was introduced in OcNOS version 6.1.0.
Examples
(config)#route-map R1 permit 10
(config-route-map)#set large-community 1111:2222:33333
(config-route-map)#
 
snmp restart bgp
Use this command to restart SNMP in Border Gateway Protocol (BGP)
Command Syntax
snmp restart bgp
Parameters
None
Default
No default value is specified
Command Mode
Configure mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#snmp restart bgp
 
synchronization
Use this command to enable IGP synchronization of Internal BGP (iBGP) learned routes with the Internal Gateway Protocol (IGP) system in the router configuration mode or in the address-family configuration mode.
Synchronization is used when a BGP router should not advertise routes learned from iBGP neighbors, unless those routes are also present in an IGP (for example, OSPF). Synchronization may be enabled when all the routers in an autonomous system do not speak BGP, and the autonomous system is a transit for other autonomous systems.
The no synchronization command is used when BGP router can advertise routes learned from its iBGP neighbors without waiting for the IGP reachability to be present.
Command Syntax
synchronization
no synchronization
Parameters
None
Default
No default value is specified
Command Mode
Address Family modes
Applicability
This command was introduced before OcNOS version 1.3.
Examples
The following example enables IGP synchronization of iBGP routes in Router mode.
#configure terminal
(config)#router bgp 11
(config-router)#address-family ipv4 unicast
(config-router-af)#synchronization
The following example enables IGP synchronization of iBGP routes in the IPv6-Unicast address family.
#configure terminal
(config)#router bgp 11
(config-router)#address-family ipv6 unicast
(config-router-af)#synchronization
timers bgp
Use this command to globally set or reset the keepalive and holdtime values for all the neighbors.
Use the no parameter with this command to reset timers to default value.
Command Syntax
timers bgp <0-65535> <0-65535>
no timers bgp
Parameters
<0-65535>
Frequency with which keepalive messages are sent to the neighbors
<0-65535>
Interval after which a neighbor is considered dead if keepalive messages are not received
Default
By default, keepalive timer value is 30 seconds
By default, holdtime value is 90 seconds
Command Mode
Router mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#router bgp 10
(config-router)#timers bgp 40 120
v4-unnumbered-mode
Use this command to configure the unnumbered peer with all the neighbor configs applicable in IPv4 unicast address family.
Use the exit parameter with this command to leave IPv4 BGP unnumbered mode.
Command Syntax
bgp v4-unnumbered-mode
exit-v4-unnumbered-mode
Parameters
None
Applicability
No default value is specified
Command Mode
Address-family IPv4 Unicast Mode
Applicability
This command was introduced in OcNOS-OTN version 4.2.
Examples
#configure terminal
(config)#router bgp 100
(config-router)#address-family ipv4 unicast
(config-router-af)#bgp v4-unnumbered-mode
(config-router-v4-unnum)#
 
 
undebug bgp
Use this command to disable BGP debugging options.
Command Syntax
undebug bgp (all|bfd|dampening|events|filters|fsm|keepalives|mpls|nht|nsm|updates)
Parameters
all
Disable all debugging for BGP
bfd
Disable debugging for BGP Bidirectional Forwarding Detection (BFD)
dampening
Disable debugging for BGP dampening
events
Disable debugging for BGP events
filters
Disable debugging for BGP filters
fsm
Disable debugging for BGP Finite State Machine (FSM)
keepalives
Disable debugging for BGP keepalives
mpls
Disable debugging for BGP MPLS
nht
Disable debugging for BGP NHT messages
nsm
Disable debugging for NSM messages
updates
Disable debugging for BGP updates
Command Mode
Privileged Exec mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#undebug bgp events
bgp unnumbered-mode
Use this command to enter the unnumbered mode in router BGP mode allowing configuration of neighbor specific parameters. In this mode we allow creation of unnumbered peer and allow all the neighbor configuration applicable in router BGP mode.
Use no form of this command to exit unnumbered-mode and return to previous mode.
Note: ECMP with BGP unnumbered and numbered together is not supported.
Command Syntax
bgp unnumbered-mode
exit-unnumbered-mode
Parameters
None
Command Mode
Router BGP mode
Applicability
This command was introduced in OcNOS-OTN version 4.2.
Examples
(config)#router bgp 100
(config-router)#bgp unnumbered-mode
(config-router-unnum)#