From owner-freebsd-net@freebsd.org Fri Oct 11 21:12:24 2019 Return-Path: Delivered-To: freebsd-net@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 7B9441321DC for ; Fri, 11 Oct 2019 21:12:24 +0000 (UTC) (envelope-from freebsd-rwg@gndrsh.dnsmgr.net) Received: from gndrsh.dnsmgr.net (br1.CN84in.dnsmgr.net [69.59.192.140]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 46qgdM0Ns1z42dZ for ; Fri, 11 Oct 2019 21:12:22 +0000 (UTC) (envelope-from freebsd-rwg@gndrsh.dnsmgr.net) Received: from gndrsh.dnsmgr.net (localhost [127.0.0.1]) by gndrsh.dnsmgr.net (8.13.3/8.13.3) with ESMTP id x9BLCIgB092448; Fri, 11 Oct 2019 14:12:18 -0700 (PDT) (envelope-from freebsd-rwg@gndrsh.dnsmgr.net) Received: (from freebsd-rwg@localhost) by gndrsh.dnsmgr.net (8.13.3/8.13.3/Submit) id x9BLCHJ7092447; Fri, 11 Oct 2019 14:12:17 -0700 (PDT) (envelope-from freebsd-rwg) From: "Rodney W. Grimes" Message-Id: <201910112112.x9BLCHJ7092447@gndrsh.dnsmgr.net> Subject: Re: FRR on FreeBSD 12 - problems with OSPFv3 In-Reply-To: To: Rudy Date: Fri, 11 Oct 2019 14:12:17 -0700 (PDT) CC: freebsd-net@freebsd.org X-Mailer: ELM [version 2.4ME+ PL121h (25)] MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=US-ASCII X-Rspamd-Queue-Id: 46qgdM0Ns1z42dZ X-Spamd-Bar: / Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=none (mx1.freebsd.org: domain of freebsd-rwg@gndrsh.dnsmgr.net has no SPF policy when checking 69.59.192.140) smtp.mailfrom=freebsd-rwg@gndrsh.dnsmgr.net X-Spamd-Result: default: False [-0.68 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.92)[-0.920,0]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; NEURAL_HAM_LONG(-0.70)[-0.703,0]; MIME_GOOD(-0.10)[text/plain]; RCVD_TLS_LAST(0.00)[]; DMARC_NA(0.00)[dnsmgr.net]; AUTH_NA(1.00)[]; TO_MATCH_ENVRCPT_SOME(0.00)[]; RCPT_COUNT_TWO(0.00)[2]; R_SPF_NA(0.00)[]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:13868, ipnet:69.59.192.0/19, country:US]; MID_RHS_MATCH_FROM(0.00)[]; IP_SCORE(0.04)[ip: (0.14), ipnet: 69.59.192.0/19(0.07), asn: 13868(0.04), country: US(-0.05)]; RCVD_COUNT_TWO(0.00)[2] X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 Oct 2019 21:12:24 -0000 > I just upgraded from FreeBSD 11 to 12 and upgrade from quagga to FRR at > the same time. I've tried frr6 and frr7 and get the same errors. > > bgpd and ospfd work fine, but ospf6 doesn't work.? Not sure what I'm > going wrong. > > If I commend out all the interfaces EXCEPT lo0, ospf6d does not crash. What if you comment out just lo0? Running OSPF on a loopback interface makes no since, your not going to be able to establish a DR/BDR pair so OSPF can never really come up on that interface, and if it did injecting any route from 127/8 into the OSPF lsdb would be very bad! Though I doubt this is the source of the illegal instuction trap it is none the less a configuration issue. > router ospf6 > ?ospf6 router-id 172.17.18.98 > ?redistribute connected route-map MONKEY-ospf6 > ?redistribute static route-map MONKEY-AND-MORE-ospf6 > ?!interface cxl1 area 0.0.0.0 > ?!interface cxl2 area 0.0.0.0 > ?!interface cxl3 area 0.0.0.0 > ?interface lo0 area 0.0.0.0 > > As soon as I get routes from my network, ospf6d tanks. By tanks I take it you mean gets the trap you show below? > Any thoughts? > > > Here is the output from zebra and ospf6. > > *** LOGS *** > > 2019/10/10 23:19:31 OSPF6: Scheduling cxl1 for sso > 2019/10/10 23:19:31 OSPF6: SPF: Scheduled in 0 msec > 2019/10/10 23:19:31 OSPF6: SPF processing: # Areas: 1, SPF runtime: 0 > sec 5 usec, Reason: L+ > > 2019/10/10 23:19:31 OSPF6: Scheduling cxl2 for sso > 2019/10/10 23:19:31 OSPF6: SPF: Scheduled in 50 msec > 2019/10/10 23:19:31 OSPF6: Scheduling cxl3 for sso > 2019/10/10 23:19:31 OSPF6: Neighbor state change 172.17.24.25%cxl3: > [Down]->[Init] (HelloReceived) > 2019/10/10 23:19:31 OSPF6: Neighbor state change 172.17.24.25%cxl3: > [Init]->[ExStart] (2-WayReceived) > 2019/10/10 23:19:31 OSPF6: Neighbor state change 172.17.24.25%cxl3: > [ExStart]->[ExChange] (NegotiationDone) > 2019/10/10 23:19:31 OSPF6: Neighbor state change 172.17.24.25%cxl3: > [ExChange]->[Loading] (ExchangeDone) > 2019/10/10 23:19:31 OSPF6: SPF processing: # Areas: 1, SPF runtime: 0 > sec 109 usec, Reason: R+, R-, L+ > > 2019/10/10 23:19:31 OSPF6: SPF: Scheduled in 83 msec > 2019/10/10 23:19:31 OSPF6: SPF processing: # Areas: 1, SPF runtime: 0 > sec 116 usec, Reason: R+, N+, L+ > > 2019/10/10 23:19:33 OSPF6: Neighbor state change 10.8.254.122%cxl1: > [Down]->[Init] (HelloReceived) > 2019/10/10 23:19:33 OSPF6: Neighbor state change 10.8.254.122%cxl1: > [Init]->[ExStart] (2-WayReceived) > 2019/10/10 23:19:33 OSPF6: Neighbor state change 10.8.254.122%cxl1: > [ExStart]->[ExChange] (NegotiationDone) > 2019/10/10 23:19:33 OSPF6: Neighbor state change 10.8.254.122%cxl1: > [ExChange]->[Loading] (ExchangeDone) > 2019/10/10 23:19:33 OSPF6: SPF: Scheduled in 0 msec > 2019/10/10 23:19:33 OSPF6: SPF processing: # Areas: 1, SPF runtime: 0 > sec 99 usec, Reason: R+, R- > > 2019/10/10 23:19:36 OSPF6: Neighbor state change 172.17.24.25%cxl3: > [Loading]->[Full] (LoadingDone) > 2019/10/10 23:19:36 OSPF6: SPF: Scheduled in 0 msec > 2019/10/10 23:19:31 ZEBRA: client 32 says hello and bids fair to > announce only ospf6 routes vrf=0 > 2019/10/10 23:19:38 ZEBRA: [EC 4043309117] Client 'ospf6' encountered an > error and is shutting down. > 2019/10/10 23:19:38 ZEBRA: release_daemon_table_chunks: Released 0 table > chunks > 2019/10/10 23:19:38 ZEBRA: release_daemon_label_chunks: Released 0 label > chunks > 2019/10/10 23:19:39 ZEBRA: client 32 disconnected. 100 ospf6 routes > removed from the rib > > *** CRASH *** Zebra process crashes after the ospf6 process has encountered some error and shut down or are you indicatong that the OSPF6D process has crashed? > If I run on the command line and don't background, it bombs after 7 > seconds: > # ospf6d > Illegal instruction > > > Here is the end of truss: > # truss ospf6d > ... > mmap(0x0,4096,PROT_READ|PROT_WRITE,MAP_PRIVATE|MAP_ANON,-1,0x0) = > 34863378432 (0x81e04f000) > mmap(0x0,4096,PROT_READ|PROT_WRITE,MAP_PRIVATE|MAP_ANON,-1,0x0) = > 34863382528 (0x81e050000) > mmap(0x0,4096,PROT_READ|PROT_WRITE,MAP_PRIVATE|MAP_ANON,-1,0x0) = > 34863386624 (0x81e051000) > mmap(0x0,4096,PROT_READ|PROT_WRITE,MAP_PRIVATE|MAP_ANON,-1,0x0) = > 34863390720 (0x81e052000) > SIGNAL 11 (SIGSEGV) code=SEGV_ACCERR trapno=12 addr=0x7fffdffffff8 > process killed, signal = 4 > > I wasn't seeing any CORE files when the process dumped, so I turned this > knob: > sysctl kern.sugid_coredump=1 > > Now there is a 1 GByte core file! > > # /usr/obj/usr/src/amd64.amd64/gnu/usr.bin/gdb/gdb/gdb > /usr/local/sbin/ospf6d ospf6d.core > > (gdb) bt > #0? 0x000000080030678c in hash_get () from /usr/local/lib/libfrr.so.0 > #1? 0x000000080033a9b2 in route_node_lookup () from > /usr/local/lib/libfrr.so.0 > #2? 0x0000000000241345 in ospf6_route_lookup () > #3? 0x000000000022e718 in ospf6_abr_examin_summary () > #4? 0x000000000022f13b in ospf6_abr_examin_brouter () > #5? 0x00000000002473ad in ospf6_top_init () > #6? 0x000000000022efda in ospf6_abr_examin_summary () > #7? 0x000000000022f13b in ospf6_abr_examin_brouter () > #8? 0x00000000002473ad in ospf6_top_init () > #9? 0x000000000022efda in ospf6_abr_examin_summary () > #10 0x000000000022f13b in ospf6_abr_examin_brouter () > #11 0x00000000002473ad in ospf6_top_init () > .... lines #3 - #5 repeat to over #8500 ... I stopped hitting ENTER > around there and quit. > > > *** The CONFIG *** > ! > ! Zebra configuration saved from vty > !?? 2019/10/10 23:58:21 > ! > frr version 7.1 > frr defaults traditional > ! > hostname red-ospf6 > password r3moved > log file /var/log/frr/ospf6d.log > service advanced-vty > ! > debug ospf6 neighbor state > ! > ! > interface cxl1 > ?ipv6 ospf6 cost 1 > ?ipv6 ospf6 priority 0 > ?ipv6 ospf6 network point-to-point > ! > interface cxl2 > ?ipv6 ospf6 cost 1 > ?ipv6 ospf6 priority 0 > ?ipv6 ospf6 network point-to-point > ! > interface cxl3 > ?ipv6 ospf6 cost 1 > ?ipv6 ospf6 priority 0 > ?ipv6 ospf6 network point-to-point > ! > interface lo0 > ?ipv6 ospf6 cost 1 > ?ipv6 ospf6 network broadcast What happens if you remove this lo0 section? > ! > router ospf6 > ?ospf6 router-id 172.17.17.17? (made example IP) > ?redistribute connected route-map MONKEY-ospf6 > ?!redistribute static route-map MONKEY-AND-MORE-ospf6 > ?interface lo0 area 0.0.0.0 And remove this too... > ?interface cxl1 area 0.0.0.0 > ?interface cxl2 area 0.0.0.0 > ?interface cxl3 area 0.0.0.0 > ! > access-list access4 permit 127.0.0.1/32 > ! > ipv6 access-list access6 permit ::1/128 > ! > ipv6 prefix-list CustomerOspf seq 5 permit 2620:62:c000::/48 le 64 > ipv6 prefix-list CustomerOspf seq 99 deny any > ipv6 prefix-list DefaultOnly seq 5 permit ::/0 > ipv6 prefix-list DefaultOnly seq 99 deny any > ipv6 prefix-list MonkeyOspf seq 5 permit 2607:f598::/32 le 64 > ipv6 prefix-list MonkeyOspf seq 10 permit 2607:f598:0:dada::/64 le 128 > ipv6 prefix-list MonkeyOspf seq 99 deny any > ipv6 prefix-list SFMix seq 5 permit 2001:504:30::/64 > ipv6 prefix-list SFMix seq 99 deny any > ! > route-map MONKEY-AND-MORE-ospf6 permit 10 > ?match ipv6 address prefix-list CustomerOspf > ?set metric-type type-2 > ?set metric 21 Your remapping ospf6 routes to ospf external type 2? Why? If you want to make them higher cost routes why not just shove the cost up on the interface towards the customer? I am not sure what happens if your taking an ospf6 route, mapping it to ext2 and then re-injecting it, that looks like a route oscillation to me. > ! > route-map MONKEY-AND-MORE-ospf6 permit 20 > ?match ipv6 address prefix-list MonkeyOspf > ?set metric 21 > ! > route-map MONKEY-AND-MORE-ospf6 permit 30 > ?match ipv6 address prefix-list DefaultOnly > ?set metric 21 > ! > route-map MONKEY-AND-MORE-ospf6 permit 40 > ?match ipv6 address prefix-list SFMix > ?set metric 221 > ! > route-map MONKEY-ospf6 permit 10 > ?match ipv6 address prefix-list MonkeyOspf > ?set metric-type type-2 > ?set metric 21 > ! > route-map MONKEY-ospf6 permit 20 > ?match ipv6 address prefix-list SFMix > ?set metric 20 > ?set metric-type type-2 > ! > route-map MONKEY-ospf6 permit 30 > ?set metric 22 > ! > line vty > ?access-class access4 > ?ipv6 access-class access6 > ?exec-timeout 0 0 > ! > > Any help would be appreciated. Does ospf6 come up and run if you remove all the route-map stuff your trying to do? Ie, let ospf do what ospf likes to do and use interface costs to decide what the shortest paths are. Or are you not actually speaking OSPF over the cxlN interfaces and just trying to inject a type 2 external route into your ospf lsdb? > > Rudy > _______________________________________________ > freebsd-net@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-net > To unsubscribe, send any mail to "freebsd-net-unsubscribe@freebsd.org" > > -- Rod Grimes rgrimes@freebsd.org