Commit Graph

17715 Commits

Author SHA1 Message Date
Russ White
d0367e6c58
Merge pull request #4934 from donaldsharp/ospf_reject_or_ignore
ospfd: Remove flog_warn for a situation user can never do anything with
2019-09-07 17:41:23 -04:00
rgirada
b1ab2876fa staticd: static route config should fail if gw configured as its local ip.
Fix:
Added a check in staticd upon receiving nexthop update from zebra such that
it will fail to resolve the nexthop if the connected address added as nexthop.

But still allowing to add to staticd database and appears in running config.
Throwing an warning massage to user if such misconfig issued.

Signed-off-by: Rajesh Girada <rgirada@vmware.com>
2019-09-07 08:11:14 -07:00
Donatas Abraitis
d32b3c5bbc
Merge pull request #4947 from sworleys/Docker-Update-Libcap
topotests: Add libcap-dev to the Dockerfile
2019-09-07 10:03:34 +03:00
Renato Westphal
651105b5fb zebra: improve cleanup of MPLS labels when zclient disconnects
Use the zserv_client_close hook to cleanup all MPLS labels advertised
by a zclient when it disconnects. We were doing this cleanup for
ldpd only, but now we have other daemons that are MPLS aware,
like ospfd (due to the new Segment Routing feature).

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
2019-09-06 21:06:11 -03:00
Renato Westphal
b3c49d0e77 lib, zebra: enhance the MPLS zapi messages
* Add ability to specify the nexthop type;
* Add ability to install or not a FTN (in addition to an LSP).

These two additions will be useful to install local SR Prefix-SIDs
configured with the no-PHP option.

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
2019-09-06 21:06:11 -03:00
Renato Westphal
635a039eef lib, zebra: rename LSP type used for OSPF SR
SR support for IS-IS is coming so we need to be able to distinguish
OSPF and IS-IS LSPs.

While here, add missing case statement for LDP on
lsp_type_from_re_type().

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
2019-09-06 21:06:11 -03:00
Renato Westphal
e132dea064 zebra: identify MPLS FTNs by route type and instance
Use the route type and instance instead of the route distance
to identify MPLS FTNs. This is a more robust approach since the
routing daemons can modify the distance of their announced routes
via configuration, which can cause inconsistencies.

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
2019-09-06 21:06:11 -03:00
Renato Westphal
bad6b0e72e lib: introduce encode/decode functions for the MPLS zapi messages
Do this for the following reasons:
* Improve modularity of the code by separating the decoding of the
  ZAPI messages from their processing;
* Create an API that is easier to use by the client daemons.

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
2019-09-06 21:06:11 -03:00
Renato Westphal
be489c5738 zebra: add missing case statement in nhlfe2str()
Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
2019-09-06 20:58:09 -03:00
Renato Westphal
e29f8d0db3 tests: remove topotest compatibility with older ldpd versions
Now that topotest was integrated into the FRR repository, we
don't need to worry anymore about creating tests that work across
different FRR versions. The topotests present on any branch need
to be compatible only with the FRR daemons from that same branch.

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
2019-09-06 20:58:09 -03:00
Renato Westphal
a971aeb68e zebra: improve the output of "show mpls table"
Use the table generator to adjust the columns width according to
the table's content.

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
2019-09-06 20:54:59 -03:00
Stephen Worley
a4e6a2f808 topotests: Add libcap-dev to the Dockerfile
Add libcap-dev to the Dockerfile now that its a required depency.

Signed-off-by: Stephen Worley <sworley@cumulusnetworks.com>
2019-09-06 18:20:47 -04:00
Chirag Shah
ff9d54fb98 bgpd: clear l3vni prefix-only flag upon deletion
When L3vni is created with prefix-only flag,
the flag is set at bgp vrf instance level.
In the case of bgp instance is non auto created,
means user configured instance (i.e 'router bgp x vrf <name>')

Upon deletion of l3vni, clear the prefix-only flag from
bgp vrf instance.

Ticket:CM-21894
Reviewed By:CCR-9176
Testing Done:

vrf vrf1
 vni 104001
 exit-vrf
!
router bgp 650030 vrf vrf1
!

