Operating System - HP-UX
1834462 Members
2666 Online
110067 Solutions
New Discussion

qurey regarding file descriptor?

 
Sanjeev gupta_2
Frequent Advisor

qurey regarding file descriptor?

Hi all
I have a query regarding File descriptor
as i know that max. no. of file descriptor a hp system supports is mentioned in system file(kernel parameter) correct me if i am wrong.
now i want to know that how can i know that at a particular time how many file descriptors are open.has max limit been reached? is system send any singal in log file when limit of max. file descriptor has reached.


Pl. put your comments.

Rgds
sanjeev gupta
4 REPLIES 4
Fred Ruffet
Honored Contributor

Re: qurey regarding file descriptor?

Without any tool, depending on your programs, reaching max files may make some programs crash, other slowdown (Oracle closing and opening files). You may see messages like "unable to open file"...

Now you can have tools :
. lsof can give you the number of files open on your system. It could be scripted to monitor the usage.
. more "professional", but a bit more expensive : glance (gpm) can give you the instant usage of files.

Regards,

Fred
--

"Reality is just a point of view." (P. K. D.)
Bharat Katkar
Honored Contributor

Re: qurey regarding file descriptor?

Sanjeev,
Have a look at this link.
http://support.zeus.com/faq/zws/v4/entries/3/os/hpuxfd.html
Hope that clears everythings except how to see no. of FileDescriptors open at a particular. In that case, not sure but may be you try lsof as suggested above.
In case of exceeding the limits you get an error in /var/adm/syslog/syslog.log saying nfile parameter execeeded.

Regards,
You need to know a lot to actually know how little you know
john korterman
Honored Contributor

Re: qurey regarding file descriptor?

Hi,
if you just want to know the number of open files and its relation to the max number, use, e.g.:
# sar -v 2 10

and pay attention to the file-sz column

regards,
John K.
it would be nice if you always got a second chance
Muthukumar_5
Honored Contributor

Re: qurey regarding file descriptor?

Number of open files are depending upon

nfiles
maxfiles
maxfiles_lim

parameter.
You can view them with kmtune -l -q for < 11.23 versions
kmtune for 11.23 version of hp-ux

We can monitor open files limits with vsar tool easily. It is given over,
http://h21007.www2.hp.com/dspp/tech/tech_TechSoftwareDetailPage_IDX/1,1703,5519,00.html

When the open files limit of max. file descriptor has reached then, we can not start application to use file des. there. It will state error as file system table is full there. "[ENFILE] The system file table is full."

HTH.
Easy to suggest when don't know about the problem!