Commit Graph

17062 Commits

Author SHA1 Message Date
Christian Franke
2028040307 isisd: Fix handling of neighbor circuit id in three way handshake
RFC 5303 states:

      If the system ID and Extended Local Circuit ID of the neighboring
      system are known (in adjacency three-way state Initializing or
      Up), the neighbor's system ID SHALL be reported in the Neighbor
      System ID field, and the neighbor's Extended Local Circuit ID
      SHALL be reported in the Neighbor Extended Local Circuit ID field.

There is nothing written about only setting the Extended circuit ID of the
adjacency only when we bring the three-way adjacency up.

In fact, we should always update it, to avoid the problem described in #4783.

Fixes: #4783
Signed-off-by: Christian Franke <chris@opensourcerouting.org>
2019-10-01 15:55:42 +02:00
dturlupov
e8a99717bd 7.2: zebra: if_is_loopback_or_vrf crash if if_lookup_by_index return NULL
Function if_lookup_by_index() can return NULL, but in if_is_loopback_or_vrf() we don't chech NULL and get next:

Sep 2 07:44:34 XXX zebra[4616]: /usr/lib64/libfrr.so.0(zlog_backtrace_sigsafe+0x48) [0x7fb5f704cf18]
Sep 2 07:44:34 XXX zebra[4616]: /usr/lib64/libfrr.so.0(zlog_signal+0x378) [0x7fb5f704d728]
Sep 2 07:44:34 XXX zebra[4616]: /usr/lib64/libfrr.so.0(+0x6b495) [0x7fb5f706b495]
Sep 2 07:44:34 XXX zebra[4616]: /lib64/libpthread.so.0(+0x123b0) [0x7fb5f6d573b0]
Sep 2 07:44:34 XXX zebra[4616]: /usr/lib64/libfrr.so.0(if_is_loopback+0) [0x7fb5f7045160]
Sep 2 07:44:34 XXX zebra[4616]: /usr/lib64/libfrr.so.0(if_is_loopback_or_vrf+0x11) [0x7fb5f7045191]
Sep 2 07:44:34 XXX zebra[4616]: /usr/sbin/zebra() [0x43b26d]
Sep 2 07:44:34 XXX zebra[4616]: /usr/sbin/zebra() [0x43db6f]
Sep 2 07:44:34 XXX zebra[4616]: /usr/lib64/libfrr.so.0(work_queue_run+0xc8) [0x7fb5f7080de8]
Sep 2 07:44:34 XXX zebra[4616]: /usr/lib64/libfrr.so.0(thread_call+0x47) [0x7fb5f7077d27]
Sep 2 07:44:34 XXX zebra[4616]: /usr/lib64/libfrr.so.0(frr_run+0xd8) [0x7fb5f704b448]

Signed-off-by: Dmitrii Turlupov dturlupov@factor-ts.ru
2019-09-27 11:23:27 +03:00
Donatas Abraitis
711e618eaf bgpd: Accept no aggregate-address <IP> route-map <RMAP> commands
Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
2019-09-27 08:14:10 +03:00
Donald Sharp
ba0d195d59
Merge pull request #5071 from ton31337/fix/aggregate-address_for_ipv6_summary-only_missreading_7.2
bgpd: [7.2] aggregate-address X:X::X:X/M summary-only was missreading config
2019-09-26 17:10:38 -04:00
Donatas Abraitis
ec7e226925
Merge pull request #5069 from donaldsharp/7.2_aggregate_address
7.2: bgpd: aggregate-address A.B.C.D A.B.C.D summary-only was missreading …
2019-09-26 21:54:10 +03:00
Donatas Abraitis
942f3777e9 bgpd: aggregate-address X:X::X:X/M summary-only was missreading config
Entering:
aggregate-address 2a02:4780::/48 summary-only

Will transform this to:
aggregate-address 2a02:4780::/48 summary-only route-map summary-only

This patch fixes that.

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
2019-09-26 21:52:19 +03:00
Donald Sharp
13809220b5 bgpd: aggregate-address A.B.C.D A.B.C.D summary-only was missreading config
The `aggregate-address 30.0.5.0 255.255.255.0 summary-only` command
was missreading the inputed data and translating it into:

`aggregate-address 30.0.5.0/24 summary-only route-map summary-only`

This is not quite correct.  Fix this behavior:

donna.cumulusnetworks.com# conf
donna.cumulusnetworks.com(config)# router bgp
donna.cumulusnetworks.com(config-router)# aggregate-address 30.0.5.0 255.255.255.0 summary-only
donna.cumulusnetworks.com(config-router)# do show run
Building configuration...

