(一.五)Memory Areas(内存结构区域)
1.PGA
1.PGA
*.An Oracle process includes the following memory areas --一个Oracle进程包(Server+Process)括下面的内存区域
Executable --执行区
PGA/Session Heap --PGA/Session内存
Shared Libraries --共享库
SGA --SGA
Stack --堆栈信息
Executable --执行区
PGA/Session Heap --PGA/Session内存
Shared Libraries --共享库
SGA --SGA
Stack --堆栈信息
Eg:
Oracle Process Structure Pmap:任意个session
Oracle Process 002e5000 88K r-x-- /lib/ld-2.3.4.so
-----------------------| 002fb000 4K r---- /lib/ld-2.3.4.so
| | 002fc000 4K rw--- /lib/ld-2.3.4.so
|----------------------|---->08048000 002ff000 1176K r-x-- /lib/tls/libc-2.3.4.so
| Execute Area | 00425000 8K r---- /lib/tls/libc-2.3.4.so
|----------------------| 00427000 8K rw--- /lib/tls/libc-2.3.4.so
|----------------------|---->0AAA28C0 00429000 8K rw--- [ anon ]
| PGA | 0042d000 8K r-x-- /lib/libdl-2.3.4.so
| (Session Heap) | 0042f000 4K r---- /lib/libdl-2.3.4.so
| (Private Structure) | 00430000 4K rw--- /lib/libdl-2.3.4.so
| | 00433000 132K r-x-- /lib/tls/libm-2.3.4.so
|----------------------| 00454000 4K r---- /lib/tls/libm-2.3.4.so
|----------------------|---->40000000 00455000 4K rw--- /lib/tls/libm-2.3.4.so
| | 00539000 56K r-x-- /lib/tls/libpthread-2.3.4.so
| Shared Library | 00547000 4K r---- /lib/tls/libpthread-2.3.4.so
| | 00548000 4K rw--- /lib/tls/libpthread-2.3.4.so
| | 00549000 8K rw--- [ anon ]
|----------------------| 0087d000 76K r-x-- /lib/libnsl-2.3.4.so
|----------------------|---->50000000 00890000 4K r---- /lib/libnsl-2.3.4.so
| | 00891000 4K rw--- /lib/libnsl-2.3.4.so
| SGA | 00892000 8K rw--- [ anon ]
| (Share Structure) | 08048000 76968K r-x-- /opt/ora_home/bin/oracle
| | 0cb72000 324K rw--- /opt/ora_home/bin/oracle
| | 0cbc3000 576K rw--- [ anon ]
| | 20000000 288768K rw-s- [ shmid=0x0 ] --shard memeory id:--SGA
| | b7121000 64K rw--- /dev/zero
| | b7131000 64K rw--- /dev/zero
| | b7141000 64K rw--- /dev/zero
|----------------------|---->584A4000 b7151000 64K rw--- /dev/zero
| | b7161000 64K rw--- /dev/zero
| Stack | b7171000 64K rw--- /dev/zero
| | b7181000 64K rw--- /dev/zero
----------------------- b7191000 64K rw--- /dev/zero
b71a1000 64K rw--- /dev/zero
b71b1000 64K rw--- /dev/zero
b71c1000 64K rw--- /dev/zero
b71d1000 320K ----- /dev/zero
b7221000 64K rw--- /dev/zero
b7231000 64K rw--- /dev/zero
b7241000 64K rw--- /dev/zero
b7251000 64K rw--- /dev/zero
b7261000 64K rw--- /dev/zero
b7271000 64K rw--- /dev/zero
b7281000 64K rw--- /dev/zero
b7291000 64K rw--- /dev/zero
b72a1000 36K r-x-- /lib/libnss_files-2.3.4.so
b72aa000 4K r---- /lib/libnss_files-2.3.4.so
b72ab000 4K rw--- /lib/libnss_files-2.3.4.so
b72ac000 80K rw--- /dev/zero
b72c0000 64K rw--- /dev/zero
b72d0000 64K rw--- /dev/zero
b72e0000 64K rw--- /dev/zero
b72f0000 64K rw--- /dev/zero
b7300000 64K rw--- /dev/zero
b7310000 64K rw--- /dev/zero
b7320000 48K rw--- /dev/zero
b732c000 1500K rw--- [ anon ]
b74a3000 4K r-x-- /usr/lib/libaio.so.1.0.1
b74a4000 4K rw--- /usr/lib/libaio.so.1.0.1
b74a5000 1904K r-x-- /opt/ora_home/lib/libnnz10.so
b7681000 152K rw--- /opt/ora_home/lib/libnnz10.so
b76a7000 8K rw--- [ anon ]
b76a9000 88K r-x-- /opt/ora_home/lib/libdbcfg10.so
b76bf000 8K rw--- /opt/ora_home/lib/libdbcfg10.so
b76c1000 32K r-x-- /opt/ora_home/lib/libclsra10.so
b76c9000 4K rw--- /opt/ora_home/lib/libclsra10.so
b76ca000 4K rw--- [ anon ]
b76cb000 7028K r-x-- /opt/ora_home/lib/libjox10.so
b7da8000 260K rw--- /opt/ora_home/lib/libjox10.so
b7de9000 4K rw--- [ anon ]
b7dea000 344K r-x-- /opt/ora_home/lib/libocrutl10.so
b7e40000 16K rw--- /opt/ora_home/lib/libocrutl10.so
b7e44000 4K rw--- [ anon ]
b7e45000 268K r-x-- /opt/ora_home/lib/libocrb10.so
b7e88000 4K rw--- /opt/ora_home/lib/libocrb10.so
b7e89000 436K r-x-- /opt/ora_home/lib/libocr10.so
b7ef6000 4K rw--- /opt/ora_home/lib/libocr10.so
b7ef7000 4K r-x-- /opt/ora_home/lib/libskgxn2.so
b7ef8000 4K rw--- /opt/ora_home/lib/libskgxn2.so
b7ef9000 880K r-x-- /opt/ora_home/lib/libhasgen10.so
b7fd5000 20K rw--- /opt/ora_home/lib/libhasgen10.so
b7fda000 16K rw--- [ anon ]
b7fde000 128K r-x-- /opt/ora_home/lib/libskgxp10.so
b7ffe000 8K rw--- /opt/ora_home/lib/libskgxp10.so
bffd6000 168K rwx-- [ stack ] --Stack
ffffe000 4K r-x-- [ anon ]
total 383652K
--PGA内容:seesion_id,cursor,uga?
2.Share Memory(SGA+Global Area)
Oradebug IPC:
Oracle Process Structure Pmap:任意个session
Oracle Process 002e5000 88K r-x-- /lib/ld-2.3.4.so
-----------------------| 002fb000 4K r---- /lib/ld-2.3.4.so
| | 002fc000 4K rw--- /lib/ld-2.3.4.so
|----------------------|---->08048000 002ff000 1176K r-x-- /lib/tls/libc-2.3.4.so
| Execute Area | 00425000 8K r---- /lib/tls/libc-2.3.4.so
|----------------------| 00427000 8K rw--- /lib/tls/libc-2.3.4.so
|----------------------|---->0AAA28C0 00429000 8K rw--- [ anon ]
| PGA | 0042d000 8K r-x-- /lib/libdl-2.3.4.so
| (Session Heap) | 0042f000 4K r---- /lib/libdl-2.3.4.so
| (Private Structure) | 00430000 4K rw--- /lib/libdl-2.3.4.so
| | 00433000 132K r-x-- /lib/tls/libm-2.3.4.so
|----------------------| 00454000 4K r---- /lib/tls/libm-2.3.4.so
|----------------------|---->40000000 00455000 4K rw--- /lib/tls/libm-2.3.4.so
| | 00539000 56K r-x-- /lib/tls/libpthread-2.3.4.so
| Shared Library | 00547000 4K r---- /lib/tls/libpthread-2.3.4.so
| | 00548000 4K rw--- /lib/tls/libpthread-2.3.4.so
| | 00549000 8K rw--- [ anon ]
|----------------------| 0087d000 76K r-x-- /lib/libnsl-2.3.4.so
|----------------------|---->50000000 00890000 4K r---- /lib/libnsl-2.3.4.so
| | 00891000 4K rw--- /lib/libnsl-2.3.4.so
| SGA | 00892000 8K rw--- [ anon ]
| (Share Structure) | 08048000 76968K r-x-- /opt/ora_home/bin/oracle
| | 0cb72000 324K rw--- /opt/ora_home/bin/oracle
| | 0cbc3000 576K rw--- [ anon ]
| | 20000000 288768K rw-s- [ shmid=0x0 ] --shard memeory id:--SGA
| | b7121000 64K rw--- /dev/zero
| | b7131000 64K rw--- /dev/zero
| | b7141000 64K rw--- /dev/zero
|----------------------|---->584A4000 b7151000 64K rw--- /dev/zero
| | b7161000 64K rw--- /dev/zero
| Stack | b7171000 64K rw--- /dev/zero
| | b7181000 64K rw--- /dev/zero
----------------------- b7191000 64K rw--- /dev/zero
b71a1000 64K rw--- /dev/zero
b71b1000 64K rw--- /dev/zero
b71c1000 64K rw--- /dev/zero
b71d1000 320K ----- /dev/zero
b7221000 64K rw--- /dev/zero
b7231000 64K rw--- /dev/zero
b7241000 64K rw--- /dev/zero
b7251000 64K rw--- /dev/zero
b7261000 64K rw--- /dev/zero
b7271000 64K rw--- /dev/zero
b7281000 64K rw--- /dev/zero
b7291000 64K rw--- /dev/zero
b72a1000 36K r-x-- /lib/libnss_files-2.3.4.so
b72aa000 4K r---- /lib/libnss_files-2.3.4.so
b72ab000 4K rw--- /lib/libnss_files-2.3.4.so
b72ac000 80K rw--- /dev/zero
b72c0000 64K rw--- /dev/zero
b72d0000 64K rw--- /dev/zero
b72e0000 64K rw--- /dev/zero
b72f0000 64K rw--- /dev/zero
b7300000 64K rw--- /dev/zero
b7310000 64K rw--- /dev/zero
b7320000 48K rw--- /dev/zero
b732c000 1500K rw--- [ anon ]
b74a3000 4K r-x-- /usr/lib/libaio.so.1.0.1
b74a4000 4K rw--- /usr/lib/libaio.so.1.0.1
b74a5000 1904K r-x-- /opt/ora_home/lib/libnnz10.so
b7681000 152K rw--- /opt/ora_home/lib/libnnz10.so
b76a7000 8K rw--- [ anon ]
b76a9000 88K r-x-- /opt/ora_home/lib/libdbcfg10.so
b76bf000 8K rw--- /opt/ora_home/lib/libdbcfg10.so
b76c1000 32K r-x-- /opt/ora_home/lib/libclsra10.so
b76c9000 4K rw--- /opt/ora_home/lib/libclsra10.so
b76ca000 4K rw--- [ anon ]
b76cb000 7028K r-x-- /opt/ora_home/lib/libjox10.so
b7da8000 260K rw--- /opt/ora_home/lib/libjox10.so
b7de9000 4K rw--- [ anon ]
b7dea000 344K r-x-- /opt/ora_home/lib/libocrutl10.so
b7e40000 16K rw--- /opt/ora_home/lib/libocrutl10.so
b7e44000 4K rw--- [ anon ]
b7e45000 268K r-x-- /opt/ora_home/lib/libocrb10.so
b7e88000 4K rw--- /opt/ora_home/lib/libocrb10.so
b7e89000 436K r-x-- /opt/ora_home/lib/libocr10.so
b7ef6000 4K rw--- /opt/ora_home/lib/libocr10.so
b7ef7000 4K r-x-- /opt/ora_home/lib/libskgxn2.so
b7ef8000 4K rw--- /opt/ora_home/lib/libskgxn2.so
b7ef9000 880K r-x-- /opt/ora_home/lib/libhasgen10.so
b7fd5000 20K rw--- /opt/ora_home/lib/libhasgen10.so
b7fda000 16K rw--- [ anon ]
b7fde000 128K r-x-- /opt/ora_home/lib/libskgxp10.so
b7ffe000 8K rw--- /opt/ora_home/lib/libskgxp10.so
bffd6000 168K rwx-- [ stack ] --Stack
ffffe000 4K r-x-- [ anon ]
total 383652K
--PGA内容:seesion_id,cursor,uga?
2.Share Memory(SGA+Global Area)
Oradebug IPC:
---------------------------
===============================================
===============================================
二. SGA (System/Share Global Area)
SQL> select * from v$sgainfo;
B71A313C 425 1 1 4 free memory 2BE4D168 52 free 0 00
NAME BYTES RES B71A3104 426 1 1 4 sql area 2BE4C168 4096 recr 4095 2C217B80
-------------------------------- ---------- --- --Base on x$ksmsd B71A30CC 427 1 1 4 sql area 2BE4B168 4096 freeabl 0 2C217B80
Fixed SGA Size 1219016 No --x$ksmlru B71A3094 428 1 1 4 sql area 2BE4A168 4096 recr 4095 2C215660
Redo Buffers 7168000 No B71A305C 429 1 1 4 sql area 2BE49168 4096 freeabl 0 2C215660
Buffer Cache Size 159383552 Yes B71A3024 430 1 1 4 sql area 2BE48168 4096 recr 4095 2C214170
Shared Pool Size 117440512 Yes B71A2FEC 431 1 1 4 sql area 2BE47168 4096 freeabl 0 2C214170
Large Pool Size 4194304 Yes B71A2FB4 432 1 1 4 sql area 2BE46168 4096 recr 4095 2C212C80
Java Pool Size 4194304 Yes B71A2F7C 433 1 1 4 sql area 2BE45168 4096 freeabl 0 2C212C80
Streams Pool Size 0 Yes B71A4F10 434 1 1 4 sql area 2BE44168 4096 recr 4095 2C211790
Granule Size 4194304 No B71A4ED8 435 1 1 4 sql area 2BE43168 4096 freeabl 0 2C211790
Maximum SGA Size 293601280 No B71A4EA0 436 1 1 4 sql area 2BE42168 4096 freeabl 0 2C23C4C4
Startup overhead in Shared Pool 92274688 No B71A4E68 437 1 1 4 PL/SQL DIANA 2BE41168 4096 freeabl 0 2C18C9CC
Free SGA Memory Available 0 B71A4E30 438 1 1 4 sql area 2BE40168 4096 freeabl 0 2C3A5620
B71A4DF8 439 1 1 4 free memory 2BE40098 208 free 0 00
二.一Shared Global Area --SGA
SGA Contains: Buffer Cache Contains:
Fixed SGA Buffer Pool includes
Buffer Pool Default cache
Shared Pool Oracle 7.0 and above Keep and Recycle cache Oracle 8.0 and above
Large Pool Oracle 8.0 and above 2K, 4K, 8K, 16K and 32K cache Oracle 9.0.1 and above
Java Pool Oracle 8.1.5 and above
Streams Pool Oracle 10.1 and above
Redo buffers
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/15072844/viewspace-627474/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/15072844/viewspace-627474/