Skip to content

[Show][BGP] Show BGP Change for no neighbor scenario#2885

Merged
developfast merged 16 commits intosonic-net:masterfrom
developfast:bgp-util-no-neigh-change-master
Jul 4, 2023
Merged

[Show][BGP] Show BGP Change for no neighbor scenario#2885
developfast merged 16 commits intosonic-net:masterfrom
developfast:bgp-util-no-neigh-change-master

Conversation

@developfast
Copy link
Copy Markdown
Contributor

What I did

Changed the show bgp summary for both ipv4 and ipv6 to show basic bgp switch information. This was done in order for hardware proxy to set the correct settings for bgp connections when no neighbors are present, and prevent errors. This was a blocking issue which prevents image upgrades for backend storage ToRs which have no bgp neighbors.

How I did it

Checked for when a bgp neighbor is present using vtysh, if not, display basic bgp information.

How to verify it

Copied the respective bgp util files onto a switch and ran show ip bgp summary and show ipv6 bgp summary when there are no bgp neighbors and see that it displays the correct information.

Previous command output (if the output of a command-line utility has changed)

~$ show ip bgp summary
No IPv4 neighbor is configured

~$ show ipv6 bgp summary
No IPv6 neighbor is configured

New command output (if the output of a command-line utility has changed)

~$ show ip bgp summary

IPv4 Unicast Summary:
BGP router identifier 10.1.0.32, local AS number 65100 vrf-id 0
BGP table version 12811
RIB entries 0, using 0 bytes of memory
Peers 0, using 0 KiB of memory
Peer groups 0, using 0 bytes of memory


Neighbor      V     AS    MsgRcvd    MsgSent    TblVer    InQ    OutQ  Up/Down    State/PfxRcd    NeighborName
-----------  ---  -----  ---------  ---------  --------  -----  ------  ---------  --------------  --------------

Total number of neighbors 0

~$ show ipv6 bgp summary

IPv6 Unicast Summary:
BGP router identifier 10.1.0.32, local AS number 65100 vrf-id 0
BGP table version 8972
RIB entries 0, using 0 bytes of memory
Peers 0, using 0 KiB of memory
Peer groups 0, using 0 bytes of memory


Neighbor      V     AS    MsgRcvd    MsgSent    TblVer    InQ    OutQ  Up/Down    State/PfxRcd    NeighborName
-----------  ---  -----  ---------  ---------  --------  -----  ------  ---------  --------------  --------------

Total number of neighbors 0

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants