ITPub博客

首页 > Linux操作系统 > Linux操作系统 > 实习日志第6天(上)·学习笔记Memory Architecture(二)

实习日志第6天(上)·学习笔记Memory Architecture(二)

原创 Linux操作系统 作者:大米嗵嗵 时间:2011-01-24 10:46:54 0 删除 编辑

Buffer Reads  When the number of clean or unused buffers is low, the database must remove buffers from the buffer cache. The algorithm depends on whether the flash cache is enabled

1.       Flash cache不可用时,DB read buffer from magnetic disk

2.       Flash cache可用时,DB read buffer from magnetic flash cacheThe database keeps the buffer header in an LRU list in main memory to track the state and location of the buffer body in the flash cache.

A cache hit occurs if the database finds the buffer in memory(缓冲命中)

1. The server process searches for the whole buffer in the buffer cache.

2. The server process searches for the buffer header in the flash cache LRU list.

3.If the process does not find the buffer in memory (a cache miss), then the server process performs the following steps:

a. Copies the block from a data file into memory (a physical read)

b. Performs a logical read of the buffer that was read into memory

 

Buffer Pools

 

Redo Log Buffer

循环的buffercircular buffer)记录重做条目的(redo entries

Redo entries contain the information necessary to reconstruct, or redo, changes made to the database by DML or DDL operations.记录redo entry占用连续的space,顺序的写入

The background process log writer (LGWR) writes the redo log buffer to the active online redo log group on disk.

LOG_BUFFER initialization parameter

 

Shared Pool

The shared pool caches various types of program dataShared pool缓存很多类型的程序数据。比如已被解析的SQL,PL/SQL代码,系统参数,数据字典信息(parsed SQL, PL/SQL code, system parameters, and data dictionary information.

The shared pool is divided into several subcomponents

Library Cache库缓存

stores executable SQL and PL/SQL code.

In a shared server architecture, the library cache also contains private(私人的) SQL areas.

If a parsed representation of a SQL statement exists in the library cache and can be shared, then the database reuses the code, known as a soft parse or a library cache hit. Otherwise, the database must build a new executable version of the application code, known as a hard parse or a library cache miss.

Data Dictionary Cache数据字典缓存

The data dictionary is a collection of database tables and views containing reference information about the database, its structures, and its users.

Oracle Database accesses the data dictionary frequently during SQL statement parsing.

 

Server Result Cache

Unlike the buffer pools, the server result cache holds result sets and not data blocks.

contains the SQL query result cache and PL/SQL function result cache

 

Reserved Pool

Oracle Database can use to allocate large contiguous chunks of memory

 

Large Pool(可选的)

The large pool can provide large memory allocations for the following:

·UGA for the shared server and the Oracle XA interface (used where transactions interact with multiple databases)

·Message buffers used in the parallel execution of statements

·Buffers for Recovery Manager (RMAN) I/O slaves

 

Java Pool

stores all session-specific Java code and data within the Java Virtual Machine (JVM).

 

Streams Pool

stores buffered queue messages and provides memory for Oracle Streams capture processes and apply processes.

 

Fixed SGA

 

Overview of Software Code Areas

Software code areas are portions of memory that store code that is being run or can be run.

usually static in size, changing only when software is updated or reinstalled.

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/24005010/viewspace-684530/,如需转载,请注明出处,否则将追究法律责任。

请登录后发表评论 登录
全部评论

注册时间:2010-07-31

  • 博文量
    75
  • 访问量
    134378