Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

7.4 bsd address #7152

Closed
wants to merge 79 commits into from
Closed

Conversation

donaldsharp
Copy link
Member

No description provided.

eqvinox and others added 30 commits May 13, 2020 22:20
This only applies for split-config;  the init script would create an
empty config file with default permissions.

Reported-by: Robert Scheck <robert@fedoraproject.org>
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
(cherry picked from commit 5c90637)
…fig-perms

[7.4] build: use configfile mode in init script
This reverts commit 3fa139a.

This is being reverted because this commit completely
breaks the invocation of frr-reload.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
We had already removed the `ip as-path..` command
to have `bgp as-path` but for some reason a `no ip as-path..`
command ALIAS was still around.  Kill with extreme prejudice.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
The `bgp bestpath bandwidth` command should not be a legal
command.  Pull out the `no` form to allow this.  Allow
`no bgp bestpath bandwidth` to work as we would expect.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Without specifying a default afi/safi we get a segfault:

```
(gdb) frame 4
bgp_table_stats (..., afi=32724, safi=SAFI_UNICAST, ...
11349		if (!bgp->rib[afi][safi]) {
(gdb)
```

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
The problem is that peer_af_array returns NULL when SAFI is changed to
unicast. We use unicast table, but peer is created and activated under
labeled-unicast, hence we should lookup with a proper SAFI id.

Without this patch peer_af_find() returns NULL and we can't show
PfxSnt in `show bgp summary`.

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
isisd: IS-IS Segment Routing support
This happens between Bird and FRR. Maybe others as well, dunno.

Bird sends ::(fe80::1588) and we have a nexthop as :: which is inaccessible:

```
BGP routing table entry for fdff:b87d:f5b0::/48
Paths: (1 available, no best path)
  Not advertised to any peer
  4242421588 4242422547 4242422601 4242423605
    :: (inaccessible) from fe80::1588 (172.20.16.140)
    (fe80::1588) (used)
      Origin IGP, invalid, external
      Last update: Mon May 25 14:27:02 2020
```

bgpd[9554]: fe80::1588 went from OpenConfirm to Established
bgpd[9554]: fe80::1588 [FSM] Timer (routeadv timer expire)
bgpd[9554]: fe80::1588 rcvd UPDATE w/ attr: , origin i, mp_nexthop ::(fe80::1588)
bgpd[9554]: fe80::1588 rcvd UPDATE wlen 0 attrlen 120 alen 0
bgpd[9554]: fe80::1588 rcvd fda9:26a9:1c47:2d42::/64 IPv6 unicast
bgpd[9554]: Allocated bnc ::/128(VRF default) peer 0x0
bgpd[9554]: bgp_update(0.0.0.0): NH unresolved
bgpd[9554]: fe80::1588 rcvd fda9:26a9:1c47:d42::/64 IPv6 unicast

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
…count

```
2  0x00007fb9adb07a10 in core_handler (signo=11, siginfo=0x7ffe1414a630, context=<optimized out>) at lib/sigevent.c:228
        sa_default = {__sigaction_handler = {sa_handler = 0x0, sa_sigaction = 0x0}, sa_mask = {__val = {0 <repeats 16 times>}}, sa_flags = 0, sa_restorer = 0x0}
        sigset = {__val = {8192, 0 <repeats 15 times>}}
3  <signal handler called>
No locals.
4  route_map_dep_update (type=RMAP_EVENT_CLIST_DELETED, rmap_name=0x55d807ddd410 "export4-as49917", dep_name=<optimized out>, dephash=0x55d807adf170) at lib/routemap.c:2750
        dep = 0x55d807d35b00
        dname = 0x55d8081ba560 "123:124"
        rname = 0x55d8081ba540 "export4-as49917"
        ret = 0
        dep_data = 0x0
        ret_dep_data = 0x0
        tmp_dep_data = {rname = 0x55d8081ba540 "export4-as49917", refcnt = 0}
5  route_map_upd8_dependency (type=RMAP_EVENT_CLIST_DELETED, arg=<optimized out>, rmap_name=0x55d807ddd410 "export4-as49917") at lib/routemap.c:2865
        upd8_hash = 0x55d807adf170
```

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
…obal_zero_7.4