Current configuration:
!
frr version 7.3-dev
frr defaults datacenter
hostname donna.cumulusnetworks.com
log file /var/log/frr/frr.log
no ipv6 forwarding
frr version 7.2-dev
!
router bgp 500
 neighbor 192.168.209.1 remote-as external
 neighbor 192.168.209.1 ebgp-multihop 255
 neighbor 192.168.210.1 remote-as external
 !
 address-family ipv4 unicast
  network 192.168.9.0/24
  network 192.168.10.0/24
  aggregate-address 30.0.5.0/24 summary-only
 exit-address-family
!

Issue: #5054
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2019-09-26 12:41:05 -04:00
Donatas Abraitis
bb4eca5cb2
Merge pull request #5057 from dslicenc/bgp-next-hop-routemap-72
7.2: bgpd: stop sending nexthop set by "route-map in" to eBGP peers
2019-09-26 16:03:46 +03:00
Donald Sharp
81496d121e
Merge pull request #5064 from idryzhov/7.2-fix-vrf-autocompletions
[7.2] *: fix missing VRF autocompletions
2019-09-26 07:31:40 -04:00
Igor Ryzhov
afd38fdc8d *: fix missing VRF autocompletions
Current autocompletion works only for simple "vrf NAME" case.

This commit expands it also for the following cases:
- "nexthop-vrf NAME" in staticd
- usage of $varname in many daemons

All daemons are updated to use single varname "$vrf_name".

Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
2019-09-26 12:17:15 +03:00
Don Slice
12a956c42a bgpd: stop sending nexthop set by "route-map in" to eBGP peers
Problem reported that when a "neighbor x.x.x.x route-map FOO in"
set a next-hop value, that modified next-hop value was also sent
to eBGP peers.  This is incorrect since bgp is expected to set
next-hop to self when sending to eBGP peers unless third party
next-hop on a shared segment is true.  This fix modifies the
behavior to stop sending the modified next-hop to eBGP peers
if the route-map was applied inbound on another peer.

Ticket: CM-26025
Signed-off-by: Don Slice <dslice@cumulusnetworks.com>
2019-09-25 13:53:26 -07:00
Donald Sharp
1e65094740
Merge pull request #5059 from mjstapp/fix_dplane_config_handler_7_2
[7.2] zebra: add dataplane variables to show run
2019-09-25 16:48:02 -04:00
Mark Stapp
988c4e27d1 zebra: handle config write for dataplane values
[7.2 version] Add the (single) dataplane config value
to the output of config write, 'show run'.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
2019-09-25 14:27:12 -04:00
Sri Mohana Singamsetty
73c659ceae
Merge pull request #5048 from donaldsharp/7.2_sa_issues
7.2 bgpd: rmap_type is 8 bit but we have 9 bits of flags
2019-09-24 08:57:57 -07:00
Donald Sharp
d15d460d35 bgpd: rmap_type is 8 bit but we have 9 bits of flags
The newly added PEER_RMAP_TYPE_AGGREGATE flag is setup to
be the 9th bit:

But the flag we are putting it into:
uint8_t rmap_type;

is 8 bits.  Adjust the size.

Found by Coverity SA Scan
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2019-09-24 08:33:55 -04:00
Donald Sharp
14ea0f94a5
Merge pull request #5041 from opensourcerouting/isisd-fix-validation-crash-7.2
[7.2] isisd: fix crash during candidate validation
2019-09-24 08:18:50 -04:00
Donatas Abraitis
8a45d667fb
Merge pull request #5038 from idryzhov/7.2-fix-vtysh-no-log-facility
[7.2] vtysh: fix "no log facility" command
2019-09-23 22:38:17 +03:00
Igor Ryzhov
ceec5a1033 vtysh: fix "no log facility" command
Actual command from the library accepts only supported facilities, not
any random word.

Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
2019-09-23 19:42:33 +03:00
Renato Westphal
952ef7cc90 isisd: fix crash during candidate validation
The "abort_if_not_found" parameter of nb_running_get_entry()
should be set to true only when this function is called during the
NB_EV_APPLY phase of a northbound callback. Failure to respect this
can lead to crashes when multiple configuration changes are being
committed at the same time.

Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
2019-09-23 09:38:05 -03:00
Donald Sharp
463ef4b2a7 configure: Update versioning
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2019-09-20 14:37:32 -04:00
Donatas Abraitis
4520c63917
Merge pull request #5027 from donaldsharp/7.2_send_that_error_bgp
7.2: bgpd: Invalid NH's should send an apropriate reason code
2019-09-20 21:41:49 +03:00
Donald Sharp
99f06b071f bgpd: Invalid NH's should send an apropriate reason code
RFC 4271 sec 6.3 p33, In the case of a BGP_NEXTHOP attribute with an
incorrect value, FRR is supposed to send a notification
and include 'Corresponding type, length and value of the NEXT_HOP
attribute in the notification data.

