# BGP

The `nv unset` commands remove the configuration you set with the equivalent `nv set` commands. This guide only describes an `nv unset` command if it differs from the `nv set` command.

## nv set router bgp

Configures BGP globally on the switch.

## nv set router bgp autonomous-system

Configures the BGP ASN on the switch to identify the BGP node. You can set a value between 1 and 4294967295. To use auto BGP to assign an ASN automatically on the leaf, set the value to `leaf`. To use auto BGP to assign an ASN automatically on the spine, set the value to `spine`.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set router bgp autonomous-system 65101

## nv set router bgp convergence-wait

Configures BGP readonly mode. Sometimes, as Cumulus Linux establishes BGP peers and receives updates, it installs prefixes in the RIB and advertises them to BGP peers before receiving and processing information from all the peers. Also, depending on the timing of the updates, Cumulus Linux sometimes installs prefixes, then withdraws and replaces them with new routing information. Readonly mode minimizes this BGP route churn in both the local RIB and with BGP peers.

Enable readonly mode to reduce CPU and network usage when restarting the BGP process. Because intermediate best paths are possible for the same prefix as peers establish and start receiving updates at different times, readonly mode is useful in topologies where BGP learns a prefix from a large number of peers and the network has a high number of prefixes.

While in readonly mode, BGP does not run best-path or generate any updates to its peers.

## nv set router bgp convergence-wait establish-wait-time

Configures BGP readonly mode by setting the establish wait time. You can set a value between 0 and 3600.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set router bgp convergence-wait establish-wait-time 200

## nv set router bgp convergence-wait time

Configures BGP readonly mode by setting the convergence wait time. You can set a value between 0 and 3600.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set router bgp convergence-wait time 300

## nv set router bgp state

Enables or disables BGP globally on the switch.

In Cumulus Linux 5.14 and earlier, you specify `enable on` or `enable off` instead of `state enabled` or `state disabled`.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set router bgp state enabled

## nv set router bgp graceful-restart

Configures BGP graceful restart globally on the switch to minimize the negative effects that occur when BGP restarts. All BGP peers inherit the graceful restart capability.

## nv set router bgp graceful-restart mode

Configures the BGP graceful restart mode globally on the switch. You can specify the following settings:

- `off`, where graceful restart is not negotiated with peers.
- `helper-only`, where the switch is in a helper role only, and routes originated and advertised from a BGP neighbor in the peer group are not deleted.
- `full`, where the switch is in both a helper and restarter role.

The default setting is `off`.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set router bgp graceful-restart mode helper-only

## nv set router bgp graceful-restart path-selection-deferral-time

Configures the number of seconds a restarting neighbor defers path-selection when waiting for the EOR marker from peers. You can set a value between 0 and 3600.

- In Cumulus Linux 5.15 and later, the default is 120 seconds.
- In Cumulus Linux 5.14 and earlier, the default is 360 seconds.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set router bgp graceful-restart path-selection-deferral-time 300

## nv set router bgp graceful-restart restart-time

Configures the number of seconds to wait for a graceful restart capable neighbor to re-establish BGP peering. The default is 120 seconds.

- In Cumulus Linux 5.15 and later, you can set a value between 0 and 4095.
- In Cumulus Linux 5.14 and earlier, you can set a value between 1 and 4095.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set router bgp graceful-restart restart-time 400

## nv set router bgp graceful-restart stale-routes-time

Configures the number of seconds to hold stale routes for a restarting neighbor. The default is 360 seconds. You can set a value between 1 and 4095.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set router bgp graceful-restart stale-routes-time 400

## nv set router bgp graceful-shutdown

Enables and disables BGP graceful shutdown on the switch to reduce packet loss during planned maintenance of a router or link. BGP graceful shutdown forces traffic to route around the BGP node.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set router bgp graceful-shutdown enabled

## nv set router bgp policy-update-timer

Configures the BGP policy update timer globally on the switch to wait the specified number of seconds before processing updates to policies to ensure that a series of changes process together. You can set a value between 0 and 600.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set router bgp policy-update-timer 300

## nv set router bgp queue-limit input

Configures the input message queue limit for all peers. You can set a value between 1 and 4294967295 messages. The default setting is 10000.

### Version History

Introduced in Cumulus Linux 5.7.0

### Example

    cumulus@switch:~$ nv set router bgp queue-limit input 2048

## nv set router bgp queue-limit output

Configures the output message queue limit for all peers. You can set a value between 1 and 4294967295 messages. The default setting is 10000.

### Version History

Introduced in Cumulus Linux 5.7.0

### Example

    cumulus@switch:~$ nv set router bgp queue-limit output 2048

## nv set router bgp router-id

Configures the BGP router ID on the switch. NVUE automatically assigns the loopback address of the switch to be the router ID. FRR automatically assigns the router ID to be the loopback address or the highest IPv4 address for the interface. If you do not have a loopback address configured or want to use a specific router ID, set the router ID globally.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set router bgp router-id 10.10.10.1

## nv set router bgp wait-for-install

Enables and disables BGP wait for install. When you enable BGP wait for install, BGP waits for a response from the RIB indicating that the routes installed in the RIB are also installed in the ASIC before sending updates to peers.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set router bgp wait-for-install enabled

## nv set vrf <vrf-id> router bgp address-family ipv4-unicast admin-distance external

Configures the distance to apply to IPv4 routes from eBGP peers when installed into the RIB. You can specify a value between 1 and 255.

The BGP administrative distance lets the switch choose which routing protocol to use when two different protocols provide IPv4 route information for the same destination. The smaller the distance, the more reliable the protocol. For example, if the switch receives a route from OSPF with an administrative distance of 110 and the same route from BGP with an administrative distance of 100, the switch chooses BGP.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp address-family ipv4-unicast admin-distance external 150

## nv set vrf <vrf-id> router bgp address-family ipv4-unicast admin-distance internal

Configures the distance to apply to IPv4 routes from iBGP peers when installed into the RIB. You can specify a value between 1 and 255.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp address-family ipv4-unicast admin-distance internal 110

## nv set vrf <vrf-id> router bgp address-family ipv4-unicast advertise-origin

BGP prefix independent convergence (PIC) reduces convergence times and improves unicast traffic convergence for remote link and node failures (when the BGP next hop fails) regardless of route scale. A remote link is a link between a spine and a remote leaf, or a spine and the super spine layer.

When you configure BGP PIC, Cumulus Linux assigns one next hop group for each source and the remote leaf advertises a route with a prefix derived from the router ID. The remote leaf tags prefix routes with a route-origin extended community (SOO) so that the local leaf recognizes the routes. When the network topology changes, the local leaf obtains the router ID route with the updated ECMP, allowing a O (1) next hop group replace operation for all prefixes from the remote leaf without waiting for individual BGP updates.

You enable the BGP advertise origin option on a leaf switch, so that BGP can attach the Site-of-Origin (SOO) extended community to all routes advertised to its peers from the source where the routes originate. On all switches (leaf, spine and super spine), you enable the next hop group per source option (`nv set vrf <vrf-id> router bgp address-family ipv4-unicast nhg-per-origin`) so that when BGP receives routes with the SOO extended community, it allocates a next hop group for each source.

