]> git.puffer.fish Git - matthieu/frr.git/log
matthieu/frr.git
4 years agobgpd: Actually find the sequence number for `bgp extcommunity-list...`
Donald Sharp [Tue, 2 Jun 2020 20:10:48 +0000 (16:10 -0400)]
bgpd: Actually find the sequence number for `bgp extcommunity-list...`

The code in the bgp extcommunity-list function was using
argv_find to get the correct idx.  The problem was that
we had already done argv_finds before and idx was non-zero
thus having us always set the seq pointer to what was last
looked up.  This causes us to pass in a value to the
underlying function and it would just wisely ignore it
causing a seq number of 0.

We would then write this seq number of 0 and then immediately
reject it on read in again.  BOO!

Actually handle argv_find the way it was meant to be.

Ticket:CM-29926
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agoMerge pull request #6513 from donaldsharp/allow_filter_deletion
Donatas Abraitis [Thu, 4 Jun 2020 05:49:35 +0000 (08:49 +0300)]
Merge pull request #6513 from donaldsharp/allow_filter_deletion

lib: Allow deletion of some access-lists

4 years agolib: Allow deletion of some access-lists
Donald Sharp [Thu, 4 Jun 2020 00:01:48 +0000 (20:01 -0400)]
lib: Allow deletion of some access-lists

Recent rework of access lists to allow sequence numbers
accidently introduced the inability to delete some
access lists.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agoMerge pull request #6508 from RichardWu-Hebut/master
Donald Sharp [Wed, 3 Jun 2020 17:09:27 +0000 (13:09 -0400)]
Merge pull request #6508 from RichardWu-Hebut/master

zebra: Fix zebra crashed in building FPM netlink message when bgp sen…

4 years agozebra: Fix zebra crashed in building FPM netlink message when bgp sends aggregation...
Richard Wu [Wed, 3 Jun 2020 01:44:16 +0000 (09:44 +0800)]
zebra: Fix zebra crashed in building FPM netlink message when bgp sends aggregation routes to zebra.

Issue:
    When BGP sends aggregation routes to zebra, the next hop is black hole.
    Then Zebra will try to build the netlink FPM message, but there is no
    next hop as it is a black hole route. Then the netlink_route_info_fill
    function returns 0. In the result, zebra will crashed in
    "assert(data_len)" of zfpm_build_route_updates.
    This issue also happen when I create a static black hole route via
    staticd.
Fix:
    As the netlink message of the blackhole route is legal, it should return
    success.

Signed-off-by: Richard Wu <wutong23@baidu.com>
4 years agoMerge pull request #6506 from volta-networks/ldp_pwstatus_cleanup
Renato Westphal [Wed, 3 Jun 2020 00:34:05 +0000 (21:34 -0300)]
Merge pull request #6506 from volta-networks/ldp_pwstatus_cleanup

ldpd: remove unused 'pwstatus' field from message zapi_pw_status

4 years agoMerge pull request #6236 from mjstapp/zebra_opaque_module
Renato Westphal [Tue, 2 Jun 2020 23:39:58 +0000 (20:39 -0300)]
Merge pull request #6236 from mjstapp/zebra_opaque_module

lib,zebra: New zebra opaque zapi module

4 years agoldpd: remove unused 'pwstatus' field from message zapi_pw_status.
Karen Schoener [Tue, 2 Jun 2020 22:03:24 +0000 (18:03 -0400)]
ldpd: remove unused 'pwstatus' field from message zapi_pw_status.

Signed-off-by: Karen Schoener <karen@voltanet.io>
4 years agoMerge pull request #6503 from donaldsharp/bgp_routemap_crash
Rafael Zalamena [Tue, 2 Jun 2020 18:28:53 +0000 (15:28 -0300)]
Merge pull request #6503 from donaldsharp/bgp_routemap_crash

bgpd: Fix crash in `match ip next-hop address` command

4 years agobgpd: Fix crash in `match ip next-hop address` command
Donald Sharp [Tue, 2 Jun 2020 16:23:09 +0000 (12:23 -0400)]
bgpd: Fix crash in `match ip next-hop address` command

When issuing the command `match ip next-hop address`
bgp would crash.  This is because the no form of the
command was making the address optional and we would
try to read data we should not be.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agoMerge pull request #6456 from ton31337/fix/set_ipv6_ll_if_zero
Sri Mohana Singamsetty [Tue, 2 Jun 2020 16:08:05 +0000 (09:08 -0700)]
Merge pull request #6456 from ton31337/fix/set_ipv6_ll_if_zero

