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

ospf6d: Prefixes are shown twice in "do sh ipv6 ospf6 database intra-… #7693

Closed
wants to merge 0 commits into from

Conversation

ranjanyash54
Copy link

@ranjanyash54 ranjanyash54 commented Dec 9, 2020

…prefix"

Some prefixes are shown twice in "sh ipv6 ospf6 database intra-prefix" but
not in "sh ipv6 ospf6 database intra-prefix detail".

Some prefixes are not getting shown in "sh ipv6 ospf6 database intra-prefix"
Changed the logic for the do-while loop.

frr# do show running-config 
!
interface ens192
 ip address 5.5.5.2/24
 ipv6 address 12::2/128
!
interface ens193
 ip address 2.2.2.4/24
!
interface ens224
 ip address 6.6.6.1/24
 ipv6 address f9:f9::1/64
 ipv6 ospf6 network point-to-point
!
router ospf6
 ospf6 router-id 10.10.10.180
 interface ens192 area 0.0.0.0
 interface ens224 area 0.0.0.0
 interface ens193 area 0.0.0.0
!
frr# do show ipv6 ospf6 database intra-prefix 

        Area Scoped Link State Database (Area 0.0.0.0)

Type LSId           AdvRouter       Age   SeqNum                        Payload
INP  0.0.0.0        10.10.10.171      6 8000ea1e                      12::1/128
INP  0.0.0.0        10.10.10.180      7 8005af6f                      12::2/128
INP  0.0.0.0        10.10.10.180      7 8005af6f                     f9:f9::/64
INP  0.0.0.0        10.10.10.180      7 8005af6f                     f9:f9::/64      <== Same prefix
INP  0.0.0.10       10.10.10.181   1574 8000002c                        66::/64

Signed-off-by: Yash Ranjan ranjany@vmware.com

@NetDEF-CI
Copy link
Collaborator

NetDEF-CI commented Dec 9, 2020

Continuous Integration Result: FAILED

Continuous Integration Result: FAILED

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

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: Failed

Ubuntu 18.04 arm7 build: Failed (click for details)

Make failed for Ubuntu 18.04 arm7 build:
(see full Make log at https://ci1.netdef.org/browse/FRR-FRRPULLREQ-15899/artifact/U18ARM7BUILD/ErrorLog/log_make.txt)

make[1]: Entering directory '/home/ci/cibuild.15899/frr-source'
ospf6d/ospf6_intra.c: In function ospf6_intra_prefix_lsa_get_prefix_str:
ospf6d/ospf6_intra.c:815:48: error: __builtin___snprintf_chk output may be truncated before the last format character [-Werror=format-truncation=]
In file included from /usr/include/stdio.h:862:0,
/usr/include/arm-linux-gnueabihf/bits/stdio2.h:64:10: note: __builtin___snprintf_chk output between 3 and 5 bytes into a destination of size 4
cc1: all warnings being treated as errors
Makefile:7678: recipe for target 'ospf6d/ospf6_intra.o' failed
make[1]: *** [ospf6d/ospf6_intra.o] Error 1
copying selected object files to avoid basename conflicts...

Ubuntu 18.04 arm7 build: Unknown Log <config.log.gz>
URL: https://ci1.netdef.org/browse/FRR-FRRPULLREQ-15899/artifact/U18ARM7BUILD/config.log/config.log.gz
Ubuntu 18.04 arm7 build: config.status output from configure script can be found at https://ci1.netdef.org/browse/FRR-FRRPULLREQ-15899/artifact/U18ARM7BUILD/config.status/config.status

Successful on other platforms/tests
  • Fedora 29 amd64 build
  • Debian 10 amd64 build
  • FreeBSD 11 amd64 build
  • OpenBSD 6 amd64 build
  • Ubuntu 16.04 arm8 build
  • CentOS 7 amd64 build
  • Ubuntu 18.04 arm8 build
  • Ubuntu 18.04 amd64 build
  • FreeBSD 12 amd64 build
  • Ubuntu 16.04 arm7 build
  • CentOS 8 amd64 build
  • Ubuntu 18.04 ppc64le build
  • Debian 9 amd64 build
  • Ubuntu 16.04 i386 build
  • NetBSD 8 amd64 build
  • Ubuntu 16.04 amd64 build
  • Ubuntu 20.04 amd64 build
  • Debian 8 amd64 build

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-15899/artifact/DEB10BUILD/ErrorLog/log_lintian.txt)

