Commit Graph

1120 Commits

Author SHA1 Message Date
Donald Sharp
2d3d652178
Merge pull request #6251 from opensourcerouting/cs-ignore
*: make coverity scan ignore random() calls
2020-04-20 16:08:37 -04:00
Mark Stapp
e4195c02a7
Merge pull request #6245 from sworleys/NHG-More-Topo
tests: add connected/recursive/duplicte/route-map NHG tests
2020-04-20 13:28:14 -04:00
Donald Sharp
8b1e4f30ba
Merge pull request #6164 from ton31337/feature/rfc8212_enabled_traditional_profile
bgpd: Enable rfc8212 by default except datacenter profile
2020-04-18 15:06:04 -04:00
Rafael Zalamena
5920b3eb38 *: replace all random() calls
Replace all `random()` calls with a function called `frr_weak_random()`
and make it clear that it is only supposed to be used for weak random
applications.

Use the annotation described by the Coverity Scan documentation to
ignore `random()` call warnings.

Signed-off-by: Rafael Zalamena <rzalamena@opensourcerouting.org>
2020-04-17 20:57:43 -03:00
Donald Sharp
2ff99507ad
Merge pull request #6135 from opensourcerouting/cli-node-cleanup
*: clean up the mess that is CLI command nodes
2020-04-16 19:24:56 -04:00
Stephen Worley
887a232c3b tests: add connected/recursive/duplicte/route-map NHG tests
Add some more NHG topotests using connected, recursive, duplicate
and higher ecmp nexthops as well as route maps.

Signed-off-by: Stephen Worley <sworley@cumulusnetworks.com>
2020-04-16 11:49:50 -04:00
Santosh P K
09133ff4f7
Merge pull request #5451 from opensourcerouting/rcu-log
logging subsystem rewrite
2020-04-16 20:23:44 +05:30
Donatas Abraitis
c845358213
Merge pull request #6238 from donaldsharp/test_evpn_vxlan_cleanup
tests: Cleanup bgp config for evpn vxlan topotest
2020-04-16 16:05:34 +03:00
Donald Sharp
e51d13ca7c tests: Cleanup bgp config for evpn vxlan topotest
The bgp configuration for the vxlan topotest mixed
and matched some configuration that does not belong
for an IBGP setup.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2020-04-16 07:04:27 -04:00
David Lamparter
f4b8291fcb *: move CLI node names to cmd_node->name
And again for the name.  Why on earth would we centralize this, just so
people can forget to update it?

Signed-off-by: David Lamparter <equinox@diac24.net>
2020-04-16 12:53:59 +02:00
David Lamparter
243895805a *: move CLI parent data to cmd_node->parent_node
Same as before, instead of shoving this into a big central list we can
just put the parent node in cmd_node.

Signed-off-by: David Lamparter <equinox@diac24.net>
2020-04-16 12:53:00 +02:00
David Lamparter
612c2c15d8 *: remove second parameter on install_node()
There is really no reason to not put this in the cmd_node.

And while we're add it, rename from pointless ".func" to ".config_write".

[v2: fix forgotten ldpd config_write]

Signed-off-by: David Lamparter <equinox@diac24.net>
2020-04-16 12:53:00 +02:00
David Lamparter
62b346eefa *: clean up cmd_node initializers
... and use named assignments everywhere (so I can change the struct.)

Signed-off-by: David Lamparter <equinox@diac24.net>
2020-04-16 12:53:00 +02:00
Donatas Abraitis
c3b426212f tests: Check if the right next-hop is shown (bgp_show_ip_bgp_fqdn)
Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
2020-04-16 10:37:21 +03:00
Renato Westphal
260616d55d
Merge pull request #6154 from donaldsharp/check_interface_working
tests: Add a route-map test to ensure it accepts an unknown intf name
2020-04-14 23:37:47 -03:00
Donald Sharp
1cb0c038c2
Merge pull request #6214 from opensourcerouting/bfdd-debug
bfdd: code/logging/debug improvements
2020-04-14 19:06:10 -04:00
Donald Sharp
e68a7dbb09
Merge pull request #6096 from pjdruddy/vxlan_evpn_topo_test
tests: add basic topotest for VXLAN EVPN
2020-04-14 11:53:48 -04:00
Donatas Abraitis
8971c2d828 tests: Describe each scenario for rfc8212 to ease debugging
Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
2020-04-14 16:01:46 +03:00
Donatas Abraitis
74f852e33b tests: Remove extra empty vertical spaces
Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
2020-04-14 16:01:46 +03:00
Donatas Abraitis
c7688a6943 tests: Enable rfc8212 by default except datacenter profile
Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
2020-04-14 16:01:46 +03:00
Rafael Zalamena
9532601587 topotest: enable bfd debugs on all BFD tests
Lets attempt to get the most out of the debug messages.