bgpd: [7.4] Use IPv6 LL address as nexthop if global was set to ::/LL
…dep_data_route-map_7.4

lib: [7.4] Make sure route_map_dep_data is not NULL before decrementing ref…
Until now, it was possible to set only for ipv4 unicast/multicast.

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
This caused duplicate `bgp dampening ...` to be printed per neighbor.

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
…_bug_7.4

bgpd: [7.4] Duplicate `bgp dampening ...` stuff
... it contains our pid, so doing it before fork leads to littering
buffers since we try to clean up with the forked pid...

Fixes: FRRouting#6541
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
…eled safi

unicast and labeled-unicast share the same table, but configuration should
be visible for both independently. Without this fix it confuses a bit
because when you enter `network 10.0.0.0/24` under labeled-unicast it's
written in unicast family block.

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
…_labeled_unicast_in_place_7.4

bgpd: [7.4] Make sure network/aggregate-address commands lay down under labeled safi
…litter

[7.4] lib: set up TLS log buffer after forking
A couple of daemons take/use no capabilities/privs; allow cleanup
of the privs/capabilities library module even if a daemon has no
caps.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
Fix a number of library and daemon issues so that daemons can
call frr_fini() during normal termination. Without this,
temporary logging files are left behind in /var/tmp/frr/.

Signed-off-by: Mark Stapp <mjs@voltanet.io>
[7.4] Daemons should call frr_fini() on shutdown
If we have something like:
```
ip route 1.1.1.0/24 Null0
!
router bgp 100
 no bgp ebgp-requires-policy
 neighbor 192.168.0.2 remote-as 200
 !
 address-family ipv4 unicast
  network 1.1.1.0/24
  redistribute connected
 exit-address-family
!
line vty
!
```

1.1.1.0/24 is not advertised due to martian nexthop (0.0.0.0). It starts
working only when we use `redistribute static`.

By checking if it's a BGP static route we able to announce
1.1.1.0/24 with `network 1.1.1.0/24` without redistribute even when
`bgp import-check` is enabled.

Disabling `bgp import-check` works as well, but it's enabled by default
since 7.4.

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
…ort_for_static_bgp_7.4

bgpd: [7.4] Do not treat the route as martian for static BGP routes
BGPd
   Use sequence numbers for community lists
   Fixes to nexthop groups
   Add feature to limit outgoing number of routes
   Per Neighbor Graceful Restart
   Multiple Graceful Restart fixes
   Support sub-Type-4 and sub-Type-5 for the VPNv4 SRv6 backend
   rfc7606 support: treat certain malformed routes as withdraw
   allow origin override for route aggregates
   rfc6608 support: Subcodes for BGP Finite State Machine Error
   rfc7607 support: Codification of AS 0 Processing
   rfc6286 support: Autonomous-System-Wide Unique BGP Identifier for BGP-4
   Unequal cost multipath (a.ka. weighted ECMP) with BGP link-bandwidth
   Enable rfc8212 by default except datacenter profile
staticd
   Add debug support
vtysh
   Add copy command to copy config from file into running config
LDPd
   adding support for LDP ordered label distribution control
ISISd
   IS-IS Segment Routing support
SHARPd
   add initial support to add/remove lsps
Zebra
   fix broadcast address in IPv4 networks with /31 mask
   Add Graceful Restart support for Protocol Daemon restarts
lib
   migrate route-maps to use northbound interface
plus countless bug fixes and other improvements

Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>
The code in the bgp extcommunity-list function was using
argv_find to get the correct idx.  The problem was that
we had already done argv_finds before and idx was non-zero
thus having us always set the seq pointer to what was last
looked up.  This causes us to pass in a value to the
underlying function and it would just wisely ignore it
causing a seq number of 0.

We would then write this seq number of 0 and then immediately
reject it on read in again.  BOO!

Actually handle argv_find the way it was meant to be.

Ticket:CM-29926
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
bgpd: Actually find the sequence number for `bgp extcommunity-list...`
…heck

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
louberger and others added 15 commits August 18, 2020 11:46
Signed-off-by: Lou Berger <lberger@labn.net>
…valgrind-supp-libyang

