Commit Graph

29152 Commits

Author SHA1 Message Date
Anuradha Karuppiah
7b0db0e43f lib, bgpd: changes for EAD-per-ES fragmentation
The EAD-per-ES route carries ECs for all the ES-EVI RTs. As the number of VNIs
increase all RTs do not fit into a standard BGP UPDATE (4K) so the route needs
to be fragmented.

Each fragment is associated with a separate RD and frag-id -
1. Local ES-per-EAD -
ES route table - {ES-frag-ID, ESI, ET=0xffffffff, VTEP-IP}
global route table - {RD-=ES-frag-RD, ESI, ET=0xffffffff}
2. Remote ES-per-EAD -
VNI route table - {ESI, ET=0xffffffff, VTEP-IP}
global route table - {RD-=ES-frag-RD, ESI, ET=0xffffffff}

Note: The fragment ID is abandoned in the per-VNI routing table. At this
point that is acceptable as we dont expect more than one-ES-per-EAD fragment
to be imported into the per-VNI routing table. But that may need to be
re-worked at a later point.

CLI changes (sample with 4 VNIs per-fragment for experimental pruposes) -
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
root@torm-11:mgmt:~# vtysh -c "show bgp l2vpn evpn es 03:44:38:39:ff:ff:01:00:00:01"
ESI: 03:44:38:39:ff:ff:01:00:00:01
 Type: LR
 RD: 27.0.0.21:3
 Originator-IP: 27.0.0.21
 Local ES DF preference: 50000
 VNI Count: 10
 Remote VNI Count: 10
 VRF Count: 3
 MACIP EVI Path Count: 33
 MACIP Global Path Count: 198
 Inconsistent VNI VTEP Count: 0
 Inconsistencies: -
 Fragments: >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
  27.0.0.21:3 EVIs: 4
  27.0.0.21:13 EVIs: 4
  27.0.0.21:22 EVIs: 2
 VTEPs:
  27.0.0.22 flags: EA df_alg: preference df_pref: 32767
  27.0.0.23 flags: EA df_alg: preference df_pref: 32767

root@torm-11:mgmt:~# vtysh -c "show bgp l2vpn evpn es-evi vni 1002 detail"
VNI: 1002 ESI: 03:44:38:39:ff:ff:01:00:00:01
 Type: LR
 ES fragment RD: 27.0.0.21:13 >>>>>>>>>>>>>>>>>>>>>>>>>
 Inconsistencies: -
 VTEPs: 27.0.0.22(EV),27.0.0.23(EV)

>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>

PS: The number of EVIs per-fragment has been set to 128 and may need further
tuning.

Ticket: #2632967

Signed-off-by: Anuradha Karuppiah <anuradhak@nvidia.com>
2022-03-18 07:37:06 -04:00
Anuradha Karuppiah
f4a5218dc6 bgpd: evpn mh changes to advertise EAD routes with user configured export-rt
This is an alternate to EAD route fragmenation and allows the user to limit
the route to a single UPDATE (<4K) independent of the number of EVIs.

Sample config (add one l2-vni RT from each VRF) -
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
!
router bgp 5556
 !
 address-family l2vpn evpn
  ead-es-route-target export 5556:1001
  ead-es-route-target export 5556:1004
  ead-es-route-target export 5556:1008
 exit-address-family
!
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>

Sample route
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
   Network          Next Hop            Metric LocPrf Weight Path
*> [1]:[4294967295]:[03:44:38:39:ff:ff:01:00:00:01]:[32]:[27.0.0.21]
                    27.0.0.21                          32768 i
                    ET:8 ESI-label-Rt:AA RT:5556:1001 RT:5556:1004 RT:5556:1008
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>

When configured, the ead-es-route-target is used instead of
the auto-generated version that includes all associated EVI's RTs.

Ticket: #2632967