tor-21(config)# vrf vrf1
tor-21(config-vrf)# vni 104001 prefix-routes-only
tor-21(config-vrf)# no vni 104001 prefix-routes-only
tor-21(config-vrf)# end

Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
2019-09-06 10:58:51 -07:00
Donald Sharp
c50addb34a
Merge pull request #4937 from mjstapp/fix_evpn_brif
zebra: avoid using zebra datastructs in evpn dataplane path
2019-09-06 13:47:38 -04:00
Donald Sharp
c341ab3c62
Merge pull request #4939 from opensourcerouting/optimize-nb-cli
lib: optimize non-transactional cli
2019-09-06 13:17:21 -04:00
Donald Sharp
743acc985e
Merge pull request #4935 from ton31337/feature/documentation_for_rfc8212
doc: Add documentation for `bgp ebgp-requires-policy` command
2019-09-06 13:17:01 -04:00
Donatas Abraitis
a422c0b650
Merge pull request #4943 from donaldsharp/increase_test_timeout
tests: Ensure we wait 1 bgp timeout period before declaring failure
2019-09-06 18:08:25 +03:00
Donald Sharp
dfff0ef449 tests: Ensure we wait 1 bgp timeout period before declaring failure
The lib/bgp.py test code is bringing up neighbors and clearing them
to test that things are working appropriately.  The problem we have
is that we are only waiting 30 seconds for declaration of failure.
In a high load system packets can be lost and as such the initial
convergence may not happen.  Modify the test to wait for 1 retry
window test period before declaring failure.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2019-09-06 08:46:27 -04:00
Sri Mohana Singamsetty
eef47e1ed1
Merge pull request #4863 from chiragshah6/evpn_dev1
bgpd: evpn convey svi_ip knob to zebra post vni add
2019-09-05 21:58:36 -07:00
Renato Westphal
689b9cf580 lib: optimize non-transactional cli
Commit eaf6705d7a fixed a problem caused by configuration changes
coming from the kernel. The fix consisted of regenerating the
candidate configuration before every configuration command (when
using the non-transactional CLI mode). There's no need, however,
to regenerate the candidate when it's identical to the running
configuration. Since the northbound keeps track of the version
of each configuration, we can use that information to prevent
regenerating the candidate configuration when that is not necessary.

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
2019-09-05 20:17:18 -03:00
Mark Stapp
478566d68b zebra: avoid using zebra datastructs in evpn dataplane path
Some netlink-facing code used for evpn/vxlan programming was
being run in the dataplane pthread, but accessing zebra core
datastructs. Move some additional data into the dataplane
context, and use it in the netlink path instead.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
2019-09-05 12:58:58 -04:00
Donatas Abraitis
713c64dd09 doc: Add documentation for bgp ebgp-requires-policy command
Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
2019-09-05 19:57:46 +03:00
Donald Sharp
96db9cd3a1 ospfd: Remove flog_warn for a situation user can never do anything with
When OSPF receives a Database description packet and is in
`Down`, `Attempt` or `2-Way` state we are creating a warning
for the end user.

rfc2328 states(10.6):
Down - The packet should be rejected
Attempt - The packet should be rejected
2-Way - The packet should be ignored

I cannot find any instructions in the rfc to state what the operational
difference is between rejected and ignored.  Neither can I figure
out what FRR expects the end user to do with this information.
I can see this information being useful if we encounter a bug
down the line and we have gathered a bunch of data.  As such
let's modify the code to remove the flog_warn and convert
the message to a debug level message that can be controlled by
appropriate debug statements.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2019-09-05 12:30:26 -04:00
Mark Stapp
e0e140a745 zebra: protect some vxlan debugs
Some VXLAN debugs weren't covered by 'if debug...' tests.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
2019-09-05 11:12:00 -04:00
Mark Stapp
6c11fdb3c4
Merge pull request #4932 from sworleys/Static-Route-Dev-Redist-Fix
staticd: Re-send/Remove routes on interface events
2019-09-04 15:06:55 -04:00
Donald Sharp
641adc3196
Merge pull request #4883 from mjstapp/dplane_vteps
Zebra: use dataplane for evpn vtep programming
2019-09-04 14:14:20 -04:00
David Lamparter
ce9d312c1c
Merge pull request #4930 from donaldsharp/4851_fixup
isisd: Enabling build with openssl
2019-09-04 20:08:37 +02:00
Mark Stapp
8ce4c74607
Merge pull request #4789 from sworleys/Nexthop-Sort-Optimization
lib: Nexthop Sorting Optimizations
2019-09-04 13:35:50 -04:00
Stephen Worley
c14b7f18f6 staticd: Re-send/Remove routes on interface events
We were not processing interface up/down events for device only
static routes. This patch looks up the ifp and then calls
the same API we are using for interface add/remove events.

Signed-off-by: Stephen Worley <sworley@cumulusnetworks.com>
2019-09-04 12:38:56 -04:00
Mark Stapp
0bbd4ff442 zebra: move EVPN VTEP programming to dataplane
Move VTEP install/uninstall to the zebra dataplane. Remove
synch kernel-facing apis and helper functions.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
2019-09-04 10:30:17 -04:00
Donald Sharp
c9042b2890
Merge pull request #4877 from mjstapp/dplane_neighs
zebra: move evpn neighbors to dataplane
2019-09-04 10:23:31 -04:00
Michal Ruprich
6252100f88 isisd: Enabling build with openssl
Similar to PR #4677, I am enabling the openssl library for md5
authentication in IS-IS

