From owner-freebsd-net@freebsd.org Wed Jun 19 23:39:34 2019 Return-Path: Delivered-To: freebsd-net@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id DA3FB15CD855; Wed, 19 Jun 2019 23:39:33 +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 1123288694; Wed, 19 Jun 2019 23:39:32 +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 x5JNdVfX020575; Wed, 19 Jun 2019 16:39:31 -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 x5JNdVYZ020574; Wed, 19 Jun 2019 16:39:31 -0700 (PDT) (envelope-from freebsd-rwg) From: "Rodney W. Grimes" Message-Id: <201906192339.x5JNdVYZ020574@gndrsh.dnsmgr.net> Subject: Re: Eliminating IPv6 (?) In-Reply-To: <1633b96e-15ba-9933-abea-46e7b4f0e6a2@grosbein.net> To: Eugene Grosbein Date: Wed, 19 Jun 2019 16:39:31 -0700 (PDT) CC: "Rodney W. Grimes" , "Ronald F. Guilmette" , freebsd-questions@freebsd.org, 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: 1123288694 X-Spamd-Bar: ++ Authentication-Results: mx1.freebsd.org X-Spamd-Result: default: False [2.84 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.02)[-0.019,0]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; NEURAL_SPAM_SHORT(0.97)[0.966,0]; IP_SCORE(0.04)[ip: (0.14), ipnet: 69.59.192.0/19(0.07), asn: 13868(0.05), country: US(-0.06)]; MIME_GOOD(-0.10)[text/plain]; RCVD_TLS_LAST(0.00)[]; DMARC_NA(0.00)[dnsmgr.net]; AUTH_NA(1.00)[]; RCPT_COUNT_FIVE(0.00)[5]; RCVD_COUNT_THREE(0.00)[3]; TO_MATCH_ENVRCPT_SOME(0.00)[]; MX_GOOD(-0.01)[cached: gndrsh.dnsmgr.net]; NEURAL_SPAM_LONG(0.96)[0.958,0]; 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)[]; SUBJECT_HAS_QUESTION(0.00)[] 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: Wed, 19 Jun 2019 23:39:34 -0000 [ Charset windows-1252 unsupported, converting... ] > 19.06.2019 22:42, Rodney W. Grimes wrote: > > >> 18.06.2019 10:10, Ronald F. Guilmette wrote: > >>> How can I turn off IPv6 entirely without rebuilding the kernel? > >> You cannot. GENERIC kernel specifically enables IPv6 support and you need to disable it at compile time. > >> And if you do, you better rebuild the world too using WITHOUT_INET6=yes in the /etc/src.conf > >> or else some utilities compiled with INET6 by default will query kernel > >> for IPv6-specific data (like routing entries) and complain that your kernel does not know about it. > > I have not seen these issues, can you give a specific example that fails? > > Other than kernel/userland interaction (that may be not relevant anymore for modern FreeBSD), > that's basically about making network connections (such as telnet etc.) > to FQDNs resolved to IPv6 addresses supported by binaries (and resolver being userland beast) > but not kernel/routing table. > > > A netstat -rn on a v4 only kernel simple reports the v4 table, and iirc a > > netstat -rn6 returns a "Protocol not supported error" as should all other > > things. > >> World built WITHOUT_INET6 has no such rough edges. > > I find that actually causes me more issues, as then my > > netstat -rn6 returns a hard error due to: > > case '6': > > #ifdef INET6 > > af = AF_INET6; > > #else > > errx(1, "IPv6 support is not compiled in"); > > #endif > > Seems very logical to me. Do we have a script in base running "netstat -rn6" > and breaking on this? Actually that would be more proper as: #ifdef INET6 case '6': af = AF_INET6; #endif With similiar adjustments to the usage message, if needed. -- Rod Grimes rgrimes@freebsd.org