From owner-freebsd-bugs Mon Nov 26 18:20: 8 2001 Delivered-To: freebsd-bugs@hub.freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.org [216.136.204.21]) by hub.freebsd.org (Postfix) with ESMTP id C796E37B41A for ; Mon, 26 Nov 2001 18:20:01 -0800 (PST) Received: (from gnats@localhost) by freefall.freebsd.org (8.11.6/8.11.6) id fAR2K1F07891; Mon, 26 Nov 2001 18:20:01 -0800 (PST) (envelope-from gnats) Date: Mon, 26 Nov 2001 18:20:01 -0800 (PST) Message-Id: <200111270220.fAR2K1F07891@freefall.freebsd.org> To: freebsd-bugs@FreeBSD.org Cc: From: Makoto Matsushita Subject: Re: bin/32318: no userland tool available to test resolver facilities Reply-To: Makoto Matsushita Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org The following reply was made to PR bin/32318; it has been noted by GNATS. From: Makoto Matsushita To: FreeBSD-gnats-submit@FreeBSD.ORG Cc: Subject: Re: bin/32318: no userland tool available to test resolver facilities Date: Tue, 27 Nov 2001 11:11:10 +0900 Anyway how about putting this tool as a port? It would be helpful for other users. anarcat> However, no tool is available to query the resolver (in the anarcat> sense of gethostbyname/addr() routines) anarcat> transparently. Host(1), dig(1), nslookup(1) all use the name anarcat> servers, and not the /etc/hosts files or NIS/YP. But only host(1) and its friend does check only DNS, these are the exceptions. You can use other networking tools such as ping(8), telnet(1), and more (I don't know which tool fits for you). anarcat> Try to do a address to hostname lookup using a command line anarcat> tool for an address in /etc/hosts that will actually use anarcat> gethostbyname(3). It would be better that you use getaddrinfo(3) instead. This tool only works with IPv4 address but FreeBSD knows what IPv6 is. -- - Makoto `MAR' Matsushita To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message