Signed-off-by: Anuradha Karuppiah <anuradhak@nvidia.com>
2022-03-18 07:33:12 -04:00
Martin Winter
f76ce0e0e0
Merge pull request #10705 from kuldeepkash/cut_execution_time
tests: Adding EVPN-GR scenario to evpn_type5 suite
2022-03-17 16:33:59 -07:00
mobash-rasool
0cd8bce123
Merge pull request #10813 from opensourcerouting/fix/include_prune_stats_for_pim_traffic_interface
pimd: Include pruneTx/pruneRx for `show ip pim interface traffic WORD…
2022-03-17 23:36:30 +05:30
Donald Sharp
f2ad96a2e8
Merge pull request #10801 from mobash-rasool/fixes
tests: Adding database info in the script to ease debug
2022-03-17 09:50:03 -04:00
anlan_cs
e57e63eb40 bgpd: fix wrong check on local es routes
Importing local es routes should be skipped. But the check of it is a bit wrong.
It is ok that local es routes can't be imported, but importing local es will
wrongly enter `uninstall` procedure.

Just adjust this check to make it clear. Immediately return in the case
of importing local es routes.

Signed-off-by: anlan_cs <vic.lan@pica8.com>
2022-03-17 21:46:44 +08:00
Philippe Guibert
dedcdb892b pimd: add 'debug pim vxlan' when 'debug pim' is used
Reversely, negating 'debug pim' will disable vxlan debugging.

Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
2022-03-17 14:36:41 +01:00
Donald Sharp
79bfe9a1ba
Merge pull request #10812 from opensourcerouting/fix/pim_igmp_statistics_per_group
pimd: Show all groups matched by an arbitrary prefix for `pim rp-info`
2022-03-17 08:21:10 -04:00
Kuldeep Kashyap
77e578c90e tests: Fix topotests crash when KeyError found
1. Handle KeyError
2. logger object is defined in main function and its not not accessible
   in other functions so defined it in local functions.

Signed-off-by: Kuldeep Kashyap <kashyapk@vmware.com>
2022-03-17 17:29:43 +05:30
Manoj Naragund
7c20ee06d3 ospf6d: crash in ospf6_decrement_retrans_count.
Problem:
ospf6d crash is observed when lsack is received from the neighbour for
AS External LSA.

RCA:
The crash is observed in ospf6_decrement_retrans_count while decrementing
retransmit counter for the LSA when lsack is recived. This is because in
ospf6_flood_interace when new LSA is being added to the neighbour's list
the incrementing is happening on the received LSA instead of the already
present LSA in scope DB which is already carrying counters.

when this new LSA replaces the old one, the already present counters are
not copied on the new LSA this creates counter mismatch which results in
a crash when lsack is recevied due to counter going to negative.

Fix:
The fix involves following changes.
   1. In ospf6_flood_interace when LSA is being added to retrans list
      check if there is alreday lsa in the scoped db and increment
      the counter on that if present.
   2. In ospf6_lsdb_add copy the retrans counter from old to new lsa
      when its being replaced.

Signed-off-by: Manoj Naragund <mnaragund@vmware.com>
2022-03-17 16:58:02 +05:30
Donatas Abraitis
7d0bc72987 pimd: Include pruneTx/pruneRx for show ip pim interface traffic WORD json
```
exit1-debian-11# sh ip pim interface traffic eth2 json
{
  "eth2":{
    "name":"eth2",
    "state":"up",
    "address":"192.168.10.123",
    "index":4,
    "flagMulticast":true,
    "flagBroadcast":true,
    "lanDelayEnabled":true,
    "helloRx":2,
    "helloTx":2,
    "joinRx":0,
    "joinTx":1,
    "pruneRx":0,
    "pruneTx":0,
    "registerRx":0,
    "registerTx":0,
    "registerStopRx":0,
    "registerStopTx":0,
    "assertRx":0,
    "assertTx":0,
    "bsmRx":0,
    "bsmTx":0
  }
}
```

Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2022-03-17 10:00:02 +02:00
Donatas Abraitis
c07ddc3656 pimd: Show all groups matched by an arbitrary prefix for pim rp-info
```
r1# show ip pim rp-info
RP address       group/prefix-list   OIF               I am RP    Source   Group-Type
192.168.10.123   225.0.0.0/24        eth2              yes        Static   ASM
192.168.10.123   239.0.0.0/8         eth2              yes        Static   ASM
192.168.10.123   239.4.0.0/24        eth2              yes        Static   SSM

r1# show ip pim rp-info 239.4.0.0/25
RP address       group/prefix-list   OIF               I am RP    Source   Group-Type
192.168.10.123   239.0.0.0/8         eth2              yes        Static   ASM
192.168.10.123   239.4.0.0/24        eth2              yes        Static   SSM
```

Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2022-03-17 09:38:22 +02:00
Mobashshera Rasool
a73e89ddbc tests: Adding database information in ospfv3 testcase
Improving the test case to show database info as well
to help narrow down whether its a LSA origination problem or
route calculation problem in case of failures.

Signed-off-by: Mobashshera Rasool <mrasool@vmware.com>
2022-03-16 23:59:05 -07:00
Jafar Al-Gharaibeh
30ba0aaa7f
Merge pull request #10807 from donaldsharp/wheel_typo
lib: wheel's typo fix
2022-03-16 20:40:18 -05:00
Jafar Al-Gharaibeh
d6d0d718b0
Merge pull request #10806 from donaldsharp/dplane_fixup_for_lua
zebra: Fixup lua with new dplane ops
2022-03-16 16:38:01 -05:00
Donald Sharp
60cd8d3b14
Merge pull request #10790 from anlancs/zebra-adjust-flag
zebra: minor changes on "zebra_evpn_mac_gw_macip_add" function
2022-03-16 16:25:24 -04:00
ron
2674ba0ab0 pimd: fix igmp packet check
ip source 0.0.0.0 is OK (RFC 3376: 4.2.13.).

Signed-off-by: ron <lyq140hf2006@163.com>
2022-03-16 15:48:51 -04:00
ron
1c475815a8 pimd: fix igmp query packet
'Max Resp Time' in v2 query needs no encode (RFC 2236: 2.2.).

Signed-off-by: ron <lyq140hf2006@163.com>
2022-03-16 15:43:27 -04:00
ron
5e7d0337f6 lib: wheel's typo fix
The wheel data structure is a array of list pointers
but the alloc for it is using the sizeof (struct listnode *)
as the amount to allocate.  Even though the (struct listnode *)
and (struct list *) sizes are the same, let's list the correct
values.

Signed-off-by: ron <lyq140hf2006@163.com>
2022-03-16 15:32:50 -04:00
Donald Sharp
105271792d zebra: Fixup lua with new dplane ops
Commit: 5d41413833 added 3 new dplane ops:

DPLANE_OP_INTF_INSTALL
DPLANE_OP_INTF_UPDATE
DPLANE_OP_INTF_DELETE

The build system does not build lua so zebra_script.c
was not updated.  Update of course!

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2022-03-16 15:10:54 -04:00
Donald Sharp
335b15ebe0
Merge pull request #10797 from fabioantonini/sysrepo-2.0.41-support
support to sysrepo-2.0.41
2022-03-16 14:33:53 -04:00
Donald Sharp
5d056cbf25
Merge pull request #10803 from anlancs/bgpd-remove-dead-l2vpn
bgpd: remove dead code
2022-03-16 14:29:42 -04:00
Donald Sharp
b89c8bdc10
Merge pull request #10804 from LabNConsulting/chopps/coverity-1
lib: grpc: fix covevrity warnings
2022-03-16 14:29:18 -04:00
Jafar Al-Gharaibeh
51012eb636
Merge pull request #9262 from gpnaveen/ospfv3_basic_tests
tests: adding ospfv3 base cases.
2022-03-16 11:06:19 -05:00
Christian Hopps
ad6bd53692
lib: grpc: fix covevrity warnings
One uninit warning and one missing lock warning, both were OK but
let's make the tool happy.

Signed-off-by: Christian Hopps <chopps@labn.net>
2022-03-16 11:31:50 -04:00
David Lamparter
b928f0a6b7
Merge pull request #10755 from patrasar/enable_pimv6 2022-03-16 16:13:56 +01:00
Donald Sharp
79f4d05c7a
Merge pull request #10798 from Jafaral/topo-detect-pim
topotest: enable pim when detecting `ip pim` using unified config
2022-03-16 10:28:56 -04:00
anlan_cs
d58f056ab7 bgpd: remove dead code
`bgp_evpn_import_route_in_vrfs()` is special ( l2vpn ) form of
`install_uninstall_evpn_route() with `AFI_L2VPN` and `SAFI_EVPN` family.

No caller, just remove it.

Signed-off-by: anlan_cs <vic.lan@pica8.com>
2022-03-16 21:06:46 +08:00
Donald Sharp
bf1bf09616
Merge pull request #10653 from g-balaji1/pimv6-ssm
pim6d: pim_ssmpingd changes to support PIMv6
2022-03-16 08:40:29 -04:00
Donatas Abraitis
f1ea200891
Merge pull request #10763 from donaldsharp/plist_speedup
lib: Convert prefix_master->str to a RB Tree
2022-03-16 13:42:18 +02:00
Donald Sharp
c77ae9a943
Merge pull request #10799 from Jafaral/ospf-not-running
ospfd: better error messages when not enabled in a vrf
2022-03-16 07:38:28 -04:00
Balaji Gurudoss
1c56018f66 pim6d: Changes done in pim_ssmpingd to support v6
Signed-off-by: Balaji Gurudoss <G_Balaji1@dell.com>
2022-03-16 13:54:24 +05:30
sarita patra
8fc3ba676e pim6d: Enable protocol as VTYSH_PIM6D for pim6_cmd.c
Signed-off-by: sarita patra <saritap@vmware.com>
2022-03-15 23:16:41 -07:00
Jafar Al-Gharaibeh
fbaafa0082 ospfd: better error messages when not enabled in a vrf
before:
```
r1# show ip ospf vrf blue
% OSPF instance not found

r1# show ip ospf vrf default
% OSPF instance not found

r1# show ip ospf
% OSPF instance not found
```

