]> git.puffer.fish Git - matthieu/frr.git/log
matthieu/frr.git
4 years agoMerge pull request #6703 from mjstapp/fix_bgp_30_secs
Donald Sharp [Fri, 10 Jul 2020 00:29:08 +0000 (20:29 -0400)]
Merge pull request #6703 from mjstapp/fix_bgp_30_secs

tests: print actual time spent waiting for bgp convergence

4 years agoMerge pull request #6708 from mrpaulmanley/bugfix/bfd_frr-reload
Donald Sharp [Fri, 10 Jul 2020 00:26:20 +0000 (20:26 -0400)]
Merge pull request #6708 from mrpaulmanley/bugfix/bfd_frr-reload

Add BFD peer awareness to frr-reload.py and vtysh markfile

4 years agoMerge pull request #6709 from mjstapp/fix_topo_ipaddr
Donald Sharp [Fri, 10 Jul 2020 00:20:36 +0000 (20:20 -0400)]
Merge pull request #6709 from mjstapp/fix_topo_ipaddr

tests: use ipaddress module; tolerate missing support bundle file

4 years agotest: use ipaddress module instead of ipaddr
Mark Stapp [Thu, 9 Jul 2020 16:32:10 +0000 (12:32 -0400)]
test: use ipaddress module instead of ipaddr

Use the standard ipaddress module instead of installing 'ipaddr',
which may be deprecated now.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agovtysh: properly exit BFD_PEER_NODE when marking file
Paul Manley [Thu, 9 Jul 2020 16:25:34 +0000 (11:25 -0500)]
vtysh: properly exit BFD_PEER_NODE when marking file

vtysh needs to be aware of how to properly exit a bfd peer when subsequent commands only succeed in a higher context.

https://github.com/FRRouting/frr/issues/6511#issuecomment-656166206

Signed-off-by: Paul Manley <paul.manley@wholefoods.com>
4 years agotools: create sub-context for bfd peers
Paul Manley [Thu, 9 Jul 2020 16:21:16 +0000 (11:21 -0500)]
tools: create sub-context for bfd peers

add lines starting with 'peer' to the list of sub-contexts that are handled by frr-reload.py.

https://github.com/FRRouting/frr/issues/6511#issuecomment-655163833

Signed-off-by: Paul Manley <paul.manley@wholefoods.com>
4 years agotests: don't fail topotests if bundle file not present
Mark Stapp [Thu, 9 Jul 2020 16:13:55 +0000 (12:13 -0400)]
tests: don't fail topotests if bundle file not present

Test for the existence of the support_bundle conf file before
trying to access it.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agotests: print actual time spent waiting for bgp convergence
Mark Stapp [Thu, 9 Jul 2020 13:51:16 +0000 (09:51 -0400)]
tests: print actual time spent waiting for bgp convergence

Stop printing hard-coded 30 seconds in a couple of places in
bgp.py in the topojson infra - print the actual time
spent waiting.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agoMerge pull request #6385 from GalaxyGorilla/bfd_igp_topotest
Renato Westphal [Wed, 8 Jul 2020 17:38:09 +0000 (14:38 -0300)]
Merge pull request #6385 from GalaxyGorilla/bfd_igp_topotest

isis: tests: Fast RIB recovery from BFD recognized link failures

4 years agoMerge pull request #6697 from donaldsharp/ospf_router_id_ordering
Mark Stapp [Wed, 8 Jul 2020 16:41:59 +0000 (12:41 -0400)]
Merge pull request #6697 from donaldsharp/ospf_router_id_ordering

ospfd: allow interfaces to come up in rare situation

4 years agoospfd: allow interfaces to come up in rare situation
Donald Sharp [Wed, 8 Jul 2020 01:48:34 +0000 (21:48 -0400)]
ospfd: allow interfaces to come up in rare situation

On startup of both zebra and ospfd.  If ospfd has not
received a valid router-id *but* has received interface
data, interfaces will not be turned on in the state
machine.  When ospf finally receives a valid router-id
it would never actually kick the state machine into
action for those interfaces it has been configured for.

Modify ospf on router id changes, *if* the old
router id was INADDR_ANY *and* the interface is
operative *and* the oi->state is ISM_Down, give
it the old kick in the patooeys

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agoMerge pull request #6693 from qlyoung/doc-value-initialization-practices
Donatas Abraitis [Wed, 8 Jul 2020 08:04:14 +0000 (11:04 +0300)]
Merge pull request #6693 from qlyoung/doc-value-initialization-practices

Document value initialization practices

4 years agoMerge pull request #6690 from kuldeepkash/bgp_basic_functionality
Donald Sharp [Tue, 7 Jul 2020 23:44:37 +0000 (19:44 -0400)]
Merge pull request #6690 from kuldeepkash/bgp_basic_functionality

tests: Generate support bundle/dump data on tests failures