[7.4] bgpd: suppress new libyang_1.0 related loss reports
Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
Missed this in 5022c83

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
Signed-off-by: Martin Winter <mwinter@opensourcerouting.org>
…es_for_debugging_if_malformed_7.4

bgpd: [7.4] Dump attributes before returning from bgp_attr_malformed()
…n27_build

[7.4] python: Make FRR build compatible with python 2.7 and 3.x
IGMP packets received from a source that does not match the subnet
of any configured addresses on the receive interface should be
ignored.
Also, find and use the correct IGMP socket object for the received
IGMP packet.

Signed-off-by: Nathan Bahr <nbahr@atcorp.com>
Signed-off-by: Jafar Al-Gharaibeh <jafar@atcorp.com>
IGMP queries should contain the source address of the IGMP socket
they are being sent from.
Added binding the IGMP sockets to their specific source, otherwise
interfaces with multiple addresses will send multiple queries using
the same source, which is determined by the kernel.

Signed-off-by: Nathan Bahr <nbahr@atcorp.com>
Reviewed-by: Jafar Al-Gharaibeh <jafar@atcorp.com>
Match by exact address rather than by prefix match to
determine if we generated the IGMPP query. Othwerwise
we will be ignoring IGMP queries coming from other
hosts on the same subnet.

Signed-off-by: Nathan Bahr <nbahr@atcorp.com>
Reviewed-by: Jafar Al-Gharaibeh <jafar@atcorp.com>
[7.4] pimd: fix igmp querier election and IP address mapping
zebra: Revert "zebra: probe local inactive neigh"
…mmand

This is needed to avoid mangling update-group which is used for many peers.

Sent prefix count is managed by update-groups.

Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
…ing_maximum-prefix-out_global_7.4

bgpd: [7.4] Create separate udpate-group when using `maximum-prefix-out` command
This series of events:

$ sudo ifconfig lo0 add 4.4.4.4/32
$ sudo ifconfig lo0 inet 4.4.4.4/32 delete

would end up leaving the 4.4.4.4/32 address on the interface under
freebsd.

This all boils down to the fact that the interface is not
considered connected yet we have a destination.  If the
destination is the same and we are not connected ignore
it on freebsd.

I am sure there are other fun scenarios that someone
will have to squirrel out.

Signed-off-by: Donald Sharp <sharpd@nvidia.com>
Copy link

@polychaeta polychaeta left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your contribution to FRR!

  • One of your commits has an improperly formatted commit message

If you are a new contributor to FRR, please see our contributing guidelines.

After making changes, you do not need to create a new PR. You should perform an amend or interactive rebase followed by a force push.

@NetDEF-CI
Copy link
Collaborator

Continuous Integration Result: FAILED

See below for issues.
CI System Testrun URL: https://ci1.netdef.org/browse/FRR-FRRPULLREQ-14305/

This is a comment from an automated CI system.
For questions and feedback in regards to this CI system, please feel free to email
Martin Winter - mwinter (at) opensourcerouting.org.

Get source / Pull Request: Successful

Building Stage: Successful

Basic Tests: Failed

Topo tests part 0 on Ubuntu 18.04 amd64: Failed (click for details)

Topology Test Results are at https://ci1.netdef.org/browse/FRR-FRRPULLREQ-TOPOU1804-14305/test

Topology Tests failed for Topo tests part 0 on Ubuntu 18.04 amd64:

*** defaultIntf: warning: r1 has no interfaces
2020-09-22 14:48:58,644 ERROR: PIMd StdErr Log:% No Path to RP address specified: 192.168.100.1

2020-09-22 14:49:00,700 ERROR: PIMd StdErr Log:% No Path to RP address specified: 192.168.100.1

2020-09-22 14:49:06,869 ERROR: PIMd StdErr Log:% No Path to RP address specified: 192.168.100.1

