[bug-notifications] [lsof 0002607]: lsof doesn\'t show processes having opened a port

Mantis Bug Tracker noreply at opencsw.org
Sat Oct 22 19:41:59 CEST 2011


The following issue has been CLOSED 
====================================================================== 
https://www.opencsw.org/mantis/view.php?id=2607 
====================================================================== 
Reported By:                askwar
Assigned To:                imp
====================================================================== 
Project:                    lsof
Issue ID:                   2607
Category:                   regular use
Reproducibility:            always
Severity:                   major
Priority:                   normal
Status:                     closed
Resolution:                 open
Fixed in Version:           
====================================================================== 
Date Submitted:             2007-10-02 06:31 CEST
Last Modified:              2011-10-22 19:41 CEST
====================================================================== 
Summary:                    lsof doesn\'t show processes having opened a port
Description: 
\"lsof -i\" should show which process has opened which port.
Using the lsof 4.77 from Unstable Sparc 10, that doesn\'t work on my
Solaris 10 U4 Sparc system. Example:

adm at winds02
~/Source/lsof_4.78/lsof_4.78_src $ sudo /opt/csw/bin/lsof -i | grep ssh
sshd        70     root    3u  IPv6                         TCP no
TCP/UDP/IP information available
sshd       308     root    3u  IPv6                         TCP no
TCP/UDP/IP information available
sshd      1713     root    3u  IPv6                         TCP no
TCP/UDP/IP information available
sshd      1808     root    3u  IPv6                         TCP no
TCP/UDP/IP information available
sshd      6728     root    6u  IPv6                         TCP no
TCP/UDP/IP information available
sshd      6731      adm    4u  IPv6                         TCP no
TCP/UDP/IP information available
sshd      6731      adm    8u  IPv4                         TCP no
TCP/UDP/IP information available

When I compile lsof 4.78 by my own, I get the wanted information:

adm at winds02
~/Source/lsof_4.78/lsof_4.78_src $ sudo ./lsof -i | grep ssh
sshd        70     root    3u  IPv6 0x60000e46700      0t0  TCP *:222
(LISTEN)
sshd       308     root    3u  IPv6 0x60000e47480      0t0  TCP *:ssh
(LISTEN)
sshd      1713     root    3u  IPv6 0x6001377e440      0t0  TCP *:ssh
(LISTEN)
sshd      1808     root    3u  IPv6 0x600130c1080      0t0  TCP *:ssh
(LISTEN)
sshd      6728     root    6u  IPv6 0x600131b5600 0t390315  TCP
winds02.win.ch.da.rtr:ssh->winnb000488.win.ch.da.rtr:48063
(ESTABLISHED)
sshd      6731      adm    4u  IPv6 0x600131b5600 0t390315  TCP
winds02.win.ch.da.rtr:ssh->winnb000488.win.ch.da.rtr:48063
(ESTABLISHED)
sshd      6731      adm    8u  IPv4 0x60013271b40      0t0  TCP
localhost:6010 (LISTEN)

As you can see, the Blastwave lsof just says \"TCP no TCP/UDP/IP
information available\", whereas the self compiled version has the
relevant information.


adm at winds02
~/Source/lsof_4.78/lsof_4.78_src $ pkginfo -l CSWlsof
   PKGINST:  CSWlsof
      NAME:  lsof - list open files
  CATEGORY:  application
      ARCH:  sparc
   VERSION:  4.77,REV=2006.11.13
   BASEDIR:  /opt/csw
    VENDOR:  ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof
packaged for CSW by Cyril Plisko
    PSTAMP:  login20061113034530
  INSTDATE:  Sep 26 2007 13:24
   HOTLINE:  http://www.blastwave.org/bugtrack/
     EMAIL:  imp at blastwave.org
    STATUS:  completely installed
     FILES:       28 installed pathnames
                   5 shared pathnames
                   4 linked files
                  16 directories
                   7 executables
                   6 setuid/setgid executables
                2658 blocks used (approx)

adm at winds02
~/Source/lsof_4.78/lsof_4.78_src $ cat /etc/release 
                       Solaris 10 8/07 s10s_u4wos_12b SPARC
           Copyright 2007 Sun Microsystems, Inc.  All Rights Reserved.
                        Use is subject to license terms.
                            Assembled 16 August 2007
adm at winds02
~/Source/lsof_4.78/lsof_4.78_src $ uname -a
SunOS winds02 5.10 Generic_120011-14 sun4u sparc SUNW,Sun-Fire-280R

====================================================================== 

---------------------------------------------------------------------- 
 (0009354) dam (administrator) - 2011-10-22 19:41
 https://www.opencsw.org/mantis/view.php?id=2607#c9354 
---------------------------------------------------------------------- 
An updated lsof lsof-4.84,REV=2011.07.13 has been released to current/
which should fix the issue.



More information about the bug-notifications mailing list