Signed-off-by: Rafael Zalamena <rzalamena@opensourcerouting.org>
2020-04-14 09:35:08 -03:00
Kuldeep Kashyap
afee014eda tests: Added new tests to bgp-basic-functionality-topo1
1. Added 2 new test cases to bgp-basic-functionality-topo1
2. Enhanced 2 tests to run for both static routes and network advvertise command

Signed-off-by: Kuldeep Kashyap <kashyapk@vmware.com>
2020-04-09 09:23:59 +00:00
Kuldeep Kashyap
089f79edd4 tests: Adding new test suite bgp_as_allow_in
1. Added 5 test cases to verify BGP AS-allow-in behavior in FRR
2. Enhanced framework to support BGP AS-allow-in config(lib/bgp.py)
3. Added API in bgp.py to verify BGP RIB table(lib/bgp.py)

Signed-off-by: Kuldeep Kashyap <kashyapk@vmware.com>
2020-04-09 09:10:21 +00:00
Donatas Abraitis
fdf44b9038
Merge pull request #6125 from kuldeepkash/bgp-communities
tests: Adding new test suite bgp_communities_topo1
2020-04-09 11:49:43 +03:00
David Lamparter
2ee1e4b1ba
Merge pull request #6175 from ton31337/fix/avoid_same_type_typecasting
*: Do not cast to the same type
2020-04-08 22:44:53 +02:00
Donald Sharp
c189a11d7f
Merge pull request #6185 from opensourcerouting/build-assorted-20200408
assorted build fixes
2020-04-08 13:29:45 -04:00
Renato Westphal
ff4e6ca785
Merge pull request #6041 from donaldsharp/wang_a_yump
Wang a yump
2020-04-08 13:33:17 -03:00
David Lamparter
d32ee243af tests: fix parallel build race
If we're building with a separate build directory, these two build
targets can fail in case their output directory hasn't been created by
some other target that may or may not have run earlier.

Signed-off-by: David Lamparter <equinox@diac24.net>
2020-04-08 16:27:59 +02:00
Donald Sharp
cfe9a58785 tests: Add tests to rip and ripngd to show func works
Add some basic tests to show that network and passive-interface
commands work with interface names in rip and ripngd.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2020-04-08 10:18:31 -04:00
Donatas Abraitis
c4efd0f423 *: Do not cast to the same type
Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
2020-04-08 17:15:06 +03:00
Donald Sharp
41fce07c34 tests: Add a route-map test to ensure it accepts an unknown intf name
Add a test to route-amps to ensure that it accepts an unknown interface
name.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2020-04-08 09:10:54 -04:00
Donald Sharp
337dcbb913 tests: Add a couple more static route tests
Add a couple more tests to static route installation
Do some very very basic work to make sure that they are working
the way we want.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2020-04-08 09:07:17 -04:00
Kuldeep Kashyap
38c3547ac8 tests: Adding new test suite bgp_communities_topo1
1. Added 1 test case to verify NO-ADVERTISE Community functionality
2. Enhanced bgp.py to exclude routers from verification, if doesn't have bgp config

Signed-off-by: Kuldeep Kashyap <kashyapk@vmware.com>
2020-04-08 12:27:23 +00:00
Kuldeep Kashyap
b7250ecfdc tests: Added new tests to bgp-basic-functionality-topo1
1. Added 2 new test cases to bgp-basic-functionality-topo1
2. Enhanced 2 tests to run for both static routes and network advvertise command

Signed-off-by: Kuldeep Kashyap <kashyapk@vmware.com>
2020-04-08 12:21:26 +00:00
Kuldeep Kashyap
9d450273df tests: Adding new test suite bgp_as_allow_in
1. Added 5 test cases to verify BGP AS-allow-in behavior in FRR
2. Enhanced framework to support BGP AS-allow-in config(lib/bgp.py)
3. Added API in bgp.py to verify BGP RIB table(lib/bgp.py)

Signed-off-by: Kuldeep Kashyap <kashyapk@vmware.com>
2020-04-08 12:21:26 +00:00
Pat Ruddy
6f77a974d8 tests: add basic topotest for VXLAN EVPN
This test creates a 5 box setup with 2 hosts, 2 PEs and a P router
it checks for
1. VNI VTEPs being communicated between zebra from PE1 to PE2
   and vice versa.