W: frr source: pkg-js-tools-test-is-missing
W: frr source: newer-standards-version 4.5.0.3 (current is 4.3.0)
W: frr source: pkg-js-tools-test-is-missing
W: frr source: newer-standards-version 4.5.0.3 (current is 4.3.0)
W: frr-rpki-rtrlib: changelog-file-missing-explicit-entry 7.5-0 -> 7.6-dev-20201209-00-g2ea91cf38-0 (missing) -> 7.6-dev-20201209-00-g2ea91cf38-0~deb10u1
W: frr-snmp: changelog-file-missing-explicit-entry 7.5-0 -> 7.6-dev-20201209-00-g2ea91cf38-0 (missing) -> 7.6-dev-20201209-00-g2ea91cf38-0~deb10u1
W: frr: changelog-file-missing-explicit-entry 7.5-0 -> 7.6-dev-20201209-00-g2ea91cf38-0 (missing) -> 7.6-dev-20201209-00-g2ea91cf38-0~deb10u1
W: frr-pythontools: changelog-file-missing-explicit-entry 7.5-0 -> 7.6-dev-20201209-00-g2ea91cf38-0 (missing) -> 7.6-dev-20201209-00-g2ea91cf38-0~deb10u1
W: frr-doc: changelog-file-missing-explicit-entry 7.5-0 -> 7.6-dev-20201209-00-g2ea91cf38-0 (missing) -> 7.6-dev-20201209-00-g2ea91cf38-0~deb10u1

@LabN-CI
Copy link
Collaborator

LabN-CI commented Dec 9, 2020

Outdated results 💚

Basic BGPD CI results: SUCCESS, 0 tests failed

_ _
Result SUCCESS git merge/7693 2ea91cf
Date 12/09/2020
Start 04:23:26
Finish 04:58:49
Run-Time 35:23
Total 1815
Pass 1815
Fail 0
Valgrind-Errors 0
Valgrind-Loss 0
Details vncregress-2020-12-09-04:23:26.txt
Log autoscript-2020-12-09-04:24:28.log.bz2
Memory 496 500 423

For details, please contact louberger

@LabN-CI
Copy link
Collaborator

LabN-CI commented Dec 9, 2020

Outdated results 💚

Basic BGPD CI results: SUCCESS, 0 tests failed

_ _
Result SUCCESS git merge/7693 c67d7d2
Date 12/09/2020
Start 06:13:00
Finish 06:48:18
Run-Time 35:18
Total 1815
Pass 1815
Fail 0
Valgrind-Errors 0
Valgrind-Loss 0
Details vncregress-2020-12-09-06:13:00.txt
Log autoscript-2020-12-09-06:14:00.log.bz2
Memory 493 491 427

For details, please contact louberger

@ranjanyash54 ranjanyash54 marked this pull request as draft December 9, 2020 12:03
@ranjanyash54 ranjanyash54 marked this pull request as ready for review December 9, 2020 12:42
@NetDEF-CI
Copy link
Collaborator

NetDEF-CI commented Dec 9, 2020

Continuous Integration Result: SUCCESSFUL

Continuous Integration Result: SUCCESSFUL

Congratulations, this patch passed basic tests

Tested-by: NetDEF / OpenSourceRouting.org CI System

CI System Testrun URL: https://ci1.netdef.org/browse/FRR-FRRPULLREQ-15904/

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.

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-15904/artifact/DEB10BUILD/ErrorLog/log_lintian.txt)

W: frr source: pkg-js-tools-test-is-missing
W: frr source: newer-standards-version 4.5.0.3 (current is 4.3.0)
W: frr source: pkg-js-tools-test-is-missing
W: frr source: newer-standards-version 4.5.0.3 (current is 4.3.0)
W: frr-doc: changelog-file-missing-explicit-entry 7.5-0 -> 7.6-dev-20201209-00-gc67d7d261-0 (missing) -> 7.6-dev-20201209-00-gc67d7d261-0~deb10u1
W: frr: changelog-file-missing-explicit-entry 7.5-0 -> 7.6-dev-20201209-00-gc67d7d261-0 (missing) -> 7.6-dev-20201209-00-gc67d7d261-0~deb10u1
W: frr-pythontools: changelog-file-missing-explicit-entry 7.5-0 -> 7.6-dev-20201209-00-gc67d7d261-0 (missing) -> 7.6-dev-20201209-00-gc67d7d261-0~deb10u1
W: frr-rpki-rtrlib: changelog-file-missing-explicit-entry 7.5-0 -> 7.6-dev-20201209-00-gc67d7d261-0 (missing) -> 7.6-dev-20201209-00-gc67d7d261-0~deb10u1
W: frr-snmp: changelog-file-missing-explicit-entry 7.5-0 -> 7.6-dev-20201209-00-gc67d7d261-0 (missing) -> 7.6-dev-20201209-00-gc67d7d261-0~deb10u1

CLANG Static Analyzer Summary

  • Github Pull Request 7693, comparing to Git base SHA 08b1709

No Changes in Static Analysis warnings compared to base

1 Static Analyzer issues remaining.

See details at
https://ci1.netdef.org/browse/FRR-FRRPULLREQ-15904/artifact/shared/static_analysis/index.html

Copy link
Member

@donaldsharp donaldsharp left a comment

Choose a reason for hiding this comment

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

In all the other lh_get_prefix_str function pointers we just go straight to the item we are interested in by doing pointer math. Why do we need to loop over all the items in the list? Why not just figure out the correct position, ensure it's within the pointer space and use that one? See ospf6_as_external_lsa_get_prefix_str as an example. There are a couple of other examples but this is a good one.

@LabN-CI
Copy link
Collaborator

LabN-CI commented Dec 9, 2020

💚 Basic BGPD CI results: SUCCESS, 0 tests failed

Results table
_ _
Result SUCCESS git merge/7693 1fe922b
Date 12/09/2020
Start 09:16:38
Finish 09:52:07
Run-Time 35:29
Total 1815
Pass 1815
Fail 0
Valgrind-Errors 0
Valgrind-Loss 0
Details vncregress-2020-12-09-09:16:38.txt
Log autoscript-2020-12-09-09:17:45.log.bz2
Memory 495 503 427

For details, please contact louberger

@NetDEF-CI
Copy link
Collaborator

NetDEF-CI commented Dec 9, 2020

Continuous Integration Result: FAILED

Continuous Integration Result: FAILED

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

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 2 on Ubuntu 16.04 i386: Failed (click for details)

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

Topology Tests failed for Topo tests part 2 on Ubuntu 16.04 i386:

2020-12-09 14:20:20,526 ERROR: r5: zebra left a dead pidfile (pid=20107)
2020-12-09 14:27:37,565 ERROR: Traceback (most recent call last):
  File "/root/bamboo-agent-home/xml-data/build-dir/FRR-FRRPULLREQ-TP2U1604I386/topotests/lib/common_config.py", line 2200, in create_bgp_community_lists
    tgen, router, config_data, "bgp_community_list", build=build
  File "/root/bamboo-agent-home/xml-data/build-dir/FRR-FRRPULLREQ-TP2U1604I386/topotests/lib/common_config.py", line 288, in create_common_configuration
    load_config_to_router(tgen, router)
  File "/root/bamboo-agent-home/xml-data/build-dir/FRR-FRRPULLREQ-TP2U1604I386/topotests/lib/common_config.py", line 572, in load_config_to_router
    raise InvalidCLIError("%s" % output)
InvalidCLIError: % Malformed community-list value
line 2: Failure to communicate[13] to bgpd, line: bgp community-list standard ANY permit 0:-1 



2020-12-09 14:27:37,874 ERROR: Traceback (most recent call last):
  File "/root/bamboo-agent-home/xml-data/build-dir/FRR-FRRPULLREQ-TP2U1604I386/topotests/lib/common_config.py", line 2200, in create_bgp_community_lists
    tgen, router, config_data, "bgp_community_list", build=build
  File "/root/bamboo-agent-home/xml-data/build-dir/FRR-FRRPULLREQ-TP2U1604I386/topotests/lib/common_config.py", line 288, in create_common_configuration
    load_config_to_router(tgen, router)
  File "/root/bamboo-agent-home/xml-data/build-dir/FRR-FRRPULLREQ-TP2U1604I386/topotests/lib/common_config.py", line 572, in load_config_to_router
    raise InvalidCLIError("%s" % output)
