]> git.proxmox.com Git - mirror_frr.git/log
mirror_frr.git
4 years agozebra: remove typedef rib_update_event_t from system
Donald Sharp [Thu, 7 May 2020 13:47:23 +0000 (09:47 -0400)]
zebra: remove typedef rib_update_event_t from system

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agozebra: Remove typedef rib_table_info_t from system
Donald Sharp [Thu, 7 May 2020 12:59:27 +0000 (08:59 -0400)]
zebra: Remove typedef rib_table_info_t from system

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agozebra: Remove typedef rib_tables_iter_state from system
Donald Sharp [Thu, 7 May 2020 12:57:04 +0000 (08:57 -0400)]
zebra: Remove typedef rib_tables_iter_state from system

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agozebra: Remove typedef rnh_type_t from system
Donald Sharp [Thu, 7 May 2020 12:55:55 +0000 (08:55 -0400)]
zebra: Remove typedef rnh_type_t from system

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agozebra: Remove typedef netlink_route_info_t
Donald Sharp [Thu, 7 May 2020 12:52:38 +0000 (08:52 -0400)]
zebra: Remove typedef netlink_route_info_t

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agozebra: Remove the typedef netlink_nh_info_t
Donald Sharp [Thu, 7 May 2020 12:50:04 +0000 (08:50 -0400)]
zebra: Remove the typedef netlink_nh_info_t

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agozebra: Remove typedef of mpls_srgb_t
Donald Sharp [Thu, 7 May 2020 12:48:42 +0000 (08:48 -0400)]
zebra: Remove typedef of mpls_srgb_t

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agozebra: Remove enum around ipv6_nd_suppress_ra_status
Donald Sharp [Thu, 7 May 2020 12:47:02 +0000 (08:47 -0400)]
zebra: Remove enum around ipv6_nd_suppress_ra_status

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agozebra: Remvoe typedef for zfpm_glob_t
Donald Sharp [Thu, 7 May 2020 12:44:57 +0000 (08:44 -0400)]
zebra: Remvoe typedef for zfpm_glob_t

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agozebra: Remove typedef zfpm_msg_format_e
Donald Sharp [Thu, 7 May 2020 12:41:33 +0000 (08:41 -0400)]
zebra: Remove typedef zfpm_msg_format_e

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agozebra: Remove the typedef for zfrpm_state_t
Donald Sharp [Thu, 7 May 2020 12:38:35 +0000 (08:38 -0400)]
zebra: Remove the typedef for zfrpm_state_t

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agozebra: Remove typedef of zfpm_stats_t
Donald Sharp [Thu, 7 May 2020 12:36:33 +0000 (08:36 -0400)]
zebra: Remove typedef of zfpm_stats_t

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agozebra: Remove typedef around zfpm_rnodes_iter
Donald Sharp [Thu, 7 May 2020 12:32:26 +0000 (08:32 -0400)]
zebra: Remove typedef around zfpm_rnodes_iter

Typedef's are not used in our system remove.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agoMerge pull request #6363 from donaldsharp/no_no_no
Donatas Abraitis [Fri, 8 May 2020 07:12:26 +0000 (10:12 +0300)]
Merge pull request #6363 from donaldsharp/no_no_no

bgpd: `bgp bestpath bandwidth` should not be a legal command

4 years agoMerge pull request #6365 from donaldsharp/bsd_v6_Null_bs
Mark Stapp [Thu, 7 May 2020 17:12:55 +0000 (13:12 -0400)]
Merge pull request #6365 from donaldsharp/bsd_v6_Null_bs

zebra: Add code to install v6 blackhole routes on *bsd

4 years agozebra: Add code to install v6 blackhole routes on *bsd
Donald Sharp [Thu, 7 May 2020 15:24:05 +0000 (11:24 -0400)]
zebra: Add code to install v6 blackhole routes on *bsd

This code was just missing.  Take the few minutes and
get it done.

!
ip route 4.5.6.7/32 Null0
ipv6 route 4::5/128 Null0
!
$ netstat -rn
Routing tables

Internet:
Destination        Gateway            Flags     Netif Expire
default            192.168.122.1      UGS      vtnet0
4.5.6.7/32         127.0.0.1          UG1B        lo0
127.0.0.1          link#2             UH          lo0
192.168.122.0/24   link#1             U        vtnet0
192.168.122.40     link#1             UHS         lo0