bgpd: Use IPv6 LL address as nexthop if global was set to ::/LL

4 years agoMerge pull request #6500 from chiragshah6/evpn_dev2
Sri Mohana Singamsetty [Tue, 2 Jun 2020 16:07:34 +0000 (09:07 -0700)]
Merge pull request #6500 from chiragshah6/evpn_dev2

bgpd: move advertise-vni-all above vni config

4 years agodoc: update zebra/zapi doc
Mark Stapp [Wed, 22 Apr 2020 18:10:14 +0000 (14:10 -0400)]
doc: update zebra/zapi doc

Add the new OPAQUE zapi messages; a couple of edits.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agozebra: handle OPAQUE registrations and forward messages
Mark Stapp [Tue, 21 Apr 2020 12:41:35 +0000 (08:41 -0400)]
zebra: handle OPAQUE registrations and forward messages

Add initial support to maintain client daemon registrations for
OPAQUE messages. Use the registered zapi client info to forward
copies of OPAQUE messages sent to zebra.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agosharpd: add handler for OPAQUE messages
Mark Stapp [Tue, 21 Apr 2020 12:40:54 +0000 (08:40 -0400)]
sharpd: add handler for OPAQUE messages

Add a simple handler to receive OPAQUE zapi messages for
testing.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agozebra: add zserv_send_batch api
Mark Stapp [Mon, 20 Apr 2020 20:59:38 +0000 (16:59 -0400)]
zebra: add zserv_send_batch api

Add a zserv api to send a batch (a fifo) of messages to a
zapi client.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agosharpd: send opaque message registrations
Mark Stapp [Sun, 19 Apr 2020 17:41:57 +0000 (13:41 -0400)]
sharpd: send opaque message registrations

For testing, add cli to sharpd to send opaque message
registration and un-registration messages.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agozebra: don't print stale text if no GR info
Mark Stapp [Thu, 16 Apr 2020 17:15:32 +0000 (13:15 -0400)]
zebra: don't print stale text if no GR info

Don't print GR show output header if no GR info is present
for a zapi client.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agosharpd: send new OPAQUE messages
Mark Stapp [Wed, 15 Apr 2020 20:31:57 +0000 (16:31 -0400)]
sharpd: send new OPAQUE messages

Add a simple cli to exercise the new OPAQUE messages.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agozebra: call zapi message handler with a batch
Mark Stapp [Wed, 8 Apr 2020 20:39:49 +0000 (16:39 -0400)]
zebra: call zapi message handler with a batch

The zapi code processes a batch of incoming messages, using a
fifo. Hand the entire batch into the main zebra handling code,
and let it loop through the individual messages.

Divert the special OPAQUE messages from the normal processing
flow, and offer them to the new zebra_opaque module instead.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agozebra: add lock and busy counter for zclients
Mark Stapp [Tue, 7 Apr 2020 13:50:53 +0000 (09:50 -0400)]
zebra: add lock and busy counter for zclients

Add a mutex used to manage the list of zclients. Add a busy
counter to the zapi client session, so that we can use a
client session from another pthread.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agozebra: add zebra opaque module
Mark Stapp [Sun, 19 Apr 2020 17:23:09 +0000 (13:23 -0400)]
zebra: add zebra opaque module

Add the zebra_opaque module, designed to offload some opaque zapi
message processing to a new, dedicated pthread. Add to the build;
also re-sort the lists of zebra files in subdir.am.
Start, stop, and clean-up the opaque module, integrate with zebra
start and shutdown.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agolib: add OPAQUE zapi message
Mark Stapp [Mon, 6 Apr 2020 20:10:13 +0000 (16:10 -0400)]
lib: add OPAQUE zapi message

Add a zapi message type designed to carry opaque data. Add
'send' api, and prototype for client handler function. Also
add registration/unreg messages, so that clients can 'subscribe'
to receive these messages as they're passing through zebra.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agolib: add stream_fifo_init, more const
Mark Stapp [Sun, 5 Apr 2020 15:48:05 +0000 (11:48 -0400)]
lib: add stream_fifo_init, more const

Add utilities that init and deinit a stream_fifo - this lets us
use an on-stack fifo in some places, avoiding malloc'ing. Also
add const to some apis (no functional changes there).

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agobgpd: move advertise-vni-all above vni config
Chirag Shah [Tue, 2 Jun 2020 05:42:19 +0000 (22:42 -0700)]
bgpd: move advertise-vni-all above vni config

