Commit graph

23794 commits

Author SHA1 Message Date
David Lamparter 09781197b6 build: make builddir include path consistent
... by referencing all autogenerated headers relative to the root
directory.  (90% of the changes here is `version.h`.)

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2021-04-21 15:42:33 +02:00
David Lamparter 9219708b13 build: fix protobuf out-of-tree build
Otherwise it aborts with "File does not reside within any path specified
using --proto_path (or -I)"

Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2021-04-21 11:13:25 +02:00
Igor Ryzhov bf6005d5f4
Merge pull request #8516 from patrasar/pim_register_suppress_time_crash 2021-04-21 00:07:36 +03:00
Mark Stapp adb7fb636f Merge pull request #8505 from mobash-rasool/ospfv3-max-path
ospf6d: Do not delete external table when configure max-path
2021-04-20 15:37:00 -04:00
Mark Stapp fe390fafc5
Merge pull request #8482 from wesleycoakley/docker-prefer-cmd-to-entrypoint
docker: prefer CMD to ENTRYPOINT for flexibility
2021-04-20 11:58:44 -04:00
Russ White 2bbf1bd88b
Merge pull request #8361 from rameshabhinay/change_1
bgpd: vrf route leaking related fixes
2021-04-20 11:23:49 -04:00
Russ White 8c3d6b8be5
Merge pull request #8455 from achernavin22/ospf_nssa_after_redist2
ospfd: install Type-7 when NSSA area is configured after redistribution
2021-04-20 10:28:49 -04:00
Russ White 0ab9f53044
Merge pull request #8456 from donaldsharp/idle_to_active
bgpd: Address LL peer not NHT when receiving connection attempt
2021-04-20 10:24:37 -04:00
Donald Sharp 9c95ede706
Merge pull request #8501 from ton31337/fix/replace_community_check
bgpd: Check for flag existense for community instead of `if not NULL`
2021-04-20 09:10:30 -04:00
Russ White 7408af70f5
Merge pull request #8373 from mjstapp/fix_ospf_timeval_dump
ospfd: show seconds in timeval_dump
2021-04-20 07:39:50 -04:00
Sarita Patra 6f5f05029c pimd: fix crash pim register-suppress-time command
Signed-off-by: Sarita Patra <saritap@vmware.com>
2021-04-20 03:57:50 -07:00
Donald Sharp 117d216ba0
Merge pull request #8503 from opensourcerouting/one-backtrace-is-enough
lib: 640k backtraces should be enough for everybody
2021-04-20 06:11:13 -04:00
Donald Sharp 0433e60cb3
Merge pull request #8511 from idryzhov/doc-fix-ospfd-maxpath
doc: fix ospfd maximum-paths command
2021-04-20 06:10:37 -04:00
Sri Mohana Singamsetty 97444b25ad
Merge pull request #8500 from ton31337/fix/indentation_for_show_ip_bgp_large_community_list_cmd
bgpd: Fix clang-format/indentation for show_ip_bgp_large_community_list_cmd
2021-04-19 17:12:24 -07:00
Igor Ryzhov 25d6c9671b doc: fix ospfd maximum-paths command
Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
2021-04-19 17:51:55 +03:00
Mobashshera Rasool ffdc63f9b4 ospf6d: Do not delete external table when configure max-path
Issue: When maximum-path is configured in ospf6 view, the
function ospf6_restart_spf deletes the external table as well
which is not required since that stores the redistribute routes.

Signed-off-by: Mobashshera Rasool <mrasool@vmware.com>
2021-04-19 05:28:24 +00:00
David Lamparter 4b4935bbc2 lib: fix bogus unlinkat() warning in zlog TLS exit
Only try to unlink the buffer if we actually set it up beforehand...

Signed-off-by: David Lamparter <equinox@diac24.net>
2021-04-19 05:47:09 +02:00
David Lamparter 5be4799dc5 lib: don't print 2 backtraces for crashes
abort() raises SIGABRT, which would confusingly cause a 2nd backtrace to
be printed after the first one...