Internet6:
Destination                       Gateway                       Flags     Netif Expire
::/96                             ::1                           UGRS        lo0
::1                               link#2                        UH          lo0
::ffff:0.0.0.0/96                 ::1                           UGRS        lo0
4::5/128                          ::1                           UG1B        lo0
fe80::/10                         ::1                           UGRS        lo0
fe80::%vtnet0/64                  link#1                        U        vtnet0
fe80::5054:ff:fe5a:e705%vtnet0    link#1                        UHS         lo0
fe80::%lo0/64                     link#2                        U           lo0
fe80::1%lo0                       link#2                        UHS         lo0
ff02::/16                         ::1                           UGRS        lo0
$

$ uname -a
FreeBSD donna 12.1-RELEASE FreeBSD 12.1-RELEASE r354233 GENERIC  amd64
$

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agobgpd: `bgp bestpath bandwidth` should not be a legal command
Donald Sharp [Thu, 7 May 2020 14:03:31 +0000 (10:03 -0400)]
bgpd: `bgp bestpath bandwidth` should not be a legal command

The `bgp bestpath bandwidth` command should not be a legal
command.  Pull out the `no` form to allow this.  Allow
`no bgp bestpath bandwidth` to work as we would expect.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agoMerge pull request #6356 from ton31337/fix/aggregator_0_ignore
Donald Sharp [Wed, 6 May 2020 23:43:21 +0000 (19:43 -0400)]
Merge pull request #6356 from ton31337/fix/aggregator_0_ignore

bgpd: Ignore aggregator attribute if it's malformed (0.0.0.0)

4 years agoMerge pull request #6358 from donaldsharp/zebra_onlink
Jafar Al-Gharaibeh [Wed, 6 May 2020 20:25:48 +0000 (15:25 -0500)]
Merge pull request #6358 from donaldsharp/zebra_onlink

zebra: Loosen ONLINK restrictions a tiny bit

4 years agoMerge pull request #6359 from sworleys/NHG-No-IPv4-IPv6
Mark Stapp [Wed, 6 May 2020 19:42:52 +0000 (15:42 -0400)]
Merge pull request #6359 from sworleys/NHG-No-IPv4-IPv6

zebra: abstract 5549 check into a function

4 years agoMerge pull request #6357 from mjstapp/fix_ldp_topo1_how
Renato Westphal [Wed, 6 May 2020 15:23:36 +0000 (12:23 -0300)]
Merge pull request #6357 from mjstapp/fix_ldp_topo1_how

tests: remove unused ref files from ldp topotest

4 years agoMerge pull request #6352 from volta-networks/fix_ldp_dscp
Renato Westphal [Wed, 6 May 2020 15:23:01 +0000 (12:23 -0300)]
Merge pull request #6352 from volta-networks/fix_ldp_dscp

ldpd: LDP does not always send traffic with correct DSCP value.

4 years agozebra: Loosen ONLINK restrictions a tiny bit
Donald Sharp [Wed, 6 May 2020 14:13:48 +0000 (10:13 -0400)]
zebra: Loosen ONLINK restrictions a tiny bit

Loosen the ONLINK restrictions such that when an upper
level protocol sends us a nexthop with an ONLINK attribute
just ensure that interface is up and usable.  ONLINK effectively
means we know what we are doing to the kernel.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agoldpd: LDP does not always send traffic with correct DSCP value.
Karen Schoener [Tue, 5 May 2020 21:59:00 +0000 (17:59 -0400)]
ldpd: LDP does not always send traffic with correct DSCP value.

Adding code so that the LDP neighbor that does not initiate the
TCP connection also sets the DSCP (via setsocketopt).

Signed-off-by: Karen Schoener <karen@voltanet.io>
4 years agotests: remove unused ref files from ldp topotest
Mark Stapp [Wed, 6 May 2020 13:31:21 +0000 (09:31 -0400)]
tests: remove unused ref files from ldp topotest

Remove a couple of a couple of mis-named reference output files
from the ldp-topo1 suite.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agobgpd: Ignore aggregator attribute if it's malformed (0.0.0.0)
Donatas Abraitis [Wed, 6 May 2020 09:55:55 +0000 (12:55 +0300)]
bgpd: Ignore aggregator attribute if it's malformed (0.0.0.0)

This is not the attribute involved in path selection and by rfc7606 it should
be just ignored.

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
4 years agobgpd: Use slightly modified version of error message if AS path contains 0
Donatas Abraitis [Wed, 6 May 2020 09:51:40 +0000 (12:51 +0300)]
bgpd: Use slightly modified version of error message if AS path contains 0

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
4 years agoMerge pull request #6347 from opensourcerouting/llvm-callgraph
Quentin Young [Tue, 5 May 2020 21:40:21 +0000 (17:40 -0400)]
Merge pull request #6347 from opensourcerouting/llvm-callgraph

