From owner-freebsd-questions Mon Feb 11 1:55: 8 2002 Delivered-To: freebsd-questions@freebsd.org Received: from mailg.telia.com (mailg.telia.com [194.22.194.26]) by hub.freebsd.org (Postfix) with ESMTP id 9ACEE37B404 for ; Mon, 11 Feb 2002 01:55:05 -0800 (PST) Received: from d1o913.telia.com (d1o913.telia.com [195.252.44.241]) by mailg.telia.com (8.11.6/8.11.6) with ESMTP id g1B9t4D14726 for ; Mon, 11 Feb 2002 10:55:04 +0100 (CET) Received: from falcon.midgard.homeip.net (h185n2fls20o913.telia.com [212.181.163.185]) by d1o913.telia.com (8.8.8/8.8.8) with SMTP id KAA29377 for ; Mon, 11 Feb 2002 10:55:04 +0100 (CET) Received: (qmail 63475 invoked by uid 1001); 11 Feb 2002 09:55:03 -0000 Date: Mon, 11 Feb 2002 10:55:03 +0100 From: Erik Trulsson To: Varshavchick Alexander Cc: questions@FreeBSD.ORG Subject: Re: lsof and listening processes on 4.5 Message-ID: <20020211095503.GB63310@student.uu.se> Mail-Followup-To: Varshavchick Alexander , questions@FreeBSD.ORG References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.3.27i Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Mon, Feb 11, 2002 at 11:42:10AM +0300, Varshavchick Alexander wrote: > Hi folks, > > Is it normal that lsof utility doesn't display the process that are > listening specified TCP sockets any more? For example, here are the > examples of the lsof output of 'lsof -i|grep inetd' command on FreeBSD 4.3 > and 4.5: > > 4.3: > inetd 157 root 4 IPv4 0xeee7f720 0t0 TCP *:ftp (LISTEN) > inetd 157 root 5 IPv4 0xeee7f500 0t0 TCP *:telnet (LISTEN) > inetd 157 root 6 IPv6 0xeee7f2e0 0t0 TCP *:telnet (LISTEN) > > 4.5: > inetd 180 root 4 IPv4 0xeb159cc0 0t0 TCP *:* > inetd 180 root 5 IPv4 0xeb15adc0 0t0 TCP *:5611->*:49308 > inetd 180 root 6 IPv4 0xeb15aba0 0t0 TCP *:5611->*:49325 > > How can it be that it doesn't show the ports on which inetd is > listening? How can this info be retrieved on 4.5 at all, are there some > other ways for doing it? Are you sure that inetd is actually listening on any ports? Unless I am not mistaken one of the differences between 4.3 and 4.5 is that inetd does, by default, not listen on ftp or telnet any longer. Look in /etc/inetd.conf and check what ports it is listening for. For me, running 'lsof -i| grep inetd' on 4.5 gave the following inetd 90 root 4u IPv4 0xc3736a40 0t0 TCP *:ftp (LISTEN) inetd 90 root 5u IPv4 0xc3736820 0t0 TCP *:smtp (LISTEN) which is exactly what I would expect, since those are the only two ports I have told inetd to listen on. -- Erik Trulsson ertr1013@student.uu.se To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message