Signed-off-by: David Lamparter <equinox@diac24.net>
2021-04-19 05:35:04 +02:00
Igor Ryzhov 8d31c67c79
Merge pull request #8502 from ranjanyash54/core_dump
ospf6d: Fix coredump when "no interface IFNAME area <A.B.C.D>" is called
2021-04-18 18:23:01 +03:00
Yash Ranjan f85a41124b ospf6d: Fix coredump when "no interface IFNAME area <A.B.C.D>" is called
When oi->area == NULL, it tries to print the
interface's area name, but no area is present.
Print the area name from the command argument instead.

Signed-off-by: Yash Ranjan <ranjany@vmware.com>
2021-04-18 04:22:56 -07:00
David Lamparter 79ec61be27
Merge pull request #8491 from qlyoung/fix-alpine-libelf-dev-build 2021-04-18 08:50:20 +02:00
Donatas Abraitis 29e72930b1 bgpd: Check for flag existense for community instead of if not NULL
Absolutetly cosmetic change, but let it be consistent with other checks
for optional attributes.

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
2021-04-18 07:56:39 +03:00
Donatas Abraitis ef3364f0f5 bgpd: Fix clang-format/indentation for show_ip_bgp_large_community_list_cmd
Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
2021-04-18 07:52:07 +03:00
Martin Winter 6e0368f61a
Merge pull request #8434 from donaldsharp/python_bullshit
Python pylint stuff
2021-04-16 23:17:04 +02:00
Mark Stapp c1f42d2614
Merge pull request #8490 from qlyoung/fix-bgp-handle-socket-read-errors-in-main-pthread
bgpd: fix uninit value when handling bgp read errs
2021-04-16 16:07:50 -04:00
Wesley Coakley 3a33be1329
docker: prefer CMD to ENTRYPOINT
Specifying watchfrr as CMD instead of ENTRYPOINT allows one to easily
override this command when starting a docker container. This allows
simple, manual testing via (e.g.) bash. With ENTRYPOINT only the
container will simply explode with an exit code if watchfrr exits.

For instance one could start a shell session in this container via:

```
docker run --name test --rm -i -t <frr-container> bash
```

The default behavior (`docker run <frr-container>` with no command
specified) is not changed.

Signed-off-by: Wesley Coakley <wcoakley@nvidia.com>
2021-04-16 13:05:44 -04:00
Quentin Young 9513086d4e docker: pin alpine base image to 3.13
'latest' isn't appropriate for us

Signed-off-by: Quentin Young <qlyoung@nvidia.com>
2021-04-16 13:02:18 -04:00
Quentin Young daff938c7e alpine: add missing libelf-dev dependency
Signed-off-by: Quentin Young <qlyoung@nvidia.com>
2021-04-16 13:02:15 -04:00
Mark Stapp 861ea6f268
Merge pull request #8465 from opensourcerouting/vtysh-scan-snafu
fix vtysh_scan SNAFUs
2021-04-16 08:23:20 -04:00
Quentin Young b8cfb2cd41 bgpd: fix uninit value when handling bgp read errs
Compiler warns about uninitialized value, although in practice it is
unreachable.

Also updates a function comment explaining what that value does.

Signed-off-by: Quentin Young <qlyoung@nvidia.com>
2021-04-15 18:07:44 -04:00
David Lamparter 010bf6f1ca python: add demo checker tool using frr.xref
More of a demo on what to do with the frr.xref file, but also slightly
useful in finding vtysh SNAFUs :)

Signed-off-by: David Lamparter <equinox@diac24.net>
2021-04-15 23:12:45 +02:00
David Lamparter ee4dcee834 vtysh: add lib/thread.c to vtysh_scan
Signed-off-by: David Lamparter <equinox@diac24.net>
2021-04-15 23:12:45 +02:00
David Lamparter 9cb089fc43 vtysh: add lib/resolver.c to vtysh_scan
Signed-off-by: David Lamparter <equinox@diac24.net>
2021-04-15 23:12:45 +02:00
David Lamparter c4e57cd52e vtysh: add lib/spf_backoff.c to vtysh_scan
Signed-off-by: David Lamparter <equinox@diac24.net>
2021-04-15 23:12:45 +02:00
David Lamparter 48843422d3 vtysh: add lib/log_vty.c to vtysh_scan
Rather than copying everything over, include the file in vtysh_scan for
automatic pickup.

Signed-off-by: David Lamparter <equinox@diac24.net>
2021-04-15 23:12:45 +02:00
Quentin Young dc92ca52c5
Merge pull request #8483 from opensourcerouting/asan-fix
lib: disable ASAN redzone around xref_p/xref_array
2021-04-15 20:46:35 +00:00
Donald Sharp 996319e63d bgpd: Address LL peer not NHT when receiving connection attempt
The new LL code in:
8761cd6ddb

Introduced the idea of the bgp unnumbered peers using interface up/down
events to track the bgp peers nexthop.  This code was not properly
working when a connection was received from a peer in some circumstances.

Effectively the connection from a peer was immediately skipping state transitions
and FRR was never properly tracking the peers nexthop.  When we receive the
connection attempt, let's track the nexthop now.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2021-04-15 13:16:28 -04:00
Martin Winter 0575d5a8f8
Merge pull request #8437 from donaldsharp/verify_bgp_community_no_sleep
tests: Do not sleep(5) when verifying bgp communities
2021-04-15 14:03:37 +02:00
Donald Sharp afbb000e26 tests: test_bgp_vrf_dynamic_route_leak_topo1.py was missing a variable
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2021-04-15 07:17:10 -04:00
Donald Sharp 6882ab5e7f tests: Fix test_bgp_multi_vrf_topo2.py string formatting
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2021-04-15 07:17:10 -04:00
Donald Sharp 0b711f0a20 tests: test_bgp_multi_vrf_topo1.py fix formatting issues pointed out by pylint
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2021-04-15 07:17:10 -04:00
Donald Sharp f4baa8fe25 tests: Remove unnecessary formating for strings
Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2021-04-15 07:17:10 -04:00
Donald Sharp d9df892180 tests: Remove duplicate functions in python code
We have basically two identical functions in test_bgp_gr_functionality_topo1.py
Fix.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
2021-04-15 07:17:06 -04:00
Igor Ryzhov dceb1b6223
Merge pull request #8477 from opensourcerouting/lib-bfd-fix 2021-04-15 09:32:23 +03:00
David Lamparter 1b958b2ef8 lib: disable ASAN redzone around xref_p/xref_array
The "xref_p" variables are placed in the "xref_array" section
specifically so they're next to each other and we get an array at the
end.  The ASAN redzone that is inserted around global variables is
breaks that since it'd be inserted before and after each of the array
items.  So disable the ASAN redzone for these variables (and only these
variables, nothing else should be affected.)

Signed-off-by: David Lamparter <equinox@diac24.net>
2021-04-15 06:27:34 +02:00
Renato Westphal 1e3937b33d
Merge pull request #8467 from idryzhov/fix-acl-delete
lib: fix access-list deletion
2021-04-14 23:58:39 -03:00
Renato Westphal 9759c5122d
Merge pull request #8469 from mjstapp/fix_bgp_nhg_mpath
bgpd: don't overrun fixed zapi array of nexthops
2021-04-14 23:54:08 -03:00
Renato Westphal 8b74cd9e6d
Merge pull request #8470 from mjstapp/fix_nhrp_cov_socket
nhrpd: fix coverity warning about os_socket()
2021-04-14 23:52:39 -03:00
Rafael Zalamena 9c39d19742 lib: fix BFD crash on interface removal
- Handle badly formatted messages (don't set `ifp` in that case)
- Handle unread messages (e.g. when family is not don't trigger `assert`)

Signed-off-by: Rafael Zalamena <rzalamena@opensourcerouting.org>
2021-04-14 15:28:09 -03:00
Patrick Ruddy 5bb91468c5
Merge pull request #8003 from donaldsharp/timings
lib: Differentiate between real and cpu bound processes
2021-04-14 18:33:18 +01:00