Move config 'advertise-vni-all' above all evpn
configuration as vni specific confi commands
have check for advertise-vni-all enabled first.

Ticket: CM-29312
Reviewed By:
Testing Done:

router bgp 5650
...
advertise-all-vni
vni 1002
 route-target import 55500:10002
 route-target export 55500:10002
exit-vni
...

Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
4 years agoMerge pull request #6497 from qlyoung/fix-centos7-docker-build
Donatas Abraitis [Tue, 2 Jun 2020 05:55:32 +0000 (08:55 +0300)]
Merge pull request #6497 from qlyoung/fix-centos7-docker-build

docker: fix centos7 install

4 years agoMerge pull request #6480 from volta-networks/feat_pwstatus
Renato Westphal [Tue, 2 Jun 2020 00:00:51 +0000 (21:00 -0300)]
Merge pull request #6480 from volta-networks/feat_pwstatus

ldpd: Relay data plane pseudowire status in LDP notification

4 years agoMerge pull request #6266 from mjstapp/backup_nhgs
Renato Westphal [Mon, 1 Jun 2020 23:54:51 +0000 (20:54 -0300)]
Merge pull request #6266 from mjstapp/backup_nhgs

zebra: backup nexthops/nhlfes for LSPs

4 years agodocker: fix centos7 install
Quentin Young [Mon, 1 Jun 2020 20:03:35 +0000 (16:03 -0400)]
docker: fix centos7 install

We require python3-sphinx for RPM builds, but it wasn't being installed.

Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
4 years agozebra: backup LSP zapi processing
Mark Stapp [Thu, 7 May 2020 20:21:20 +0000 (16:21 -0400)]
zebra: backup LSP zapi processing

Move some processing of zapi label messages so they can be
handled more efficiently. Handle zapi delete and replace
messages.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agozebra: add check_free api
Mark Stapp [Wed, 6 May 2020 20:46:22 +0000 (16:46 -0400)]
zebra: add check_free api

Add a 'check' api to hold the code that determines whether an LSP
can be freed or not. Replace calls to the free api with check
calls.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agozebra: rename 'nhg_copy' to 'nhe_copy'
Mark Stapp [Tue, 5 May 2020 21:03:33 +0000 (17:03 -0400)]
zebra: rename 'nhg_copy' to 'nhe_copy'

It copies nhes...

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agozebra: show backup nhlfes with dynamic LSPs
Mark Stapp [Fri, 17 Apr 2020 19:58:44 +0000 (15:58 -0400)]
zebra: show backup nhlfes with dynamic LSPs

Include backup nhlfe info with the show output of
dynamic LSPs (no json yet).

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agozebra: support backup nhlfes in LSPs
Mark Stapp [Fri, 10 Apr 2020 18:47:00 +0000 (14:47 -0400)]
zebra: support backup nhlfes in LSPs

Handle backup nhlfes in LSP zapi messages. Capture backup info
with LSPs, capture backup info in the dataplane LSP processing.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agosharpd: include backup nh info with lsps
Mark Stapp [Thu, 9 Apr 2020 17:53:38 +0000 (13:53 -0400)]
sharpd: include backup nh info with lsps

If present in a configured nexthop_group, include
backup nexthop/nhlfe info with LSP zapi add/update
messages.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agolib: add zapi_nexthop2str()
Mark Stapp [Fri, 3 Apr 2020 19:00:13 +0000 (15:00 -0400)]
lib: add zapi_nexthop2str()

Add a handy 2str api for zapi nexthop debugging.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agozebra: init dest's list of routes
Mark Stapp [Thu, 2 Apr 2020 15:20:58 +0000 (11:20 -0400)]
zebra: init dest's list of routes

Use the dlist init api on the zebra dest object's list
of routes.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agolib: add backup nexthop/nhlfe to zapi label messages
Mark Stapp [Thu, 2 Apr 2020 13:29:36 +0000 (09:29 -0400)]
lib: add backup nexthop/nhlfe to zapi label messages

Add backup nexthops/nhlfes to the zapi messages used
to convey LSPs to zebra.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agozebra: convert LSP nhlfe lists to use typesafe lists
Mark Stapp [Tue, 19 May 2020 18:11:32 +0000 (14:11 -0400)]
zebra: convert LSP nhlfe lists to use typesafe lists