4 years agoMerge pull request #6692 from mjstapp/fix_sharp_gcc10
Quentin Young [Tue, 7 Jul 2020 20:59:48 +0000 (16:59 -0400)]
Merge pull request #6692 from mjstapp/fix_sharp_gcc10

sharpd: use extern for globals

4 years agodoc: remove trailing whitespace
Quentin Young [Tue, 7 Jul 2020 17:56:14 +0000 (13:56 -0400)]
doc: remove trailing whitespace

Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
4 years agodoc: note preferences for value initialization
Quentin Young [Tue, 7 Jul 2020 17:55:43 +0000 (13:55 -0400)]
doc: note preferences for value initialization

Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
4 years agosharpd: use extern for globals
Mark Stapp [Tue, 7 Jul 2020 17:00:42 +0000 (13:00 -0400)]
sharpd: use extern for globals

Use extern when declaring a couple of globals in sharp_zebra.
gcc 10 on fedora 32 needs this.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agotests: Generate support bundle/dump data on tests failures
Kuldeep Kashyap [Tue, 7 Jul 2020 15:17:04 +0000 (15:17 +0000)]
tests: Generate support bundle/dump data on tests failures

1. It will generate support bundle/sump data on test failures
2. It used /usr/lib/frr/generate_support_bundle.py utility to dump the data

Signed-off-by: Kuldeep Kashyap <kashyapk@vmware.com>
4 years agoMerge pull request #6689 from mjstapp/doc_topotest_timeouts
Quentin Young [Tue, 7 Jul 2020 15:27:53 +0000 (11:27 -0400)]
Merge pull request #6689 from mjstapp/doc_topotest_timeouts

doc: add note about generous BGP topotest timeouts

4 years agoMerge pull request #6685 from donaldsharp/fix_rare_ospf_test_failure
Mark Stapp [Tue, 7 Jul 2020 14:38:26 +0000 (10:38 -0400)]
Merge pull request #6685 from donaldsharp/fix_rare_ospf_test_failure

tests: Fix rare case in ospf tests due to small hello timer

4 years agoMerge pull request #6687 from mjstapp/fix_topo_timeout_again
Donald Sharp [Tue, 7 Jul 2020 13:25:02 +0000 (09:25 -0400)]
Merge pull request #6687 from mjstapp/fix_topo_timeout_again

tests: fix short timeout in lib/bgp.py

4 years agodoc: add note about generous BGP topotest timeouts
Mark Stapp [Tue, 7 Jul 2020 12:55:31 +0000 (08:55 -0400)]
doc: add note about generous BGP topotest timeouts

Add note blocks to the topotest and topotest-json dev docs to
emphasize the need for generous BGP retry/convergence timers.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agotests: fix short timeout in lib/bgp.py
Mark Stapp [Tue, 7 Jul 2020 12:25:01 +0000 (08:25 -0400)]
tests: fix short timeout in lib/bgp.py

Another short timeout for bgp - make the
verify_bgp_convergence_from_running_config() api use the same
generous timeout as verify_bgp_convergence()

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agotests: Fix rare case in ospf tests due to small hello timer
Donald Sharp [Tue, 7 Jul 2020 11:36:54 +0000 (07:36 -0400)]
tests: Fix rare case in ospf tests due to small hello timer

There exists the possiblity that the hello timer printed would
show a time to expiration in this format:

Hello due in 350 usecs

The tests are looking for:

Hello due in 5.430s

Just notice that we may have gotten usecs and act accordingly

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agoMerge pull request #6656 from mjstapp/fix_lsp_del_schedule
Russ White [Tue, 7 Jul 2020 10:56:22 +0000 (06:56 -0400)]
Merge pull request #6656 from mjstapp/fix_lsp_del_schedule

zebra: check LSP flags when deleting an LSP

4 years agoMerge pull request #6675 from volta-networks/fix_isis_spf_assert
Quentin Young [Mon, 6 Jul 2020 18:41:27 +0000 (14:41 -0400)]
Merge pull request #6675 from volta-networks/fix_isis_spf_assert

isisd: gracefully handle spf error

4 years agoMerge pull request #6682 from qlyoung/doc-json-empty-output
Mark Stapp [Mon, 6 Jul 2020 18:25:00 +0000 (14:25 -0400)]
Merge pull request #6682 from qlyoung/doc-json-empty-output

doc: specify output for json commands w/ no output

4 years agoMerge pull request #6607 from kuldeepkash/bgp_basic_functionality
Mark Stapp [Mon, 6 Jul 2020 17:18:06 +0000 (13:18 -0400)]
Merge pull request #6607 from kuldeepkash/bgp_basic_functionality

tests: Add bgp_recursive_route_ebgp_multi_hop test suite