2020-09-22 14:57:16,626 ERROR: 'router_json_cmp' failed after 122.31 seconds
2020-09-22 14:57:16,628 ERROR: assert failed at "test_isis_sr_topo1/test_rib_ipv4_step9": "rt4" JSON output mismatches the expected result
assert json value is different (
  --- Expected value
  +++ Current value
  @@ -5,0 +6,4 @@
  +        "internalFlags": 8, 
  +        "internalNextHopActiveNum": 1, 
  +        "internalNextHopNum": 1, 
  +        "internalStatus": 20, 
  @@ -11,0 +16,2 @@
  +                "flags": 3, 
  +                "interfaceIndex": 5, 
  @@ -15,2 +21,3 @@
  -                    3
  -                ]
  +                    0
  +                ], 
  +                "weight": 1
  @@ -21 +28,3 @@
  -        "selected": true
  +        "selected": true, 
  +        "table": 254, 
  +        "uptime": "00:04:18")

see full log at https://ci1.netdef.org/browse/FRR-FRRPULLREQ-14305/artifact/TOPOU1804/ErrorLog/log_topotests.txt

Topo tests part 1 on Ubuntu 18.04 arm8: Failed (click for details) Topo tests part 1 on Ubuntu 18.04 arm8: No useful log found
Successful on other platforms/tests
  • Debian 9 deb pkg check
  • Topo tests part 0 on Ubuntu 18.04 arm8
  • Static analyzer (clang)
  • Topo tests part 2 on Ubuntu 18.04 arm8
  • Topo tests part 2 on Ubuntu 16.04 i386
  • Ubuntu 18.04 deb pkg check
  • Topo tests part 1 on Ubuntu 18.04 amd64
  • Ubuntu 20.04 deb pkg check
  • Topo tests part 0 on Ubuntu 16.04 i386
  • Addresssanitizer topotests part 1
  • Debian 10 deb pkg check
  • CentOS 7 rpm pkg check
  • Addresssanitizer topotests part 0
  • Topo tests part 2 on Ubuntu 18.04 amd64
  • IPv4 ldp protocol on Ubuntu 18.04
  • Topo tests part 2 on Ubuntu 16.04 amd64
  • Addresssanitizer topotests part 2
  • Fedora 29 rpm pkg check
  • IPv4 protocols on Ubuntu 18.04
  • Topo tests part 1 on Ubuntu 16.04 amd64
  • IPv6 protocols on Ubuntu 18.04
  • Topo tests part 1 on Ubuntu 16.04 i386
  • Ubuntu 16.04 deb pkg check
  • Debian 8 deb pkg check
  • Topo tests part 0 on Ubuntu 16.04 amd64

Warnings Generated during build:

Debian 10 amd64 build: Successful with additional warnings

Debian Package lintian failed for Debian 10 amd64 build:
(see full package build log at https://ci1.netdef.org/browse/FRR-FRRPULLREQ-14305/artifact/DEB10BUILD/ErrorLog/log_lintian.txt)

W: frr source: pkg-js-tools-test-is-missing
W: frr source: newer-standards-version 4.4.1 (current is 4.3.0)
W: frr source: pkg-js-tools-test-is-missing
W: frr source: newer-standards-version 4.4.1 (current is 4.3.0)
W: frr-snmp: changelog-file-missing-explicit-entry 7.4-0 -> 7.4-20200922-00-g8d20ecbd8-0 (missing) -> 7.4-20200922-00-g8d20ecbd8-0~deb10u1
W: frr: changelog-file-missing-explicit-entry 7.4-0 -> 7.4-20200922-00-g8d20ecbd8-0 (missing) -> 7.4-20200922-00-g8d20ecbd8-0~deb10u1
W: frr-pythontools: changelog-file-missing-explicit-entry 7.4-0 -> 7.4-20200922-00-g8d20ecbd8-0 (missing) -> 7.4-20200922-00-g8d20ecbd8-0~deb10u1
W: frr-doc: changelog-file-missing-explicit-entry 7.4-0 -> 7.4-20200922-00-g8d20ecbd8-0 (missing) -> 7.4-20200922-00-g8d20ecbd8-0~deb10u1
W: frr-rpki-rtrlib: changelog-file-missing-explicit-entry 7.4-0 -> 7.4-20200922-00-g8d20ecbd8-0 (missing) -> 7.4-20200922-00-g8d20ecbd8-0~deb10u1

@donaldsharp donaldsharp deleted the 7.4_bsd_address branch June 23, 2021 11:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.