1833645 Members
4721 Online
110062 Solutions
New Discussion

Shared Memory Issue?

 
Justin Willoughby
Regular Advisor

Shared Memory Issue?

I have a rp5470 with 5GB of memory. In glance it shows almost 2gb for system memory. This seems really high to me as user memory is only 1gb.

I used ipcs to take a look at shared memory and it shows the following. I tried to look at the CPID and LPID but there is no such process. Is it possible that some prevous process left a bunch of memory in use that should not be? How do I trouble shoot this? In the past I have run out of memory and can't find out what's using it all as Glance does not report what process is using all the memory up.


root# ipcs -ma | sort -rnk10 | more
m 404 0x0c6629c9 --rw-r----- root root root root 2 19057872 2021 17160 8:09:
21 8:20:49 14:16:01
m 3 0x301c567c --rw-rw-rw- root root root root 3 1048576 1111 1140 14:16:3
0 no-entry 14:15:38
m 5 0x06347849 --rw-rw-rw- root root root root 1 77384 2021 2099 14:16:04
14:16:01 14:16:01
m 1 0x4e0c0002 --rw-rw-rw- root root root root 1 61760 526 526 14:15:08
14:15:12 14:15:05
m 6 0xffffffff --rw-r--rw- root root root root 0 22908 2018 2018 14:16:03
14:16:03 14:16:03
m 2 0x41204c2a --rw-rw-rw- root root root root 1 8192 526 538 14:15:08
14:15:05 14:15:05
m 0 0x411c28ee --rw-rw-rw- root root root root 0 348 526 526 14:15:12
14:15:12 14:15:05
IPC status from /dev/kmem as of Tue Feb 22 09:00:59 2005
T ID KEY MODE OWNER GROUP CREATOR CGROUP NATTCH SEGSZ CPID LPID ATIME
DTIME CTIME
Shared Memory:
4 REPLIES 4
Uday_S_Ankolekar
Honored Contributor

Re: Shared Memory Issue?

In Glance memory report look for pageouts if this number is growing then you potentialy have memory issue.

vmstat and swapinfo is also can be used

EX :vmstat -S 5 5 and swapinfo -tam

-USA..
Good Luck..
David Child_1
Honored Contributor

Re: Shared Memory Issue?

Justin,

Perhaps you could provide the output from 'kmtune' and 'kmsystem'. Some kernel parms and loaded modules can increase the size of your system memory.

David
Stephen Keane
Honored Contributor

Re: Shared Memory Issue?

Unfortunately, it is not uncommon for the CPID and LPID processes to no longer exist. This doesn't mean the memory is not in use. You really need to look at the NATTACH column to see how many processes are currently attached to the shared memory. If this remains zero for a long period of time, it could indicate the memory has been forgotten. Also the ATIME/DTIME columns indicate the last time a process attached/detacched to/from the shared memory, again if this is a long time ago it could indicate a forgotten memory segment.

Rajeev Tyagi
Valued Contributor

Re: Shared Memory Issue?

Justin,

Look at NATTACH column if it is not 0 that means shared memory segment is still attached to no of processes in NATTACH column. If it is 0 that means shared memory segment is not in use and is not released by processes. Also please check your dbc_max_pct value which by default is 50% of your total memory. With 5GB of memory you should set it to 8%.

Rajeev