InvalidCLIError: % Malformed community-list value
line 2: Failure to communicate[13] to bgpd, line: bgp community-list standard ANY permit 0:65536 



2020-12-09 14:27:38,178 ERROR: Traceback (most recent call last):
  File "/root/bamboo-agent-home/xml-data/build-dir/FRR-FRRPULLREQ-TP2U1604I386/topotests/lib/common_config.py", line 2200, in create_bgp_community_lists
    tgen, router, config_data, "bgp_community_list", build=build
  File "/root/bamboo-agent-home/xml-data/build-dir/FRR-FRRPULLREQ-TP2U1604I386/topotests/lib/common_config.py", line 288, in create_common_configuration
    load_config_to_router(tgen, router)
  File "/root/bamboo-agent-home/xml-data/build-dir/FRR-FRRPULLREQ-TP2U1604I386/topotests/lib/common_config.py", line 572, in load_config_to_router
    raise InvalidCLIError("%s" % output)
InvalidCLIError: % Malformed community-list value
line 2: Failure to communicate[13] to bgpd, line: bgp large-community-list standard ANY permit 0:4294967296 



2020-12-09 14:27:38,472 ERROR: Traceback (most recent call last):
  File "/root/bamboo-agent-home/xml-data/build-dir/FRR-FRRPULLREQ-TP2U1604I386/topotests/lib/common_config.py", line 2200, in create_bgp_community_lists
    tgen, router, config_data, "bgp_community_list", build=build
  File "/root/bamboo-agent-home/xml-data/build-dir/FRR-FRRPULLREQ-TP2U1604I386/topotests/lib/common_config.py", line 288, in create_common_configuration
    load_config_to_router(tgen, router)
  File "/root/bamboo-agent-home/xml-data/build-dir/FRR-FRRPULLREQ-TP2U1604I386/topotests/lib/common_config.py", line 572, in load_config_to_router
    raise InvalidCLIError("%s" % output)
InvalidCLIError: % Malformed community-list value
line 2: Failure to communicate[13] to bgpd, line: bgp large-community-list standard ANY permit 0:-1:1 



2020-12-09 14:31:12,052 ERROR: Traceback (most recent call last):
  File "/root/bamboo-agent-home/xml-data/build-dir/FRR-FRRPULLREQ-TP2U1604I386/topotests/lib/common_config.py", line 2200, in create_bgp_community_lists
    tgen, router, config_data, "bgp_community_list", build=build
  File "/root/bamboo-agent-home/xml-data/build-dir/FRR-FRRPULLREQ-TP2U1604I386/topotests/lib/common_config.py", line 288, in create_common_configuration
    load_config_to_router(tgen, router)
  File "/root/bamboo-agent-home/xml-data/build-dir/FRR-FRRPULLREQ-TP2U1604I386/topotests/lib/common_config.py", line 572, in load_config_to_router
    raise InvalidCLIError("%s" % output)
InvalidCLIError: line 2: % Command incomplete[4]: bgp large-community-list standard Test1 permit  



2020-12-09 14:56:57,581 ERROR: assert failed at "test_bgp_multi_vrf_topo2/test_delete_and_re_add_vrf_p1": Testcase test_delete_and_re_add_vrf_p1 :Failed 
   Error Missing route in RIB of router r2, routes: ['3.1.1.1/32', '3.1.1.2/32']
  
assert "Missing route in RIB of router r2, routes: ['3.1.1.1/32', '3.1.1.2/32']\n" is True

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

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

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-15906/artifact/DEB10BUILD/ErrorLog/log_lintian.txt)

W: frr source: pkg-js-tools-test-is-missing
W: frr source: newer-standards-version 4.5.0.3 (current is 4.3.0)
W: frr source: pkg-js-tools-test-is-missing
W: frr source: newer-standards-version 4.5.0.3 (current is 4.3.0)
W: frr: changelog-file-missing-explicit-entry 7.5-0 -> 7.6-dev-20201209-01-g1fe922bad-0 (missing) -> 7.6-dev-20201209-01-g1fe922bad-0~deb10u1
W: frr-pythontools: changelog-file-missing-explicit-entry 7.5-0 -> 7.6-dev-20201209-01-g1fe922bad-0 (missing) -> 7.6-dev-20201209-01-g1fe922bad-0~deb10u1
W: frr-snmp: changelog-file-missing-explicit-entry 7.5-0 -> 7.6-dev-20201209-01-g1fe922bad-0 (missing) -> 7.6-dev-20201209-01-g1fe922bad-0~deb10u1
W: frr-doc: changelog-file-missing-explicit-entry 7.5-0 -> 7.6-dev-20201209-01-g1fe922bad-0 (missing) -> 7.6-dev-20201209-01-g1fe922bad-0~deb10u1
W: frr-rpki-rtrlib: changelog-file-missing-explicit-entry 7.5-0 -> 7.6-dev-20201209-01-g1fe922bad-0 (missing) -> 7.6-dev-20201209-01-g1fe922bad-0~deb10u1

CLANG Static Analyzer Summary

  • Github Pull Request 7693, comparing to Git base SHA 2a20876
  • Base image data for Git 2a20876 does not exist - compare skipped

1 Static Analyzer issues remaining.

See details at
https://ci1.netdef.org/browse/FRR-FRRPULLREQ-15906/artifact/shared/static_analysis/index.html

@ranjanyash54
Copy link
Author

@donaldsharp the pointer maths in the case of intra-prefix and link LSAs are a bit tricky as unlike external LSAs these have more than one prefixes. And to get to the position directly is not possible because the size of prefixes depends upon the prefix length.
#define OSPF6_PREFIX_SIZE(x) \ (OSPF6_PREFIX_SPACE((x)->prefix_length) + sizeof(struct ospf6_prefix))
So that is why an iterative approach is better. For example the ospf6_intra_prefix_lsa_show function. But I understand that in this case it is not ideal as it leads to O(n2) complexity. I am trying to find out a more convenient way to do this. Changing this to draft.

@ranjanyash54 ranjanyash54 marked this pull request as draft December 10, 2020 11:11
@donaldsharp
Copy link
Member

if the pointer differences make it hard to decode without walking let's just get this in then. Please provide a PR for the 7.5 branch

@NetDEF-CI
Copy link
Collaborator

Continuous Integration Result: SUCCESSFUL

Congratulations, this patch passed basic tests

Tested-by: NetDEF / OpenSourceRouting.org CI System

CI System Testrun URL: https://ci1.netdef.org/browse/FRR-FRRPULLREQ-15930/

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.

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-15930/artifact/DEB10BUILD/ErrorLog/log_lintian.txt)

W: frr source: pkg-js-tools-test-is-missing
W: frr source: newer-standards-version 4.5.0.3 (current is 4.3.0)
W: frr source: pkg-js-tools-test-is-missing
W: frr source: newer-standards-version 4.5.0.3 (current is 4.3.0)
W: frr: changelog-file-missing-explicit-entry 7.5-0 -> 7.6-dev-20201208-02-g08b17099f-0 (missing) -> 7.6-dev-20201208-02-g08b17099f-0~deb10u1
W: frr-snmp: changelog-file-missing-explicit-entry 7.5-0 -> 7.6-dev-20201208-02-g08b17099f-0 (missing) -> 7.6-dev-20201208-02-g08b17099f-0~deb10u1
W: frr-rpki-rtrlib: changelog-file-missing-explicit-entry 7.5-0 -> 7.6-dev-20201208-02-g08b17099f-0 (missing) -> 7.6-dev-20201208-02-g08b17099f-0~deb10u1
W: frr-pythontools: changelog-file-missing-explicit-entry 7.5-0 -> 7.6-dev-20201208-02-g08b17099f-0 (missing) -> 7.6-dev-20201208-02-g08b17099f-0~deb10u1
W: frr-doc: changelog-file-missing-explicit-entry 7.5-0 -> 7.6-dev-20201208-02-g08b17099f-0 (missing) -> 7.6-dev-20201208-02-g08b17099f-0~deb10u1

CLANG Static Analyzer Summary

  • Github Pull Request 7693, comparing to Git base SHA 101ad54
  • Base image data for Git 101ad54 does not exist - compare skipped

1 Static Analyzer issues remaining.

See details at
https://ci1.netdef.org/browse/FRR-FRRPULLREQ-15930/artifact/shared/static_analysis/index.html

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants