Commit Graph

38195 Commits

Author SHA1 Message Date
Donna Sharp
453154497e zebra: allow retrieval of ip forwarding state
There was no ability to retrieve the ip-forwarding state
of zebra.  Add this to yang under the state container.

Signed-off-by: Donna Sharp <dksharp5@gmail.com>
2025-03-01 14:39:07 -05:00
Christian Hopps
311bd23ccb
Merge pull request #18236 from donaldsharp/zebra_multipath_num_operational_data
zebra: Add operational retrieval of Multipath Number
2025-02-24 12:33:34 -05:00
Donald Sharp
03ebdc3c4a zebra: Add operational retrieval of Multipath Number
The multipath number specified is not available through
the yang data and is not retrievable.  Make it so.
At this point in time do not allow this to be set from
yang.  Perhaps in the future.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2025-02-23 11:14:47 -05:00
Jafar Al-Gharaibeh
3f290c97e8
Merge pull request #18231 from LabNConsulting/chopps/fix-case-choice-queries
Fix oper-state queries that involve choice/case nodes
2025-02-22 14:06:37 -06:00
Christian Hopps
73df7da40a tests: add unit-test for choice/case node queries
Signed-off-by: Christian Hopps <chopps@labn.net>
2025-02-22 16:25:31 +00:00
Christian Hopps
b9ff10b086 lib: nb: fix oper-state queries that involve choice/case nodes
Signed-off-by: Christian Hopps <chopps@labn.net>
2025-02-22 16:25:31 +00:00
Jafar Al-Gharaibeh
67985ba8ec
Merge pull request #18210 from donaldsharp/fix_bestpath_evpn_issue
bgpd: remove dmed check not required in bestpath selection
2025-02-21 17:11:13 -06:00
Jafar Al-Gharaibeh
7719645c69
Merge pull request #18224 from LabNConsulting/chopps/fe-client-docstrings
tests: add docstrings to frontend mgmtd client
2025-02-21 17:07:26 -06:00
Jafar Al-Gharaibeh
aa4bd0839f
Merge pull request #18223 from LabNConsulting/chopps/doc-mgmt-update
doc: update mgmtd list of converted
2025-02-21 17:07:02 -06:00
Christian Hopps
84ab204ebe tests: add docstrings to frontend mgmtd client
Signed-off-by: Christian Hopps <chopps@labn.net>
2025-02-21 18:47:15 +00:00
Christian Hopps
30f8de4417 doc: update mgmtd list of converted
Signed-off-by: Christian Hopps <chopps@labn.net>
2025-02-21 18:44:51 +00:00
Donald Sharp
eb6f49ff1d
Merge pull request #18218 from y-bharath14/srib-yang-v3
yang: Corrected Pyang errors or warnings
2025-02-21 11:18:03 -05:00
Y Bharath
a05799bd8b yang: Corrected Pyang errors or warnings
Corrected Pyang errors or warnings at frr-route-types.yang file

Signed-off-by: y-bharath14 <y.bharath@samsung.com>
2025-02-21 15:03:31 +05:30
Donatas Abraitis
7e34722472
Merge pull request #18213 from donaldsharp/add_membership
*: Remove unneeded IPV6_JOIN|LEAVE_GROUP
2025-02-21 11:10:57 +02:00
Donald Sharp
f7fd861fda *: Remove unneeded IPV6_JOIN|LEAVE_GROUP
Headers include this stuff now.  No need for it
in our code base.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2025-02-20 16:16:35 -05:00
Donald Sharp
83ad94694b bgpd: remove dmed check not required in bestpath selection
As part of the upstream master commit (f3575f61c7 bgpd: Sort the
bgp_path_inf) the snippet of the code for dmed check condition
left out, which leads to an issue of selecting incorrect bestpath.

As an example:

During the bestpath selection local route looses to another path due
to dmed condition being hit.

The snippet of the logs:

2025/02/20 03:06:20.131441 BGP: [JW7VP-K1YVV]
[2]:[0]:[48]:[00:92:00:00:00:10](VRF default): Comparing path
27.0.0.7 flags Valid  with path Static announcement flags Selected Valid Attr Changed Unsorted
2025/02/20 03:06:20.131445 BGP: [SYTDR-QV6X9] [2]:[0]:[48]:[00:92:00:00:00:10]: path 27.0.0.7 loses to path Static announcement as ES 03:44:38:39:ff:ff:02:00:00:01 is same and local
2025/02/20 03:06:20.131452 BGP: [JW7VP-K1YVV] [2]:[0]:[48]:[00:92:00:00:00:10](VRF default): Comparing path 27.0.0.8 flags Valid  with path Static announcement flags Selected Valid Attr Changed Unsorted
2025/02/20 03:06:20.131456 BGP: [SYTDR-QV6X9] [2]:[0]:[48]:[00:92:00:00:00:10]: path 27.0.0.8 loses to path Static announcement as ES 03:44:38:39:ff:ff:02:00:00:01 is same and local
2025/02/20 03:06:20.131458 BGP: [WEWEC-8SE72] [2]:[0]:[48]:[00:92:00:00:00:10](VRF default): path Static announcement is the bestpath from AS 0   <<<< static is best
2025/02/20 03:06:20.131463 BGP: [Z3A78-GM3G5] bgp_best_selection: [2]:[0]:[48]:[00:92:00:00:00:10](VRF default) pi 27.0.0.7 dmed
2025/02/20 03:06:20.131467 BGP: [Z3A78-GM3G5] bgp_best_selection: [2]:[0]:[48]:[00:92:00:00:00:10](VRF default) pi 27.0.0.8 dmed
2025/02/20 03:06:20.131471 BGP: [N6CTF-2RSKS] [2]:[0]:[48]:[00:92:00:00:00:10](VRF default): After path selection, newbest is path 27.0.0.7 oldbest was Static announce

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2025-02-20 14:28:15 -05:00
Mark Stapp
bf8e4a3b83
Merge pull request #17666 from routingrocks/pim_fhr_rp
pimd: During prefix-list update, behave as PIM_UPSTREAM_NOTJOINED sta…
2025-02-20 13:41:10 -05:00
Jafar Al-Gharaibeh
fc6b0413fa
Merge pull request #14227 from routingrocks/pim_data_fix
pimd: Fix for data packet loss when FHR is LHR and RP
2025-02-20 10:56:05 -06:00
Donatas Abraitis
dad880201b
Merge pull request #18194 from donaldsharp/more_orf_funniness
bgpd: Fix another crash in orf
2025-02-19 22:34:43 +02:00
Donatas Abraitis
1508bbdb59
Merge pull request #18197 from donaldsharp/ospf_passive_test_removal
tests: Remove warning about passive command
2025-02-19 22:33:10 +02:00
Jafar Al-Gharaibeh
ce64c34f12
Merge pull request #17914 from opensourcerouting/pim-nb-filter
pimd: filter neighbors by address
2025-02-19 13:39:12 -06:00
Donald Sharp
d0a0e7061c tests: Remove warning about passive command
Several tests have warnings about the passive
command and how to use it.  Let's address this.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2025-02-19 08:04:54 -05:00
Rafael Zalamena
c92061b8db doc: add allowed-neighbors command
Let users know about new command to filter PIM sessions based on peer
address.

Signed-off-by: Rafael Zalamena <rzalamena@opensourcerouting.org>
2025-02-19 09:56:09 -03:00
Rafael Zalamena
47daa3e53f topotests: test PIM neighbor filtering
Add new topology for testing neighbor filtering and more features in
the future.