Convert the embedded lists of nhlfes and snhlfes in zebra LSPs
and SLSPs to use typesafe dlists.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agoldpd: Relay data plane pseudowire status in LDP notification
Karen Schoener [Thu, 28 May 2020 20:36:35 +0000 (16:36 -0400)]
ldpd: Relay data plane pseudowire status in LDP notification

Provide a way for the data plane to indicate pseudowire
status (such as: not forwarding, AC failure).

On a data plane pseudowire install failure, data plane
sets the pseudowire status.
Zebra relays the pseudowire status to LDP.
LDP includes the pseudowire status in the LDP notification
to the LDP peer.

Signed-off-by: Karen Schoener <karen@voltanet.io>
4 years agoMerge pull request #6054 from sarav511/dr2ndr
Donald Sharp [Mon, 1 Jun 2020 11:58:32 +0000 (07:58 -0400)]
Merge pull request #6054 from sarav511/dr2ndr

pimd: When DR becomes non DR, Still sends register packets to RP

4 years agoMerge pull request #6442 from wesleycoakley/pbrd-showjson
Russ White [Mon, 1 Jun 2020 11:44:36 +0000 (07:44 -0400)]
Merge pull request #6442 from wesleycoakley/pbrd-showjson

pbrd: Optional JSON output for all `show pbr` directives

4 years agoMerge pull request #6048 from sarav511/joinsup
Donald Sharp [Mon, 1 Jun 2020 11:36:24 +0000 (07:36 -0400)]
Merge pull request #6048 from sarav511/joinsup

pimd: In join suppression period, join is being sent

4 years agoMerge pull request #6467 from qlyoung/fix-bgp-logrotation
Donatas Abraitis [Mon, 1 Jun 2020 05:46:26 +0000 (08:46 +0300)]
Merge pull request #6467 from qlyoung/fix-bgp-logrotation

bgpd: avoid spamming bgp_accept() on bad vrf sock

4 years agoMerge pull request #6490 from qlyoung/fix-alpine-python3-build
Donatas Abraitis [Mon, 1 Jun 2020 04:57:26 +0000 (07:57 +0300)]
Merge pull request #6490 from qlyoung/fix-alpine-python3-build

alpine: update packages

4 years agobgpd: avoid spamming bgp_accept() on bad vrf sock
Quentin Young [Fri, 22 May 2020 20:12:38 +0000 (16:12 -0400)]
bgpd: avoid spamming bgp_accept() on bad vrf sock

bgp_accept() gets called over and over again when a VRF device is
deleted out from under a bgp listener socket that is bound to it.
Prevent this by noting the error and cancelling ourselves, allowing the
vrf status code to clean up the mess when it receives word about the
change from Zebra.

Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
4 years agoalpine: update packages
Quentin Young [Sun, 31 May 2020 08:10:33 +0000 (04:10 -0400)]
alpine: update packages

Alpine builds have been failing for some time as a consequence of only
installing python 2 development packages when we have build scripts that
require python 3.

Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
4 years agoMerge pull request #6484 from kaloom/master
Donatas Abraitis [Sun, 31 May 2020 07:33:57 +0000 (10:33 +0300)]
Merge pull request #6484 from kaloom/master

bgpd: Fix "malformed communities" for accept-own-nexthop

4 years agoMerge pull request #6488 from donaldsharp/more_useful_debug
Donatas Abraitis [Sun, 31 May 2020 07:31:54 +0000 (10:31 +0300)]
Merge pull request #6488 from donaldsharp/more_useful_debug

More useful debug

4 years agobgpd: Improve connection rejection messages
Donald Sharp [Sat, 30 May 2020 19:44:54 +0000 (15:44 -0400)]
bgpd: Improve connection rejection messages

Try to give a bit more useful data about where we
think the connection is trying to come in from.
Hopefully this will let us debug connection issues
a bit faster in cases where there are config issues.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agodoc: Fix warning about incorrect underline length
Donald Sharp [Sat, 30 May 2020 19:43:30 +0000 (15:43 -0400)]
doc: Fix warning about incorrect underline length

The recent change for more snmp doc gave us a sphinx error.
Let's clean it up.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agoMerge pull request #6482 from donaldsharp/update_snmp_rst
Renato Westphal [Sat, 30 May 2020 03:17:11 +0000 (00:17 -0300)]
Merge pull request #6482 from donaldsharp/update_snmp_rst

