Oracle's PGA memory Utilization

 
Thread Tools Search this Thread
Special Forums UNIX and Linux Applications Oracle's PGA memory Utilization
# 1  
Old 12-23-2009
Oracle's PGA memory Utilization

Hello all,

I'm running Oracle 10g on Linux (RHEL5). The box has 66G of RAM with 2 databases running on it with 4 quadcore CPUs. I was monitoring the memory usage on the box and found something wierd. First, I executed the following query from the database to find out the PGA usage which looked normal. No session used more than 200M of PGA.

select b.sid, substr(a.name,1,30), b.value
from v$statname a, v$sesstat b
where a.statistic#= b.statistic# and a.name like '%ga %'
and value > 50000000
order by value


803 session pga memory 52189696
1044 session pga memory 53172736
1014 session pga memory 53828096
1028 session pga memory 54548992
1041 session pga memory max 56007840
1028 session pga memory max 58677760
1014 session pga memory max 60643840
911 session pga memory 61102592
903 session pga memory max 61561344
1044 session pga memory max 63658496
997 session pga memory 64248320
1019 session pga memory max 65559040
1075 session pga memory 66345472
887 session pga memory max 70998528
1068 session pga memory 72178176
817 session pga memory 73637024
911 session pga memory max 74406400
817 session pga memory max 76717216
1068 session pga memory max 78862848
1079 session pga memory 79911424
884 session pga memory 81615360
1075 session pga memory max 83778048
1079 session pga memory max 84236800
884 session pga memory max 87906816
1025 session pga memory 89627808
997 session pga memory max 90135040
803 session pga memory max 93215232
1025 session pga memory max 94674080
1039 session pga memory 106912256
1039 session pga memory max 113334784
894 session pga memory 116152832
1004 session pga memory 117546144
894 session pga memory max 120674816
1004 session pga memory max 124427424
986 session pga memory 144464384
832 session pga memory max 146692608
986 session pga memory max 149510656
862 session uga memory max 175362736
964 session uga memory max 175362736
1070 session uga memory max 175362736
1027 session uga memory max 175493552
964 session pga memory max 179674272
862 session pga memory max 179674272
1070 session pga memory max 180067488
1027 session pga memory max 180133024


But when I ran the top command sorted by memory from the OS, I was surprised to see that each process was taking close to about 3G of Resident Memory and VIRT was even worse at around 12G for each process. Not sure why each proces would take so much memory when the query above reports only around 200M for each session. Am I missing something here? By the way, the apps connect to the database through connection pool.


Tasks: 486 total, 1 running, 483 sleeping, 0 stopped, 2 zombie
Cpu(s): 1.4%us, 0.1%sy, 0.0%ni, 98.3%id, 0.2%wa, 0.0%hi, 0.0%si, 0.0%st
Mem: 66070028k total, 65953288k used, 116740k free, 166388k buffers
Swap: 33554424k total, 11825316k used, 21729108k free, 60255088k cached

PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
9232 oracle 15 0 12.4g 3.4g 3.3g S 0 5.4 13:33.26 oracle
19661 oracle 15 0 12.4g 3.3g 3.2g S 0 5.2 14:00.36 oracle
7821 oracle 16 0 12.4g 3.2g 3.2g S 0 5.1 11:39.45 oracle
7796 oracle 15 0 12.4g 3.1g 3.1g S 0 5.0 10:23.40 oracle
8773 oracle 15 0 12.4g 3.0g 2.9g S 0 4.8 8:25.98 oracle
8776 oracle 15 0 12.4g 3.0g 2.9g S 0 4.7 7:59.11 oracle
8778 oracle 15 0 12.5g 2.9g 2.8g S 0 4.7 9:18.47 oracle
7813 oracle 15 0 12.4g 2.8g 2.8g S 0 4.4 9:14.48 oracle
8733 oracle 15 0 12.4g 2.8g 2.7g S 0 4.4 6:55.10 oracle
8254 oracle 15 0 12.4g 2.8g 2.7g S 0 4.4 6:32.34 oracle
7819 oracle 15 0 12.4g 2.7g 2.7g S 0 4.4 7:18.70 oracle
7798 oracle 15 0 12.4g 2.7g 2.6g S 0 4.3 9:33.76 oracle
8291 oracle 15 0 12.4g 2.7g 2.6g S 0 4.3 8:11.63 oracle
8481 oracle 15 0 12.4g 2.7g 2.6g S 0 4.2 9:27.28 oracle
8003 oracle 15 0 12.4g 2.7g 2.6g S 0 4.2 5:48.87 oracle
8420 oracle 15 0 12.4g 2.5g 2.5g S 0 4.0 6:09.58 oracle
8163 oracle 15 0 12.4g 2.4g 2.4g S 0 3.8 4:06.40 oracle