On a spine and super spine, you must set the read-only mode BGP convergence wait time to 30 (`nv set router bgp convergence-wait time 30`)and the convergence wait establish wait time to 15 (`nv set router bgp convergence-wait establish-wait-time 15`). These are the minimum recommended timer settings to ensure optimal convergence when using PIC.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.12.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp address-family ipv4-unicast advertise-origin

## nv set vrf <vrf-id> router bgp address-family ipv4-unicast nhg-per-origin

BGP prefix independent convergence (PIC) reduces convergence times and improves unicast traffic convergence for remote link and node failures (when the BGP next hop fails) regardless of route scale. A remote link is a link between a spine and a remote leaf, or a spine and the super spine layer.

When you configure BGP PIC, Cumulus Linux assigns one next hop group for each source and the remote leaf advertises a route with a prefix derived from the router ID. The remote leaf tags prefix routes with a route-origin extended community (SOO) so that the local leaf recognizes the routes. When the network topology changes, the local leaf obtains the router ID route with the updated ECMP, allowing a O (1) next hop group replace operation for all prefixes from the remote leaf without waiting for individual BGP updates.

You enable the next hop group per source option on all switches (leaf, spine and super spine), so that when BGP receives routes with the SOO extended community, it allocates a next hop group for each source. On a leaf switch, you enable the BGP advertise origin option (`nv set vrf <vrf-id> router bgp address-family ipv4-unicast advertise-origin`) so that BGP can attach the Site-of-Origin (SOO) extended community to all routes advertised to its peers from the source where the routes originate.

On a spine and super spine, you must set the read-only mode BGP convergence wait time to 30 (`nv set router bgp convergence-wait time 30`)and the convergence wait establish wait time to 15 (`nv set router bgp convergence-wait establish-wait-time 15`). These are the minimum recommended timer settings to ensure optimal convergence when using PIC.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.11.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp address-family ipv4-unicast nhg-per-origin

## nv set vrf <vrf-id> router bgp address-family ipv4-unicast aggregate-route <aggregate-route-id> as-set

Enables and disables generation of an `AS_SET` for route aggregate for the specified VRF. When `enabled`, BGP creates an aggregate address with a mathematical set of autonomous systems. The `AS_SET` option summarizes the `AS_PATH` attributes of all the individual routes to help BGP detect and avoid loops. The default setting is `disabled`.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<aggregate-route-id>` | The IPv4 address and route prefix in CIDR notation.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp address-family ipv4-unicast aggregate-route 10.1.0.0/16 as-set enabled

## nv set vrf <vrf-id> router bgp address-family ipv4-unicast aggregate-route <aggregate-route-id> route-map

Applies a route map to the IPv4 aggregate route for the specified VRF.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<aggregate-route-id>` | The IPv4 address and route prefix in CIDR notation.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp address-family ipv4-unicast aggregate-route 10.1.0.0/16 route-map routemap1

## nv set vrf <vrf-id> router bgp address-family ipv4-unicast aggregate-route <aggregate-route-id> summary-only

Configures BGP to suppress longer IPv4 prefixes inside the aggregate address before sending updates. The default setting is `disabled`.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<aggregate-route-id>` | The IPv4 address and route prefix in CIDR notation.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp address-family ipv4-unicast aggregate-route 10.1.0.0/16 summary-only enabled

## nv set vrf <vrf-id> router bgp address-family ipv4-unicast state

Enables and disables the BGP IPv4 address family for the specified VRF. The default setting is `disabled`.

In Cumulus Linux 5.14 and earlier, you specify `enable on` or `enable off` instead of `state enabled` or `state disabled`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp address-family ipv4-unicast state enabled

## nv set vrf <vrf-id> router bgp address-family ipv4-unicast multipaths

Configures the maximum number of equal-cost BGP paths allowed for IPv4 for the specified VRF. The BGP multipath option is on by default and the maximum number of paths is 64 so that the switch can install multiple equal-cost BGP paths to the forwarding table and load balance traffic across multiple links. You can change the number of paths allowed, according to your needs. 1 disables the BGP multipath option.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf RED router bgp address-family ipv4-unicast multipaths 1

## nv set vrf <vrf-id> router bgp address-family ipv4-unicast conditional-disaggregation

Enables and disables BGP conditional disaggregation for IPv4 on a leaf switch.

BGP conditional disaggregation advertises specific prefixes when a failure is detected, while continuing to advertise the aggregate route. Combined with anycast Site-of-Origin (SOO) matching, this triggers peer plane leafs to conditionally originate specific routes to draw traffic instead of using the aggregate route that might lead to an unreachable destination.

To use BGP conditional disaggregation, you must also:

- Configure BGP PIC (`nv set vrf <vrf-id> router bgp address-family ipv4-unicast advertise-origin` and `nv set vrf <vrf-id> router bgp address-family ipv4-unicast nhg-per-origin`).
- Configure BGP PIC anycast (`nv set vrf <vrf-id> router bgp soo-source`).
- For 802.1X: Enable the `preserve-on-link-down` option with the `nv set system dot1x ipv4-profile <profile-id> preserve-on-link-down enabled` command to preserve IPv6 addresses when the switch reboots or a link flaps.
- Enable BGP unreachability (failure signaling) globally and on relevant peers or peer groups.
- Define the aggregate prefix and the included interfaces for which to conditionally advertise unreachability (`nv set vrf <vrf-id> router bgp address-family ipv4-unreachability advertise-unreach interfaces-match`).

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp address-family ipv4-unicast conditional-disaggregation

## nv set vrf <vrf-id> router bgp address-family ipv4-unicast multipaths ebgp

Configures the number of equal-cost eBGP paths allowed for IPv4 for the specified VRF. The default value is 64.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp address-family ipv4-unicast multipaths ebgp 120

## nv set vrf <vrf-id> router bgp address-family ipv4-unicast multipaths ibgp

Configures the number of equal-cost iBGP paths allowed for IPv4 for the specified VRF. The default value is 64.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp address-family ipv4-unicast multipaths ibgp 120

## nv set vrf <vrf-id> router bgp address-family ipv4-unicast multipaths compare-cluster-length

Enables and disables cluster length comparison for IPv4 for the specified VRF. When `enabled` and iBGP paths have a cluster list, their lengths must be equal to be selected as multipaths. The default setting is `disabled`.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp address-family ipv4-unicast compare-cluster-length enabled

## nv set vrf <vrf-id> router bgp address-family ipv4-unicast network <static-network-id>

Configures the IPv4 prefixes to originate from a BGP node for the specified VRF.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<static-network-id>` | The IPv4 address and route prefix in CIDR notation.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp address-family ipv4-unicast network 10.10.10.1/32

## nv set vrf <vrf-id> router bgp address-family ipv4-unicast network <static-network-id> route-map