4 years agoMerge pull request #6681 from opensourcerouting/rmap-desc-leak-fix
Quentin Young [Mon, 6 Jul 2020 17:05:59 +0000 (13:05 -0400)]
Merge pull request #6681 from opensourcerouting/rmap-desc-leak-fix

lib: fix route map description memory leak

4 years agoMerge pull request #6114 from rgirada/frr-static
Quentin Young [Mon, 6 Jul 2020 17:04:43 +0000 (13:04 -0400)]
Merge pull request #6114 from rgirada/frr-static

pimd: Providing json support for few pim commands

4 years agolib: fix route map description memory leak
Rafael Zalamena [Mon, 6 Jul 2020 14:39:27 +0000 (11:39 -0300)]
lib: fix route map description memory leak

Route map entries are not getting a chance to call `description` string
deallocation on shutdown or when the parent entry is destroyed, so lets
add a code to handle this in the `route_map_index_delete` function.

Signed-off-by: Rafael Zalamena <rzalamena@opensourcerouting.org>
4 years agodoc: specify output for json commands w/ no output
Quentin Young [Mon, 6 Jul 2020 16:07:33 +0000 (12:07 -0400)]
doc: specify output for json commands w/ no output

JSON commands should always return valid JSON

Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
4 years agotests: Add bgp_recursive_route_ebgp_multi_hop test suite
Kuldeep Kashyap [Thu, 18 Jun 2020 11:33:31 +0000 (11:33 +0000)]
tests: Add bgp_recursive_route_ebgp_multi_hop test suite

1. Added 7 test cases to verify bgp recursive nexthop and ebgp multi-hop functionality
2. Added framework support to automate these test cases
3. Total execution time is ~5 mins

Signed-off-by: Kuldeep Kashyap <kashyapk@vmware.com>
4 years agoisisd: gracefully handle spf error
Emanuele Di Pascale [Fri, 3 Jul 2020 14:55:28 +0000 (16:55 +0200)]
isisd: gracefully handle spf error

the code in isis_spf_add2tent was asserting in case the vertex
we were trying to add was already present in the path or tent
trees. This however CAN happen if the user accidentally configures
the system Id of the area to the same value of an estabished
neighbor. Handle this more gracefully by logging and returning,
to prevent crashes.

Signed-off-by: Emanuele Di Pascale <emanuele@voltanet.io>
4 years agoMerge pull request #6628 from adharkar/frr-master-evpn_rt
Russ White [Sun, 5 Jul 2020 20:07:10 +0000 (16:07 -0400)]
Merge pull request #6628 from adharkar/frr-master-evpn_rt

bgpd: Incorrect auto-RT formed when L3VNI is not configured

4 years agozebra: check LSP flags when deleting an LSP
Mark Stapp [Tue, 30 Jun 2020 16:47:46 +0000 (12:47 -0400)]
zebra: check LSP flags when deleting an LSP

Check the LSP INSTALLED flag in delete apis, to ensure we
enqueue a delete operation for the lfib. Some apis were only
checking the nexthop/nhlfe INSTALLED flags, and those could be
unset if there's an in-flight dataplane update.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agoMerge pull request #6678 from mjstapp/fix_topo_zebra
Donald Sharp [Sun, 5 Jul 2020 16:41:32 +0000 (12:41 -0400)]
Merge pull request #6678 from mjstapp/fix_topo_zebra

tests,zebra: fix more startup topotest issues

4 years agoMerge pull request #6646 from xThaid/dplane_batching1
Mark Stapp [Sun, 5 Jul 2020 16:41:23 +0000 (12:41 -0400)]
Merge pull request #6646 from xThaid/dplane_batching1

zebra: prepare dplane for batching

4 years agotests,zebra: fix more startup topotest issues
Mark Stapp [Sat, 4 Jul 2020 16:25:10 +0000 (12:25 -0400)]
tests,zebra: fix more startup topotest issues

Use the right list of daemons to avoid trying to start zebra twice.
Change a zebra log message to INFO level to avoid stderr check
failure.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agoMerge pull request #6666 from donaldsharp/pbr_interface
Donatas Abraitis [Sat, 4 Jul 2020 06:07:24 +0000 (09:07 +0300)]
Merge pull request #6666 from donaldsharp/pbr_interface

pbrd: Be a bit more lenient with `set nexthop A.B.C.D <intf>`

4 years agoMerge pull request #6677 from mjstapp/fix_topo_daemons
Donald Sharp [Fri, 3 Jul 2020 23:10:50 +0000 (19:10 -0400)]
Merge pull request #6677 from mjstapp/fix_topo_daemons

tests: wait longer when shutting down in topotests

4 years agoMerge pull request #6676 from mjstapp/fix_bfd_profile_sa
Donald Sharp [Fri, 3 Jul 2020 23:10:01 +0000 (19:10 -0400)]
Merge pull request #6676 from mjstapp/fix_bfd_profile_sa

