Skip to main content

Setting up Border Gateway Protocol (BGP)

Starting with ONTAP 9.5, virtual IP (VIP) LIFs are supported. Before creating VIP LIFs, you must set up BGP, which is the routing protocol used for announcing the existence of VIP LIF to peer routers.

Before you begin

Peer router must be configured to accept BGP connection from the BGP LIF for the configured autonomous system number (ASN).
Note
ONTAP does not process any incoming route announcements from the router; therefore, you should configure the peer router for not sending any route updates to the cluster.

About this task

Setting up BGP involves optionally creating a BGP configuration, creating a BGP LIF, and creating a BGP peer group. ONTAP automatically creates a default BGP configuration with default values when the first BGP peer group is created on a given node. A BGP LIF is used to establish BGP TCP sessions with peer routers. For a peer router, a BGP LIF is the next hop to reach a VIP LIF. Failover is disabled for the BGP LIF. A BGP peer group advertises the VIP routes for all of the SVMs in the peer group's IPspace.
  1. Log in to the advanced privilege level: set -privilege advanced
  2. Optional: Create a BGP configuration or modify the default BGP configuration of the cluster by performing one of the following actions:
    • Create a BGP configuration: network bgp config create -node {node_name | local} -asn asn_integer -holdtime hold_time -routerid local_router_IP_address
      cluster1::*> network bgp config create -node node1 -asn 65502 -holdtime 180 -routerid 1.1.1.1
    • Modify the default BGP configuration: network bgp defaults modify -asn asn_integer -holdtime hold_time
      cluster1::*> network bgp defaults modify -asn 65502

    asn_integer specifies the ASN. ASN for BGP is a non-negative 16-bit integer. The default ASN is 65501.

    hold_time specifies the hold time in seconds. The default value is 180s.

  3. Create a BGP LIF for the system SVM: network interface create -vserver system_svm -lif lif_name -service-policy net-route-announce -home-node home_node -home-port home_port -address ip_address -netmask netmask

    You can use the net-route-announce service policy for the BGP LIF.

    Example

    cluster1::> network interface create -vserver cluster1 -lif bgp1 -service-policy net-route-announce -home-node 
    cluster1-01 -home-port e0c -address 10.10.10.100 -netmask 255.255.255.0
  4. Create a BGP peer group that is used to establish BGP sessions with the remote peer routers and configure the VIP route information that is advertised to the peer routers: network bgp peer-group create -peer-group group_name -ipspace ipspace_name -local-lif bgp_lif -peer-address peer-router_ip_address -peer-asn 65502 -route-preference integer

    Example

    cluster1::> network bgp peer-group create -peer-group group1 -ipspace Default -local-lif bgp1 
    -peer-address 10.10.10.1 -peer-asn 65502 -route-preference 100