- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: Wrong group membership
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-25-2004 05:58 AM
11-25-2004 05:58 AM
Wrong group membership
I have one of my HP-UX 11iv1 servers with WebSphere on it and I have problems with the number of open files getting the nfile limit.
Do you know a way to know the number of open files for each process in the system?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-25-2004 06:20 AM
11-25-2004 06:20 AM
Re: Wrong group membership
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-25-2004 06:37 AM
11-25-2004 06:37 AM
Re: Wrong group membership
if you don't have glace you can use Q4 dump debugger to check number of used nfile.
1. preprocess the kernel for debugging
/usr/contrib/bin/q4pxdb /stand/vmunix
2. start Q4 using the running kernel
/usr/contrib/bin/q4 /stand/vmunix /dev/mem
3. in Q4 prompt run:
load struct file from file max nfile; keep f_count
4. result: kept XXX of YYY
XXX - files opened
YYY - nfile set in kernel
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-25-2004 07:04 AM
11-25-2004 07:04 AM
Re: Wrong group membership
I have glance, but what I want to know is the number of open files that a particular process has opened. With this I hope to find the process which is causing this abrupt increase of opened files.
First I thougth to do this using lsof and an awk program but I want to know if there is any other way to do this thing.
Slawomir: your approach it's very good, I´m tinking to write a script that will check the utilization of nfile and then recognize the process which is taking the major part of this tabl
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-25-2004 11:56 AM
11-25-2004 11:56 AM
Re: Wrong group membership
However, the question is: why not increase nfile to 2 or 2 times it's current value? Knowing that some process in WebSphere or some other application needs 500 files open at the same time isn't something you can change (unless you can rewrite the code and recompile). Note that nfile is way too small in HP-UX for anything but a simple 1-user workstation. It is not unusual to have nfile=4000, even nfile=50000 is not a problem.
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-25-2004 12:09 PM
11-25-2004 12:09 PM
Re: Wrong group membership
$ glance -F
Enter PID (14227) :
There doesn't seem to be an easy way to get per-process file count in glance.
Here is lsof/perl one-liner to achieve this. It should print output 'PID:
lsof -d 0-10000 2>/dev/null | perl -ane '!/PID/ && $count{$F[1]}++; END {for (sort {$count{$a} <=> $count{$b}} keys %count) {print "$_: $count{$_}\n"}}'
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-25-2004 08:00 PM
11-25-2004 08:00 PM
Re: Wrong group membership
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-26-2004 03:42 AM
11-26-2004 03:42 AM
Re: Wrong group membership
ps -efx | grep native | while read line
do
line1="`echo $line | awk -F\"ActiveEJBServerProcess\" '{ print $1}'"
line2="`echo $line | awk -F\"ActiveEJBServerProcess\" '{ print $2}'"
pid="`echo $line1 | awk '{ print $2 }'`"
openfiles="`/usr/contrib/bin/lsof -p $pid | wc -l `"
echo $line2 | awk -F: '{ print $2 }' | sed -e "/^$/d" | awk -v p="$pid" -v f=$openfiles '{ print p" "$
1"\t"f" archivos abiertos" }'
done
Now, all is working well but I'l trying to take pictures until the problem arises, and then recognized wich app is failing.
Regards, Ricardo.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-26-2004 03:48 AM
11-26-2004 03:48 AM
Re: Wrong group membership
ps -efx | grep native | while read line
do
line1="`echo $line | awk -F\"ActiveEJBServerProcess\" '{ print $1}'"
line2="`echo $line | awk -F\"ActiveEJBServerProcess\" '{ print $2}'"
pid="`echo $line1 | awk '{ print $2 }'`"
openfiles="`/usr/contrib/bin/lsof -p $pid | wc -l `"
echo $line2 | awk -F: '{ print $2 }' | sed -e "/^$/d" | awk -v p="$pid" -v f=$openfiles '{ print p" "$
1"\t"f" archivos abiertos" }'
done
Now, all is working well but I'll trying to take pictures until the problem arises, and then recognized which app is failing.
Regards, Ricardo.