From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/4837 Path: news.gmane.org!not-for-mail From: Rich Felker Newsgroups: gmane.linux.lib.musl.general Subject: Re: if_nameindex/getifaddrs and dhcpcd issue Date: Tue, 8 Apr 2014 11:38:41 -0400 Message-ID: <20140408153840.GF26358@brightrain.aerifal.cx> References: <20140408111147.5f79729f@ncopa-desktop.alpinelinux.org> <20140408134255.GE26358@brightrain.aerifal.cx> Reply-To: musl@lists.openwall.com NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1396971543 6673 80.91.229.3 (8 Apr 2014 15:39:03 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 8 Apr 2014 15:39:03 +0000 (UTC) To: musl@lists.openwall.com Original-X-From: musl-return-4841-gllmg-musl=m.gmane.org@lists.openwall.com Tue Apr 08 17:38:56 2014 Return-path: Envelope-to: gllmg-musl@plane.gmane.org Original-Received: from mother.openwall.net ([195.42.179.200]) by plane.gmane.org with smtp (Exim 4.69) (envelope-from ) id 1WXY6w-0001XW-2s for gllmg-musl@plane.gmane.org; Tue, 08 Apr 2014 17:38:54 +0200 Original-Received: (qmail 9793 invoked by uid 550); 8 Apr 2014 15:38:53 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: Original-Received: (qmail 9785 invoked from network); 8 Apr 2014 15:38:53 -0000 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) Xref: news.gmane.org gmane.linux.lib.musl.general:4837 Archived-At: On Tue, Apr 08, 2014 at 03:16:10PM +0100, Justin Cormack wrote: > On Tue, Apr 8, 2014 at 2:42 PM, Rich Felker wrote: > >> and it only needs to read ipv4 addresses, > >> unless it is implementing dhcp6 too, maybe it does now. Again dhcp6 > >> needs netlink, the Musl ipv6 parts for getifaddrs already use /proc > >> which is definitely unreliable for early boot config in a distro in my > >> view. > > > > In what way does dhcp6 need netlink? What's made this discussion > > difficult so far on IRC is assertions of that form (although not the > > same one) without an explanation of why it's believed to be true, so > > I'd like to keep rational discussion possible by making sure that such > > claims are backed up by explanation rather than just stated as fact. > > I was under the impression that the ioctl-based interface for ipv6 is > incomplete under Linux. Probably "incomplete" in a sense that it can't do some special-purpose stuff that most users don't need. Busybox entirely avoids netlink, as far as I can tell, and it's perfectly acceptable for setting up ipv6, at least in simple setups. You don't even need busybox's iproute2 workalikes; ifconfig and route work fine. > That does not mean anything needs to be in > libc though. ISC dhcp for v6 just calls out to ip in scripts, rather > than ifconfig that it uses for v4, so it is indirectly uses netlink, > but does not require any libc support, indeed all the C code is > portable. udhcpcd works the same; it doesn't make any changes to the interfaces; it just speaks the dhcp protocol. This is really the correct factorization. Rich