summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* zebra: Handling of connection disconnect and connect with GR.Santosh P K2020-01-305-6/+221
| | | | | | | | | | | Zebra will have special handling for clients with GR enabled. When client disconnects with GR enabled, then a stale client will be created and its RIB will be retained till stale timer or client comes up and updated its RIB. Co-authored-by: Santosh P K <sapk@vmware.com> Co-authored-by: Soman K S <somanks@vmware.com> Signed-off-by: Santosh P K <sapk@vmware.com>
* zebra: Header file changes and show commands.Santosh P K2020-01-303-4/+153
| | | | | | | | | | | Adding header files changes where structure to hold received graceful restart info from client is defined. Also there are changes for show commands where exisiting commands are extended. Co-authored-by: Santosh P K <sapk@vmware.com> Co-authored-by: Soman K S <somanks@vmware.com> Signed-off-by: Santosh P K <sapk@vmware.com>
* lib: Adding GR capabilites encode and decode.Santosh P K2020-01-304-68/+77
| | | | | | | | | | For Graceful restart clients have to send GR capabilities library functions are added to encode capabilities and also for zebra to decode client capabilities. Co-authored-by: Santosh P K <sapk@vmware.com> Co-authored-by: Soman K S <somanks@vmware.com> Signed-off-by: Santosh P K <sapk@vmware.com>
* Merge pull request #5210 from bisdhdh/masterRuss White2020-01-2825-166/+3546
|\ | | | | bgpd:BGP Graceful Restart Per Neighbor(BGPN) Feature.
| * bgpd: Added bgp graceful restart additional debug logs.bisdhdh2020-01-233-3/+9
| | | | | | | | | | | | | | bgp graceful restart additional debug logs, resolved merge conflicts. Signed-off-by: Biswajit Sadhu <sadhub@vmware.com>
| * bgpd: BGP Garaceful Restart debug logs.bisdhdh2020-01-2313-239/+322
| | | | | | | | | | | | Reorganizing bgp gr debug logs and code review comments. Signed-off-by: Biswajit Sadhu <sadhub@vmware.com>
| * bgpd: BGP Graceful Restart documentation.bisdhdh2020-01-231-0/+175
| | | | | | | | | | | | | | This change list contains the documentation of BGP Greacful Restart feature and all the commnads to enable/disable the feature Signed-off-by: Biswajit Sadhu <sadhub@vmware.com>
| * bgpd: Adding bgp peer route processing and EOR state Signalling from BGPD to ↵bisdhdh2020-01-232-7/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Zebra. * While the Deferral timer is running, signal route update pending (ZEBRA_CLIENT_ROUTE_UPDATE_PENDING) from BGPD to Zebra. * After expiry of the Deferral timer, the deferred routes are processed. When the deferred route_list becomes empty, End-of-Rib is send to the peer and route processing complete message (ZEBRA_CLIENT_ROUTE_UPDATE_COMPLETE) is sent to Zebra. So that Zebra would delete any stale routes still present in the rib. Signed-off-by: Biswajit Sadhu <sadhub@vmware.com>
| * bgpd: Add rib-stale-time(running in Zebra).bisdhdh2020-01-232-74/+202
| | | | | | | | | | | | | | | | | | | | | | * Added CLI commands to update rib-stale-time, running in Cmd : "bgp gaceful-restart rib-stale-time (1-3000)". Cmd : "no bgp gaceful-restart rib-stale-time". * Integrating the hooks function for signalling from BGPD to ZEBRA to ZEBRA to enable or disable GR feature in ZEBRA depending on bgp per peer gr configuration. Signed-off-by: Biswajit Sadhu <sadhub@vmware.com>
| * bgpd: Adding helper caller hooks for BGPD-ZEBRA integration for GR.bisdhdh2020-01-233-0/+16
| | | | | | | | | | | | | | | | *Adding helper caller hooks function for signalling from BGPD to ZEBRA to enable or disable GR feature in ZEBRA depending on bgp per peer gr configuration. Signed-off-by: Biswajit Sadhu <sadhub@vmware.com>
| * bgpd: Adding helper function for BGPD-ZEBRA integration for GR.bisdhdh2020-01-231-0/+160
| | | | | | | | | | | | | | | | *Adding helper function for signalling from BGPD to ZEBRA to enable or disable GR feature in ZEBRA depending on bgp per peer gr configuration. Signed-off-by: Biswajit Sadhu <sadhub@vmware.com>
| * bgpd: Zebra lib for Graceful Restart.bisdhdh2020-01-232-0/+49
| | | | | | | | | | | | | | | | | | These changes are for Zebra lib in order to supportGraceful Restart feature. These changes are addedtemporarily, until Zebra Graceful Restart lib Pr is merged. Signed-off-by: Biswajit Sadhu <sadhub@vmware.com> Signed-off-by: Soman K S <somanks@vmware.com>
| * bgpd: Adding header files for BGPD-ZEBRA integration for GR.bisdhdh2020-01-233-2/+115
| | | | | | | | | | | | | | | | Data Structures, function declaration and Macros forSignalling from BGPD to ZEBRA to enable or disable GR feature in ZEBRA depending on bgp per peer gr configuration. Signed-off-by: Biswajit Sadhu <sadhub@vmware.com>
| * bgpd: Restarting node does not send EOR after the convergence.bisdhdh2020-01-238-18/+101
| | | | | | | | | | | | | | | | | | | | | | | | *After a restarting router comes up and the bgp session is successfully established with the peer. If the restarting router doesn’t have any route to send, it send EOR to the peer immediately before receiving updates from its peers. *Instead the restarting router should send EOR, if the selection deferral timer is not running OR count of eor received and eor required are matches then send EOR. Signed-off-by: Biswajit Sadhu <sadhub@vmware.com>
| * bgpd: Added hidden CLI command to disable sending of End-of-Rib.bisdhdh2020-01-234-18/+59
| | | | | | | | | | | | | | | | | | | | | | | | BGP disable EOR sending is a useful command for testing various scenarios of BGP graceful restart. * Added the hidden CLI command : bgp graceful-restart disable-eor * The CLI will not be displayed in "show running-config" and will not be stored in configuration file. * When enabled, EOR will not be sent to peer Signed-off-by: Biswajit Sadhu <sadhub@vmware.com> Signed-off-by: Soman K S <somanks@vmware.com>
| * bgpd: BGP-GR peer router restart-time should be reset.bisdhdh2020-01-231-0/+7
| | | | | | | | | | | | | | | | When the peer router's gr mode had changed from helper/restart to disable. The local bgp gr router should reset the peer router's restart-time stored. Signed-off-by: Biswajit Sadhu <sadhub@vmware.com>
| * bgpd: Fix for Helper node doesn't set R-bit in OPEN message after the reload.bisdhdh2020-01-231-3/+1
| | | | | | | | | | | | | | BGP Helper node doesn't set R-bit in OPEN message after the restart or reload of the BGP router. Signed-off-by: Biswajit Sadhu <sadhub@vmware.com>
| * bgpd: BGP tcp session failed to apply GR configuration on the transferredbisdhdh2020-01-236-8/+76
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | bgp tcp connection. When the BGP peer is configured between two bgp routes both routers would create peer structure , when they receive each other’s open message. In this event both speakers, open duplicate TCP sessions and send OPEN messages on each socket simultaneously, the BGP Identifier is used to resolve which socket should be closed. If BGP GR is enabled the old tcp session is dumped and the new session is retained. So while this transfer of connection is happening, if all the bgp gr config is not migrated to the new connection, the new bgp gr mode will never get applied. Fix Summary: 1. Replicate GR configuration from the old session to the new session in bgp_accept(). 2. Replicate GR configuration from stub to full-fledged peer in bgp_establish(). 3. Disable all NSF flags, clear stale routes (if present), stop restart & stale timers (if they are running) when the bgp GR mode is changed to “Disabled”. 4. Disable R-bit in cap, if it is not set the received open message. Signed-off-by: Biswajit Sadhu <sadhub@vmware.com>
| * bgpd: show BGP GR Neighbor mode as “NotApplicable”,when local mode is ↵bisdhdh2020-01-231-4/+5
| | | | | | | | | | | | | | | | | | | | | | “Disable”. BGP GR Neighbor mode is showing the default string as “NotRecieved”, as the bgp gr neighbour capability was not processed, since the local mode is “Disable”. However now it would be changed to “NotApplicable”. Signed-off-by: Biswajit Sadhu <sadhub@vmware.com>
| * bgpd: Fix for BGP core when connected routes are redistributedbisdhdh2020-01-231-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | & GR is enabled. When GR with deferral is enabled and connected routes are distributed then in one race condition route node gets added in to both deferred queue and work queue. If deferred queue gets processed first then it ends up delete only flag while leaving the entry in the work queue as it is. When a new update comes for the same route node next time from peer then it hits assert. Assert check is added to ensure we don’t add to work queue again while it is already present. So, check before adding in to deferred queue if it is already present in work queue and bail if so. Signed-off-by: Biswajit Sadhu <sadhub@vmware.com>
| * bgpd: Adding BGP GR change mode config apply on notification sent & received.bisdhdh2020-01-233-8/+46
| | | | | | | | | | | | | | | | | | | | | | | | * Changing GR mode on a router needs a session reset from the SAME router to negotiate new GR capability. * The present GR implementation needs a session reset after every new BGP GR mode change. * When BGP session reset happens due to sending or receiving BGP notification after changing BGP GR mode, there is no need of explicit session reset. Signed-off-by: Biswajit Sadhu <sadhub@vmware.com>
| * bgpd: Adding BGP GR Neighbour mode show, when local mode is “Disable”.bisdhdh2020-01-231-14/+26
| | | | | | | | | | | | | | | | | | | | * BGP GR Neighbour mode in show command would show as “NotApplicable”, when local mode is “Disable”. As the bgp gr neighbour capability was not processed, since the local mode is “Disable”. * Minor changes in show Selection Deferral Time. Signed-off-by: Biswajit Sadhu <sadhub@vmware.com>
| * bgpd: Adding Selection Deferral Timer handler changes.bisdhdh2020-01-2310-14/+498
| | | | | | | | | | | | | | | | | | | | * Selection Deferral Timer for Graceful Restart. * Added selection deferral timer handling function. * Route marking as selection defer when update message is received. * Staggered processing of routes which are pending best selection. * Fix for multi-path test case. Signed-off-by: Biswajit Sadhu <sadhub@vmware.com>
| * bgpd: Adding changes for Selection Deferral Timer config cmdbisdhdh2020-01-233-4/+109
| | | | | | | | | | | | | | | | | | | | | | | | and DS. * Added config commands and data structures for deferral timer configuration and processing. Cmd : bgp graceful-restart select-defer-time (0-3600) Cmd : no bgp graceful-restart select-defertime (0-3600) Signed-off-by: Biswajit Sadhu <sadhub@vmware.com> Signed-off-by: Soman K S <somanks@vmware.com>
| * bgpd: Adding BGP GR Per Neighbor show commands.bisdhdh2020-01-236-56/+693
| | | | | | | | | | | | | | | | | | | | | | * Added new show command to show the graceful restart information for each neighbor. Cmd: show bgp [<ipv4|ipv6>] neighbors [<A.B.C.D|X:X::X:X|WORD>] graceful-restart * Changes to show neighbors commands for displaying graceful restart information. Cmd :show [ip] bgp [<view|vrf> VIEWVRFNAME] [<ipv4|ipv6>] neighbors [<A.B.C.D|X:X::X:X| Signed-off-by: Biswajit Sadhu <sadhub@vmware.com>
| * bgpd: Adding BGP GR Per Neighbor config commands.bisdhdh2020-01-231-57/+370
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Added configuration commands for enabling and disabling graceful restart per neighbour. Cmd : neighbor A.B.C.D graceful-restart Cmd : no neighbor A.B.C.D graceful-restart Cmd : neighbor A.B.C.D graceful-restart-helper Cmd : no neighbor A.B.C.D graceful-restart-helper Cmd : neighbor A.B.C.D graceful-restart-disable Cmd : no neighbor A.B.C.D graceful-restart-disable * Added configuration commands for disabling graceful restart at the global Level. Cmd : bgp graceful-restart disable Cmd : no bgp graceful-restart disable Signed-off-by: Biswajit Sadhu <sadhub@vmware.com>
| * bgpd: BGP GR advertise capabilities in the open message.bisdhdh2020-01-232-45/+81
| | | | | | | | | | | | | | * Changes to the capability sending function to advertise graceful restart capability in the bgp OPEN message. Signed-off-by: Biswajit Sadhu <sadhub@vmware.com>
| * bgpd: Adding BGP GR Global & Per Neighbour FSM changesbisdhdh2020-01-238-28/+597
| | | | | | | | | | | | | | | | * Added FSM for peer and global configuration for graceful restart * Added debug option BGP_GRACEFUL_RESTART for logs specific to graceful restart processing Signed-off-by: Biswajit Sadhu <sadhub@vmware.com>
| * bgpd: BGP Graceful Restart Per Neighbor(BGPN), DS & header files.bisdhdh2020-01-235-4/+236
| | | | | | | | | | | | | | This pr contains all the header files changes for BGP GR per Neighbour(BGPN) feature. Signed-off-by: Biswajit Sadhu <sadhub@vmware.com>
* | Merge pull request #4773 from thozza/31-prefix-bcast-addrRuss White2020-01-282-7/+6
|\ \ | | | | | | ipv4_broadcast_addr() didn't comply with RFC3021
| * | lib/prefix.c: ipv4_broadcast_addr() didn't comply with RFC3021Tomas Hozza2019-08-052-7/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The function ipv4_broadcast_addr() does not calculate correct broadcast addresses for point-to-point connections with prefix 31. RFC3021 section 3.3 [1] specifies: "The 255.255.255.255 IP broadcast address MUST be used for broadcast Address Mask Replies in point-to-point links with 31-bit subnet masks" The issue causes Zebra to print the following warning when IPv4 address with 31 prefix (e.g. 192.168.222.240/31) is configured on a network interface: ZEBRA: [EC 4043309141] warning: interface VNS broadcast addr 255.255.255.255/31 != calculated 192.168.222.241, routing protocols may malfunction The issue has been originally found in Quagga [2], but it is present also in FRR. [1] https://tools.ietf.org/html/rfc3021#section-3.3 [2] https://bugzilla.redhat.com/show_bug.cgi?id=1713449 Signed-off-by: Tomas Hozza <thozza@redhat.com>
* | | Merge pull request #5721 from mjstapp/vty_copy_to_runnRuss White2020-01-282-0/+27
|\ \ \ | | | | | | | | vtysh: add a cli that reads a file into running-config
| * | | vtysh: add a cli that reads a file into running-configMark Stapp2020-01-232-0/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Add a 'copy' cli that reads a file into the current running config. Add an entry about the new cli to the user doc. Signed-off-by: Mark Stapp <mjs@voltanet.io>
* | | | Merge pull request #5706 from mjstapp/fix_nh_debug_showRuss White2020-01-281-2/+10
|\ \ \ \ | | | | | | | | | | zebra: include zebra nexthop debug in show runn
| * | | | zebra: include zebra nexthop debug in show runnMark Stapp2020-01-211-2/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add show output for 'debug zebra nexthop [detail]' category. Signed-off-by: Mark Stapp <mjs@voltanet.io>
* | | | | Merge pull request #5716 from opensourcerouting/bfdd-logRuss White2020-01-287-155/+20
|\ \ \ \ \ | | | | | | | | | | | | bfdd: remove logging shim & fix warnings
| * | | | | bfdd: fix format stringsDavid Lamparter2020-01-213-5/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ... now that we get warnings about them ... Signed-off-by: David Lamparter <equinox@diac24.net>
| * | | | | bfdd: remove logging shimDavid Lamparter2020-01-214-150/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This does exactly nothing, other than hiding format warnings... Signed-off-by: David Lamparter <equinox@diac24.net>
* | | | | | Merge pull request #5725 from ↵Russ White2020-01-282-0/+24
|\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | ton31337/feature/doc_for_set_metric_increment_decrement doc: Add documentation about OSPF(6) `set metric [+|-]metric` cmd
| * | | | | | doc: Add documentation about OSPF(6) `set metric [+|-]metric` cmdDonatas Abraitis2020-01-242-0/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
* | | | | | | Merge pull request #5731 from chiragshah6/mdevRuss White2020-01-281-16/+32
|\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | bgpd: fix memory leak in evpn json outpus II
| * | | | | | | bgpd: fix memory leak in evpn json outpus IIChirag Shah2020-01-271-16/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Two of the evpn show commands with json option has memory leak. 1) show bgp l2vpn evpn route vni all json 2) show bgp l2vpn evpn route esi json Before fix: ---------- Executed 'show bgp l2vpn evpn route vni all json' multiple times used ordinary blocks continue to increase. Note at the time of show command capture there were 22 evpn routes in vni evpn route table. Memory statistics for bgpd: System allocator statistics: Total heap allocated: 9152 KiB Holding block headers: 0 bytes Used small blocks: 0 bytes Used ordinary blocks: 7300 KiB Free small blocks: 1760 bytes Free ordinary blocks: 1852 KiB Ordinary blocks: 880 Small blocks: 51 Holding blocks: 0 Ticket:CM-27920 Reviewed By: Testing Done: After fix: --------- Executed 'show bgp l2vpn evpn route vni all json' multiple times Used ordinary blocks remains low. Memory statistics for bgpd: System allocator statistics: Total heap allocated: 8356 KiB Holding block headers: 0 bytes Used small blocks: 0 bytes Used ordinary blocks: 6492 KiB Free small blocks: 1840 bytes Free ordinary blocks: 1864 KiB Ordinary blocks: 939 Small blocks: 52 Holding blocks: 0 Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
* | | | | | | | Merge pull request #5673 from ↵Donatas Abraitis2020-01-281-6/+12
|\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | qlyoung/fix-zebra-ipset-iptable-memleak-on-disconnect zebra: fix ipset, iptable, ipset entry memleaks
| * | | | | | | | zebra: fix ipset, iptable, ipset entry memleaksQuentin Young2020-01-161-6/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Removed from hash, but not freed, on client disconnect. Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
* | | | | | | | | Merge pull request #5728 from opensourcerouting/move_rpm_to_python3Donatas Abraitis2020-01-283-33/+61
|\ \ \ \ \ \ \ \ \ | |_|/ / / / / / / |/| | | | | | | | Move rpm to python3
| * | | | | | | | doc: Update RedHat packaging description to use Python 3Martin Winter2020-01-251-7/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>
| * | | | | | | | redhat: Update frr.spec.in to move all systems to Python3 except CentOS 6Martin Winter2020-01-251-13/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>
| * | | | | | | | tools: Update generate_support_bundle.py to support Python 3Martin Winter2020-01-251-13/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>
* | | | | | | | | Merge pull request #5727 from chiragshah6/mdevDonatas Abraitis2020-01-271-15/+41
|\ \ \ \ \ \ \ \ \ | |_|_|/ / / / / / |/| | | | | | | | bgpd: fix memory leak in evpn json outputs
| * | | | | | | | bgpd: fix memory leak in evpn json outputsChirag Shah2020-01-241-15/+41
|/ / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Found memory leak in json output of evpn's route commands. After executing 'show bgp l2vpn evpn route type prefix json' and 'show bgp l2vpn evpn route type macip json' few times (6 times) with more than 600 routes in total seeing memory footprint for bgpd continue to grow. Memory statistics for bgpd: System allocator statistics: Total heap allocated: 12 MiB Holding block headers: 0 bytes Used small blocks: 0 bytes Used ordinary blocks: 8390 KiB Free small blocks: 1760 bytes Free ordinary blocks: 3762 KiB Ordinary blocks: 1161 Small blocks: 51 Holding blocks: 0 Ticket:CM-27920 Testing Done: After fix: excute few times, 'show bgp l2vpn evpn route type prefix json' and 'show bgp l2vpn evpn route type macip json' commands where used ordinary blocks (uordblks) is in steady state. Memory statistics for bgpd: System allocator statistics: Total heap allocated: 9968 KiB Holding block headers: 0 bytes Used small blocks: 0 bytes Used ordinary blocks: 6486 KiB Free small blocks: 1984 bytes Free ordinary blocks: 3482 KiB Ordinary blocks: 1110 Small blocks: 54 Holding blocks: 0 Memory statistics for bgpd: System allocator statistics: Total heap allocated: 10100 KiB Holding block headers: 0 bytes Used small blocks: 0 bytes Used ordinary blocks: 6488 KiB Free small blocks: 1984 bytes Free ordinary blocks: 3612 KiB Ordinary blocks: 1113 Small blocks: 54 Holding blocks: 0 Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>