- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: Kernel Semaphore table utilization high
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
07-13-2007 05:55 PM
07-13-2007 05:55 PM
I have a system running on HP Ux 11.11. I found that semaphore table utilization is at 99%. I wish to find and remove the unused semaphores. Is the following process correct.
Check for defunct semaphore using ipcs –sb. If the third column is like 0x0000000, then we can remove the semaphore.
Use ipcrm –s
If the above process is in correct, could you please advice how to bring the semaphore usage, without rebooting the box.
Thanks,
Ravi.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-13-2007 09:34 PM
07-13-2007 09:34 PM
Re: Kernel Semaphore table utilization high
I am not sure the current step you have is right.
Do you see any line with 0x0000000 entry currently in "ipcs -sb" output.
where are you getting the semaphore table utilization is at 99% messages?
Could you send the output of "kmtune|grep -i sem"
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-14-2007 02:42 AM
07-14-2007 02:42 AM
Re: Kernel Semaphore table utilization high
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-14-2007 11:23 AM
07-14-2007 11:23 AM
Re: Kernel Semaphore table utilization high
Here is a part of o/p of ipcs -sb
s 15325223 0x00000000 --ra------- ftphr ftpgroup 1
s 5718056 0x00000000 ----------- ftphr ftpgroup 1
s 798761 0x00000000 ----------- ftphr ftpgroup 1
s 95274 0x00000000 --ra------- ftphr ftpgroup 1
s 55339 0x00000000 ----------- ftphr ftpgroup 1
s 53292 0x00000000 ----------- ftphr ftpgroup 1
s 53293 0x00000000 --ra------- ftphr ftpgroup 1
s 39982 0x00000000 --ra------- hrpadm sapsys 1
s 12335 0x00000000 --ra------- hrpadm sapsys 1
sema 1 - 1
semaem 16384 - 16384
semmap 1026 - (SEMMNI+2)
semmni 1024 - 1024
semmns 2048 - 2048
semmnu 1024 - 1024
semmsl 2048 Y 2048
semume 1024 - 1024
semvmx 32767 - 32767
Ravi.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-14-2007 01:58 PM
07-14-2007 01:58 PM
Re: Kernel Semaphore table utilization high
You might want to use -sa so you can see all of the info.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-14-2007 02:08 PM
07-14-2007 02:08 PM
Re: Kernel Semaphore table utilization high
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-15-2007 12:18 AM
07-15-2007 12:18 AM
Re: Kernel Semaphore table utilization high
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-15-2007 02:38 AM
07-15-2007 02:38 AM
Re: Kernel Semaphore table utilization high
Your explanation is interesting. Could you please let me know, is there any procedure to know the unused semaphores.
Ravi.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-15-2007 05:22 AM
07-15-2007 05:22 AM
Re: Kernel Semaphore table utilization high
I found a document that supports my statement at the beginning of the thread.
http://developer.softwareag.com/AdaNat/knowhow//adabas_tech/110205_AdabasUNIXMemory.pdf
I wish to know your comments.
Ravi.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-15-2007 07:36 AM
07-15-2007 07:36 AM
Re: Kernel Semaphore table utilization high
sema 1 - 1
semaem 16384 - 16384
semmap 32767 - 32767
semmni 32765 - 32765
semmns 32767 - 32767
semmnu 29984 - 29984
semmsl 2048 Y 2048
semume 64 - 64
semvmx 32767 - 32767
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-15-2007 08:22 AM
07-15-2007 08:22 AM
Re: Kernel Semaphore table utilization high
Still need more analysis.
#ipcs|grep 0x0000000
m 34938 0x00000000 D-rw------- applmgr dba
root [/opt/local/unix/bin] ./shminfo -s 34938
libp4 (7.0): Opening /stand/vmunix /dev/kmem
Loading symbols from /stand/vmunix
shminfo (3.6)
Shmid 34938:
struct shmid_ds at 0xdfb5b8
Pseudo vas at 0x9d3da800
Pseudo pregion at 0x94f55100
Shared region at 0xa9017c00
Segment at 0x74db400.0xc8126000
Segment allocated out of "Global 32-bit quadrant 4"
Processes using this segment:
proc=0x519eb500 (pid 11168 "httpd"): vas=0x9d0d4200, SHMEM preg=0x9f892f00
proc=0x519b6580 (pid 20116 "httpd"): vas=0x9e0c9d00, SHMEM preg=0xace54e00
proc=0x519d8900 (pid 28977 "httpd"): vas=0x78fcbb00, SHMEM preg=0xa9059000
proc=0x51a2b4c0 (pid 28775 "httpd"): vas=0x9f89ab00, SHMEM preg=0xa4669300
proc=0x519da340 (pid 28771 "httpd"): vas=0x9edccc00, SHMEM preg=0x95654600
proc=0x519e9e80 (pid 28503 "httpd"): vas=0x9f3e0b00, SHMEM preg=0xa5577500
proc=0x519e9700 (pid 28502 "httpd"): vas=0x9c6fbd00, SHMEM preg=0xaceb8100
proc=0x51a1ee00 (pid 28501 "httpd"): vas=0xa076b500, SHMEM preg=0xa48d0900
proc=0x519ef880 (pid 28500 "httpd"): vas=0xa4555200, SHMEM preg=0x9fe69300
proc=0x51a2fc00 (pid 28498 "httpd"): vas=0x94445c00, SHMEM preg=0xa9e62000
proc=0x519e22c0 (pid 28468 "httpd"): vas=0xacda2e00, SHMEM preg=0x94a46900
acadv05:root [/opt/local/unix/bin] ps -ef|grep 28468
applmgr 20116 28468 0 Jul 10 ? 0:00 /sa_lgd3_q/applmgr/q303ora/iAS/Apache/Apache/bin/httpd -d /s
applmgr 28977 28468 0 Jul 10 ? 0:00 /sa_lgd3_q/applmgr/q303ora/iAS/Apache/Apache/bin/httpd -d /s
applmgr 28771 28468 0 Jul 10 ? 0:00 /sa_lgd3_q/applmgr/q303ora/iAS/Apache/Apache/bin/httpd -d /s
applmgr 28468 1 0 Jul 10 ? 0:36 /sa_lgd3_q/applmgr/q303ora/iAS/Apache/Apache/bin/httpd -d /s
applmgr 28502 28468 0 Jul 10 ? 0:00 /sa_lgd3_q/applmgr/q303ora/iAS/Apache/Apache/bin/httpd -d /s
applmgr 28503 28468 0 Jul 10 ? 0:00 /sa_lgd3_q/applmgr/q303ora/iAS/Apache/Apache/bin/httpd -d /s
applmgr 11168 28468 0 Jul 10 ? 0:00 /sa_lgd3_q/applmgr/q303ora/iAS/Apache/Apache/bin/httpd -d /s
applmgr 28500 28468 0 Jul 10 ? 0:00 /sa_lgd3_q/applmgr/q303ora/iAS/Apache/Apache/bin/httpd -d /s
applmgr 28488 28468 0 Jul 10 ? 2:03 /sa_lgd3_q/applmgr/q303ora/iAS/Apache/Apache/bin/httpd -d /s
root 2860 2052 1 16:15:33 pts/5 0:00 grep 28468
applmgr 28501 28468 0 Jul 10 ? 0:00 /sa_lgd3_q/applmgr/q303ora/iAS/Apache/Apache/bin/httpd -d /s
applmgr 28775 28468 0 Jul 10 ? 0:00 /sa_lgd3_q/applmgr/q303ora/iAS/Apache/Apache/bin/httpd -d /s
applmgr 28498 28468 0 Jul 10 ? 0:00 /sa_lgd3_q/applmgr/q303ora/iAS/Apache/Apache/bin/httpd -d /s
acadv05:root [/opt/local/unix/bin] ./shminfo|grep 34938
Q4 0x074db400.0xc8126000-0xc83affff 2600 SHMEM id=34938
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-16-2007 01:41 AM
07-16-2007 01:41 AM
Re: Kernel Semaphore table utilization high
Thanks for the values.
Second, I was speaking about semaphores, not shared memory segments.
Following one is a shared memory segment.
m 34938 0x00000000 D-rw------- applmgr dba
Thanks Ravi.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-16-2007 05:14 PM
07-16-2007 05:14 PM
SolutionIt is really IPC_PRIVATE. With this info, it is pretty simple. If there are no processes using it, that semaphore is dead.
Hmm, it seems an application can do ipcs -s and just pick up existing private semaphores and just use them without going through semget(2).
I guess your Adabas documentation is impling they don't do that, so as long as it is not running, IPC_PRIVATE semaphores are dead.
Attached is a program that uses pstat(2) to get the time in days, not just in hours and seconds, perhaps that maybe helpful to tell if they are still used?
ID KEY NSEMS OTIME CTIME
0 0x4f0c2576 1 06-11|10:43 06-11|10:43
...
40983 0x00000000 1 NO-ENTRY 07-16|21:59
24 0x00000000 1 07-14|11:44 07-14|11:44
So 40983 was created on July 16.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-16-2007 07:44 PM
07-16-2007 07:44 PM
Re: Kernel Semaphore table utilization high
Your explanation is wonderfull.
I tried to compile the C program on HP UX 11.00 OS, I got the following error.
/usr/bin/cc 291509.c
(Bundled) cc: "291509.c", line 13: error 1000: Unexpected symbol: "t".
(Bundled) cc: "291509.c", line 14: error 1588: "t" undefined.
(Bundled) cc: "291509.c", line 15: error 1563: Expression in if must be scalar.
(Bundled) cc: "291509.c", line 29: error 1588: "pse_semid" undefined.
(Bundled) cc: "291509.c", line 29: error 1531: Invalid member of struct or union.
I am not good at C programming. Could you please help me.
Ravi.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-16-2007 10:08 PM
07-16-2007 10:08 PM
Re: Kernel Semaphore table utilization high
You must compile the program with an ANSI C compiler. Or you must port it to K&R.
Also, it seems that source only compiles on 11.23 and higher.
Here is a new version. You'll need to compile with -DHP11_11 for 11.00 and 11.11.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-17-2007 05:20 PM
07-17-2007 05:20 PM
Re: Kernel Semaphore table utilization high
Thanks
Ravi
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-17-2007 10:48 PM
07-17-2007 10:48 PM
Re: Kernel Semaphore table utilization high
Could you please provide me a URL, where I can download DHP11_11 compiler
Regards,
Ravi.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-18-2007 07:29 AM
07-18-2007 07:29 AM
Re: Kernel Semaphore table utilization high
-DHP11_11 is a compiler option that should work with your bundled compiled.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-18-2007 06:06 PM
07-18-2007 06:06 PM
Re: Kernel Semaphore table utilization high
It works fine. Thank You Very Much.
Regards,
Ravi.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-18-2007 06:13 PM
07-18-2007 06:13 PM
Re: Kernel Semaphore table utilization high
Regards,
Ravi.