bfdd: Use XFREE when freeing bfd profiles

4 years agoMerge pull request #6654 from donaldsharp/sorted
Sri Mohana Singamsetty [Fri, 3 Jul 2020 20:43:05 +0000 (13:43 -0700)]
Merge pull request #6654 from donaldsharp/sorted

Sorted vtysh commands

4 years agotests: wait longer when shutting down in topotests
Mark Stapp [Fri, 3 Jul 2020 17:22:42 +0000 (13:22 -0400)]
tests: wait longer when shutting down in topotests

Add a few retries during router shutdown before killing a daemon. Also
work harder to start only a single instance of daemons, esp. zebra.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agobfdd: Use XFREE, clean up SA warning for bfd profiles
Mark Stapp [Fri, 3 Jul 2020 15:43:00 +0000 (11:43 -0400)]
bfdd: Use XFREE, clean up SA warning for bfd profiles

Use XFREE instead of raw free, clean up SA warning in bfd
profile delete.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agoMerge pull request #6669 from ton31337/fix/large-community-list-set_sequence
Donald Sharp [Fri, 3 Jul 2020 11:47:28 +0000 (07:47 -0400)]
Merge pull request #6669 from ton31337/fix/large-community-list-set_sequence

bgpd: Actually find the sequence number for large-community-list

4 years agoMerge pull request #6671 from opensourcerouting/topostart-refactory
Donald Sharp [Fri, 3 Jul 2020 11:46:43 +0000 (07:46 -0400)]
Merge pull request #6671 from opensourcerouting/topostart-refactory

topotests: FRR start procedure improvements

4 years agoMerge pull request #6672 from pjdruddy/pr-l3vpn-rt-change-fix
Donald Sharp [Fri, 3 Jul 2020 11:44:20 +0000 (07:44 -0400)]
Merge pull request #6672 from pjdruddy/pr-l3vpn-rt-change-fix

bgpd: detect change of RT for L3VPN routes

4 years agoisisd: Fast RIB recovery from BFD recognized link failures
GalaxyGorilla [Tue, 19 May 2020 11:52:04 +0000 (11:52 +0000)]
isisd: Fast RIB recovery from BFD recognized link failures

Unfortunately as the topotests show a fast recovery after failure
detection due to BFD is currently not possible because of the following
issue:

There are multiple scheduling mechanisms within isisd to prevent
overload situations. Regarding our problem these two are important:

* scheduler for regenerating ISIS Link State PDUs scheduler for managing
* consecutive SPF calculations

In fact both schedulers are coupled, the first one triggers the second
one, which again is triggered by isis_adj_state_change (which again is
triggered by a BFD 'down' message). The re-calculation of SPF paths
finally triggers updates in zebra for the RIB.

Both schedulers work as a throttle, e.g. they allow the regeneration of
Link State PDUs or a re-calculation for SPF paths only once within a
certain time interval which is configurable (and by default different!).

This means that a request can go through the first scheduler but might
still be 'stuck' at the second one for a while. Or a request can be
'stuck' at the first scheduler even though the second one is ready. This
also explains the 'random' behaviour one can observe testing since a
'fast' recovery is only possible if both schedulers are ready to process
this request.

Note that the solution in this commit is 'thread safe' in the sense that
both schedulers use the same thread master such that the introduced
flags are only used exactly one time (and one after another) for a
'fast' execution.

Further there are some irritating comments and logs which I partially
removed. They seems to be not valid anymore due to changes in thread
management (or they were never valid in the first place).

Signed-off-by: GalaxyGorilla <sascha@netdef.org>
4 years agotests: Introduce BFD IS-IS topotests
GalaxyGorilla [Tue, 12 May 2020 11:49:58 +0000 (11:49 +0000)]
tests: Introduce BFD IS-IS topotests

The tests work with the default settings of BFD meaning that bfdd is
able to recognize a 'down' link after ~900ms so a route recovery should
be visible in the RIB after 1 second.

In the current state only IPv4 is used (when using IPv6
autoconfiguration) within BFD, even though the recovery also affects
IPv6 routes. This is different to the current state of ospfd/ospf6d in
combination with BFD since both IPv4 and IPv6 sessions are used there.