Fixes: #4997
Signed-off-by: Nikos <ntriantafillis@gmail.com>
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2019-09-20 12:11:01 -04:00
Donald Sharp
5d911bee1a
Merge pull request #5014 from idryzhov/7.2-fix-vtysh-prefix-list
[7.2] vtysh: fix multiple "no ip/ipv6 prefix-list sequence-number" lines in running-config
2019-09-19 06:41:23 -04:00
Igor Ryzhov
7dbd9fa33d vtysh: fix multiple "no ip/ipv6 prefix-list sequence-number" lines in running-config
Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
2019-09-19 11:29:55 +03:00
Donald Sharp
1f18affbf2
Merge pull request #4999 from mjstapp/fix_notif_installed_7_2
[7.2] zebra: dplane route updates need to check all nexthops
2019-09-18 17:39:08 -04:00
Mark Stapp
4b6319b26e zebra: check all dplane nexthops when processing
[7.2 version]
When processing route updates from the dataplane, we were
terminating the checking of nexthops prematurely, and we could
miss meaningful changes.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
2019-09-17 11:33:46 -04:00
Sri Mohana Singamsetty
dfbca14b5e
Merge pull request #4986 from qlyoung/fix-bgp-zero-keepalive-timer-7.2
[7.2] bgpd: do not send keepalives when KA timer is 0
2019-09-16 11:19:50 -07:00
Quentin Young
d8e2b28bd8 bgpd: do not send keepalives when KA timer is 0
RFC4271 specifies behavior when the hold timer is sent to zero - we
should not send keepalives or run a hold timer. But FRR, and other
vendors, allow the keepalive timer to be set to zero with a nonzero hold
timer. In this case we were sending keepalives constantly and maxing out
a pthread to do so. Instead behave similarly to other vendors and do not
send keepalives.

Unsure what the utility of this is, but blasting keepalives is
definitely the wrong thing to do.

Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
2019-09-16 16:18:07 +00:00
Donatas Abraitis
4de6689dc7
Merge pull request #4976 from opensourcerouting/disable-ecmp2-test-7.2
[7.2] Disable bgp-ecmp-topo2 topotest until proper fix is developed
2019-09-14 17:26:42 +03:00
Donald Sharp
19804885a1
Merge pull request #4979 from ton31337/feature/route-map_aggregate_command_7.2
bgpd: [7.2] Apply route-map for aggregate-address
2019-09-14 07:42:33 -04:00
Donatas Abraitis
16570e338a tests: Improve bgp_aggregate-address_route-map test
Rewrite some parts to add more visibility what's going on if test fails.

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
2019-09-13 14:56:09 +03:00
Donatas Abraitis
fd92514cbc doc: Add documentation for aggregate-address with route-map support
Additionally remove trailling/unnecesarry whitespaces and align code
snippets correctly.

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
2019-09-13 14:52:46 +03:00
Donatas Abraitis
65e62caddc topotests: Add test for checking if route-map is applied for aggregate-address
Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
2019-09-13 14:52:40 +03:00
Donatas Abraitis
cde3c2b2ea bgpd: Apply route-map for aggregate-address command
Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
2019-09-13 14:52:34 +03:00
Martin Winter
cbda750080 tests: Disable bgp-ecmp-topo2 topotest until proper fix is developed
Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>
2019-09-13 02:09:05 +02:00
Donald Sharp
4afb9e38ad
Merge pull request #4971 from mjstapp/fix_redist_update_7_2
[7.2] zebra: revise redistribution delete to improve update case
2019-09-12 17:41:06 -04:00
Mark Stapp
ee8a72f315 zebra: revise redistribution delete to improve update case
When selecting a new best route, zebra sends a redist update
when the route is installed. There are cases where redist
clients may not see that redist add - clients who are not
subscribed to the new route type, e.g. In that case, attempt
to send a redist delete for the old/previous route type.

Revised the redist delete api to accomodate both cases;
also tightened up the const-ness of a few internal redist apis.

[7.2 version]

Signed-off-by: Mark Stapp <mjs@voltanet.io>
2019-09-12 11:30:42 -04:00
Donatas Abraitis
ad1fb8e40e
Merge pull request #4944 from donaldsharp/72_increase_time_out
[7.2]tests: Ensure we wait 1 bgp timeout period before declaring failure
2019-09-07 07:11:26 +03:00
Donald Sharp
5ba498905f 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 13:02:58 -04:00
Donald Sharp
81b96c6e95
Merge pull request #4936 from ton31337/feature/documentation_for_rfc8212_7.2
doc: [7.2] Add documentation for `bgp ebgp-requires-policy` command
2019-09-06 07:37:16 -04:00
Donatas Abraitis
8b29169eb4 doc: Add documentation for bgp ebgp-requires-policy command
Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
2019-09-05 20:05:05 +03: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