Operating System - HP-UX
1833771 Members
2310 Online
110063 Solutions
New Discussion

lsof problem ( "stocks" )

 
yair_2
Occasional Advisor

lsof problem ( "stocks" )

hello all
i have lsof 4.67 built on hp-ux 11.11
i went through all the compilation procedure o.k
but when i'm trying to run lsof , it just stock with no output.
when i run tusc on it i'm getting that the process is sleeping :
"pstat(0x80000019, 0x7dff0d68, 648, 0, 0) ....[sleeping]"

does anybody can tell me what's going wrong with that ???


yairmg
13 REPLIES 13
Jeff Schussele
Honored Contributor

Re: lsof problem ( "stocks" )

Hi yair,

What was the exact lsof command line you are using?

Rgds,
Jeff
PERSEVERANCE -- Remember, whatever does not kill you only makes you stronger!
Zeev Schultz
Honored Contributor

Re: lsof problem ( "stocks" )

Yair,
What options do you run lsof with?
Try to run wiht -p PID or -u UID options.
Also try to run tusc lsof ... > /tmp/tusc.log.
After a minute cancel with Ctl+C.Read the log.

Best regards,

Zeev
So computers don't think yet. At least not chess computers. - Seymour Cray
harry d brown jr
Honored Contributor

Re: lsof problem ( "stocks" )

Why not just download and run a precompiled version?

http://hpux.cs.utah.edu/hppd/hpux/Sysadmin/lsof-4.67/

use 11.00 for 11.11


live free or die
harry
Live Free or Die
yair_2
Occasional Advisor

Re: lsof problem ( "stocks" )

hi zeev && jeff && thanks !
i'm running the command without any arguments because i would like to see list of the open files

the output from the tusc command ( after a minute ) is :

" pstat(0x80000019, 0x7dff0e28, 648, 0, 0) ................................................. [sleeping] "


i also attached you the output
yairmg
Jeff Schussele
Honored Contributor

Re: lsof problem ( "stocks" )

Hi (again) yair,

Well I've never ran lsof w/o any parameters, But I'd suspect that it would take a while to list ALL open files for ALL active processes.
How long are you giving the command to complete?
Also how's the resources on this system - i.e. free memory, CPU & disk load?

Rgds,
Jeff
PERSEVERANCE -- Remember, whatever does not kill you only makes you stronger!
Zeev Schultz
Honored Contributor

Re: lsof problem ( "stocks" )

Ok,what I see in tusc output is :

Inconsistent arg # for syscall 59 (execve): 1/3
or
Inconsistent arg # for syscall 5 (open): 1/3

I'd take some time to think what it can be :)
So computers don't think yet. At least not chess computers. - Seymour Cray
yair_2
Occasional Advisor

Re: lsof problem ( "stocks" )

hi all and thanks
harry -> i did already download the precompiled version and the compilation went o.k. the trouble is going on after that ( when i'm running the command....)

jeff --> i realy give it enough time ....
you can see in the output ( of the tusc ) that someone is sleeping there.....


zeev --> i'm looking forward for your checks...
yairmg
Zeev Schultz
Honored Contributor

Re: lsof problem ( "stocks" )

yair,
Ok.what I saw in tusc output is that lsof does
open() on files but doesn't supply arguments to open sytem call (ie how to open,permissions Read/Write etc).From here I have 2 guesses:

1)when you run lsof without options (and as root user) it also checks network sockets (which are actually a special type of file) and
here is may hang - there were some issues on hp-ux,patches phkl_24047/24507 were used.
2)run lsof as usual user (that doesn't have open connections,like telnets/ftps etc).See if it hangs...

Zeev
So computers don't think yet. At least not chess computers. - Seymour Cray
yair_2
Occasional Advisor

Re: lsof problem ( "stocks" )

hi

i tried to run as a usuall user and it still hangs ( i get the same .."Inconsistent arg # for syscall 5 (open): 1/3" ( tusc's output )

as to the patches : we do have these 2 patches installed in our server...


yairmg
harry d brown jr
Honored Contributor

Re: lsof problem ( "stocks" )


Try the PRE-compiled version, NOT the one you compile yourself.

Additionally, what was the last major patch bundle you installed?

live free or die
harry
Live Free or Die
Zeev Schultz
Honored Contributor

Re: lsof problem ( "stocks" )

Ok,
I read lsof FAQ and there are some points on
64bit hp-ux 11.11 support etc.
What compiler did you use,and your hp-ux is 32 or 64 bit?
I post a FAQ here,read section 9.
For more details you can also contact lsof creator : Victor A. Abell .

best regards,

zeev
So computers don't think yet. At least not chess computers. - Seymour Cray
Sorrel G. Jakins
Valued Contributor

Re: lsof problem ( "stocks" )

Yair, to underscore what Harry said:
Download the precompiled version.
Do not compile anything, just run what you get.
Worked for me.

Sorrel Jakins, BYU
yair_2
Occasional Advisor

Re: lsof problem ( "stocks" )

hi Sorel

i tried to install the depot but i'm getting:

"ERROR: Corrupt lsof.lsof-RUN,r=4.67 "

i downloaded it again but it didn't work ...

yairmg