The following topology is used:

                        +---------+
                        |         |
           eth-rt2 (.1) |   RT1   | eth-rt3 (.1)
             +----------+ 1.1.1.1 +----------+
             |          |         |          |
             |          +---------+          |
             |                               |
             |                   10.0.2.0/24 |
             |                               |
             |                       eth-rt1 | (.2)
             | 10.0.1.0/24              +----+----+
             |                          |         |
             |                          |   RT3   |
             |                          | 3.3.3.3 |
             |                          |         |
        (.2) | eth-rt1                  +----+----+
        +----+----+                  eth-rt4 | (.1)
        |         |                          |
        |   RT2   |                          |
        | 2.2.2.2 |              10.0.4.0/24 |
        |         |                          |
        +----+----+                          |
        (.1) | eth-rt5               eth-rt3 | (.2)
             |                          +----+----+
             |                          |         |
             |                          |   RT4   |
             |                          | 4.4.4.4 |
             |                          |         |
             |                          +----+----+
             | 10.0.3.0/24           eth-rt5 | (.1)
             |                               |
             |                               |
             |                   10.0.5.0/24 |
             |                               |
             |          +---------+          |
             |          |         |          |
             +----------+   RT5   +----------+
           eth-rt2 (.2) | 5.5.5.5 | eth-rt4 (.2)
                        |         |
                        +---------+

Route recovery is tested on RT1. The focus here lies on the two
different routes to RT5. Link failures are generated by taking
down interfaces via the mininet Python interface on RT2 and RT3.
Hence routes are supposed to be adjusted to use RT3 when a link
failure happens on RT2 or vice versa.

Note that only failure recognition and recovery is "fast". BFD
does not monitor a link becoming available again.

Signed-off-by: GalaxyGorilla <sascha@netdef.org>
4 years agobgpd: detect change of RT for L3VPN routes
Pat Ruddy [Thu, 2 Jul 2020 16:33:37 +0000 (17:33 +0100)]
bgpd: detect change of RT for L3VPN routes

If the RT changes on a L3VPN route then any leak of this route into
a VRF should be withdrawn.
Extend existing EVPN check for RT change to cover L3VPN routes.

Signed-off-by: Pat Ruddy <pat@voltanet.io>
4 years agotopotests: remove daemons start up sleep
Rafael Zalamena [Thu, 2 Jul 2020 17:51:37 +0000 (14:51 -0300)]
topotests: remove daemons start up sleep

Instead of waiting for daemons start with `sleep`, start them with the
`-d` parameter so they can release the terminal themselves when ready.

Signed-off-by: Rafael Zalamena <rzalamena@opensourcerouting.org>
4 years agotopotests: start logging early
Rafael Zalamena [Thu, 2 Jul 2020 17:49:25 +0000 (14:49 -0300)]
topotests: start logging early

Start logging early everything (including debug) to
`/tmp/topotest/<test>/<node>/<daemon>.{out,err}`.

Signed-off-by: Rafael Zalamena <rzalamena@opensourcerouting.org>
4 years agotopotests: remove duplicated code
Rafael Zalamena [Thu, 2 Jul 2020 17:47:28 +0000 (14:47 -0300)]
topotests: remove duplicated code

Handle the duplicated code with a simple conditional: if called from
specialized API use provided daemons configuration, otherwise fallback
to old `Router` own daemon settings.

Signed-off-by: Rafael Zalamena <rzalamena@opensourcerouting.org>
4 years agoMerge pull request #6437 from opensourcerouting/bfd-profiles-bgp
Donald Sharp [Thu, 2 Jul 2020 16:22:44 +0000 (12:22 -0400)]
Merge pull request #6437 from opensourcerouting/bfd-profiles-bgp

bfdd,bgpd: profiles integration support

4 years agoMerge pull request #6667 from ton31337/fix/bool_return_bgpd
Donald Sharp [Thu, 2 Jul 2020 13:32:09 +0000 (09:32 -0400)]
Merge pull request #6667 from ton31337/fix/bool_return_bgpd

bgpd: Return bool type for ecommunity_add_val and subgroup_announce_check

4 years agoMerge pull request #6590 from streambinder/master
Donald Sharp [Thu, 2 Jul 2020 11:56:08 +0000 (07:56 -0400)]
Merge pull request #6590 from streambinder/master

bgpd: bmp: add support for L2VPN/EVPN routes

4 years agobgpd: Actually find the sequence number for large-community-list
Donatas Abraitis [Thu, 2 Jul 2020 08:39:40 +0000 (11:39 +0300)]
bgpd: Actually find the sequence number for large-community-list

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
4 years agotools: Catch argv_find() cases when testing only the index
Donatas Abraitis [Thu, 2 Jul 2020 08:39:29 +0000 (11:39 +0300)]
tools: Catch argv_find() cases when testing only the index

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
4 years agobgpd: Return bool type for ecommunity_add_val and subgroup_announce_check
Donatas Abraitis [Thu, 2 Jul 2020 08:08:29 +0000 (11:08 +0300)]
bgpd: Return bool type for ecommunity_add_val and subgroup_announce_check

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
4 years agoMerge pull request #6661 from donaldsharp/flag_is_singular
Donatas Abraitis [Thu, 2 Jul 2020 05:19:38 +0000 (08:19 +0300)]
Merge pull request #6661 from donaldsharp/flag_is_singular

bgpd: peer_af_flag_modify_vty assumes 1 flag at a time