Signed-off-by: Michal Ruprich <michalruprich@gmail.com>
2019-09-04 09:39:47 -04:00
Donald Sharp
628c0de887
Merge pull request #4874 from manuhalo/fix_isis_mtu
isisd: check MTU when configuring circuit
2019-09-04 07:54:08 -04:00
Donald Sharp
947d34af23
Merge pull request #4869 from rtrlib/2019-08-22-bugfix-master
bgpd: rpki fixes (master)
2019-09-04 07:49:14 -04:00
Donatas Abraitis
240c41c821
Merge pull request #4908 from qlyoung/vtysh-find-regexp
vtysh, lib: allow regexp in `find` command
2019-09-04 14:47:34 +03:00
Donald Sharp
4e279d01b7
Merge pull request #4918 from brchiu/fix_values_cnt_error
lib: Fix erroneously setting pointer values_cnt as NULL
2019-09-04 06:53:33 -04:00
Jafar Al-Gharaibeh
ad489a1892
Merge pull request #4927 from donaldsharp/eigrp_sa_fix
eigrpd: Fix SA issue with setting but not using
2019-09-04 01:00:06 -05:00
Jafar Al-Gharaibeh
cc7f8ad974
Merge pull request #4926 from donaldsharp/pbr_mark
doc: Update pbr to reflect new mark match command.
2019-09-03 21:17:13 -05:00
Donald Sharp
11d443f591
Merge pull request #4925 from ddutt/master
bgpd: Fixes to error message printed for failed peerings
2019-09-03 20:36:53 -04:00
Bi-Ruei, Chiu
dd9a956ee6 lib: Fix erroneously setting pointer values_cnt as NULL
It should be :

  *values_cnt = 0;

not

  values_cnt = 0;

Signed-off-by: Bi-Ruei, Chiu <biruei.chiu@gmail.com>
2019-09-04 08:27:43 +08:00
Donald Sharp
7d7acfc779 eigrpd: Fix SA issue with setting but not using
We assign a value to the eigrp data structure and then
immediately overwrite it in the for loop.  No need to
do a eigrp_lookup.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2019-09-03 19:22:27 -04:00
Donald Sharp
91dd8efee3
Merge pull request #4924 from Jafaral/gnulinux
zebra: use GNU_LINUX instead of LINUX
2019-09-03 19:21:06 -04:00
Donald Sharp
a547ef391c doc: Update pbr to reflect new mark match command.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2019-09-03 19:18:21 -04:00
Donald Sharp
453ff8cd87
Merge pull request #4923 from Jafaral/pbrmark
pbrd: support mark matches
2019-09-03 19:12:44 -04:00
Marcin Matląg
95a9fe025a pbrd: initial fwmark support for pbr matches #4460
Adds support to specify marks in pbr-map match clause.
Marks should be provided as decimal (unsigned int).

Currently supported on Linux only. Attempting to configure
marks on other platform will result in:

"pbr marks are not supported on this platform"

Signed-off-by: Marcin Matlag <marcin.matlag@gmail.com>
Signed-off-by: Jafar Al-Gharaibeh <jafar@atcorp.com>
2019-09-03 15:30:10 -05:00
Dinesh G Dutt
05912a17e6 bgpd: Fixes to error message printed for failed peerings
There was a silly bug introduced when the command to show failed sessions
was added. A missing "," caused the wrong error message to be printed.
Debugging this led down a path that:
   - Led to discovering one more error message that needed to be added
   - Providing the error code along with the string in the JSON output
     to allow programs to key off numbers rather than strings.
   - Fixing the missing ","
   - Changing the error message to "Waiting for Peer IPv6 LLA" to
     make it clear that we're waiting for the link local addr.

Signed-off-by: Dinesh G Dutt <5016467+ddutt@users.noreply.github.com>
2019-09-03 19:55:49 +00:00
Donald Sharp
9d55926924
Merge pull request #4892 from pguibert6WIND/nhtresolvedefaultvrf
zebra: nht resolution default configurable per vrf
2019-09-03 15:40:43 -04:00
Jafar Al-Gharaibeh
70bc8385a3 zebra: use GNU_LINUX instead of LINUX
Everywhere else in the code we use GNU_LINUX, that is the symbol we actualy define in the configuration. Don't rely on compiler's built-in symbols.

Signed-off-by: Jafar Al-Gharaibeh <jafar@atcorp.com>
2019-09-03 14:22:38 -05:00
Quentin Young
68376178e5
Merge pull request #4919 from opensourcerouting/config-warnings
build: error out on implicit missing libcap, warn for protobuf FPM
2019-09-03 14:55:38 -04:00
Quentin Young
9dcb41a65c
Merge pull request #4604 from opensourcerouting/mutex-sugar
mutex syntactic sugar
2019-09-03 14:55:14 -04:00