doc: Update snmp.rst

4 years agoMerge pull request #6479 from volta-networks/fix_isis_if_addr_te
Renato Westphal [Sat, 30 May 2020 02:59:33 +0000 (23:59 -0300)]
Merge pull request #6479 from volta-networks/fix_isis_if_addr_te

isisd: fix issue with local address TE TLV

4 years agotests: Add a basic test for pbr
Donald Sharp [Wed, 27 May 2020 13:55:09 +0000 (09:55 -0400)]
tests: Add a basic test for pbr

Just add a basic test for pbr.  This code
does not actually test installation in the kernel at this
point in time.

What we do do is make sure pbr is in a sane state after
some very basic configuration.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agotests: Setup very basic pbr tests for our topology tests
Donald Sharp [Sat, 23 May 2020 17:24:38 +0000 (13:24 -0400)]
tests: Setup very basic pbr tests for our topology tests

Just a simple setup for pbr to prove it starts.  Once the json
code for pbr gets in we can add more.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agobgpd: Fix "malformed communities" for accept-own-nexthop
Appu Joseph [Fri, 29 May 2020 14:23:36 +0000 (10:23 -0400)]
bgpd: Fix "malformed communities" for accept-own-nexthop

"set community accept-own-nexthop" returns "malformed communities"
error. This is because the token matching hits an earlier "accept-own"
and leaves "-nexthop" as a separate token to be processed.
Reorder the switch cases so that both are processed correctly.

Signed-off-by: Appu Joseph <apjo@kaloom.com>
4 years agoisisd: fix local address TE TLV
Emanuele Di Pascale [Thu, 28 May 2020 13:46:56 +0000 (15:46 +0200)]
isisd: fix local address TE TLV

we were not correctly checking the MPLS-TE status of the area when
adding an IP address to a circuit, and this was preventing the local
address TLV to be populated after an interfaced flap.

Signed-off-by: Emanuele Di Pascale <emanuele@voltanet.io>
4 years agodoc: Update snmp.rst
Bart Vrancken [Tue, 26 May 2020 07:35:46 +0000 (09:35 +0200)]
doc: Update snmp.rst

Updated documentation for routers with a large route table, which breaks
SNMP/AgentX and in some conditions even crashes FRR. The documentation
proposal amends the SNMP configuration to exclude certain OID's that
are not needed in normal cases.

Format-fixed-by: Donald Sharp <sharpd@cumulusnetworks.com>
Signed-off-by: Bart Vrancken <bart@abuse.io>
4 years agoMerge pull request #6481 from donaldsharp/bgp_thread_cancel
Renato Westphal [Thu, 28 May 2020 23:28:31 +0000 (20:28 -0300)]
Merge pull request #6481 from donaldsharp/bgp_thread_cancel

bgpd: Use THREAD_CANCEL instead of thread_cancel

4 years agoMerge pull request #6416 from Orange-OpenSource/master
Renato Westphal [Thu, 28 May 2020 23:03:43 +0000 (20:03 -0300)]
Merge pull request #6416 from Orange-OpenSource/master

ospfd: Solve crash after removing and adding conf.

4 years agobgpd: Use THREAD_CANCEL instead of thread_cancel
Donald Sharp [Thu, 28 May 2020 20:33:10 +0000 (16:33 -0400)]
bgpd: Use THREAD_CANCEL instead of thread_cancel

We are crashing in thread_cancel on shutdown because
the thread pointer is NULL.  Use the more appropriate
THREAD_CANCEL macro

Ticket: CM-29873
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agoMerge pull request #6478 from mjstapp/dev_doc_more_const
Stephen Worley [Thu, 28 May 2020 19:02:00 +0000 (15:02 -0400)]
Merge pull request #6478 from mjstapp/dev_doc_more_const

doc: encourage const in the developer doc

4 years agoMerge pull request #6476 from wesleycoakley/zebra-debuglogfix
Mark Stapp [Thu, 28 May 2020 17:40:39 +0000 (13:40 -0400)]
Merge pull request #6476 from wesleycoakley/zebra-debuglogfix

zebra, lib: bugfix for zebra packet debugging messages

4 years agodoc: encourage const in the developer doc
Mark Stapp [Thu, 28 May 2020 16:37:51 +0000 (12:37 -0400)]
doc: encourage const in the developer doc