tools: LLVM-based call graphs

4 years agoMerge pull request #6350 from pureport/fix/bgp_double_community_free
Quentin Young [Tue, 5 May 2020 21:39:28 +0000 (17:39 -0400)]
Merge pull request #6350 from pureport/fix/bgp_double_community_free

bgpd: Check to ensure community attributes exist before freeing them

4 years agobgpd: Check to ensure community attributes exist before freeing them
Josh Cox [Tue, 5 May 2020 17:09:14 +0000 (13:09 -0400)]
bgpd: Check to ensure community attributes exist before freeing them

Community attributes might have been removed by an inbound route map, so we
should check to ensure they still exist before trying to free them.
This fixes a segfault described in issue #6345.

Signed-off-by: Josh Cox <josh.cox@pureport.com>
4 years agoMerge pull request #6349 from qlyoung/hook-cpp-compat
David Lamparter [Tue, 5 May 2020 19:42:29 +0000 (21:42 +0200)]
Merge pull request #6349 from qlyoung/hook-cpp-compat

4 years agozebra: abstract 5549 check into a function
Stephen Worley [Tue, 5 May 2020 19:05:30 +0000 (15:05 -0400)]
zebra: abstract 5549 check into a function

Abstract the 5549 ipv4 over ipv6 into a function for easier
code reuse and reading.

Signed-off-by: Stephen Worley <sworley@cumulusnetworks.com>
4 years agolib: make hook.h cpp-compatible
Quentin Young [Tue, 5 May 2020 18:03:19 +0000 (14:03 -0400)]
lib: make hook.h cpp-compatible

Some CPP compilers don't support these designated initializers, since
we're just zero initializing don't need em

Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
4 years agoMerge pull request #6103 from mjstapp/fix_all_unnumbered
Donald Sharp [Tue, 5 May 2020 17:00:26 +0000 (13:00 -0400)]
Merge pull request #6103 from mjstapp/fix_all_unnumbered

zebra: don't treat every interface as unnumbered

4 years agoMerge pull request #6335 from ton31337/feature/show_policy_in_bgp_summary
David Lamparter [Tue, 5 May 2020 13:29:09 +0000 (15:29 +0200)]
Merge pull request #6335 from ton31337/feature/show_policy_in_bgp_summary

4 years agobuild: don't link ldpd.c twice
David Lamparter [Tue, 5 May 2020 12:32:21 +0000 (14:32 +0200)]
build: don't link ldpd.c twice

... this breaks LLVM bitcode linking.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
4 years agopython: add graphviz callgraphs
David Lamparter [Mon, 4 May 2020 18:57:45 +0000 (20:57 +0200)]
python: add graphviz callgraphs

Uses the JSON data extracted from LLVM bitcode by tools/frr-llvm-cg.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
4 years agobuild: add LLVM bitcode targets
David Lamparter [Mon, 4 May 2020 16:39:35 +0000 (18:39 +0200)]
build: add LLVM bitcode targets

Just an easy way to produce LLVM .bc (bitcode) files.  Not used during
normal builds.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
4 years agotools: frr-llvm-cg
David Lamparter [Mon, 4 May 2020 15:30:24 +0000 (17:30 +0200)]
tools: frr-llvm-cg

This dumps call graph data from LLVM bitcode files into a JSON file.
Specifically for FRR, it understands thread_add_*(), hook_*() and
install_element() so it can provide extra information in these cases.
As a general feature, it tries to track down function pointers as far as
easily feasible.

Signed-off-by: David Lamparter <equinox@diac24.net>
4 years agobuild: rework Makefile var extraction... again
David Lamparter [Fri, 1 May 2020 13:22:05 +0000 (15:22 +0200)]
build: rework Makefile var extraction... again

*sigh* I can't seem to catch a break on this.  Add a regex variant.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
4 years agoMerge commit '97cfd5d207e46a027809125cfb356fd301af0cf5'
David Lamparter [Mon, 4 May 2020 19:02:13 +0000 (21:02 +0200)]
Merge commit '97cfd5d207e46a027809125cfb356fd301af0cf5'