4 years agoMerge pull request #6665 from volta-networks/fix_isis_adj_log
Donald Sharp [Thu, 2 Jul 2020 01:32:54 +0000 (21:32 -0400)]
Merge pull request #6665 from volta-networks/fix_isis_adj_log

isisd: log adj change when circuit goes down

4 years agopbrd: Be a bit more lenient with `set nexthop A.B.C.D <intf>`
Donald Sharp [Tue, 30 Jun 2020 15:16:36 +0000 (11:16 -0400)]
pbrd: Be a bit more lenient with `set nexthop A.B.C.D <intf>`

When specifying an interface in a pbr-map `set nexthop ..` command
be a bit more lenient about the interface.

a) If the interface does not exist bail on the command
    (this is the same)
b) If the interface exists but is in a different vrf
   than specified use the vrf it is actually in.
    (this is new behavior)

Ticket: CM-30187
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agoMerge pull request #6663 from wesleycoakley/qobj-unreg-fixup
Mark Stapp [Wed, 1 Jul 2020 19:48:38 +0000 (15:48 -0400)]
Merge pull request #6663 from wesleycoakley/qobj-unreg-fixup

pbrd, lib: remember to free alloc'd qobj elements on delete

4 years agoisisd: log adj change when circuit goes down
Emanuele Di Pascale [Wed, 1 Jul 2020 17:37:16 +0000 (19:37 +0200)]
isisd: log adj change when circuit goes down

if we shutdown an interface isisd will delete the adjacencies
on the corresponding circuit, but it will not log the change.
Fix it to make sure that each change is logged. Also specify
the level of the adjacency in the log message, while we are at it.

Signed-off-by: Emanuele Di Pascale <emanuele@voltanet.io>
4 years agobgpd: peer_af_flag_modify_vty assumes 1 flag at a time
Donald Sharp [Wed, 1 Jul 2020 13:00:59 +0000 (09:00 -0400)]
bgpd: peer_af_flag_modify_vty assumes 1 flag at a time

We have a bunch of code in bgp_vty.c that was passing
to peer_af_flag_modify_vty more than 1 flag at a time.
This was causing the underlying routines to get the
flags wrong.  In order to prevent this convert all the
places where we send multiple flags down to this function
to individual flag changes.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agopbrd, lib: remember to free alloc'd qobj on delete
Wesley Coakley [Wed, 1 Jul 2020 01:21:17 +0000 (01:21 +0000)]
pbrd, lib: remember to free alloc'd qobj on delete

Signed-off-by: Wesley Coakley <wcoakley@nvidia.com>
4 years agoMerge pull request #6657 from donaldsharp/pbr_disable_on_4.9
Mark Stapp [Wed, 1 Jul 2020 11:45:17 +0000 (07:45 -0400)]
Merge pull request #6657 from donaldsharp/pbr_disable_on_4.9

tests: pbr is not working properly on arm 4.9 kernels

4 years agotests: pbr is not working properly on arm 4.9 kernels
Donald Sharp [Tue, 30 Jun 2020 19:10:20 +0000 (15:10 -0400)]
tests: pbr is not working properly on arm 4.9 kernels

Just disable pbr tests on anything less than 4.10.

This has to do with the fact that the arm platform
is not allowing us to install a route into a
non default table using a interface associated
with a vrf.

ip route add default 4.5.6.7 via swp39 table 10000

When swp39 is in a vrf other than default

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agovtysh: Improve lookup performance
Donald Sharp [Tue, 30 Jun 2020 13:03:55 +0000 (09:03 -0400)]
vtysh: Improve lookup performance

When we find the line we are interested in, stop looking.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agovtysh: master is a non-sorted list
Donald Sharp [Tue, 30 Jun 2020 12:59:46 +0000 (08:59 -0400)]
vtysh: master is a non-sorted list

The commit:
a798241265a5808083a06b14ce1637d1ddf6a45a

attempted to use sorted master lists to do faster lookups
by using a RB Tree.  Unfortunately the original code
was creating a list->cmp function *but* never using it.
If you look at the commit, it clearly shows that the
function listnode_add is used to insert but when you
look at that function it is a tail push.

Fixes: #6573
Namely now this ordering is preserved:
bgp as-path access-list originate-only permit ^$
bgp as-path access-list originate-only deny .*

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agobgpd: bmp: add support for L2VPN/EVPN routes
streambinder [Tue, 30 Jun 2020 12:37:00 +0000 (14:37 +0200)]
bgpd: bmp: add support for L2VPN/EVPN routes

Co-authored-by: giacomo270197 <gcasoni@hotmail.it>
Signed-off-by: streambinder <posta@davidepucci.it>
4 years agoMerge pull request #6645 from pguibert6WIND/maxpathlunicast
Donatas Abraitis [Mon, 29 Jun 2020 11:06:56 +0000 (14:06 +0300)]
Merge pull request #6645 from pguibert6WIND/maxpathlunicast