Add a little text about using 'const' in the dev doc.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agolib: stream_hexdump takes const struct
Wesley Coakley [Thu, 28 May 2020 15:18:11 +0000 (11:18 -0400)]
lib: stream_hexdump takes const struct

Signed-off-by: Wesley Coakley <wcoakley@cumulusnetworks.com>
4 years agoMerge pull request #6466 from opensourcerouting/frr-reload-cleanup
Mark Stapp [Thu, 28 May 2020 15:06:20 +0000 (11:06 -0400)]
Merge pull request #6466 from opensourcerouting/frr-reload-cleanup

tools/frr-reload: cleanup + `--vty_socket`

4 years agoMerge pull request #6475 from donaldsharp/pim_thread_cancel
Mark Stapp [Thu, 28 May 2020 15:02:57 +0000 (11:02 -0400)]
Merge pull request #6475 from donaldsharp/pim_thread_cancel

pimd: Fix crash on restart from thread_cancel

4 years agozebra, lib: bugfix on zebra packet debugging
Wesley Coakley [Thu, 28 May 2020 14:41:10 +0000 (10:41 -0400)]
zebra, lib: bugfix on zebra packet debugging

`debug zebra packet detail` dumps the full message whereas
it had been dropping exactly 10 bytes, the size of the zebra header

Signed-off-by: Wesley Coakley <wcoakley@cumulusnetworks.com>
4 years agoMerge pull request #6474 from ton31337/fix/doc_bgp_community
Donald Sharp [Thu, 28 May 2020 12:55:16 +0000 (08:55 -0400)]
Merge pull request #6474 from ton31337/fix/doc_bgp_community

doc: Update BGP show bgp (ext|large-)community-list commands

4 years agopimd: Fix crash on restart from thread_cancel
Donald Sharp [Thu, 28 May 2020 12:36:04 +0000 (08:36 -0400)]
pimd: Fix crash on restart from thread_cancel

We were using thread_cancel() directly instead of
THREAD_OFF which correctly ensures the pointer is not NULL.

Ticket:CM-29866
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agodoc: Update BGP show bgp (ext|large-)community-list commands
Donatas Abraitis [Thu, 28 May 2020 09:34:24 +0000 (12:34 +0300)]
doc: Update BGP show bgp (ext|large-)community-list commands

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
4 years agoMerge pull request #6469 from mjstapp/add_ubu_20_doc
Donald Sharp [Wed, 27 May 2020 14:43:05 +0000 (10:43 -0400)]
Merge pull request #6469 from mjstapp/add_ubu_20_doc

doc: add dev doc for ubuntu 20.04

4 years agoMerge pull request #6447 from opensourcerouting/rename-bgp-vrf-leak
Donald Sharp [Wed, 27 May 2020 14:34:13 +0000 (10:34 -0400)]
Merge pull request #6447 from opensourcerouting/rename-bgp-vrf-leak

topotest: refactory BGP VRF leak basic test

4 years agopbrd, lib, doc: fix new `show` json key semantics
Wesley Coakley [Tue, 26 May 2020 20:44:46 +0000 (16:44 -0400)]
pbrd, lib, doc: fix new `show` json key semantics

Revise new `show pbr` keys to be consistent with existing
json in other daemons

target->nexthop
id->tableId (where relevant)
isValid->valid
isInstalled->installed

Signed-off-by: Wesley Coakley <wcoakley@cumulusnetworks.com>
4 years agopbrd, doc: pbr map json `sequences` -> `policies`
Wesley Coakley [Fri, 22 May 2020 15:47:18 +0000 (11:47 -0400)]
pbrd, doc: pbr map json `sequences` -> `policies`

Semantics

Signed-off-by: Wesley Coakley <wcoakley@cumulusnetworks.com>
4 years agodoc: document json for remaining `show pbr` cmds
Wesley Coakley [Fri, 22 May 2020 15:36:52 +0000 (11:36 -0400)]
doc: document json for remaining `show pbr` cmds

Signed-off-by: Wesley Coakley <wcoakley@cumulusnetworks.com>
4 years agodoc: document `show pbr interface` directive
Wesley Coakley [Fri, 22 May 2020 13:07:00 +0000 (09:07 -0400)]
doc: document `show pbr interface` directive

Signed-off-by: Wesley Coakley <wcoakley@cumulusnetworks.com>
4 years agopbrd: `show` directives give arrays where appropos
Wesley Coakley [Thu, 21 May 2020 19:33:06 +0000 (15:33 -0400)]
pbrd: `show` directives give arrays where appropos