after:
```
r1# show ip ospf vrf blue
% OSPF is not enabled in vrf blue

r1# show ip ospf vrf default
% OSPF is not enabled in vrf default

r1# show ip ospf
% OSPF is not enabled in vrf default
```

Signed-off-by: Jafar Al-Gharaibeh <jafar@atcorp.com>
2022-03-16 00:59:26 -05:00
Jafar Al-Gharaibeh
93a7f236ac topotest: enable pim when detecting pim using unified config
Signed-off-by: Jafar Al-Gharaibeh <jafar@atcorp.com>
2022-03-15 22:29:52 -05:00
nguggarigoud
d1b5fa5b9e tests: adding ospfv3 base cases.
Covers basic test case like route map, rte calc.

Signed-off-by: nguggarigoud <nguggarigoud@vmware.com>
2022-03-15 19:58:51 -07:00
Russ White
5d97021ba3
Merge pull request #10427 from sworleys/Protodown-Reason-Upstream
Add Support for Setting Protodown Reason Code
2022-03-15 19:58:16 -04:00
Donald Sharp
b975463458
Merge pull request #10643 from Jafaral/ospf-multi-vrf
tests: add a topotest for ospf, mutli vrf, and route leaking
2022-03-15 18:58:03 -04:00
Jafar Al-Gharaibeh
83e839d6b6 topotests: pytest mark bgpd
Signed-off-by: Jafar Al-Gharaibeh <jafar@atcorp.com>
2022-03-15 15:55:26 -05:00
Sri Mohana Singamsetty
3d58538a75
Merge pull request #10770 from chiragshah6/evpn_dev3
zebra: evpn disable remove l2vni from l3vni list
2022-03-15 12:32:22 -07:00
Donald Sharp
2ea93eb023
Merge pull request #10580 from leonshaw/fix/link-ns
zebra: Lookup linked interface in link netns
2022-03-15 15:23:18 -04:00
Donald Sharp
ed03d4d03b
Merge pull request #10791 from opensourcerouting/feature/igmp_stats_total_received_message
pimd: Add additional IGMP stats (peak number of groups)
2022-03-15 15:14:37 -04:00
Donald Sharp
30119c81d2
Merge pull request #10794 from opensourcerouting/fix/do_not_print_empty_stats_for_non_existing_interface
pimd: Return empty JSON if we query non existing interface for IGMP s…
2022-03-15 15:13:23 -04:00
Rafael F. Zalamena
1c9bd416f4 doc: document yang show operational data
Add missing documentation for the command and describe the available
options.

Signed-off-by: Rafael F. Zalamena <rzalamena@opensourcerouting.org>
2022-03-15 15:32:34 -03:00
Fabio Antonini
7b73f3db94 lib: support to sysrepo-2.0.41
northbound_sysrepo.c fixed to use the newer APIs from sysrepo 2.0.41

Signed-off-by: Fabio Antonini <f.antonini@tiesse.com>
2022-03-15 16:30:00 +01:00
Donatas Abraitis
42982834d4 pimd: Return empty JSON if we query non existing interface for IGMP stats
Now we return all zeroed stats, which seems wrong. Handle the same way, as
with PIM interfaces. Return empty JSON and a warning for VTYSH.

```
exit1-debian-11# sh ip igmp statistics interface belekas
% No such interface
exit1-debian-11# sh ip igmp statistics interface belekas json
{
}
```

Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
2022-03-15 17:08:35 +02:00
Donatas Abraitis
a191345424
Merge pull request #10792 from donaldsharp/pim_blargle
Fix up #6058
2022-03-15 16:22:37 +02:00
Donald Sharp
6a68f0ecab
Merge pull request #10796 from anlancs/bgpd-zebra-newline
bgpd: add new line for prompt of "no router bgp"
2022-03-15 09:40:44 -04:00
anlan_cs
be125e6fe5 bgpd: add new line for prompt of "no router bgp"
Simple prompt issue.
"no router bgp <ASN>" is ok, but "no router bgp" without <ASN> missed "\n".

Signed-off-by: anlan_cs <vic.lan@pica8.com>
2022-03-15 09:55:28 -04:00
Donald Sharp
7344eb1f62
Merge pull request #10739 from LabNConsulting/chopps/fixgrpc-reorg
grpc, lib: grpc cleanup/reorg
2022-03-15 09:10:03 -04:00