Oracle内存全面分析(1)
来源:互联网 发布:Js each 编辑:程序博客网 时间:2024/04/28 17:04
目录(?)[-]
- Oracle的内存架构组成
- SGASystemGlobal Area
- SGA的重要参数和特性
-
SGA_MAX_SIZE -
PRE_PAGE_SGA -
LOCK_SGA -
SGA_TARGET
-
首先,看看Oracle内存存储的主要内容是什么:
- 程序代码(PLSQL、Java);
- 关于已经连接的会话的信息,包括当前所有活动和非活动会话;
- 程序运行时必须的相关信息,例如查询计划;
- Oracle进程之间共享的信息和相互交流的信息,例如锁;
- 那些被永久存储在外围存储介质上,被cache在内存中的数据(如redo log条目,数据块)。
1. Oracle的内存架构组成
1.1. SGA(System Global Area)
[sql]viewplaincopy
- "font-size:14px;">SQL>
startup - ORACLE
instance started. - Total
System Global Area 289406976 bytes - Fixed
Size 1248576 bytes - Variable
Size 117441216 bytes - Database
Buffers 163577856 bytes - Redo
Buffers 7139328 bytes - Database
mounted. - Database
opened. - SQL>
- 数据缓冲(Buffer Cache)
- 重做日志缓冲(Redo Log Buffer)
- 共享池(Shared Pool)
- Java池(Java Pool)
- 大池(Large Pool)
- 流池(Streams Pool --- 10g以后才有)
- 数据字典缓存(Data Dictionary Cache)
- 其他信息(如数据库和实例的状态信息)
1.1.1. SGA的重要参数和特性
· SGA_MAX_SIZE
系统内存
SGA_MAX_SIZE值
1G
400-500M
2G
1G
4G
2500M
8G
5G
SGA实际大小
公式种涉及到的参数在下面的内容种会一一介绍。
· PRE_PAGE_SGA
[sql]viewplaincopy
- SQL>
show parameter sga - NAME
TYPE VALUE - ------------------------------------
----------- -------------------------- - lock_sga
boolean FALSE - pre_page_sga
boolean FALSE - sga_max_size
big integer 276M - sga_target
big integer 276M - SQL>
startup force - ORACLE
instance started. - Total
System Global Area 289406976 bytes - Fixed
Size 1248576 bytes - Variable
Size 117441216 bytes - Database
Buffers 163577856 bytes - Redo
Buffers 7139328 bytes - Database
mounted. - Database
opened. - SQL>
· LOCK_SGA
· SGA_TARGET
- 共享池(Shared Pool)
- Java池(Java Pool)
- 大池(Large Pool)
- 数据缓存区(Buffer Cache)
- 流池(Streams Pool)
[sql]viewplaincopy
- SQL>
show parameter sga - NAME
TYPE VALUE - ------------------------------------
----------- ------------------------------ - lock_sga
boolean FALSE - pre_page_sga
boolean FALSE - sga_max_size
big integer 276M - sga_target
big integer 276M - SQL>
- SQL>
- SQL>
- SQL>
alter system setsga_target=280M; - alter
system setsga_target=280M - *
- ERROR
at line 1: - ORA-02097:
parameter cannot be modified because specified value is invalid - ORA-00823:
Specified value of sga_target greater than sga_max_size
[sql]viewplaincopy
- SQL>
show parameter sga - NAME
TYPE VALUE - ------------------------------------
----------- ------------------------------ - lock_sga
boolean FALSE - pre_page_sga
boolean FALSE - sga_max_size
big integer 276M - sga_target
big integer 276M - SQL>
alter system setsga_target=252M; - System
altered. - SQL>
show parameter sga - NAME
TYPE VALUE - ------------------------------------
----------- ------------------------------ - lock_sga
boolean FALSE - pre_page_sga
boolean FALSE - sga_max_size
big integer 276M - sga_target
big integer 252M - SQL>
startup force - ORACLE
instance started. - Total
System Global Area 264241152 bytes - Fixed
Size 1248428 bytes - Variable
Size 117441364 bytes - Database
Buffers 138412032 bytes - Redo
Buffers 7139328 bytes - Database
mounted. - Database
opened. - SQL>
show parameter sga - NAME
TYPE VALUE - ------------------------------------
----------- ------------------------------ - lock_sga
boolean FALSE - pre_page_sga
boolean FALSE - sga_max_size
big integer 252M - sga_target
big integer 252M - SQL>
- Oracle内存全面分析(1)
- Oracle内存全面分析(1)
- Oracle内存全面分析(1)
- Oracle内存全面分析(1)
- Oracle内存全面分析 1
- Oracle内存全面分析
- Oracle内存全面分析
- Oracle内存全面分析(1)
- Oracle内存全面分析(2)
- Oracle内存全面分析(3)
- Oracle内存全面分析(4)
- Oracle内存全面分析(5)
- Oracle内存全面分析(6)
- Oracle内存全面分析(7)
- Oracle内存全面分析(8)
- Oracle内存全面分析(9)
- Oracle内存全面分析(10)
- Oracle内存全面分析(11)
- Oracle SGA 概述
- Oracle后台进程
- Oracle 进程类别
- oracle 的服务器进程(PMON,&…
- oracle SGA的查询与调整
- Oracle内存全面分析(1)
- Oracle内存全面分析(2)
- Oracle内存全面分析(3)
- Oracle内存全面分析(4)
- Oracle内存全面分析(5)
- Oracle内存全面分析(6)
- Oracle内存全面分析(7)
- Oracle内存全面分析(8)
- Oracle内存全面分析(9)