The new json output for the `show pbr` directives return arrays instead
of associative arrays, which are more meaningful in this context

Signed-off-by: Wesley Coakley <wcoakley@cumulusnetworks.com>
4 years agopbrd, lib: verbosity++ for json `show` directives
Wesley Coakley [Thu, 21 May 2020 19:18:34 +0000 (15:18 -0400)]
pbrd, lib: verbosity++ for json `show` directives

Increased the verbosity of the json keys and flattened the returned
structure by removing superfluous keys.

Signed-off-by: Wesley Coakley <wcoakley@cumulusnetworks.com>
4 years agopbrd, lib: opt. json for `show pbr nexthop-group`
Wesley Coakley [Wed, 20 May 2020 14:49:54 +0000 (10:49 -0400)]
pbrd, lib: opt. json for `show pbr nexthop-group`

Signed-off-by: Wesley Coakley <wcoakley@cumulusnetworks.com>
4 years agopbrd: optional json for `show pbr map`
Wesley Coakley [Tue, 19 May 2020 18:15:21 +0000 (13:15 -0500)]
pbrd: optional json for `show pbr map`

Signed-off-by: Wesley Coakley <wcoakley@cumulusnetworks.com>
4 years agopbrd: json added to `show pbr interface [json]`
Wesley Coakley [Mon, 18 May 2020 14:05:08 +0000 (10:05 -0400)]
pbrd: json added to `show pbr interface [json]`

Signed-off-by: Wesley Coakley <wcoakley@cumulusnetworks.com>
4 years agodoc: add dev doc for ubuntu 20.04
Mark Stapp [Wed, 27 May 2020 12:49:36 +0000 (08:49 -0400)]
doc: add dev doc for ubuntu 20.04

Add a doc for ubuntu 20 LTS; it's mainly the same as the 18 LTS
doc, with a couple of extra notes.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agodoc: add docs for frr-reload.py options
Emanuele Di Pascale [Wed, 20 May 2020 08:20:30 +0000 (10:20 +0200)]
doc: add docs for frr-reload.py options

Signed-off-by: Emanuele Di Pascale <emanuele@voltanet.io>
4 years agotools/frr-reload: --vty_socket arg
David Lamparter [Tue, 26 May 2020 17:12:24 +0000 (19:12 +0200)]
tools/frr-reload: --vty_socket arg

After the cleanup, adding this doesn't require updating a zillion
locations in the code anymore, just one :)

Partially derived from 6a00e91d99f7f98d857c2056d0dcfeba48966581

Originally-by: Emanuele Di Pascale <emanuele@voltanet.io>
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
4 years agotools/frr-reload: cleanup pass
David Lamparter [Fri, 6 Dec 2019 19:36:33 +0000 (20:36 +0100)]
tools/frr-reload: cleanup pass

- throw vtysh into a wrapper class
- ignore "username" commands
- use mark output on stdout
- some other random cleanups

Signed-off-by: David Lamparter <equinox@diac24.net>
4 years agovtysh: add "no-header" to show running-config
David Lamparter [Thu, 8 Aug 2019 18:04:52 +0000 (20:04 +0200)]
vtysh: add "no-header" to show running-config

... to skip the "Building configuration..." header that gets in the way
of automated processing.

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
4 years agovtysh: throw mark output on stdout, not stderr
David Lamparter [Fri, 6 Dec 2019 19:35:50 +0000 (20:35 +0100)]
vtysh: throw mark output on stdout, not stderr

Why is this on stderr...

Signed-off-by: David Lamparter <equinox@diac24.net>
4 years agoMerge pull request #6375 from adharkar/frr-master-l3vni_label
Russ White [Tue, 26 May 2020 16:14:16 +0000 (12:14 -0400)]
Merge pull request #6375 from adharkar/frr-master-l3vni_label

bgpd: EVPN RT-2 advertised with 2 labels for prefix-routes-only config

4 years agoMerge pull request #6463 from vivek-cumulus/evpn_extend_nht
Sri Mohana Singamsetty [Tue, 26 May 2020 15:18:29 +0000 (08:18 -0700)]
Merge pull request #6463 from vivek-cumulus/evpn_extend_nht

bgpd: Extend EVPN next hop tracking for additional EVPN routes

4 years agoMerge pull request #5881 from patrasar/2386420
Donald Sharp [Tue, 26 May 2020 13:21:10 +0000 (09:21 -0400)]
Merge pull request #5881 from patrasar/2386420