Signed-off-by: Rafael Zalamena <rzalamena@opensourcerouting.org>
2025-02-19 09:56:08 -03:00
David Lamparter
b84493132c pimd: allow restricting neighbors per interface
Just filter incoming packets against a specified prefix-list.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2025-02-19 09:49:06 -03:00
Donald Sharp
66434fc2ee
Merge pull request #18108 from opensourcerouting/fix/zebra_no_vni_validation
zebra: Do not flush an existing vni configuration trying to remove wrong vni
2025-02-19 07:22:03 -05:00
Donald Sharp
23fc4ce666
Merge pull request #18111 from opensourcerouting/gmp-leave
pimd,pim6d: support IGMPv2/MLDv1 immediate leave
2025-02-19 07:21:00 -05:00
Donald Sharp
ffff1a1760 bgpd: Fix another crash in orf
I was pointed at yet another crash in the orf code.  I think it
stems from basicaly the same problem as the last one.  Let's just
make sure that the orf_plist is handled appropriately.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2025-02-19 06:29:36 -05:00
Russ White
5082cab809
Merge pull request #18164 from Pdoijode/pdoijode/staticd-nht-register
staticd: Failed to register nexthop after networking restart
2025-02-18 09:18:29 -05:00
Russ White
77ab298369
Merge pull request #18189 from Shbinging/fix_ip_rip_split-horizon
doc: correct `ip rip split-horizon` command in the documentation
2025-02-18 09:16:46 -05:00
Russ White
3eedab0928
Merge pull request #18095 from opensourcerouting/zebra-check-class-e
Use ipv4 class E addresses (240.0.0.0/4) as connected routes by default
2025-02-18 08:31:31 -05:00
Carmine Scarpitta
b85cf812c2
Merge pull request #17957 from pguibert6WIND/codepoint_add_some_flavors
isisd, lib: add some codepoints usually shared with other vendors
2025-02-18 11:06:51 +01:00
Shbinging
5256a8b5c0 doc: correct ip rip split-horizon command in the RIP documentation.
The previous version incorrectly spelled the command as `ip split-horizon`. The correct command is `ip rip split-horizon`, as indicated in the code at line 675 of rip_cli.c.

Signed-off-by: Shbinging <bingshui@smail.nju.edu.cn>
2025-02-18 15:37:19 +08:00
Jafar Al-Gharaibeh
4315f2eedb
Merge pull request #18082 from LabNConsulting/chopps/fix-yang-config-destroy
lib: nb: call child destroy CBs when YANG container is deleted
2025-02-17 20:35:49 -06:00
Donatas Abraitis
b6ae929c1d
Merge pull request #16796 from gtataranni/feat/logfmt
tools: add logfmt option for frr-reload.py
2025-02-17 23:02:27 +02:00
Giovanni Tataranni
44a6e0dfed tools: add logfmt option for frr-reload.py
Add the option of printing logs in logfmt format.

Additional machine readable information can be printed via the `extra`
argument.
Example:
```python
log.debug("exit context"), extra={"line": line, "ctx_keys": ctx_keys})

log.error(f"Failed to execute command {' '.join(cmd)}", extra={"cmd": cmd})
```

Signed-off-by: Giovanni Tataranni <g.tataranni@gmail.com>
2025-02-17 17:33:28 +01:00
Christian Hopps
e241882d8f
Merge pull request #18139 from y-bharath14/srib-yang-v2
yang: Default value for a key leaf to be ignored
2025-02-17 05:13:57 -05:00
Donald Sharp
197d12ffba
Merge pull request #18187 from cscarpitta/fix/fix_srv6_encap_src_addr_test_failures
tests: Fix intermittent failures in `srv6_encap_src_addr` topotest
2025-02-16 08:09:18 -05:00
Carmine Scarpitta
c621b5e759 tests: Fix intermittent failures in srv6_encap_src_addr topotest
The `srv6_encap_src_addr` runs a vtysh command to configure the SRv6
encapsulation source address and then immediately invokes an iproute2
command to verify that zebra has set this address in the kernel. There
is no wait between the two operations and the verification is attempted
only once. If the topotest does not find the expected address it fails
immediately.

The problem is that when topotest is run on a heavyily loaded system,
it can take some time for zebra to set the address in the kernel.
In this case, when the topotest checks the kernel address right after
running the vtysh command, it doesn't find the expected address because
zebra hasn't set it yet.

This commit gives zebra some time to configure the address. It keeps to
check that the address is the expected one for about 1 minute. If after
1 minute the address is not the expected one then the test fails.

Signed-off-by: Carmine Scarpitta <cscarpit@cisco.com>
2025-02-16 11:14:54 +01:00
Carmine Scarpitta
206a647ea6 tests: Increase retry timeout in srv6_encap_src_addr topotest
The `srv6_encap_src_addr` topotest uses a waiting time that is too
small. For this reason during startup it prints a warning:

