System Administration

List of Processes attached to shared memory

 
Fedon Kadifeli
Super Advisor

List of Processes attached to shared memory

I get the following output from "ipcs -mp"

T ID KEY MODE OWNER GROUP CPID LPID
...
m 63004 0x00000000 D-rw-r----- oracle dba 3919 4346
m 5 0x00000000 D-rw-r----- oracle dba 3919 4346
...

These segments look removed. However since some processes are attached to them, the system cannot remove them. The attached processes are not 3919, neither 4346. How can I find which process uses these segments?

I was not able to find such an information in gpm or lsof...
3 REPLIES 3
Tim Malnati
Honored Contributor

Re: List of Processes attached to shared memory

The ipcrm command should be able to clean these out for you but I would make absolutely sure that Oracle is fully shutdown first. A system reboot may be easier unless your system takes a lot of time to do this or there are some other critical functions running on the box.
Navin Bhat
Occasional Advisor

Re: List of Processes attached to shared memory

Hi Fedon,
Use ipcs -am to know the owner and creator. Also do a "ps" on those processes and check if they are zombies. If they are then use ipcrm and remove them. If not then I dont think there is a way of knowing who is attached with out using q4.

If you know oracle has been shutdown and these segemnts are left behind then you could use ipcrm to remove them.

Regards,
All's well that ends well
Navin Bhat
Occasional Advisor

Re: List of Processes attached to shared memory

oops I ment something like q4 used in HP.
All's well that ends well