bgpd: add maximum-paths vty command to ipv6 lu node

4 years agobgpd: add maximum-paths vty command to ipv4 lu node
Philippe Guibert [Fri, 26 Jun 2020 12:39:04 +0000 (14:39 +0200)]
bgpd: add maximum-paths vty command to ipv4 lu node

add maximum-paths vty command to ipv4 lu node.

Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
4 years agoMerge pull request #6643 from mjstapp/fix_typos_bgp_multivrf1
Donatas Abraitis [Sat, 27 Jun 2020 15:41:20 +0000 (18:41 +0300)]
Merge pull request #6643 from mjstapp/fix_typos_bgp_multivrf1

test: fix some typos in bgp_multi_vrf_topo1

4 years agoMerge pull request #6635 from Niral-Networks/niral_dev_vrf_isis
Renato Westphal [Sat, 27 Jun 2020 01:23:40 +0000 (22:23 -0300)]
Merge pull request #6635 from Niral-Networks/niral_dev_vrf_isis

ISIS VRF: Added vrf_socket and new param in isisd privileges.

4 years agozebra: prepare data plane for batching
Jakub Urbańczyk [Wed, 24 Jun 2020 11:33:08 +0000 (13:33 +0200)]
zebra: prepare data plane for batching

 * Add new zebra_dplane_result to allow kernel updates not to return
   a result immediately.

Signed-off-by: Jakub Urbańczyk <xthaid@gmail.com>
4 years agoMerge pull request #6639 from qlyoung/fix-alpine-pkg-arch
Donatas Abraitis [Fri, 26 Jun 2020 16:14:49 +0000 (19:14 +0300)]
Merge pull request #6639 from qlyoung/fix-alpine-pkg-arch

alpine: enable multi-arch builds

4 years agoMerge pull request #6644 from donaldsharp/more_pbr_debugs_for_arm
Mark Stapp [Fri, 26 Jun 2020 16:04:26 +0000 (12:04 -0400)]
Merge pull request #6644 from donaldsharp/more_pbr_debugs_for_arm

tests: Add some more data gathering

4 years agoMerge pull request #6640 from qlyoung/doc-docker-builds
Donatas Abraitis [Fri, 26 Jun 2020 15:18:43 +0000 (18:18 +0300)]
Merge pull request #6640 from qlyoung/doc-docker-builds

doc: add docker image build instructions

4 years agotests: Add some more data gathering
Donald Sharp [Fri, 26 Jun 2020 11:10:08 +0000 (07:10 -0400)]
tests: Add some more data gathering

From last addition we can tell that the nexthop-group C is
installed but pbr does not think it is.  This failure
has been consistent the last 4-5 runs in master.  Lets
add a bit more data gathering to figure out what is going on.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agotest: fix some typos in bgp_multi_vrf_topo1
Mark Stapp [Thu, 25 Jun 2020 17:43:37 +0000 (13:43 -0400)]
test: fix some typos in bgp_multi_vrf_topo1

Noticed a few text things in this topotest.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agoMerge pull request #6611 from mjstapp/fix_rib_comparisons
Donald Sharp [Thu, 25 Jun 2020 16:33:25 +0000 (12:33 -0400)]
Merge pull request #6611 from mjstapp/fix_rib_comparisons

zebra: improve route_entry comparison logic

4 years agoMerge pull request #6642 from donaldsharp/forgotten_daemons
Donatas Abraitis [Thu, 25 Jun 2020 15:48:11 +0000 (18:48 +0300)]
Merge pull request #6642 from donaldsharp/forgotten_daemons

Forgotten daemons

4 years agoMerge pull request #6630 from opensourcerouting/bgp-node-dest-rename
Donald Sharp [Thu, 25 Jun 2020 13:14:18 +0000 (09:14 -0400)]
Merge pull request #6630 from opensourcerouting/bgp-node-dest-rename

bgp: rename bgp_node to bgp_dest

4 years agoMerge pull request #6619 from Niral-Networks/niral_isis_debug_p2
Donald Sharp [Thu, 25 Jun 2020 13:07:42 +0000 (09:07 -0400)]
Merge pull request #6619 from Niral-Networks/niral_isis_debug_p2

ISIS VRF: ISIS Debug structure modifications Type 2

4 years agoMerge pull request #6641 from donaldsharp/bgp_sighup_is_bad
Mark Stapp [Thu, 25 Jun 2020 12:28:57 +0000 (08:28 -0400)]
Merge pull request #6641 from donaldsharp/bgp_sighup_is_bad

bgpd: Have bgp ignore SIGHUP at the moment

4 years agozebra: improve route_entry comparison logic
Mark Stapp [Thu, 18 Jun 2020 17:26:47 +0000 (13:26 -0400)]
zebra: improve route_entry comparison logic