Thanks
# 2  
Old 12-23-2009
Those processes are using shared memory - ie., a lot of the memory reported is shared among all processes. So 12 processes may have the exact same 2GB in common.

We have a 32GB machine and often see 50% memory free but we can also see a slew of processes with "3GB", whose total memory appears to exceed 32GB.
# 3  
Old 12-23-2009
Thanks for the reply. If the resident memory figure that the top is showing for each process incudes the shared memory its well and good. I'm worried about the swap usage. Its close to about 11G based on top's output. Is this just allocated or real swap usage.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. AIX

Need help on memory utilization.

I have run the utility nmon in aix 6.1, and found memory utilization is 99.9% in physical. and pressed h key and then t , in that it is not showing single process which is consuming memory resources. please help me how to find out actual memory utilization. wheather 99% is real memory... (1 Reply)
Discussion started by: manoj.solaris
1 Replies

2. Red Hat

CPU Utilization and Memory Utilization of Services and Applications

Hi, i am new to linux/RHEL 6.0 and i have two questions. 1) How to get the CPU utilization and Memory Utilization of all Services running currently? 2) How to get the CPU utilization and Memory Utilization of all Applications running currently? Please help me to find the script. ... (2 Replies)
Discussion started by: nossam
2 Replies

3. Solaris

High Memory Utilization

Hello Guys, I have one Solaris server with high memory utilization >90%. As per checking, below is the output for memory usage. bash-3.00# ps -efo pmem,uid,pid,ppid,pcpu,comm | sort -r %MEM UID PID PPID %CPU COMMAND 1.7 29496 20668 1 0.0 /opt/app/iw-home/tools/java/bin/java 1.5... (1 Reply)
Discussion started by: myrpthidesis
1 Replies

4. Solaris

[DOUBT] Memory high in idle process on Solaris 10 (Memory Utilization > 90%)

Hi Experts, Our servers running Solaris 10 with SAP Application. The memory utilization always >90%, but the process on SAP is too less even nothing. Why memory utilization on solaris always looks high? I have statement about memory on solaris, is this true: Memory in solaris is used for... (4 Replies)
Discussion started by: edydsuranta
4 Replies

5. HP-UX

memory utilization

command for checking memory utilization in HP -UX (2 Replies)
Discussion started by: tushar_spatil
2 Replies

6. AIX

Memory Utilization

Hi friends i have a query. we have two p-series machine(p550 & p570) with HACMP 5.3 and AIX 5.3 hosting SAP. Now i need to now is there a way or a command to check the memory utilization on these machines on daily basis. I have tried vmstat and iostat but still it's not clear. We have... (3 Replies)
Discussion started by: nathandrake13
3 Replies

7. Shell Programming and Scripting

Memory utilization in HP unix

Hi, I am creating monitoring scripts in HP unix for that i need CPU utilization and memory utilization in HP unix. for CPU utilization i am using TOP command for Memory utilizaion i am not able to use glance command in scripts. means i am not able to redirect and stop. apart from... (1 Reply)
Discussion started by: rsivasan
1 Replies

8. Shell Programming and Scripting

Memory Utilization

Hi, Is it possible to obtain physical memory and swap memory available in HP-UX server. I tried using "top" command but i'm not able to grep the memory part exclusively... Thanks.... (4 Replies)
Discussion started by: EmbedUX
4 Replies

9. UNIX for Dummies Questions & Answers

CPU/Memory utilization

hi guys I just want to know how to get the cpu/memory utilization of a running script? Well i know that I can use the sar command but it shows the whole system's statistics. Is it possible to get the stats of a single scirpt or a single running service? (6 Replies)
Discussion started by: khestoi
6 Replies

10. AIX

Memory Utilization

All, The (fre) coloumn of the (vmstat) command, does it report the size of the free list including the swap space or it only report on the RAM (physical memory). BR, (1 Reply)
Discussion started by: Negm
1 Replies
Login or Register to Ask a Question