AIX

AIX

Connect with fellow AIX users and experts to gain knowledge, share insights, and solve problems.

 View Only
  • 1.  AIX 5.3 TL10 broke lsof

    Posted Tue February 16, 2010 08:23 AM

    Originally posted by: SystemAdmin


    Hello,

    Current lsof provided by ibm is broken by TL10.

    In TL09 :

    $ lsof -p $$
    Value of I :215 np:0
    COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
    bash 1130498 admin cwd VDIR 10,8 4096 64 /home (/dev/hd1)
    bash 1130498 admin 0u VCHR 19,4 0t3347 696 /dev/pts/4
    bash 1130498 admin 1u VCHR 19,4 0t3347 696 /dev/pts/4
    bash 1130498 admin 2u VCHR 19,4 0t3347 696 /dev/pts/4
    bash 1130498 admin 255u VCHR 19,4 0t3347 696 /dev/pts/4

    In TL10:
    $ lsof -p $$
    Value of I :190 np:0
    COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
    bash 811028 admin cwd VDIR 10,8 4337916968961 5002816694230450176 /home (/dev/hd1)
    bash 811028 admin 0u VCHR 23,2 0t71163 5002816689935482880 / (/dev/hd4) (like character special /dev/pts/2)
    bash 811028 admin 1u VCHR 23,2 0t71163 5002816689935482880 / (/dev/hd4) (like character special /dev/pts/2)
    bash 811028 admin 2u VCHR 23,2 0t71163 5002816689935482880 / (/dev/hd4) (like character special /dev/pts/2)
    bash 811028 admin 255u VCHR 23,2 0t71163 5002816689935482880 / (/dev/hd4) (like character special /dev/pts/2)

    I have the latest version :
    $ lslpp -l *lsof*
    Fileset Level State Description
    Path: /usr/lib/objrepos
    lsof.base 4.7.0.2 COMMITTED List Of Open Files
    lsof.man.en_US 4.7.0.2 COMMITTED List Of Open Files

    $ lsof -v
    lsof version information:
    revision: 4.77
    latest revision: ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/
    latest FAQ: ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/FAQ
    latest man page: ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/lsof_man
    configuration info: 64 bit kernel
    constructed: Thu Nov 6 16:04:11 PAKST 2008
    constructed by and on: root@Innovator
    compiler: cc
    compiler version: IBM XL C Enterprise Edition for AIX, Version 9.0.0.3
    compiler flags: -DHASIPv6 -DHASSTAT64 -DHAS_JFS2 -I/home/guest/jyoti/lsof_4.77_src/dialects/aix/aix5 -q64 -DAIX_KERNBITS=64 -DAIXA=1 -DAIXV=5300 -qmaxmem=-1 -DLSOF_VSTR="5.3.0.0" -O
    loader flags: -L./lib -llsof -bnolibpath
    system info: AIX Innovator 3 5 00CE34DE4C00
    Only root can list all files.
    /dev warnings are enabled.
    Kernel ID check is disabled.
    Device cache file read-only paths:
    Named via -D: none
    Named in environment variable LSOFDEVCACHE: none
    Personal path format (HASPERSDC): "%h/%p.lsof_%L"
    Modified personal path environment variable: LSOFPERSDCPATH
    LSOFPERSDCPATH value: none
    Personal path: /home/admin/.lsof_qualif
    Device cache file write paths:
    Named via -D: none
    Named in environment variable LSOFDEVCACHE: none
    Personal path format (HASPERSDC): "%h/%p.lsof_%L"
    Modified personal path environment variable: LSOFPERSDCPATH
    LSOFPERSDCPATH value: none
    Personal path: /home/admin/.lsof_qualif

    Must I compiled my own ?

    Thank you


  • 2.  Re: AIX 5.3 TL10 broke lsof

    Posted Wed February 17, 2010 04:11 AM

    Originally posted by: SystemAdmin


    Install lsof RPM and try.

    http://gnome.bullfreeware.com/aixtoolbox/RPMS/ppc/lsof/lsof-4.61-4.aix5.3.ppc.rpm


  • 3.  Re: AIX 5.3 TL10 broke lsof

    Posted Thu February 18, 2010 03:38 PM

    Originally posted by: SystemAdmin


    I compiled the latest version from the official site and now it's ok.

    Seen in 00README file :

    =======================
    Pre-built Lsof Binaries
    =======================

    Avoid using pre-built lsof binaries if you can; build your own
    instead.

    I do not support lsof binaries built and packaged by third parties nor
    lsof binaries built from anything but the latest lsof revision. (See
    the Bug Reports section for more information on the details of lsof
    support.)

    One important reasone for those support restrictions is that when lsof
    is built its Configure script tunes lsof to the features available on
    the building system, often embodied in supporting header files and
    libraries. If the building system doesn't have support for a
    particular feature, lsof won't be built to support the feature on any
    system.

    The Veritas VxFS file system is a good example of a feature that
    requires build-time support.

    UNIX dialect version differences -- Solaris 8 versus 9, AIX 4.3.3
    vesus 5.2, etc. -- can also render a pre-built lsof binary useless
    on a different version. So can kernel bit size.

    There are so many potential pitfalls to using an lsof binary
    improperly that I strongly recommend lsof be used only where it is
    built.