pimd: add show ip multicast count [json] command

4 years agoMerge pull request #6441 from opensourcerouting/ospf-doc
Russ White [Tue, 26 May 2020 11:45:30 +0000 (07:45 -0400)]
Merge pull request #6441 from opensourcerouting/ospf-doc

ospfd: small doc and cli changes

4 years agoMerge pull request #6445 from donaldsharp/really_start_all_daemons
Russ White [Tue, 26 May 2020 11:44:48 +0000 (07:44 -0400)]
Merge pull request #6445 from donaldsharp/really_start_all_daemons

tests: Turn on nhrpd and babeld as part of all-protocol-startup

4 years agoMerge pull request #6458 from vivek-cumulus/bgp_nht_command_enhance
Russ White [Tue, 26 May 2020 11:32:12 +0000 (07:32 -0400)]
Merge pull request #6458 from vivek-cumulus/bgp_nht_command_enhance

bgpd: Enhance BGP NHT show commands

4 years agoMerge pull request #6459 from vivek-cumulus/bgp_nht_fix
Russ White [Tue, 26 May 2020 11:29:25 +0000 (07:29 -0400)]
Merge pull request #6459 from vivek-cumulus/bgp_nht_fix

Fix BGP NHT to skip inappropriate paths & only act upon change

4 years agoMerge pull request #6462 from vivek-cumulus/lib_evpn_prefix_fix
Russ White [Tue, 26 May 2020 11:28:26 +0000 (07:28 -0400)]
Merge pull request #6462 from vivek-cumulus/lib_evpn_prefix_fix

lib: Minor update to EVPN type-5 prefix display

4 years agoospfd: Solve crash after removing and adding conf.
Olivier Dugeon [Fri, 15 May 2020 17:18:36 +0000 (19:18 +0200)]
ospfd: Solve crash after removing and adding conf.

Issue number #6291 describes how OSPFd crashes after being deleted and then
added again with configuration when segment routing is used.

The problem occurs in ospf_ri.c because the OspfRI structures retains
the reference to the old area pointer which is mofified when ospfd is
reactivated by configuration. When segment routing is activated, the LSA Router
Information is sent with reference to the old area pointer, instead the new one,
which causes the crash. The same problem is also present in ospf_ext.c with
OspfEXT structure and Extended Link/Prefix structure.

This commit introduces Extended Link/Prefix and Router Information LSAs flusing
when OSPFd is stopped when configuration is removed and adds the correct
initialization to the area pointer in OspfRI and Extended Link/Prefix structure
when OSPFd is re-enabled with the configuration. Area pointer has been removed
from the OspfEXT structure as it is never used with this commit.

Signed-off-by: Olivier Dugeon <olivier.dugeon@orange.com>
4 years agobgpd: Extend EVPN next hop tracking for additional EVPN routes
vivek [Tue, 26 May 2020 06:00:49 +0000 (23:00 -0700)]
bgpd: Extend EVPN next hop tracking for additional EVPN routes

Extend the next hop tracking for type-2 and type-3 EVPN routes also.

Updates: "bgpd: Add nexthop of received EVPN RT-5 for nexthop tracking"
Signed-off-by: Vivek Venkatraman <vivek@cumulusnetworks.com>
4 years agolib: Minor update to EVPN type-5 prefix display
vivek [Tue, 26 May 2020 05:40:44 +0000 (22:40 -0700)]
lib: Minor update to EVPN type-5 prefix display

Signed-off-by: Vivek Venkatraman <vivek@cumulusnetworks.com>
4 years agobgpd: During NHT change evaluation, skip inappropriate paths
vivek [Mon, 25 May 2020 21:17:12 +0000 (14:17 -0700)]
bgpd: During NHT change evaluation, skip inappropriate paths

When there is a NHT change and the paths dependent on that NHT are being
evaluated, skip those that are marked for removal or as history.

When a route gets withdrawn, its valid flag is cleared and it is flagged
for removal; in the case of an EVPN route, it is also unimported from
VRFs (L2 and/or L3). bgp_process is then scheduled. Under rare timing
conditions, an NHT update for the route's next hop may arrive right after,
and if routes flagged for removal are not skipped, they may not only be
incorrectly marked as valid but also re-imported in the case of EVPN,
which will be a serious error.

Signed-off-by: Vivek Venkatraman <vivek@cumulusnetworks.com>