summaryrefslogtreecommitdiffstats
path: root/bgpd (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Merge pull request #4331 from patrasar/bgp_cli_fixDonald Sharp2019-06-221-4/+3
|\ | | | | bgpd : add prefix-length in show ip bgp neighbor advertised routes key
| * bgpd : add prefix-length in show ip bgp neighbor advertised routes keySarita Patra2019-06-111-4/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Issue: ip route 15.1.1.0/24 10.112.158.15 ip route 15.1.1.0/32 10.112.158.15 Brought up ebgp session between two FRR routers and redistributed static routes via BGP and verfied the advertising routes in the peer. Verify the command "show ip bgp neighbors <neighbor address> advertised-routes json". It only shows 15.1.1.0/32 route details. Root casue: For both the routes "15.1.1.0/24" and "15.1.1.0/32" the advertised routes key is the prefix i.e. "15.1.1.0". Fix: Modify the key to prefix/prefix-length. Signed-off-by: Sarita Patra <saritap@vmware.com>
* | Merge pull request #4262 from vishaldhingra/lcomm_1Donald Sharp2019-06-225-21/+114
|\ \ | | | | | | bgpd : Support for exact-match in match clause for lcommunity
| * | bgpd : Support for exact-match in match clause for lcommunityvishaldhingra2019-06-192-14/+50
| | | | | | | | | | | | | | | | | | | | | | | | | | | FRR has a provision to give exact-match in match clause for standard community, but this option is missing for lcommunity. Part 3 : show related changes for match clause Signed-off-by: vishaldhingra <vdhingra@vmware.com>
| * | bgpd : Support for exact-match in match clause for lcommunityvishaldhingra2019-06-191-7/+36
| | | | | | | | | | | | | | | | | | | | | | | | | | | FRR has a provision to give exact-match in match clause for standard community, but this option is missing for lcommunity. Part 2 : CLI related changes for match clause Signed-off-by: vishaldhingra <vdhingra@vmware.com>
| * | bgpd : Support for exact-match in match clause for lcommunityvishaldhingra2019-06-192-0/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | FRR has a provision to give exact-match in match clause for standard community, but this option is missing for lcommunity. Part 1 : Added support in clist lib Signed-off-by: vishaldhingra <vdhingra@vmware.com>
* | | Merge pull request #4508 from kssoman/updgrpDonald Sharp2019-06-221-2/+9
|\ \ \ | | | | | | | | bgpd: Process core when prefix list is applied
| * | | bgpd: Process core when prefix list is appliedSoman K S2019-06-131-2/+9
| | |/ | |/| | | | | | | | | | | | | | | | * Added debug logs and assert to get more information when bgp process core is observed Signed-off-by: Soman K S <somanks@vmware.com>
* | | lib: use MTYPE_STATICDavid Lamparter2019-06-211-8/+0
| | | | | | | | | | | | Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
* | | Merge pull request #4470 from donaldsharp/bgp_mac_rescanSri Mohana Singamsetty2019-06-202-15/+37
|\ \ \ | | | | | | | | Bgp mac rescan
| * | | bgpd: Remove unused count variable in mac_rescan_table functionDonald Sharp2019-06-181-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | The variable count was being incremented but never used. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
| * | | bgpd: Fix crash when rd has no dataDonald Sharp2019-06-181-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There exists a state where we may have a rd node but no individual evpn prefix nodes in the two level table: (gdb) bt at bgpd/bgp_evpn_vty.c:1190 filter=FILTER_RELAXED) at lib/command.c:1060 at lib/command.c:1119 vtysh=vtysh@entry=0) at lib/command.c:1273 (gdb) f 5 at bgpd/bgp_evpn_vty.c:1190 1190 bgpd/bgp_evpn_vty.c: No such file or directory. (gdb) p buf $1 = "[2]:[0]:[48]:[00:00:00:00:00:00]", '\000' <repeats 240 times>... (gdb) p json_nroute $2 = (json_object *) 0x0 (gdb) p rd_header $3 = 1 (gdb) p buf $4 = "[2]:[0]:[48]:[00:00:00:00:00:00]", '\000' <repeats 240 times>... (gdb) I'm not entirely sure that this is not a `different` problem in that the rd node should have been removed. But I think preventing the crash in a show command is probably the right thing to do here. Fixes: #4501 Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
| * | | bgpd: Mac rescan on interface up/down efficency improvementsDonald Sharp2019-06-181-11/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On interface up/down, bgp stores the mac address of the interface in a bgp_mac_hash table entry and then initiates a rescan of the evpn l2vpn table. The problem with this scan is that it is looking at every item in the table when only 1 mac has changed. So every up/down event causes some major trauma in the bgp_update processing. Modify the mac scanning such that we know the mac that is changed and as such we should reprocess those entries only. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
* | | | Merge pull request #4549 from donaldsharp/multiple_instanceSri Mohana Singamsetty2019-06-207-20/+2
|\ \ \ \ | |_|_|/ |/| | | Multiple instance
| * | | doc: Update documentation about multiple-instanceDonald Sharp2019-06-181-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | The `bgp multiple-instance` command has been removed but we did not properly update the documentation. Let's do so. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
| * | | bgpd: BGP_ERR_MULTIPLE_INSTANCE_NOT_SET is an impossible conditionDonald Sharp2019-06-186-19/+2
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This code is not returned anywhere in the system as that bgp is by default multiple-instance 'only' now. So remove the last remaining bits of it from the code base. Remove BGP_ERR_MULTIPLE_INSTANCE_USED too. Make bgp_get explicitly return BGP_SUCCESS instead of 0. Remove the multi-instance error code too. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
* | | Merge pull request #4260 from vishaldhingra/lcommDonald Sharp2019-06-191-5/+15
|\ \ \ | | | | | | | | bgpd: Added the as-set option for IPV6 agg. route
| * | | bgpd: Added the as-set option for IPV6 agg. routevishaldhingra2019-06-171-5/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | FRR has no option for the as-set for aggregate route under IPV6 address family. Added the command to configure the as-set option for IPV6. Signed-off-by: vishaldhingra <vdhingra@vmware.com>
* | | | Merge pull request #4513 from chiragshah6/evpn_dev1Sri Mohana Singamsetty2019-06-181-0/+18
|\ \ \ \ | | | | | | | | | | bgpd: skip evpn remove marked routes from rescan
| * | | | bgpd: skip evpn remove marked routes from rescanChirag Shah2019-06-131-0/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Skip evpn routes marked for removed from rescan list when an interface is flapped. Ticket:CM-24933 Testing Done: Validated in a scenario where evpn route is marked for remove as bgp evpn withdrawal is received. Due to link flap (frr restart of downstream router), the route was considered for readd via bgp_update. With this fix, the remove marked routes are skipped from update. Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
* | | | | bgpd: Fix memleak of Mac Hash String upon insertionDonald Sharp2019-06-181-1/+3
| |_|/ / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If we get a callback for a interface change but we do not actually have to move the mac entry in the hash then we were accidently leaking the Mac Hash String all over ourselves. Messy Messy! Ticket: CM-25351 Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
* | | | Merge pull request #4514 from opensourcerouting/warnings-20190612Donald Sharp2019-06-174-24/+17
|\ \ \ \ | | | | | | | | | | *: kill more warnings
| * | | | bgpd: fix uninitialized & wrong endian NOTIFYDavid Lamparter2019-06-131-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | notify_data_remote_as4 would contain garbage if optlen == 0, and also as4 is in host byte order while the notify needs network byte order. Signed-off-by: David Lamparter <equinox@diac24.net>
| * | | | bgpd/rfapi: fix clang-SA warningDavid Lamparter2019-06-131-1/+1
| | | | | | | | | | | | | | | | | | | | Signed-off-by: David Lamparter <equinox@diac24.net>
| * | | | *: config.h or zebra.h is the first #includeDavid Lamparter2019-06-132-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is mostly relevant for Solaris, where config.h sets up some #define that affect overall header behaviour, so it needs to be before anything else. Signed-off-by: David Lamparter <equinox@diac24.net>
| * | | | bgpd: fix clang format warningDavid Lamparter2019-06-131-21/+7
| |/ / / | | | | | | | | | | | | | | | | | | | | ... by simplifying the code to use %pI6 instead. Signed-off-by: David Lamparter <equinox@diac24.net>
* | | | Merge pull request #4505 from ton31337/feature/autocomplete_bgp_peer-groupQuentin Young2019-06-172-14/+14
|\ \ \ \ | | | | | | | | | | bgpd: List all groups dynamically for commands with peer-group
| * | | | bgpd: List all groups dynamically for commands with peer-groupDonatas Abraitis2019-06-112-14/+14
| | |_|/ | |/| | | | | | | | | | Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
* | | | bgpd: show bgp vrfs formattingChirag Shah2019-06-141-7/+18
| |_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | show bgp vrfs command is formatted with couple of things. show bgp vrfs to inclue bgp vrf instance's SVI interface. Move L3vni, RMAC and SVI value in next line. Ticket:CM-25317 Reviewed By:CCR-8816 Testing Done: New Output: TORS1# show bgp vrfs Type Id routerId #PeersVfg #PeersEstb Name L3-VNI RouterMAC Interface DFLT 0 27.0.0.15 2 2 default 0 00:00:00:00:00:00 unknown VRF 31 45.0.8.2 0 0 vrf3 4003 00:02:00:00:00:4e vlan4003 VRF 35 45.0.2.2 0 0 vrf1 4001 00:02:00:00:00:4e vlan4001 VRF 25 45.0.6.2 0 0 vrf2 4002 00:02:00:00:00:4e vlan4002 Total number of VRFs (including default): 4 Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
* | | Merge pull request #4512 from mjstapp/fix_bgp_auto_ridSri Mohana Singamsetty2019-06-143-10/+32
|\ \ \ | | | | | | | | bgpd: auto router-id should not change configured vpn RD/RT
| * | | bgpd: auto router-id should not change configured vpn RD/RTMark Stapp2019-06-123-10/+32
| |/ / | | | | | | | | | | | | | | | | | | | | | A router-id change that isn't explicitly configured (a change from zebra, for example) should not replace a configured vpn RD/RT. Signed-off-by: Mark Stapp <mjs@voltanet.io>
* | | Merge pull request #4499 from kssoman/coreLou Berger2019-06-133-0/+11
|\ \ \ | | | | | | | | bgpd: Process core when bgp instance is deleted
| * | | bgpd: Process core when bgp instance is deletedSoman K S2019-06-113-0/+11
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | * When the bgp is being deleted and routes are in clear workqueue and new aggregate address being allocated * Added flag BGP_FLAG_DELETE_IN_PROGRESS in bgp structure to bgp instance is being deleted * When adding aggregate route check this flag and peer_self is valid Signed-off-by: Soman K S <somanks@vmware.com>
* | | bgpd, lib: Add iana_afi2str and iana_safi2str for eye pleasing strings (#4439)David Lamparter2019-06-134-41/+60
|\ \ \ | |_|/ |/| | bgpd, lib: Add iana_afi2str and iana_safi2str for eye pleasing strings
| * | lib, bgpd: Create iana_afi.h for storing iana_afi/safi enumsDonald Sharp2019-06-021-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The iana_afi_t and iana_safi_t were being created in zebra.h and zebra.h is a bit of a dumping ground. When the iana_afi2str and iana_safi2str functions were created, it was correctly pointed out that we should just use the internal afi_t and safi_t 2str functions but to do that we would need to include prefix.h in zebra.h. Which really is not the right thing to do. This tells us that we need to break out this code into it's own header. Move to iana_afi.h the enums and specific functions and remove from zebra. Convert to using the afi2str and safi2str functions. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
| * | bgpd, lib: Add iana_afi2str and iana_safi2str for eye pleasing stringsDonald Sharp2019-06-023-41/+59
| | | | | | | | | | | | | | | | | | | | | Modify the code such that we can auto turn the iana values of afi and safi to pleasant to read strings. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
* | | Merge pull request #3509 from faickermo/fix_bgp_ipv6_default_nexthopDonald Sharp2019-06-121-0/+1
|\ \ \ | |_|/ |/| | bgpd: Set bgp default nexthop value of IPv6
| * | bgpd: Set bgp default nexthop value of IPv6Faicker Mo2019-05-311-0/+1
| |/ | | | | | | | | | | | | | | | | | | Set the bgp default nexthop value of IPv6 to the local ipv6 addr of the tcp connection like IPv4. Fixed the problem of route with empty nexthop advertised to the peer when zebra is not running. * bgp_zebra.c: (bgp_zebra_nexthop_set) Set IPv6 bgp default nexthop value. Signed-off-by: Faicker Mo <faicker.mo@ucloud.cn>
* | bgpd: add l2vpn evpn to afi safi parse utilityDon Slice2019-06-101-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | Problem reported with "clear bgp l2vpn evpn * soft" clearing the wrong afi/safi (cleared ipv6 unicast instead). Determined that the calling function used the argv_find_and_parse_afi/safi routines to determine the correct afi/safi to pass on. Since l2vpn/evpn were missing from the lookup, the command defaulted to ipv6 unicast. This fix just adds that afi/safi to the lookup routine. Ticket: CM-25167 Signed-off-by: Don Slice <dslice@cumulusnetworks.com>
* | lib,bgpd,babeld,ripngd,nhrpd,bfdd: clean up SA warningsMark Stapp2019-06-062-1/+9
| | | | | | | | | | | | Clean up several SA warnings. Signed-off-by: Mark Stapp <mjs@voltanet.io>
* | Merge pull request #3555 from pguibert6WIND/bgp_wording_vrf_tableRuss White2019-06-041-6/+8
|\ \ | | | | | | bgpd: use the wording vrf instead of table
| * | bgpd: use the wording vrf instead of tablePhilippe Guibert2019-01-071-6/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | in bgp, even if the main vrf implementation relies on tables, the fact is some vrf implementation rely on network namespaces, and then the table used is the default table from the network namespace. Use the wording vrf instead of table. Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
* | | Merge pull request #4455 from lkrishnamoor/revertDonald Sharp2019-06-045-197/+203
|\ \ \ | | | | | | | | Revert of PR 4078 and PR 4315
| * | | Revert of PR 4078 and PR 4315Lakshman Krishnamoorthy2019-06-045-197/+203
| | | | | | | | | | | | | | | | Signed-off-by: Lakshman Krishnamoorthy <lkrishnamoor@vmware.com>
* | | | bgpd: Remove BGP_OPT_CONFIG_CISCODonald Sharp2019-06-033-108/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The BGP_OPT_CONFIG_CISCO command could no longer be set as such remove it from the system as a viable option to be used. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
* | | | bgpd: Remove `[no] bgp config-type <cisco|zebra>`Donald Sharp2019-06-031-42/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This command has been deprecated for a year and no-one has complained. Remove from system. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
* | | | bgpd: Remove BGP_OPT_MULTIPLE_INSTANCE flagDonald Sharp2019-06-033-64/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since we no-longer allow you to select multiple-instance or not from the cli, let's completely remove the flag as well. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
* | | | bgpd: Remove deprecated '[no] bgp multiple-instance' commandDonald Sharp2019-06-031-39/+0
|/ / / | | | | | | | | | | | | | | | Remove this command from the cli. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
* | | Merge pull request #4345 from NaveenThanikachalam/route_map_depDonald Sharp2019-06-032-2/+3
|\ \ \ | | | | | | | | lib: Changes made to dependencies of a route-map do not take effect dynamically.
| * | | lib: Changes made to dependencies of a r-map do not take effect.Naveen Thanikachalam2019-05-312-2/+3
| | |/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | Say, more than one sequence of a route-map uses the same named entity in its match clause. After that entity is removed from any one of the route-map sequences, any further changes made to that entity doesn't dynamically take effect. A reference counter, that allows the named entity to keep a count of the route-maps dependent on it, has been introduced to address this issue. Signed-off-by: NaveenThanikachalam <nthanikachal@vmware.com>