Page MenuHomeVyOS Platform

BGP- warning message that AFI/SAFI is needed to establish the neighborship
Closed, ResolvedPublicFEATURE REQUEST

Description

Hi team

I would like to introduce a warning message when we don't enable AFI on BGP(ipv4/ipv6,etc.), this message prevents these types of issues :

https://phabricator.vyos.net/T4175

example:

vyos@vyos:~$ show bgp summary
% No BGP neighbors found in VRF default
vyos@vyos:~$ show bgp vrf all summary
% No BGP neighbors found in VRF default

vyos@vyos:~$ show ip bgp neighbors
BGP neighbor is 10.10.150.1, remote AS 100, local AS 100, internal link
  BGP version 4, remote router ID 0.0.0.0, local router ID 10.10.150.2
  BGP state = Idle
  Last read 00:11:35, Last write never
  Hold time is 180, keepalive interval is 60 seconds
  Graceful restart information:
    Local GR Mode: Helper*
    Remote GR Mode: NotApplicable
    R bit: False
    Timers:
      Configured Restart Time(sec): 120
      Received Restart Time(sec): 0
  Message statistics:
    Inq depth is 0
    Outq depth is 0
                         Sent       Rcvd
    Opens:                  0          0
    Notifications:          0          0
    Updates:                0          0
    Keepalives:             0          0
    Route Refresh:          0          0
    Capability:             0          0
    Total:                  0          0
  Minimum time between advertisement runs is 0 seconds
  Update source is eth2

  Connections established 0; dropped 0
  Last reset 00:11:35, ** No AFI/SAFI activated for peer**
BGP Connect Retry Timer in Seconds: 120
Read thread: off  Write thread: off  FD used: -1

solution set protocols bgp neighbor x.x.x.x address-family ipv4-unicast, here is a basic example:

set protocols bgp local-as '100'
set protocols bgp neighbor 10.10.150.1 remote-as '100'
set protocols bgp neighbor 10.10.150.1 update-source 'eth2'
set protocols bgp parameters log-neighbor-changes
set protocols bgp parameters router-id '10.10.150.2'

Details

Difficulty level
Unknown (require assessment)
Version
-
Why the issue appeared?
Will be filled on close
Is it a breaking change?
Unspecified (possibly destroys the router)
Issue type
Unspecified (please specify)

Related Objects

Event Timeline

fernando changed the task status from Open to In progress.Jun 28 2022, 12:12 PM
fernando claimed this task.
fernando triaged this task as Low priority.
Viacheslav moved this task from Need Triage to Finished on the VyOS 1.4 Sagitta board.
set protocols bgp local-as 200
set protocols bgp peer-group foo remote-as external
set protocols bgp peer-group foo address-family ipv4-unicast  ipv6-unicast
set protocols bgp neighbor 1.1.1.1 peer-group foo
commit

Shows: WARNING: BGP neighbor "1.1.1.1" requires address-family! - this should not be the case as the AFI is specified via the peer-group