Applies a route map to the IPv4 prefixes that originate from a BGP node for the specified VRF.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<static-network-id>` | The IPv4 address and route prefix in CIDR notation.

### Version History

Introduced in Cumulus Linux 5.2.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp address-family ipv4-unicast network 10.10.10.1/32 route-map HI-PRIO

## nv set vrf <vrf-id> router bgp address-family ipv4-unicast rib-filter

Applies a route map on IPv4 route updates from BGP to the Route Information Base (RIB). You can match on prefix, next hop, communities, and so on. You can set the metric and next hop only. Route maps do not affect the BGP internal RIB. Route maps work on multi-paths; however, BGP bases the metric setting on the best path only.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp address-family ipv4-unicast rib-filter routemap1

## nv set vrf <vrf-id> router bgp address-family ipv4-unicast route-export to-evpn default-route-origination

Configures originating EVPN default type-5 routes for the specified VRF. The default type-5 route originates from a border (exit) leaf and advertises to all the other leafs within the pod. Any leaf within the pod follows the default route towards the border leaf for all external traffic (towards the Internet or a different pod). The default setting is `disabled`.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp address-family ipv4-unicast route-export to-evpn default-route-origination enabled

## nv set vrf <vrf-id> router bgp address-family ipv4-unicast route-export to-evpn state

Enables and disables IPv4 prefix-based routing using EVPN type-5 routes for the specified VRF. When `enabled`, the switch can announce IP prefixes in the BGP RIB as EVPN type-5 routes. The default setting is `disabled`.

In Cumulus Linux 5.14 and earlier, you specify `enable on` or `enable off` instead of `state enabled` or `state disabled`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp address-family ipv4-unicast route-export to-evpn state enabled

## nv set vrf <vrf-id> router bgp address-family ipv4-unicast route-export to-evpn route-map

Sets the route map to control the export of IPv4 routes into EVPN for the specified VRF. By default, when announcing IP prefixes in the BGP RIB as EVPN type-5 routes, the switch selects all routes in the BGP RIB to advertise as EVPN type-5 routes. You can use a route map to allow selective route advertisement from the BGP RIB.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp address-family ipv4-unicast route-export to-evpn route-map HIGH-PRIO

## nv set vrf <vrf-id> router bgp address-family ipv4-unicast route-import from-vrf list <leak-vrf-id>

Configures the VRF from which to import (leak) IPv4 routes. You can specify multiple VRFs.

VRF route leaking is where a destination VRF wants to know the routes of a source VRF. As routes come and go in the source VRF, they dynamically leak to the destination VRF through BGP.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<leak-vrf-id>` | The VRF from which you want to leak routes.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf RED router bgp address-family ipv4-unicast route-import from-vrf list BLUE

## nv set vrf <vrf-id> router bgp address-family ipv4-unicast route-import from-vrf state

Enables and disables IPv4 VRF route leaking. The default setting is `disabled`.

In Cumulus Linux 5.14 and earlier, you specify `enable on` or `enable off` instead of `state enabled` or `state disabled`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf RED router bgp address-family ipv4-unicast route-import from-vrf state enabled

## nv set vrf <vrf-id> router bgp address-family ipv4-unicast route-import from-vrf route-map <instance-name>

Applies a route map to control importing IPv4 routes for the specified VRF. For example, to exclude certain prefixes from the import process, configure the prefixes in a route map.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf RED router bgp address-family ipv4-unicast route-import from-vrf route-map BLUEtoRED

## nv set vrf <vrf-id> router bgp autonomous-system

Configures the BGP ASN in the specified VRF to identify the BGP node. You can set a value between 1 and 4294967295. To use auto BGP to assign an ASN automatically on the leaf, set the value to `leaf`. To use auto BGP to assign an ASN automatically on the spine, set the value to `spine`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp autonomous-system 65101

## nv set vrf <vrf-id> router bgp confederation id

Configures the Confederation Identifier to advertise routes outside the confederation; sub-AS numbers are not visible externally. You can set a value between 1 and 4294967295 or `none`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp confederation id 100

## nv set vrf <vrf-id> router bgp confederation member-as

Configures the confederation neighbor ASNs. You can set a value between 1 and 4294967295.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp confederation member-as 65101

## nv set vrf <vrf-id> router bgp dynamic-neighbor

Configures BGP dynamic neighbors that provide BGP peering to remote neighbors within a specified range of IPv4 or IPv6 addresses for a BGP peer group. You can configure each range as a subnet IP address.

After you configure the dynamic neighbors, a BGP speaker can listen for, and form neighbor relationships with, any neighbor that is in the IP address range and maps to a peer group.

## nv set vrf <vrf-id> router bgp dynamic-neighbor limit

Configures the maximum number of dynamic neighbors from which you can accept a connection. You must also set the `nv set vrf <vrf-id> router bgp dynamic-neighbor listen-range` command. You can specify a value between 1 and 5000. The default value is 100.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.3.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp dynamic-neighbor limit 5

## nv set vrf <vrf-id> router bgp dynamic-neighbor listen-range <ip-sub-prefix-id> peer-group

Configures the dynamic neighbor listen range.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<ip-sub-prefix-id>` | The IP address and prefix.

### Version History

Introduced in Cumulus Linux 5.3.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp dynamic-neighbor listen-range 10.0.1.0/24 peer-group SPINES

## nv set vrf <vrf-id> router bgp state

Enables and disables BGP for the specified VRF.

In Cumulus Linux 5.14 and earlier, you specify `enable on` or `enable off` instead of `state enabled` or `state disabled`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp state enabled

## nv set vrf <vrf-id> router bgp address-family ipv4-unreachability advertise-origin

Attaches the SOO for BGP unreachability information signaling for IPv4.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp address-family ipv4-unreachability advertise-origin

## nv set vrf <vrf-id> router bgp address-family ipv4-unreachability advertise-unreach interfaces-match

Configures BGP unreachability SAFI advertisements for interfaces matching a network for IPv4.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp address-family ipv4-unreachability advertise-unreach interfaces-match 10.10.10.101/32

## nv set vrf <vrf-id> router bgp address-family ipv4-unreachability state

Enables and disables BGP unreachability SAFI (failure signaling) globally.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ cumulus@leaf01:~$ nv set vrf default router bgp address-family ipv4-unreachability state enabled

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> address-family ipv4-unreachability aspath allow-my-asn occurrences

Configures the maximum number of occurrences of the local system’s AS number in the received AS_PATH for BGP unreachability SAFI (failure signaling). You can set a value between 1 and 10.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 address-family ipv4-unreachability aspath allow-my-asn occurrences 3

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> address-family ipv4-unreachability aspath allow-my-asn origin

Configures BGP to allow a received AS_PATH containing the ASN of the local system but only if it is the originating AS for BGP unreachability SAFI (failure signaling). You can specify `enabled` or `disabled`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 address-family ipv4-unreachability aspath allow-my-asn origin enabled

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> address-family ipv4-unreachability aspath allow-my-asn route-map

Applies the route map to filter IPv4 routes with my AS in the AS_PATH for BGP unreachability SAFI (failure signaling). Allows selective application of `allowas-in` based on route map matching.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 address-family ipv4-unreachability aspath allow-my-asn route-map ROUTEMAP1

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> address-family ipv4-unreachability aspath allow-my-asn state

Enables and disables the local system’s AS number in the received AS_PATH for BGP unreachability SAFI (failure signaling). You can specify `enabled` or `disabled`. The default setting is `disabled`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 address-family ipv4-unreachability aspath allow-my-asn state enabled

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> address-family ipv4-unreachability aspath private-as

Configures how to handle private ASNs in the update to the peer for BGP unreachability SAFI (failure signaling). You can specify:

- `none` to take no action. This is the default setting.
- `remove` to remove any private ASNs in the update to the peer
- `replace` to replace any private ASNs in the update to the peer with the ASN of the local system.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 address-family ipv4-unreachability aspath private-as replace

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> address-family ipv4-unreachability aspath replace-peer-as

Configures BGP to replace the ASN of the peer in the AS_PATH of an outgoing update with the ASN of the local system for BGP unreachability SAFI (failure signaling). You can specify `enabled` or `disabled`. The default setting is `disabled`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 address-family ipv4-unreachability aspath replace-peer-as enabled

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> address-family ipv4-unreachability prefix-limits maximum

Configures the maximum number of BGP unreachability SAFI IPv4 prefixes that can be received from the peer. This is CRITICAL for security to prevent state exhaustion.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 address-family ipv4-unreachability prefix-limits maximum 6

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> address-family ipv4-unreachability prefix-limits reestablish-wait

Configures the time in minutes to wait before establishing the BGP session again with the peer for BGP unreachability SAFI. The default value is `auto`, which uses standard BGP timers and processing.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 address-family ipv4-unreachability prefix-limits reestablish-wait 6

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> address-family ipv4-unreachability prefix-limits warning-only

Configures the switch to only generate a warning syslog if the number of received BGP unreachability SAFI prefixes exceeds the limit, but does not bring down the BGP session. You can set this option to `enabled` or `disabled`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 address-family ipv4-unreachability prefix-limits warning-only enabled

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> address-family ipv4-unreachability prefix-limits warning-threshold

Configures the prefix limits for a neighbor for BGP unreachability SAFI (failure signaling). Sets the percentage of the maximum at which a syslog warning is generated. You can set the value between 1 and 100. The default value is 75.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 address-family ipv4-unreachability prefix-limits warning-threshold 50

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> address-family ipv4-unreachability state

Enables and disables BGP unreachability SAFI (failure signaling) on the IPv4 neighbor. The default value is disabled.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 address-family ipv4-unreachability state enabled

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> bfd detect-multiplier

Configures the BFD detect multiplier that determines the maximum number of concurrent BFD packets (including control packets and echo packets) that BGP can discard. You can set a value between 2 and 255.

Cumulus Linux 5.15 and later no longer supports this command.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 bfd detect-multiplier 200

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> bfd enable

Enables and disables BFD to configure tracking BGP peering sessions using this configuration.

Cumulus Linux 5.15 and later no longer supports this command.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 bfd enable on

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> bfd min-rx-interval

Configures the minimum interval for receiving single-hop BFD control packets. You can specify a value between 50 and 60000.

Cumulus Linux 5.15 and later no longer supports this command.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 bfd min-rx-interval 30000

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> bfd min-tx-interval

Configures the minimum interval for transmitting single-hop BFD control packets. You can specify a value between 50 and 60000. The actual value used is the smaller of this value or the value that the neighbor expects.

Cumulus Linux 5.15 and later no longer supports this command.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 bfd min-tx-interval 30000

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> capabilities

Configures BGP capabilities, which the switch advertises to its BGP peers to inform them about the feature it can support and tries to negotiate that capability with its neighbours.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 capabilities

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> capabilities extended-nexthop

Enables and disables advertisement of IPv4 prefixes with IPv6 next hops over global IPv6 peerings. You must add the extended nexthop capability to the global IPv6 neighbor statements on each end of the BGP sessions.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 capabilities extended-nexthop enabled

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> capabilities source-address

Configures the source IP address of the TCP connection, which is often used as the BGP next hop for updates.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.1.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 capabilities source-address 10.10.10.1

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> description

Configures a description for the BGP neighbor in the specified VRF. If the description is more than one word, enclose it in double quotes (").

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.1.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 description SPINE01

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> enforce-first-as

Configures BGP to check that the first AS matches the AS of the neighbor when BGP updates are received from eBGP neighbors with this configuration. You can specify `enabled` or `disabled`.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 enforce-first-as enabled

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> local-as

Configures BGP local AS, which allows the switch to appear to be a member of a second autonomous system (AS), in addition to its real AS.

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> local-as asn

Configures the ASN to use to establish the peering if different from the ASN of the BGP instance. The local configured AS is also attached to incoming and outgoing updates.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 local-as asn 65532

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> local-as state

Enables and disables BGP local AS, which allows the switch to appear to be a member of a second autonomous system (AS), in addition to its real AS.

In Cumulus Linux 5.14 and earlier, you specify `enable on` or `enable off` instead of `state enabled` or `state disabled`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 local-as state enabled

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> local-as prepend

Enables and disables local AS prepend. When on, BGP prepends the configured local AS to received updates.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 local-as prepend enabled

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> multihop-ttl

Configures the maximum number of hops allowed. You can specify a value between 1 and 255 or `auto`. The default setting is `auto`, where the type of neighbor determines the appropriate value (255 for iBGP and 1 for eBGP).

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 multihop-ttl 25

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> nexthop-connected-check

Enables and disables next hop connected check. If you enable next hop connected check, BGP does not check that a non-multihop eBGP neighbor is directly connected and only announces connected next hops.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 nexthop-connected-check enabled

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> passive-mode

Turns passive mode on so that the switch does not initiate the BGP connection but waits for an incoming connection. If you set the command to `disabled`, the switch initiates the BGP connection without waiting for an incoming connection.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 passive-mode enabled

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> local-as replace

Enables and disables local AS replace. When enabled, BGP attaches only the configured local AS to generated updates, replacing the AS number configured for the BGP instance with the local AS applicable for the peering. When disabled, BGP attach the AS number of the BGP instance and then prepends it with the configured local AS.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 local-as replace enabled

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> graceful-restart mode

Configures the BGP graceful restart mode for the neighbor session. You can specify the following settings:

- `off`, where graceful restart is not negotiated with peers.
- `helper-only`, where the switch is in a helper role only, and routes originated and advertised from a BGP neighbor in the peer group are not deleted.
- `full`, where the switch is in both a helper and restarter role.

The default setting is `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.1.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 graceful-restart mode helper-only

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> ttl-security state

Enables and disables TTL security (RFC 5082) for the neighbor session.

In Cumulus Linux 5.14 and earlier, you specify `enable on` or `enable off` instead of `state enabled` or `state disabled`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 ttl-security state enabled

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> ttl-security hops

Configures the TTL security hop count to prevent attacks against eBGP, such as denial of service (DoS) attacks. By default, BGP messages to eBGP neighbors have an IP time-to-live (TTL) of 1, which requires the neighbor to be directly connected, otherwise, the packets expire along the way. You can adjust the TTL with the eBGP multihop option. An attacker can adjust the TTL of packets so that they look like they originate from a directly connected neighbor.

The BGP TTL security hops option inverts the direction in which BGP counts the TTL. Instead of accepting only packets with a TTL of 1, Cumulus Linux accepts BGP messages with a TTL greater than or equal to 255 minus the specified hop count.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 ttl-security hops 200

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> address-family ipv4-unicast aspath allow-my-asn state

Configures BGP to allow a received AS path to contain the ASN of the local system. You can specify `enabled` or `disabled`

In Cumulus Linux 5.14 and earlier, you specify `enable on` or `enable off` instead of `state enabled` or `state disabled`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 address-family ipv4-unicast allow-my-asn state enabled

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> address-family ipv4-unicast aspath allow-my-asn occurrences

Configures the maximum number of times the local system AS number can occur in the received AS_PATH.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IPv4 address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 address-family ipv4-unicast allow-my-asn occurrences 5

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> address-family ipv4-unicast aspath allow-my-asn route-map

Attaches a route map that filters routes with the local AS in the AS path.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IPv4 address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 address-family ipv4-unicast aspath allow-my-asn route-map ROUTEMAP1

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> address-family ipv4-unicast policy inbound aspath-list

Configures the AS Path filter list to apply to updates received from this neighbor.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IPv4 address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 address-family ipv4-unicast policy inbound aspath-list ASPATHIN

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> address-family ipv4-unicast policy outbound aspath-list none

Applies the IPv4 outbound policy for the specified AS_PATH list.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IPv4 address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 address-family ipv4-unicast policy outbound aspath-list ASPATHOUT

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> address-family ipv4-unicast prefix-limits inbound warning-threshold

Configures the percentage of the maximum at which a warning syslog is generated. You can set a value between 1 and 100.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IPv4 address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 address-family ipv4-unicast prefix-limits inbound warning-threshold 30

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> address-family ipv4-unicast prefix-limits inbound reestablish-wait

Specifes the time in seconds to wait before establishing the IPv4 BGP session again with the neighbor. You can set a value between 1 and 4294967295. The default setting is auto, which uses standard BGP timers and processing (typically between 2-3 seconds).

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IPv4 address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 address-family ipv4-unicast prefix-limits inbound reestablish-wait 50

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> address-family ipv4-unicast conditional-advertise advertise-map <instance-name>

Configures the route map that contains the prefix list with a list of IPv4 routes and prefixes on which to operate.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IPv4 address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 address-family ipv4-unicast conditional-advertise advertise-map ADVERTISEMAP

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> address-family ipv4-unicast conditional-advertise exist-map <instance-name>

Configures a route map that uses a prefix list with the IPv4 routes that must exist in the routing table.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IPv4 address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 address-family ipv4-unicast conditional-advertise exist-map EXIST

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> address-family ipv4-unicast conditional-advertise non-exist-map <instance-name>

Configures a route map that uses a prefix list with the IPv4 routes that must not exist in the routing table.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IPv4 address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 address-family ipv4-unicast conditional-advertise non-exist-map NONEXIST

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> address-family ipv4-unicast weight

Configures the weights to apply to IPv4 routes from the neighbor; this is used in the BGP route selection algorithm.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IPv4 address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 address-family ipv4-unicast weight 10

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> state

Enables and disables the exchange of information with a BGP neighbor in the specified VRF. The default value is `enabled`.

In Cumulus Linux 5.14 and earlier, you specify `enable on` or `enable off` instead of `state enabled` or `state disabled`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 state enabled

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> shutdown

Administratively shuts down a specific neighbor in the specified VRF. You can specify `enabled` or `disabled`.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 shutdown enabled

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> timers connection-retry

Configures how often the BGP process attempts to connect to a neighbor after a failure or when starting up. The default value is 10 seconds.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 timers connection-retry 30.

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> timers hold

Configures the hold time in seconds. If BGP does not receive a keepalive or update message from the neighbor within the hold time, it declares the neighbor down and withdraws all routes received by this neighbor from the local BGP table. The default value is 9 seconds.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 timers hold 30.

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> timers keepalive

Configures the interval during which keepalive messages are exchanged. To decrease CPU load when there are a lot of neighbors, you can increase the values of this timer and the hold timer, or disable the exchange of keepalives. When manually configuring new values, the keepalive interval can be less than or equal to one third of the hold time, but cannot be less than 1 second. Setting the keepalive and hold time values to 0 disables the exchange of keepalive messages. The default value is 3 seconds.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 timers keepalive 10

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> timers route-advertisement

Configures the delay in seconds before advertising new results to a neighbor after making a new best path decision for a prefix. This delay rate limits the number of changes advertised to downstream peers and lowers processing requirements by slowing down convergence. The default value is 0 seconds.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 timers route-advertisement 5

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> password

Configures MD5 authentication for a BGP neighbor connection to prevent interference with your routing tables. You must set the same password on each BGP neighbor.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 mypassword

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> peer-group

Configures the peer group in which the specified BGP neighbor belongs. The BGP neighbor inherits the group’s configuration.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 peer-group SPINES

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> remote-as

Configures BGP to establish a connection between two eBGP peers that are not directly connected. You can set a value between 1 and 4294967295, `auto`, `internal`, or `external`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor 10.10.10.101 peer-group remote-as external

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> type

Configures the BGP neighbor type in the specified VRF. You can set a value of `numbered` or `unnumbered`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 type unnumbered

## nv set vrf <vrf-id> router bgp neighbor <neighbor-id> update-source

Configures the BGP source of routing updates. You can specify an interface, or an IPv4 or IPv6 address.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<neighbor-id>` | The IP address of the BGP neighbor or the interface if you are using unnumbered BGP.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp neighbor swp51 update-source 10.10.10.5

## nv set vrf <vrf-id> router bgp path-selection aspath compare-lengths

Configures BGP to select the AS based on path length for the specified VRF.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp path-selection aspath compare-lengths on

## nv set vrf <vrf-id> router bgp path-selection aspath compare-confed

Configures BGP to select the AS based on confederations for the specified VRF.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp path-selection aspath compare-confed on

## nv set vrf <vrf-id> router bgp path-selection med compare-always

Configures BGP to always compare the MED on routes even when received from different neighboring autonomous systems. When enabled, BGP compares MEDs for all paths.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp path-selection med compare-always on

## nv set vrf <vrf-id> router bgp path-selection med compare-deterministic

Applies route selection for the specified VRF in a way that produces deterministic answers locally.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp path-selection med compare-deterministic on

## nv set vrf <vrf-id> router bgp path-selection med compare-confed

Configures MED for route-selection based on confederations for the specified VRF.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp path-selection med compare-confed on

## nv set vrf <vrf-id> router bgp path-selection med missing-as-max

Enables and disables BGP MED missing-as-max for the specified VRF.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp path-selection med missing-as-max enabled

## nv set vrf <vrf-id> router bgp path-selection multipath aspath-ignore

Configures BGP to ignore the AS path when determining multipath routing for the specified VRF. The default setting is `disabled`.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp path-selection multipath aspath-ignore enabled

## nv set vrf <vrf-id> router bgp path-selection multipath generate-asset

Enables and disables BGP multipath generate asset for the specified VRF. The default setting is `disabled`.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp path-selection multipath generate-asset enabled

## nv set vrf <vrf-id> router bgp path-selection multipath bandwidth

Configures multipath route selection based on bandwidth for the specified VRF. You can specify `bandwidth`, `all-paths`, `skip-missing`, `default-weight-for-missing`, or `ignore`. The default setting is `ignore`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp path-selection multipath bandwidth all-paths

## nv set vrf <vrf-id> router bgp path-selection routerid-compare

Configures BGP to use the router ID to decide the best path when the switch receives two identical routes from two different peers. The default setting is `disabled`.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp path-selection routerid-compare enabled

## nv set vrf <vrf-id> router bgp path-selection use-imported-attributes

Configures BGP to calculate the bestpath using the path attribute of the imported (destination) instead of the attribute of the source path. You can specify `enabled` or `disabled`. The default value is `disabled`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp path-selection use-imported-attributes enabled

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast add-path-tx

Configures BGP to advertise more than just the best path for a prefix. You can specify `all-paths` to advertise all known paths to the peers in the peer group or `best-per-AS` to advertise only the best path learned from each AS. The default setting is disabled.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast add-path-tx all-paths

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast aspath allow-my-asn occurrences

Configures the maximum number of times BGP allows the ASN for the local system in the received `AS_PATH`. You can specify a value between 1 and 10.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast aspath allow-my-asn occurrences 6

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast aspath allow-my-asn origin

Configures BGP to allow a received `AS_PATH` containing the ASN of the local system, but only if it is the originating AS. You can specify `enabled` or `disabled`.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast aspath allow-my-asn origin enabled

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast aspath replace-peer-as

Configures BGP to replace the AS path in an outgoing update that contains the ASN of the neighbor with the ASN of the local system. You can specify `enabled` or `disabled`.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast aspath replace-peer-as enabled

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast aspath private-as

Configures what action to take with private ASNs for the peer group in the specified VRF. You can specify `none` to take no action, `remove`, to remove any private ASNs in the update to the neighbors, or `replace` to replace any private ASNs in the update to the neighbors with the ASN of the local system.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast aspath private-as replace

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast attribute-mod aspath

Configures BGP to follow normal BGP procedures when generating the `AS_PATH` attribute for the specified peer group. You can specify `enabled` or `disabled`.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast attribute-mod aspath enabled

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast attribute-mod med

Configures BGP to follow normal BGP procedures when generating the `MED` attribute for the peer group in the specified VRF. You can specify `enabled` or `disabled`. If you set this attribute to `disabled`, BGP does not change the `MED` when sending an update to the peer group.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast attribute-mod med enabled

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast attribute-mod nexthop

Configures BGP to follow normal BGP procedures when generating the `NEXT_HOP` attribute for the peer group in the specified VRF. You can specify `enabled` or `disabled`. If you set this attribute to `disabled`, BGP does not change `NEXT_HOP` when sending an update to the peer group.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast attribute-mod nexthop enabled

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast community-advertise regular

Configures BGP to announce the `COMMUNITIES` attribute to the peer group in the specified VRF. You can specify `enabled` or `disabled`. The default setting is `enabled`.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast community-advertise regular disabled

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast community-advertise extended

Configures BGP to announce the `EXT_COMMUNITIES` attribute to the peer group in the specified VRF. You can specify `enabled` or `disabled`. The default setting is `enabled`.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast community-advertise extended disabled

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast community-advertise large

Configures BGP to announce the `LARGE_COMMUNITIES` attribute to the peer group in the specified VRF. You can specify `enabled` or `disabled`. The default setting is `enabled`.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast community-advertise large disabled

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast conditional-advertise state

Enables and disables BGP conditional advertisement for IPv4. The default setting is `disabled`.

BGP conditional advertisement lets you advertise certain routes only if other routes either do or do not exist. BGP conditional advertisement is typically used in multihomed networks where BGP advertises some prefixes to one of the providers only if information from the other provider is not present. For example, a multihomed router can use conditional advertisement to choose which upstream provider learns about the routes it provides so that it can influence which provider handles traffic destined for the downstream router. This is useful for cost of service, latency, or other policy requirements that are not natively accounted for in BGP.

In Cumulus Linux 5.14 and earlier, you specify `enable on` or `enable off` instead of `state enabled` or `state disabled`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast conditional-advertise state enabled

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast conditional-advertise advertise-map <instance-name>

Configures the route map that contains the prefix list with the list of IPv4 routes or prefixes you want to advertise.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast conditional-advertise advertise-map myadvertise

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast conditional-advertise exist-map <instance-name>

Configures the route map that contains the prefix list with the conditional IPv4 routes or prefixes.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast conditional-advertise exist-map EXIST

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast conditional-advertise non-exist-map <instance-name>

Configures the route map that contains the prefix list with the negative conditional IPv4 routes or prefixes.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast conditional-advertise non-exist-map NONEXIST

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast state

Enables and disables IPv4 for the BGP peer group in the specified VRF. The default setting is `disabled`.

In Cumulus Linux 5.14 and earlier, you specify `enable on` or `enable off` instead of `state enabled` or `state disabled`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast state enabled

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast nexthop-setting

Configures the BGP next hop value of advertised IPv4 routes for the peers in the peer group. You can specify `auto` to follow regular BGP next hop determination rules, `self` to set the next hop to ourselves for route advertisement excluding reflected routes, or `force` to set the next hop to ourselves for route advertisement including reflected routes. The default setting is `auto`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast nexthop-setting force

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast prefix-limits inbound maximum

Configures the maximum number of inbound IPv4 prefixes allowed from the peer group in the specified VRF.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast prefix-limits inbound maximum 3000

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast prefix-limits inbound warning-threshold

Configures the maximum number of inbound IPv4 prefixes (as a percentage) allowed before the switch generates a syslog warning. You can set a value between 1 and 100.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast prefix-limits inbound warning-threshold 4

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast prefix-limits inbound reestablish-wait

Configures the time in seconds to wait before establishing the BGP session again with the peers in the peer group. You can specify a value between 1 and 4294967295. A value of `auto` uses standard BGP timers and processing (between 2 and 3 seconds). The default setting is `auto`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast prefix-limits inbound reestablish-wait 3000000000

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast policy inbound route-map

Configures the route map you want to apply to updates received from the peers in the peer group.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast policy inbound route-map myroutemap

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast policy inbound prefix-list

Configures the prefix list you want to apply to updates received from the peers in the peer group.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast policy inbound prefix-list myprefixlist

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast policy inbound aspath-list none

Configures the AS path filter list you want to apply to updates received from the peers in the peer group.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast policy inbound aspath-filter myaspathlist

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast policy outbound aspath-list none

Configures the AS path filter list you want to apply to updates sent to the peers in the peer group.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast policy outbound aspath-list myaspathlist

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast policy outbound prefix-list

Configures the prefix list you want to apply to updates to be sent to the peers in the peer group.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast policy outbound prefix-list myprefixlist

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast policy outbound route-map

Configures the route map you want to apply to updates to be sent to the peers in the peer group.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast policy outbound route-map myroutemap

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast policy outbound unsuppress-map

Configures the route map used to unsuppress IPv4 routes selectively when advertising to the peers in the peer group; these are routes that have been suppressed due to aggregation configuration.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast policy outbound unsuppress-map myunsuppress

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast route-reflector-client

Configures the BGP node as a route reflector for the BGP peer group in the specified VRF. The default setting is `disabled`.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast route-reflector-client enabled

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast soft-reconfiguration

Enables and disables soft configuration so that received IPv4 routes from peers in the peer group that are rejected by an inbound policy are still stored. This allows policy changes to take effect without any exchange of BGP updates. The default setting is `disabled`.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast soft-reconfiguration enabled

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unicast weight

Configures the weight applied to IPv4 routes received from peer group in the specified VRF. This is used in the BGP route selection algorithm.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES address-family ipv4-unicast weight 65535

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unreachability aspath allow-my-asn occurrences

Configures the maximum number of occurrences of the local system’s AS number in the received AS_PATH for the peer group for BGP unreachability SAFI (failure signaling). You can set a value between 1 and 10.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group UNDERLAY-LEAF address-family ipv4-unreachability aspath allow-my-asn occurrences 3

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unreachability aspath allow-my-asn origin

Configures BGP to allow a received AS_PATH containing the ASN of the local system but only if it is the originating AS for the peer group for BGP unreachability SAFI (failure signaling). You can specify `enabled` or `disabled`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group UNDERLAY-LEAF address-family ipv4-unreachability aspath allow-my-asn origin enabled

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unreachability aspath allow-my-asn route-map

Applies the route map to filter IPv4 routes with my AS in the AS_PATH for BGP unreachability SAFI (failure signaling). Allows selective application of `allowas-in` based on route map matching.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group UNDERLAY-LEAF address-family ipv4-unreachability aspath allow-my-asn route-map ROUTEMAP1

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unreachability aspath allow-my-asn state

Enables and disables the local system’s AS number in the received AS_PATH for the peer group for BGP unreachability SAFI (failure signaling). You can specify `enabled` or `disabled`. The default setting is `disabled`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group UNDERLAY-LEAF address-family ipv4-unreachability aspath allow-my-asn state enabled led

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unreachability aspath private-as

Configures how to handle private ASNs in the update to the peer group for BGP unreachability SAFI (failure signaling). You can specify:

- `none` to take no action. This is the default setting.
- `remove` to remove any private ASNs in the update to the peer
- `replace` to replace any private ASNs in the update to the peer with the ASN of the local system.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group UNDERLAY-LEAF address-family ipv4-unreachability aspath private-as replace

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unreachability aspath replace-peer-as

Configures BGP to replace the ASN of the peer in the AS_PATH of an outgoing update with the ASN of the local system for the peer group for BGP unreachability SAFI (failure signaling). You can specify `enabled` or `disabled`. The default setting is `disabled`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group UNDERLAY-LEAF address-family ipv4-unreachability aspath replace-peer-as enabled

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unreachability prefix-limits maximum

Configures the maximum number of unreachability prefixes that can be received from the peer group for BGP unreachability SAFI (failure signaling). This is CRITICAL for security to prevent state exhaustion.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group UNDERLAY-LEAF address-family ipv4-unreachability prefix-limits maximum 6

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unreachability prefix-limits reestablish-wait

Configures the time in minutes to wait before establishing the BGP session again with the peer group for BGP unreachability SAFI. The default value is `auto`, which uses standard BGP timers and processing.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group UNDERLAY-LEAF address-family ipv4-unreachability prefix-limits reestablish-wait 6

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unreachability prefix-limits warning-only

Configures the switch for BGP unreachability SAFI (failure signaling) to only generate a warning syslog if the number of received unreachability IPv4 prefixes exceeds the limit, but does not bring down the BGP session. You can set this option to `enabled` or `disabled`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group UNDERLAY-LEAF address-family ipv4-unreachability prefix-limits warning-only enabled

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unreachability prefix-limits warning-threshold

Configures the IPv4 prefix limits for a peer group for BGP unreachability SAFI (failure signaling). Sets the percentage of the maximum at which a syslog warning is generated. You can set the value between 1 and 100. The default value is 75.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group UNDERLAY-LEAF address-family ipv4-unreachability prefix-limits warning-threshold 50

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> address-family ipv4-unreachability state

Enables and disables IPv4 BGP unreachability SAFI (failure signaling) for the peer group. The default value is disabled.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.16.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group UNDERLAY-LEAF address-family ipv4-unreachability state enabled

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> bfd enable

Enables and disables BFD for the BGP peer group in the specified VRF. The default setting is `disable`.

Cumulus Linux 5.15 and later no longer supports this command.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES bfd state enable

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> bfd detect-multiplier

Configures the BFD interval multiplier for the BGP peer group in the specified VRF. You can specify a value between 2 and 255.

Cumulus Linux 5.15 and later no longer supports this command.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES bfd detect-multiplier 4

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> bfd min-rx-interval

Configures the minimum interval between received BFD control packets for the BGP peer group in the specified VRF. You can specify a value between 50 and 60000.

Cumulus Linux 5.15 and later no longer supports this command.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES bfd min-rx-interval 400

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> bfd min-tx-interval

Configures the minimum interval between sending BFD control packets for the BGP peer group in the specified VRF. You can specify a value between 50 and 60000.

Cumulus Linux 5.15 and later no longer supports this command.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES bfd min-tx-interval 400

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> capabilities extended-nexthop

Enables and disables the extended next hop capability defined in RFC 5549 in the specified VRF. The extended nexthop is advertised to peers in the peer group. If you specify `auto`, extended next hop is enabled for unnumbered peers and disabled otherwise. The default setting is `auto`.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES capabilities extended-nexthop enabled

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> capabilities source-address

Configures the source IP address of the TCP connection for the peer group, which is often used as the BGP next hop for updates.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.1.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES capabilities source-address 10.10.10.1

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> description

Configures a description for the peer group.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.1.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES description none

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> graceful-shutdown

Enables and disables graceful shutdown on a peer group. You can specify `enabled` or `disabled`.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.12.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group underlay graceful-shutdown enabled

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> local-as asn

Configures the ASN you want to use for the peer group to establish the peering if it is different from the ASN of the BGP instance. The local AS configured is also attached to incoming and outgoing updates.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES local-as asn 65101

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> local-as state

Enables and disables local AS for the peer group. The default setting is `disabled`.

In Cumulus Linux 5.14 and earlier, you specify `enable on` or `enable off` instead of `state enabled` or `state disabled`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES local-as state enabled

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> local-as prepend state

Configures BGP to prepend the configured local AS to updates for the peer group in the specified VRF. The default setting is `disabled`.

In Cumulus Linux 5.14 and earlier, you specify `enabled` or `disabled` instead of `state enabled` or `state disabled`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES local-as state enabled

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> local-as replace

Configures BGP to either attach only the configured local AS to generated updates or attach the ASN of the BGP instance, then prepend it with the configured local AS. The default setting is `disabled`.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES local-as replace enabled

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> password none

Configures a password for the BGP peer group.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES password none

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> timers connection-retry

Configures the time interval at which BGP attempts to connect to a neighbor in the peer group after a failure. You can specify a value between 1 and 65535. If you specify `auto`, BGP uses the global value. The default setting is `auto`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES timers connection-retry 30

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> timers keepalive

Configures the interval at which BGP exchanges periodic keepalive messages to measure and ensure that a peer is still alive and functioning. You can specify a value between 1 and 65535. If you specify `none`, BGP does not send keepalives. If you specify `auto`, BGP uses the global value. The default setting is `auto`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES timers keepalive 10

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> timers hold

Configures the hold timer for the peer group in the specified VRF. If BGP does not receive a keepalive or update message from a neighbor in the peer group within the hold time, it declares the neighbor down and withdraws all routes received by this neighbor from the local BGP table. If you specify `none`, BGP does not track keepalives from the neighbor and the peering session does not experience a hold timeout. You can specify a value between 3 and 65535. If you specify `auto`, BGP uses the global value. The default setting is `auto`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES timers hold 30

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> timers route-advertisement

Configures the time between route advertisements (BGP updates) for the BGP group in the specified VRF. After making a new best path decision for a prefix, BGP can insert a delay before advertising the new results to a neighbor. This delay rate limits the number of changes advertised to downstream peers and lowers processing requirements by slowing down convergence. You can specify a value between 1 and 65535. If you specify `none`, BGP delays and sends route advertisements in batches. If you specify `auto`, BGP uses the global value. The default setting is `auto`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES timers route-advertisement 5

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> ttl-security state

Enables and disables BGP TTL security in the specified VRF.

Use this option to prevent attacks against eBGP, such as denial of service (DoS). By default, BGP messages to eBGP neighbors have an IP time-to-live (TTL) of 1, which requires the neighbor to be directly connected, otherwise, the packets expire along the way. An attacker can adjust the TTL of packets so that they look like they originate from a directly connected neighbor. The BGP TTL security hops option inverts the direction in which BGP counts the TTL. Instead of accepting only packets with a TTL of 1, Cumulus Linux accepts BGP messages with a TTL greater than or equal to 255 minus the specified hop count.

In Cumulus Linux 5.14 and earlier, you specify `enable on` or `enable off` instead of `state enabled` or `state disabled`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES ttl-security state enabled

## nv set vrf <vrf-id> router bgp peer-group <peer-group-id> ttl-security hops

Configures the number of hops to deduct from a TTL greater than or equal to 255 to prevent attacks against eBGP, such as denial of service (DoS).

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<peer-group-id>` | The peer group name.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp peer-group SPINES ttl-security hops 200

## nv set vrf <vrf-id> router bgp rd

Configures the BGP route distinguisher (RD) in the specified VRF.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf RED router bgp rd 10.1.20.2:5

## nv set vrf <vrf-id> router bgp route-export to-evpn route-target <rt-id>

Configures the tenant VRF RTs (layer 3 RTs) for BGP route export.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<rt-id>` | The route target.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp route-export to-evpn route-target 10.10.10.1:20

## nv set vrf <vrf-id> router bgp route-import from-evpn route-target <rt-id>

Configures the tenant VRF RTs (layer 3 RTs) for BGP route import.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.
`<rt-id>` | The route target.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp route-import from-evpn route-target 10.10.10.1:20

## nv set vrf <vrf-id> router bgp route-reflection state

Enables and disables BGP route reflection. The default setting is `disabled`.

When you configure an iBGP speaker as a route reflector, it can send iBGP learned routes to other iBGP peers.

In Cumulus Linux 5.14 and earlier, you specify `enable on` or `enable off` instead of `state enabled` or `state disabled`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp route-reflection state enabled

## nv set vrf <vrf-id> router bgp route-reflection cluster-id

Configures the cluster ID to use during route reflection. When route reflection is on, you must set the cluster ID.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp route-reflection cluster-id 10

## nv set vrf <vrf-id> router bgp route-reflection reflect-between-clients

Allows routes to be reflected between clients for the specified VRF. Typically, routes are reflected only between clients and non-clients, with the clients of a route reflector expected to be fully meshed. The default setting is `disabled`.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp route-reflection reflect-between-clients enabled

## nv set vrf <vrf-id> router bgp route-reflection outbound-policy

Allows an outbound neighbor policy to modify the attributes for reflected routes. Typically, reflected routes have to retain their original attributes. The default setting is `disabled`.

In Cumulus Linux 5.14 and earlier, you specify `on` or `off`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp route-reflection outbound-policy enabled

## nv set vrf <vrf-id> router bgp router-id

Configures the router ID in the specified VRF.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp router-id 10.10.10.1

## nv set vrf <vrf-id> router bgp timers conditional-advertise

Configures the time interval at which the BGP table is scanned for a condition that is met. You can sepcify a value between 5 and 240 or `none`.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp timers conditional-advertise 20

## nv set vrf <vrf-id> router bgp timers connection-retry

Configures the time interval (in seconds) at which BGP connection attempts are retried after a failure. The default value is 10.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp timers connection-retry 10

## nv set vrf <vrf-id> router bgp timers hold

Configures the hold time (in seconds). By default, BGP exchanges periodic keepalive messages to measure and ensure that a neighbor is still alive and functioning. If BGP does not receive a keepalive or update message from the neighbor within the hold time, it declares the neighbor down and withdraws all routes received by this neighbor from the local BGP table.

You can specify a value between 03and 65535 or `none`. The default value is 9 seconds.

The keepalive interval can be less than or equal to one third of the hold time, but cannot be less than 1 second. Setting the keepalive and hold time values to 0 disables the exchange of keepalives.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp timers hold 30

## nv set vrf <vrf-id> router bgp timers keepalive

Configures the rate (in seconds) at which BGP sends keepalive messages to all the peers in the specified VRF. BGP exchanges periodic keepalive messages to measure and ensure that a neighbor is still alive and functioning. You can specify a value between 0 and 65535 or `none`. The default value is 3 seconds.

The keepalive interval can be less than or equal to one third of the hold time, but cannot be less than 1 second. Setting the keepalive and hold time values to 0 disables the exchange of keepalives.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp timers keepalive 10

## nv set vrf <vrf-id> router bgp timers route-advertisement

Configures the delay to insert before advertising the new results to a neighbor after making a new best path decision for a prefix. This delay rate limits the number of changes advertised to downstream peers and lowers processing requirements by slowing down convergence. You can set a value between 1 and 600 or `none`. The default value is 0 for both eBGP and iBGP sessions, which allows for fast convergence.

### Command Syntax

Syntax | Description
--- | ---
`<vrf-id>` | The VRF you want to configure.

### Version History

Introduced in Cumulus Linux 5.0.0

### Example

    cumulus@switch:~$ nv set vrf default router bgp timers route-advertisement 5