Improve and centralize some logic used to a) compare two
route_entries, and b) to locate a route_entry that matches
a dplane context object that contains the results of a
fib update. We were not rigorous enough in checking routes'
properties, especially when examining connected routes where
we allow multiple route_entries.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agoMerge pull request #6636 from mjstapp/fix_topojson_intf_names
Donald Sharp [Thu, 25 Jun 2020 12:19:59 +0000 (08:19 -0400)]
Merge pull request #6636 from mjstapp/fix_topojson_intf_names

tests: in topojson framework, include vrf with interface name

4 years agodebian: Add missing daemons to logrotation knowledge
Donald Sharp [Thu, 25 Jun 2020 11:13:50 +0000 (07:13 -0400)]
debian: Add missing daemons to logrotation knowledge

Update missing daemons to rotate as well.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agoredhat: Update logrotate to have knowledge of all daemons
Donald Sharp [Thu, 25 Jun 2020 11:12:59 +0000 (07:12 -0400)]
redhat: Update logrotate to have knowledge of all daemons

Upon visual inspection the redhat logrotate file was incomplete
Make it complete.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agobgpd: Have bgp ignore SIGHUP at the moment
Donald Sharp [Thu, 25 Jun 2020 00:15:12 +0000 (20:15 -0400)]
bgpd: Have bgp ignore SIGHUP at the moment

SIGHUP is ostensibly supposed to reload configuration
from a fresh slate.  This is currently horribly broken
so much so that bgp just crashes.  I see no point
in trying to make this work considering the yang
work coming down the pike.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agodoc: add docker image build instructions
Quentin Young [Wed, 24 Jun 2020 23:11:33 +0000 (19:11 -0400)]
doc: add docker image build instructions

Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
4 years agoalpine: enable multi-arch builds
Quentin Young [Wed, 24 Jun 2020 20:33:18 +0000 (16:33 -0400)]
alpine: enable multi-arch builds

Now that amd64 dependencies have been removed we can use the correct
architecture specifier for Alpine packaging metadata in order to build
packages for all supported platforms.

Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
4 years agoMerge pull request #6637 from donaldsharp/frr_reload_ipv6
Mark Stapp [Wed, 24 Jun 2020 20:30:27 +0000 (16:30 -0400)]
Merge pull request #6637 from donaldsharp/frr_reload_ipv6

tools: Fix reload with 'ipv6 address...' in interface

4 years agotools: Fix reload with 'ipv6 address...' in interface
Donald Sharp [Wed, 24 Jun 2020 18:30:49 +0000 (14:30 -0400)]
tools: Fix reload with 'ipv6 address...' in interface

When you have this configuration:

int foo
  ipv6 address fd01:0:0:1::1/64

And issue a reload statement, FRR-reload
is reducing the code to a
`no ipv6 address fd01:0:0:1::/64`
and then issuing a:
`ipv6 address fd01:0:0:1::/64`

The end result is of course that the foo
interface now has two v6 addresses on it.

The brilliance of this is of course if you
happen to have two systems that are connected
over an interface, and you issue a reload command.
They both get fd01:0:0:1::/64 as an ipv6 address
and DAD detection kicks in and stomps on your stuff.

Put a special hey don't munch the v6 address line
in a reload situation.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
4 years agotests: fix interface and debug config diff in topojson framework
Mark Stapp [Wed, 24 Jun 2020 13:27:05 +0000 (09:27 -0400)]
tests: fix interface and debug config diff in topojson framework

Include vrf name with interface name when topojson framework
generates interface configuration. This matches the output of
'show runn', and makes config reset less disruptive. Also
stop removing configured debugs and log output when re-generating
config.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
4 years agoISIS VRF: Added vrf_socket and new param in isisd privileges.
Kaushik [Wed, 24 Jun 2020 12:27:14 +0000 (05:27 -0700)]
ISIS VRF: Added vrf_socket and new param in isisd privileges.

1. The socket() call replaced with vrf_socket() in open_packet_socket().
2. One new isisd privileges is added in zebra_capabilities_t [].

Signed-off-by: Kaushik <kaushik@niralnetworks.com>
4 years agoMerge pull request #6632 from donaldsharp/pbr_data_gathering
Mark Stapp [Wed, 24 Jun 2020 11:43:07 +0000 (07:43 -0400)]
Merge pull request #6632 from donaldsharp/pbr_data_gathering

tests: the pbr topo1 test is failing gather data to help debug

4 years agoISIS VRF: ISIS Debug structure modifications
harios [Fri, 19 Jun 2020 19:04:33 +0000 (00:34 +0530)]
ISIS VRF: ISIS Debug structure modifications

1. The "isis->debug" variable dependency on debug logs print is removed.

Signed-off-by: harios <hari@niralnetworks.com>