From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by sourceware.org (Postfix) with ESMTPS id 64ADE3858017 for ; Wed, 14 Sep 2022 09:54:52 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 64ADE3858017 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1663149291; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=8LAY530yYFSeytU7XDVKw5zt1BlhKRJ11EWb8WTjDuU=; b=hSDON5LlnovclCu91vKL6R5JMRcDLh+vRcMUL0N1lzdwLsfN4vqQ/Y/Uz85jvvtQIBgPi2 V93VEeee+WxAX+tmwjZlDXbRLJ62Ho6HO4kJR6a6mvspSG0mNvzix+nO5/oaiwIVuLKwNC qyh94Z1WrlK+QH+h2emtAX1TA1tawKU= Received: from mimecast-mx02.redhat.com (mx3-rdu2.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-167-ejcvOvh5MDiDXdC1ufUrug-1; Wed, 14 Sep 2022 05:54:50 -0400 X-MC-Unique: ejcvOvh5MDiDXdC1ufUrug-1 Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.rdu2.redhat.com [10.11.54.1]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 29563296A601 for ; Wed, 14 Sep 2022 09:54:50 +0000 (UTC) Received: from oldenburg.str.redhat.com (unknown [10.39.192.151]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 9705540C83EB; Wed, 14 Sep 2022 09:54:49 +0000 (UTC) From: Florian Weimer To: Carlos O'Donell Cc: libc-alpha@sourceware.org Subject: Re: [PATCH 0/2] Fix nss/tst-nss-files-hosts-long on single-stack hosts (bug 24816) References: Date: Wed, 14 Sep 2022 11:54:47 +0200 In-Reply-To: (Carlos O'Donell's message of "Wed, 14 Sep 2022 05:42:10 -0400") Message-ID: <877d26e0wo.fsf@oldenburg.str.redhat.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.1 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain X-Spam-Status: No, score=-5.5 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_LOW,SPF_HELO_NONE,SPF_NONE,TXREP,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: * Carlos O'Donell: > On Tue, Sep 13, 2022 at 04:35:39PM +0200, Florian Weimer via Libc-alpha wrote: >> Our Fedora builders started running the container tests (after the >> switch to systemd-nspawn), and we encountered this test failure as well. >> Fix this by disabling address configuration in the getent tool. > > Two things I'd like to discuss. > > (1) Change the getent default and drop AI_ADDRCONFIG. > > I'm hesitant to add a new option to getent as a solution to a testing > problem. The documented description for getent ahosts talks only > about enumerating the host entries or calling getaddrinfo with > AF_UNSPEC. Could we just change the default and ignore the host > configuration? This is less conservative but logically it seems to me > that we could just drop AI_ADDRCONFIG, and add a --addrconfig option to > get back the old behaviour. What could we possibly break? I'm not sure why we would make such a backwards-incompatible change just to fix a test. It sounds even more preposterous than adding the new option. There have been support cases where the --no-addrconfig option would have been useful. Today, getent isn't a great tool for diagnosing DNS issues, and I think this option improves the situation slightly. > (2) Fix the test. > > Alternatively the test should be checking to see if it is in a dual > stack environment or single stack environment and only call getent for > the specific case when such interfaces are enabled. > > Can we resolve this entirely in tst-nss-files-hosts-long? I think it's futile to try to replicate the AI_ADDRCONFIG behavior in the test. Thanks, Florian