```
2025-02-16 09:23:47,704 WARNING: topo: Waiting time is too small (count=10, wait=1), using default values (count=20, wait=3)
```

This commit increases the waiting time to fix the warning.

Signed-off-by: Carmine Scarpitta <cscarpit@cisco.com>
2025-02-16 11:01:01 +01:00
Carmine Scarpitta
d8483f410e tests: Do not load bgpd config in srv6_encap_src_addr topotest
The `srv6_encap_src_addr` topotest tries to load bgpd.conf file that
does not exist, which produces the following warning:

```
2025-02-16 09:23:35,151 WARNING: topo: missing config 'r1' for '/media/frr/tests/topotests/srv6_encap_src_addr/r1/bgpd.conf' creating empty file '/etc/frr/bgpd.conf'
```

Since this topotest doesn't actually use bgpd, there's no point in
loading the config file.

Signed-off-by: Carmine Scarpitta <cscarpit@cisco.com>
2025-02-16 11:01:01 +01:00
Carmine Scarpitta
cb38a6f962 tests: Do not load sharpd config in srv6_encap_src_addr topotest
The `srv6_encap_src_addr` topotest tries to load sharpd.conf file that
does not exist, which produces the following warning:

```
2025-02-16 09:23:35,151 WARNING: topo: missing config 'r1' for '/media/frr/tests/topotests/srv6_encap_src_addr/r1/sharpd.conf' creating empty file '/etc/frr/sharpd.conf'
```

Since this topotest doesn't actually use sharpd, there's no point in
loading the config file.

Signed-off-by: Carmine Scarpitta <cscarpit@cisco.com>
2025-02-16 11:00:36 +01:00
Carmine Scarpitta
f2bf1f95b3 tests: Remove bgpd marker in srv6_encap_src_addr topotest
The `srv6_encap_src_addr` does not use bgp. As such, it should not have
bgpd marker.

Signed-off-by: Carmine Scarpitta <cscarpit@cisco.com>
2025-02-16 09:51:22 +01:00
Donatas Abraitis
88f4bb2761
Merge pull request #18109 from mjstapp/fix_evpn_vty_rt
bgpd: fix vty output of evpn route-target AS4
2025-02-15 22:11:00 +02:00
Donald Sharp
b2c960a19d
Merge pull request #18178 from cscarpitta/fix/isis_request_srv6_locator
isisd: Request SRv6 locator after zebra connection
2025-02-15 09:39:04 -05:00
Donald Sharp
ca46b52436
Merge pull request #18163 from opensourcerouting/sharpd-crash-command
sharpd: add `crashme` commands
2025-02-15 09:17:10 -05:00
Carmine Scarpitta
f02dba19d2 isisd: Request SRv6 locator after zebra connection
When SRv6 is enabled and an SRv6 locator is specified in the IS-IS
configuration, IS-IS may attempt to request SRv6 locator information from
zebra before the connection is fully established. If this occurs, the
request fails with the following error:

```
2025/02/14 21:41:20 ISIS: [HR66R-TWQYD][EC 100663302] srv6_manager_get_locator: invalid zclient socket
````

As a result, IS-IS is unable to obtain the locator information,
preventing SRv6 from working.

This commit fixes the issue by ensuring IS-IS requests SRv6 locator
information once the connection with zebra is successfully established.

Signed-off-by: Carmine Scarpitta <cscarpit@cisco.com>
2025-02-15 10:39:40 +01:00
Carmine Scarpitta
0b76fb3c13 isisd: Add helper function to request SRv6 locator information
This commit adds a function that iterates over all IS-IS areas and asks
the SRv6 Manager for information about the configured locators.

Signed-off-by: Carmine Scarpitta <cscarpit@cisco.com>
2025-02-15 10:39:30 +01:00
David Lamparter
050989d2fb
Merge pull request #18160 from donaldsharp/orf_plist_argie_bargie
bgpd: When removing the prefix list drop the pointer
2025-02-14 22:28:09 +01:00
Donatas Abraitis
d8ea27a188
Merge pull request #18122 from louis-6wind/bgp_cleanup_table-factorize
bgpd: factorize bgp_table_cleanup()
2025-02-14 23:08:51 +02:00