2. MAC addresses from host 1 being learned by PE1 and signalled
   to PE2 over BGP

Signed-off-by: Pat Ruddy <pat@voltanet.io>
2020-04-06 16:49:23 +01:00
Sri Mohana Singamsetty
70ecc066e7
Merge pull request #6105 from vivek-cumulus/bgp_link_bandwidth_unequal_cost_multipath
Unequal cost multipath (a.ka. weighted ECMP) with BGP link-bandwidth
2020-04-05 11:41:42 -07:00
Sri Mohana Singamsetty
2ebae25d08
Merge pull request #6143 from ton31337/fix/remove_prefixReceivedCount
bgpd: Remove `prefixReceivedCount` from JSON
2020-04-05 11:41:04 -07:00
Quentin Young
a5ba758e61
Merge pull request #6144 from ton31337/fix/python_formatter
tests: Run python formatter (black) for topotests
2020-04-05 13:20:30 -04:00
Renato Westphal
b90204a8e9 lib, tools: silence harmless warnings in the northbound tools
Our two northbound tools don't have embedded YANG modules like the
other FRR binaries. As such, ly_ctx_set_module_imp_clb() shouldn't be
called when the YANG subsystem it being initialized by a northbound
tool. To make that possible, add a new "embedded_modules" parameter
to the yang_init() function to control whether libyang should look
for embedded modules or not.

With this fix, "gen_northbound_callbacks" and "gen_yang_deviations"
won't emit "YANG model X not embedded, trying external file"
warnings anymore.

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
2020-04-03 22:34:55 -03:00
reformat
787e762445 tests: Run python formatter (black) for topotests
Mostly ' => ", whitespace changes.

Using https://github.com/psf/black

Signed-off-by: reformat <reformat@nobody.nobody>
2020-04-03 19:41:28 +03:00
David Lamparter
cd05906c41
Merge pull request #6071 from ton31337/feature/rfc6286
bgpd: Add support for Autonomous-System-Wide Unique BGP Identifier
2020-04-03 15:16:59 +02:00
Donatas Abraitis
18a7d0eaaa tests: Replace prefixReceivedCount to pfxRcd in JSONs
Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
2020-04-03 16:15:55 +03:00
Sri Mohana Singamsetty
dba3453515
Merge pull request #6130 from ton31337/fix/remove_some_redundant_attributes_from_json
bgpd: Remove deprecated JSON fields for `show bgp ... json`
2020-04-02 16:17:24 -07:00
Renato Westphal
16a064ef24
Merge pull request #6109 from volta-networks/feat_ldp_host_only
ldpd:  host only filter
2020-04-01 19:51:22 -03:00
Donatas Abraitis
0a9fe278f6 tests: Remove/change JSON attributes for show bgp ... json
This is related to some attributes changes: aspath, med, localPref.

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
2020-04-01 23:59:45 +03:00
David Lamparter
0bdeb5e58d lib: rewrite zlog lock-free & TLS-buffered
This is a full rewrite of the "back end" logging code.  It now uses a
lock-free list to iterate over logging targets, and the targets
themselves are as lock-free as possible.  (syslog() may have a hidden
internal mutex in the C library;  the file/fd targets use a single
write() call which should ensure atomicity kernel-side.)

Note that some functionality is lost in this patch:
- Solaris printstack() backtraces are ditched (unlikely to come back)
- the `log-filter` machinery is gone (re-added in followup commit)
- `terminal monitor` is temporarily stubbed out.  The old code had a
  race condition with VTYs going away.  It'll likely come back rewritten
  and with vtysh support.
- The `zebra_ext_log` hook is gone.  Instead, it's now much easier to
  add a "proper" logging target.

v2: TLS buffer to get some actual performance

Signed-off-by: David Lamparter <equinox@diac24.net>
2020-04-01 06:53:26 +02:00
Donald Sharp
d2f589ce7a tests: More cbit extensions
We are still seeing cbit test failures in the ci system.  I am
gonna try extending the timeout a bit more as that 8 seconds
doesn't seem to be long enough.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2020-03-31 18:38:01 -04:00
lynne
6b4830dc1e tests: adding LDP tests for advertising host-routes.
Adding test to verify that proper LDP labels are advertised if
host-route configuration is changed.

Signed-off-by: Lynne Morrison <lynne@voltanet.io>
2020-03-31 16:28:35 -04:00
David Lamparter
83b27fdaab
Merge pull request #6093 from LabNConsulting/working/lb/no-birds
*: use the current project name (FRRouting)
2020-03-31 15:10:17 +02:00