(from PR #6137)

4 years agodoc: Add an example about what "(Policy)" means under `show bgp summary`
Donatas Abraitis [Mon, 4 May 2020 11:49:13 +0000 (14:49 +0300)]
doc: Add an example about what "(Policy)" means under `show bgp summary`

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
4 years agobgpd: Show "(Policy)" under PfxRcd/PfxSnt when eBGP policy is in use
Donatas Abraitis [Sun, 3 May 2020 18:49:46 +0000 (21:49 +0300)]
bgpd: Show "(Policy)" under PfxRcd/PfxSnt when eBGP policy is in use

It could be hard to notice when eBGP policy is missing in `show bgp summary`.

This adds more sugar to the output:

Normal:
```
 MsgSent   TblVer  InQ OutQ  Up/Down State/PfxRcd   PfxSnt
      10        0    0    0 00:02:07            6        8
```
When rfc8212 is enabled (default since 7.4) - OUTBOUND:
```
 MsgSent   TblVer  InQ OutQ  Up/Down State/PfxRcd   PfxSnt
      13        0    0    0 00:04:56            6 (Policy)
```
INBOUND:
```
 MsgSent   TblVer  InQ OutQ  Up/Down State/PfxRcd   PfxSnt
      19        0    0    0 00:06:27     (Policy)        2
```

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
4 years agoMerge pull request #6330 from sworleys/No-NHG-Install-With-VRFns
Mark Stapp [Fri, 1 May 2020 18:23:49 +0000 (14:23 -0400)]
Merge pull request #6330 from sworleys/No-NHG-Install-With-VRFns

zebra: force off kernel NHG install with netns VRFs

4 years agoMerge pull request #6329 from donaldsharp/zebra_more_info
Mark Stapp [Fri, 1 May 2020 17:48:50 +0000 (13:48 -0400)]
Merge pull request #6329 from donaldsharp/zebra_more_info

zebra: Display ifindex of interface being installed on

4 years agozebra: force off kernel NHG install with netns VRFs
Stephen Worley [Fri, 1 May 2020 16:34:43 +0000 (12:34 -0400)]
zebra: force off kernel NHG install with netns VRFs

Force off kernel NHG install with netns-based VRFs for
now. There is not really a good solution for allowing
kernel nexthop groups in namespaced based vrfs.

Signed-off-by: Stephen Worley <sworley@cumulusnetworks.com>
4 years agozebra: Display ifindex of interface being installed on
Donald Sharp [Fri, 1 May 2020 15:57:02 +0000 (11:57 -0400)]
zebra: Display ifindex of interface being installed on

When installing a nexthop group, dump out the ifindex of the
nexthop being installed as a bit more data for the developer.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agoMerge pull request #6326 from mjstapp/ignore_emacs_desktop
Quentin Young [Thu, 30 Apr 2020 22:23:27 +0000 (18:23 -0400)]
Merge pull request #6326 from mjstapp/ignore_emacs_desktop

git: ignore emacs desktop

4 years agogit: ignore emacs desktop
Mark Stapp [Thu, 30 Apr 2020 18:19:10 +0000 (14:19 -0400)]
git: ignore emacs desktop

Ignore the emacs desktop files - should never ever be committed

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agoMerge pull request #6323 from donaldsharp/floom
Mark Stapp [Thu, 30 Apr 2020 17:25:42 +0000 (13:25 -0400)]
Merge pull request #6323 from donaldsharp/floom

bgpd: Ensure that we have a ifp pointer

4 years agoMerge pull request #6322 from ton31337/feature/bgp_bogon_filter_example
Donald Sharp [Thu, 30 Apr 2020 17:14:30 +0000 (13:14 -0400)]
Merge pull request #6322 from ton31337/feature/bgp_bogon_filter_example

doc: Add an example how to filter BGP bogon ASNs

4 years agobgpd: Ensure that we have a ifp pointer
Donald Sharp [Thu, 30 Apr 2020 15:16:28 +0000 (11:16 -0400)]
bgpd: Ensure that we have a ifp pointer

It is possible that the if_lookup_by_index() call will return
a NULL value and calling zclient_send_interface_radv_req.  Just
test that we have a valid interface pointer.

Found by Coverity

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agodoc: Add an example how to filter BGP bogon ASNs
Donatas Abraitis [Thu, 30 Apr 2020 14:35:49 +0000 (17:35 +0300)]
doc: Add an example how to filter BGP bogon ASNs

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
4 years agoMerge pull request #6318 from opensourcerouting/fix-exit-vrf
Donald Sharp [Thu, 30 Apr 2020 11:30:01 +0000 (07:30 -0400)]
Merge pull request #6318 from opensourcerouting/fix-exit-vrf

lib: update the CLI xpath index when exiting from the VRF node

4 years agoMerge pull request #6320 from opensourcerouting/fix-vrf-misconfig-detection
Donald Sharp [Thu, 30 Apr 2020 11:29:17 +0000 (07:29 -0400)]
Merge pull request #6320 from opensourcerouting/fix-vrf-misconfig-detection

zebra: fix detection of VRF misconfiguration

4 years agozebra: fix detection of VRF misconfiguration
Renato Westphal [Thu, 30 Apr 2020 02:12:22 +0000 (23:12 -0300)]
zebra: fix detection of VRF misconfiguration

The netlink_vrf_change() function is called both when a VRF device
is created in the Linux kernel and when it is activated. This
commit changes this function to perform the VRF misconfiguration
detection only when the VRF device is created, as doing the check
twice would cause a false positive followed by a hard failure (not
to mention the double check is unnecessary since the VRF table ID
can't change once the device is created).

Fixes #6319.

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
4 years agoMerge pull request #6241 from volta-networks/fix_ldp_acl
Renato Westphal [Thu, 30 Apr 2020 01:44:25 +0000 (22:44 -0300)]
Merge pull request #6241 from volta-networks/fix_ldp_acl

ldpd: fix ACL rule modification

4 years agolib: update the CLI xpath index when exiting from the VRF node
Renato Westphal [Wed, 29 Apr 2020 21:49:29 +0000 (18:49 -0300)]
lib: update the CLI xpath index when exiting from the VRF node

All custom "exit-*" commands that exit from a YANG-modeled
CLI node need to use cmd_exit() to ensure the CLI xpath index
(vty->xpath_index) will be updated accordingly.

Fixes #6316.

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
4 years agoMerge pull request #6314 from pjdruddy/fix-arp-cache-vtep-json-cli
Sri Mohana Singamsetty [Wed, 29 Apr 2020 16:31:22 +0000 (09:31 -0700)]
Merge pull request #6314 from pjdruddy/fix-arp-cache-vtep-json-cli

zebra: fix json for show evpn arp-cache vni vtep

4 years agoMerge pull request #5786 from mjstapp/fix_notif_empty_nhg
Stephen Worley [Wed, 29 Apr 2020 16:28:56 +0000 (12:28 -0400)]
Merge pull request #5786 from mjstapp/fix_notif_empty_nhg

zebra: fix handling of failed route install via notification

4 years agoldpd: fix ACL rule modification
lynne [Wed, 15 Apr 2020 17:49:41 +0000 (13:49 -0400)]
ldpd: fix ACL rule modification

Changes to ACL rules were not applied to LDP.  This fix allows
LDP to be notified when a rule in an ACL filter is modified by
the user. The filter is properly applied to the LDP session.
The filter may cause a LDP session to go down/up or to remove/add
labels being advertised/received from a neighbor.

Signed-off-by: Lynne Morrison <lynne@voltanet.io>
Signed-off-by: Karen Schoener <karen@voltanet.io>
4 years agozebra: don't treat every interface as unnumbered
Mark Stapp [Fri, 6 Mar 2020 21:09:10 +0000 (16:09 -0500)]
zebra: don't treat every interface as unnumbered

Commit e93a6fbb4 from PR3908 changed every interface into an
'unnumbered' interface - even interfaces that do not have
ipv4 at all. Undo that.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agoMerge pull request #6309 from dslicenc/ra-retrans-interval
Russ White [Wed, 29 Apr 2020 15:10:33 +0000 (11:10 -0400)]
Merge pull request #6309 from dslicenc/ra-retrans-interval

zebra: add ability to set retransmit timer for IPv6 RAs

4 years agoMerge pull request #6303 from dslicenc/stop-enhe-ras
Russ White [Wed, 29 Apr 2020 15:09:58 +0000 (11:09 -0400)]
Merge pull request #6303 from dslicenc/stop-enhe-ras

bgpd: turn off RAs when numbered peers are deleted

4 years agoMerge pull request #6313 from volta-networks/fix_zebra_pw_nht
Donald Sharp [Wed, 29 Apr 2020 14:22:04 +0000 (10:22 -0400)]
Merge pull request #6313 from volta-networks/fix_zebra_pw_nht

zebra: fix zebra pseudowire manager NHT

4 years agoMerge pull request #6299 from ton31337/fix/access-list_deletion
Donald Sharp [Wed, 29 Apr 2020 12:31:31 +0000 (08:31 -0400)]
Merge pull request #6299 from ton31337/fix/access-list_deletion

lib: Delete the entire access-list only if there are no more entries

4 years agozebra: fix json for show evpn arp-cache vni vtep
Pat Ruddy [Wed, 29 Apr 2020 11:22:14 +0000 (12:22 +0100)]
zebra: fix json for show evpn arp-cache vni vtep

The function zebra_vxlan_print_neigh_vni_vtep does not create
a json object when json has been requested from the CLI and as a
result it prints out the information in normal CLI format.
Fix is to allocate the json object when required.

Signed-off-by: Pat Ruddy <pat@voltanet.io>
4 years agodoc: Documentation for ipv6 nd ra-retrans-timer command
Don Slice [Wed, 22 Apr 2020 11:55:10 +0000 (11:55 +0000)]
doc: Documentation for ipv6 nd ra-retrans-timer command

Signed-off-by: Don Slice <dslice@cumulusnetworks.com>
4 years agozebra: add ability to set retransmit timer for IPv6 RAs
Don Slice [Tue, 28 Apr 2020 11:54:14 +0000 (11:54 +0000)]
zebra: add ability to set retransmit timer for IPv6 RAs

Reported by testing agency that rfc 4861 section 6.2.1 states
that all implementations must have a configuration knob to change
the setting of the advertised retransmit timer sent in RA packets.
This fix adds that capability.

Ticket: CM-29199
Signed-off-by: Don Slice <dslice@cumulusnetworks.com>
4 years agoMerge pull request #6228 from donaldsharp/change_network_statement_default
David Lamparter [Wed, 29 Apr 2020 07:02:42 +0000 (09:02 +0200)]
Merge pull request #6228 from donaldsharp/change_network_statement_default

4 years agoMerge pull request #6310 from donaldsharp/revert_the_behavior
Sri Mohana Singamsetty [Tue, 28 Apr 2020 22:41:47 +0000 (15:41 -0700)]
Merge pull request #6310 from donaldsharp/revert_the_behavior

Revert "vtysh: fix searching commands in parent nodes"

4 years agodoc: Update doc for the `bgp network import-check` command
Donald Sharp [Wed, 15 Apr 2020 12:31:27 +0000 (08:31 -0400)]
doc: Update doc for the `bgp network import-check` command

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agobgpd,tests: Modify import-check to require underlying prefixes to exist
Donald Sharp [Wed, 15 Apr 2020 12:21:11 +0000 (08:21 -0400)]
bgpd,tests: Modify import-check to require underlying prefixes to exist

Modify the import-check command to require the underlying prefix
to exist in the rib.  General consensus is that this is the correct
behavior.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agoMerge pull request #6302 from volta-networks/fix_ldpd_af_reload
Donald Sharp [Tue, 28 Apr 2020 19:05:57 +0000 (15:05 -0400)]
Merge pull request #6302 from volta-networks/fix_ldpd_af_reload

tools: fix frr-reload AF issue with ldpd

4 years agozebra: fix zebra pseudowire manager NHT
Karen Schoener [Mon, 27 Apr 2020 18:31:50 +0000 (14:31 -0400)]
zebra: fix zebra pseudowire manager NHT

Intermittently, there is a 30 second delay for a LDP pseudowire to become
operational.

One way to reproduce the issue is: Once PW is up, shutdown link to trigger
a change to the pseudowire's next hop, and then restore link to cause
pseudowire to return to original NH.

Problem Descripton:
    The Zebra PW manager installs pseudowires in the data plane when the
    following two conditions are met:
        1. Pseudowire is labeled via LDP mapping messages
        2. A labeled NH route exists to reach the remote pseudowire endpoint

    The Zebra PW manager registers a NHT callback when a pseudowire is enabled.
    This allows the Zebra PW manager to install or reinstall the pseudowire.

    The Zebra PW manager deregisters for the NHT callback when the pseudowire is
    disabled.  When LDP learns the remote-pseudowire status is 'not forwarding',
    LDP notifies Zebra that the pseudowire is disabled.

    This creates a race condition where a new labeled NH can be resolved after the
    Zebra PW manager deregistered for the NHT callback.

    For static pseudowires, it makes sense for Zebra PW manager to deregister for
    NHT callbacks for disabled pseudowires.  Static pseudowires become disabled
    via CLI configuration commands.

    For LDP pseudowires, the Zebra PW manager should not deregister for NHT
    callbacks for disabled pseudowires.

Overview of changes:
    1. Zebra PW manager should not deregister for NHT callbacks when an LDP
       pseudowire is disabled.
       Zebra PW manager will register for NHT callbacks when the LDP pseudowire
       is first enabled.
       Zebra PW manager will deregister for NHT callbacks when the LDP
       pseudowire is deleted.
    2. Remove the 30 second timer that was added in PR4122.
       PR4122 tried to fix this race condition with a timer.
       Once we eliminate the race condition (by keeping the Zebra PW manager
       registered for NHT callbacks), this timer can be removed.
    3. Zebra PW manager handling of static pseudowires will remain as-is.
       Zebra PW manager will register for NHT callbacks when the static
       pseudowire is enabled.
       Zebra PW manager will deregister for NHT callbacks when the static
       pseudowire is disabled.

Signed-off-by: Lynne Morrison <lynne@voltanet.io>
Signed-off-by: Karen Schoener <karen@voltanet.io>
4 years agoMerge pull request #6295 from ton31337/feature/show_bgp_afi_safi_sntpfx
Lou Berger [Tue, 28 Apr 2020 15:34:13 +0000 (11:34 -0400)]
Merge pull request #6295 from ton31337/feature/show_bgp_afi_safi_sntpfx

bgpd: Show PfxSnt for `show bgp <afi> <safi>` command

4 years agoMerge pull request #6308 from donaldsharp/pim_ordering
David Lamparter [Tue, 28 Apr 2020 15:14:28 +0000 (17:14 +0200)]
Merge pull request #6308 from donaldsharp/pim_ordering

4 years agoRevert "vtysh: fix searching commands in parent nodes"
Donald Sharp [Tue, 28 Apr 2020 14:46:22 +0000 (10:46 -0400)]
Revert "vtysh: fix searching commands in parent nodes"

This reverts commit d741915ecdcf8930ccb3bd23eec1da2f0d000483.

This is because it breaks this behavior:

router ospf6
  <commands>
!
int enp39s0
  <more commands>
!

This is a very legal set of commands and completely destroys the
ability to do this.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agoMerge pull request #6306 from opensourcerouting/triple-wtf-20200428
Donald Sharp [Tue, 28 Apr 2020 12:00:28 +0000 (08:00 -0400)]
Merge pull request #6306 from opensourcerouting/triple-wtf-20200428

*: triple pack of one-liner WTF fixes

4 years agopimd: Add a needed space for formatting
Donald Sharp [Tue, 28 Apr 2020 11:59:18 +0000 (07:59 -0400)]
pimd: Add a needed space for formatting

Display a space in the output.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agopimd: don't split format string from zlog call
David Lamparter [Tue, 28 Apr 2020 09:09:26 +0000 (11:09 +0200)]
pimd: don't split format string from zlog call

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
4 years agotests: fix size confusion
David Lamparter [Thu, 23 Apr 2020 21:54:05 +0000 (23:54 +0200)]
tests: fix size confusion

The question here isn't "why does it break on PowerPC?", but rather "why
doesn't it break on x86_64 or ARM?"

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
4 years agobgpd: fix typo
David Lamparter [Tue, 28 Apr 2020 09:07:01 +0000 (11:07 +0200)]
bgpd: fix typo

o.O

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
4 years agoMerge pull request #6301 from pguibert6WIND/bfd_debug_show
Rafael Zalamena [Mon, 27 Apr 2020 18:12:07 +0000 (15:12 -0300)]
Merge pull request #6301 from pguibert6WIND/bfd_debug_show

bfdd: display debugging status of bfd

4 years agobgpd: turn off RAs when numbered peers are deleted
Don Slice [Tue, 21 Apr 2020 19:01:35 +0000 (19:01 +0000)]
bgpd: turn off RAs when numbered peers are deleted

Problem reported that in many circumstances, RAs created in the
process of bringing up numbered IPv6 peers with extended-nexthop
capability enabled (for ipv4 over ipv6) were not stopped on the
interface when those peers were deleted.  Found several circumstances
where this occurred and fix them in this patch.

Ticket: CM-26875
Signed-off-by: Don Slice <dslice@cumulusnetworks.com>
4 years agobfdd: display debugging status of bfd
Philippe Guibert [Mon, 27 Apr 2020 15:21:45 +0000 (17:21 +0200)]
bfdd: display debugging status of bfd

display debugging status of bfd.

Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
4 years agotools: fix frr-reload AF issue with ldpd
Emanuele Di Pascale [Mon, 27 Apr 2020 13:47:03 +0000 (15:47 +0200)]
tools: fix frr-reload AF issue with ldpd

when removing a whole address-family block from ldpd config
we were erroneously trying to also remove each of the interface
sub-sub-contexts that belonged to it; this would effectively
re-enable the AF we just removed. Work around this by ignoring
these sub-sub-contexts if we detect that we are already
removing the parent block.

Signed-off-by: Emanuele Di Pascale <emanuele@voltanet.io>
4 years agozebra: fix handling of failed route install via notification
Mark Stapp [Mon, 10 Feb 2020 18:12:58 +0000 (13:12 -0500)]
zebra: fix handling of failed route install via notification

An async route notification can indicate that installation
has failed, but the handling code wasn't dealing with that
possibility correctly.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agoMerge pull request #6298 from opensourcerouting/build-assorted-20200423
Donald Sharp [Mon, 27 Apr 2020 13:06:19 +0000 (09:06 -0400)]
Merge pull request #6298 from opensourcerouting/build-assorted-20200423

build: spring cleaning

4 years agodoc: fix typo in archlinux doc
Mark Stapp [Mon, 27 Apr 2020 12:47:34 +0000 (08:47 -0400)]
doc: fix typo in archlinux doc

Fix a typo to remove a warning when building the dev
docs.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agolib: Delete the entire access-list only if there are no more entries
Donatas Abraitis [Mon, 27 Apr 2020 09:13:48 +0000 (12:13 +0300)]
lib: Delete the entire access-list only if there are no more entries

When you enter the access-list with the same sequence number but with a
different prefix AND access-list has only a single entry, then the entry
is deleted and the whole access-list is deleted.

That means that "replace entry" never be re-inserted.

With fix:
```
~# vtysh -c 'c' -c 'access-list 1 seq 10 permit 127.0.0.10/32'
~# vtysh -c 'sh run' | grep access-list
access-list 1 seq 10 permit 127.0.0.10/32
~# vtysh -c 'c' -c 'access-list 1 seq 10 permit 127.0.0.20/32'
~# vtysh -c 'sh run' | grep access-list
access-list 1 seq 10 permit 127.0.0.20/32
~# vtysh -c 'c' -c 'access-list 1 seq 11 permit 127.0.0.11/32'
~# vtysh -c 'sh run' | grep access-list
access-list 1 seq 10 permit 127.0.0.20/32
access-list 1 seq 11 permit 127.0.0.11/32
~# vtysh -c 'c' -c 'no access-list 1 seq 10 permit 127.0.0.20/32'
~# vtysh -c 'sh run' | grep access-list
access-list 1 seq 11 permit 127.0.0.11/32
~#
```

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
4 years agolib: Convert access_list_empty to bool
Donatas Abraitis [Mon, 27 Apr 2020 09:13:04 +0000 (12:13 +0300)]
lib: Convert access_list_empty to bool

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
4 years agobuild: silence idiotic libtool warnings
David Lamparter [Wed, 15 Apr 2020 14:03:42 +0000 (16:03 +0200)]
build: silence idiotic libtool warnings

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
4 years agobuild: move python 2.x to the very last preference
David Lamparter [Thu, 23 Apr 2020 18:41:04 +0000 (20:41 +0200)]
build: move python 2.x to the very last preference

Also try explicit 3.9 & 3.10.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
4 years agobfdd: fix frr-format false warning
David Lamparter [Thu, 23 Apr 2020 18:34:16 +0000 (20:34 +0200)]
bfdd: fix frr-format false warning

Dealing with PRIu64 is unfortunately a bit hacky in the frr-format
plugin, as in, it works correctly with snprintfrr, but breaks on plain
snprintf.  There's no good solution unfortunately :/.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
4 years agolib/zlog: fix printfrr format attribute
David Lamparter [Thu, 23 Apr 2020 18:17:18 +0000 (20:17 +0200)]
lib/zlog: fix printfrr format attribute

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
4 years ago*: fix first header
David Lamparter [Thu, 23 Apr 2020 18:16:37 +0000 (20:16 +0200)]
*: fix first header

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
4 years agopython: add check-first-header tool
David Lamparter [Thu, 23 Apr 2020 18:14:58 +0000 (20:14 +0200)]
python: add check-first-header tool

The first #include statement in all FRR .c files should be either
zebra.h or config.h.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
4 years agobuild: make clippy Makefile rules nicer
David Lamparter [Wed, 15 Apr 2020 08:27:49 +0000 (10:27 +0200)]
build: make clippy Makefile rules nicer

These are easy to get subtly wrong, and doing so can cause
nondeterministic failures when racing in parallel builds.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
4 years agotools/symalyzer: fix copypasta
David Lamparter [Thu, 23 Apr 2020 18:01:23 +0000 (20:01 +0200)]
tools/symalyzer: fix copypasta

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>