`
csstome
  • 浏览: 1468018 次
  • 性别: Icon_minigender_1
  • 来自: 北京
文章分类
社区版块
存档分类
最新评论

参数CONTROL_FILE_RECORD_KEEP_TIME和MAXLOGHISOTRY

 
阅读更多

--**************************************************

-- 参数 CONTROL_FILE_RECORD_KEEP_TIME MAXLOGHISOTRY

--**************************************************

参数 control_file_record_keep_time 是一 位于控制文件中比 重要的 参数 之一。 它决 定了控制文件里可重 使用的 记录 所能保存的

最小天 新的 记录 需要添加到可重用 记录 的空 间时 且最老的 记录 在可重用 记录 还没 有老化,即 实际 保留的天 未超 过这

个参数规 定的天 控制文件中可重用 记录 部分的空 间将 被自 动扩 展,此 控制文件尺寸 将会变 大。

一、control_file_record_keep_time 信息

1 . 参数 的描述信息

Property Description

-----------------------------------------------------------

Parameter type Integer

Default value 7 (days) -- 缺省

Modifiable ALTER SYSTEM -- 使用ALTER SYSTEM 修改

Range of values 0 to 365 (days) -- 的范 围从 0-365

Basic No

----------------------------------------------------------

2 . 官方定

CONTROL_FILE_RECORD_KEEP_TIME specifies the minimum number of days before a reusable record in the control file

can be reused. In the event a new record needs to be added to a reusable section and the oldest record has not

aged enough, the record section expands. If this parameter is set to 0 , then reusable sections never expand ,

and records are reused as needed.

Note:

This parameter applies only to records in the control file that are circularly reusable (such as archive log

records and various backup records ). It does not apply to records such as datafile , tablespace , and redo

thread records , which are never reused unless the corresponding object is dropped from the tablespace.

3 . 可重用的模

ARCHIVED LOG BACKUP CORRUPTION

BACKUP DATAFILE BACKUP PIECE

BACKUP REDO LOG BACKUP SET

COPY CORRUPTION DATAFILE COPY

DELETED OBJECT LOGHISTORY

OFFLINE RANGE

二、MAXLOGHISOTRY

这个参数 ,咋一看,貌似眼熟的不得了。 没错 ,在 建控制文件的 候被使用。

印象? 里: Oracle 控制文件( CONTROLFILE )

字面上的意思 分析即可知, 该参数 用于控制日志 记录 。即 归档 日志的 记录数应 在控制文件 MAXLOGHISOTRY 参数 的范

,或者 v$log_history 视图 里所有 归档 日志文件 总数 小于等于 MAXLOGHISOTRY

一旦 归档 日志超 过这个 最大 目,且 参数 control_file_record_keep_time 定的 备份 的保留策略之外,即可以被重用或老化

则从头 覆盖以前的 归档 志文件 。也即是 v$log_history 里的相 应记录会 除。

上, 在初始化控制文件的 候, MAXLOGHISOTRY 值来决 保存 归档 日志 记录 信息分配多大的空 该值设 定之后,

其分配的空 间将 不再 动态扩 展。我 知道 RMAN 备份 ,日志 归档时 的信息都 在控制文件或恢 之中。 然已分配存

不能自 动扩 展,那新的 归档 信息 如何追加呢?即由 参数 control_file_record_keep_time 中保留 时间来 确定是否 将过时 的信息 覆盖。

注:v$log_historyOracle 8 i 后由v$archived_log 代替。 maxloghistory 不限制能 够插 入到 v$archived_log 中的 记录数

SQL > select * from v$version;

BANNER

----------------------------------------------------------------

Oracle Database 10 g Enterprise Edition Release 10.2 .0.4.0 - 64 bi

PL / SQL Release 10.2 .0.4.0 - Production

CORE 10.2 .0.4.0 Production

TNS for Solaris: Version 10.2 .0.4.0 - Production

NLSRTL Version 10.2 .0.4.0 - Production

-- 看几 最大的 MAX 置的

SQL > select TYPE ,RECORDS_TOTAL from v$controlfile_record_section

2 where type in ( 'REDO LOG' , 'DATAFILE' , 'CKPT PROG%' , 'REDO THREAD' , 'ARCHIVED LOG' );

TYPE RECORDS_TOTAL

---------------------------- -------------

REDO THREAD 8 --> MAXINSTANCES

REDO LOG 32 --> MAXLOGFILES

DATAFILE 968 --> MAXDATAFILES

ARCHIVED LOG 83536 --> MAXLOGHISTORY

-- ARCHIVED LOG 的明 信息

SQL > select * from v$controlfile_record_section where type like '%ARCHIVED LOG%' ;

TYPE RECORD_SIZE RECORDS_TOTAL RECORDS_USED FIRST_INDEX LAST_INDEX LAST_RECID

---------------------------- ----------- ------------- ------------ ----------- ---------- ----------

ARCHIVED LOG 584 83536 83536 52748 52747 679267

上面的 查询 中可以看到 MAXLOGHISTORY 分配的空 大小以及 记录总数 ,已是使用的 记录总数

视图 v$archived_log 记录 归档 日志

SQL > select count (*) from v$archived_log;

COUNT (*)

----------

83536

SQL > select min (FIRST_TIME), min (COMPLETION_TIME), max (FIRST_TIME), max (COMPLETION_TIME) from

2 v$archived_log;

MIN (FIRST_TIME) MIN (COMPLETION_TIME MAX (FIRST_TIME) MAX (COMPLETION_TIME

------------------- ------------------- ------------------- -------------------

2011 - 04 - 24 12 : 59 : 01 2011 - 04 - 24 13 : 02 : 00 2011 - 06 - 05 23 : 00 : 49 2011 - 06 - 06 03 : 19 : 21

在使用RMAN 备份 备份 信息 有使用恢 的情 下,即使用控制文件 信息。那 control_file_record_keep_time

定的 值应当轻 得大于 用所需 备份 保留的 时间 ( 基于 时间 的保留 参数 )

假定使用控制文件保存 备份 信息,每周 行一次全 ,且 备份 保留恢 窗口 7 天, 议将 control_file_record_keep_time

10 14

三、 Log History 超出MAXLOGHISTORY 的情形

有些情 下, Log History 超出MAXLOGHISTORY 的情形,什 Log History 超出MAXLOGHISTORY ?那不是 动扩 ?是的,正常

应当扩 展控制文件。 Log History 大于MAXLOGHISTORY 有自 控制 展的情形是存在的。 况则 是空 分配所引起的。

假定有下面的情形, 建控制文件 指定 MAXLOGHISTORY 值为 100 ,而Log History 保留了 227 条记录 Why ?

建控制文件 会为 部分分配相 的大小和空 。而每 部分的空 分配根据 Oracle 而不是依据 当时设 定的 记录数

在控制文件中, log history 单条记录 大小通常是固定的, 36 。因此, 100 个记录 MAXLOGHISTORY )需要3600 。控制文

的大小 与数 的大小一 ,同 db_block_size 控制。因此特定 目的 块将为 Log History 部分分配。例如,如果

DB_BLOCK_SIZE 8192 ,那 个块 就足 了。在 这个块 中,我 8192/ 36 ,大 227 个记录 。如果 DB_BLOCK_SIZE 2048 ,那 么将

2 快,但是只 113 个记录

四、 快捷参考

性能 请参

Oracle 硬解析 与软 解析

共享池的 与优 (Shared pool Tuning)

Buffer cache 与优 (一)

Oracle (caching table)的使用

ORACLE 体系 结构请参

Oracle 表空 间与数 据文件

Oracle 文件

Oracle 参数 文件

Oracle 机重做日志文件 (ONLINE LOG FILE)

Oracle 控制文件(CONTROLFILE)

Oracle 归档 日志

Oracle (ROLLBACK)和撤 (UNDO)

Oracle 库实 启动关闭过

Oracle 10g SGA 的自 化管理

Oracle 例和 Oracle (Oracle体系 结构 )

关闪 回特性 请参

Oracle 回特性 (FLASHBACK DATABASE)

Oracle 回特性 (FLASHBACK DROP & RECYCLEBIN)

Oracle 回特性 (Flashback Query、Flashback Table)

Oracle 回特性 (Flashback Version、Flashback Transaction)

基于用 管理的 备份 备份 请参

Oracle 备份

Oracle 热备份

Oracle 备份 复概

Oracle 例恢

Oracle 基于用 管理恢 ( 详细 描述了介 及其 )

SYSTEM 表空 管理 备份

SYSAUX表空 管理及恢

RMAN 备份 复与 管理 请参

RMAN 述及其体系 结构

RMAN 配置、 管理

RMAN 备份详

RMAN

RMAN catalog 建和使用

基于catalog RMAN 脚本

基于catalog 的RMAN 备份与

使用 RMAN迁移文件系统数据库到 ASM

RMAN 备份 困惑 (使用plus archivelog )

ORACLE 故障 请参

ORA-32004 错误处

ORA-01658 错误

CRS-0215 错误处

ORA-00119,ORA-00132 错误处

又一例SPFILE 错误导 无法 启动

对参数 FAST_START_MTTR_TARGET = 0 解及

SPFILE 错误导 无法 启动 (ORA-01565)

ASM 请参

ASM 例及 ASM

ASM 、目 的管理

使用 ASMCMD 工具管理ASM 及文件

SQL/PLSQL 请参

SQLPlus 常用命令

替代 SQL*Plus

使用Uniread 实现 SQLplus 功能

SQL -->SELECT 查询

SQL --> NEW_VALUE 的使用

SQL --> 集合 (UNION UNION ALL)

SQL --> 常用函

SQL --> 视图 (CREATE VIEW)

SQL --> 建和管理表

SQL --> 多表 查询

SQL --> 过滤 和排序

SQL --> 查询

SQL --> 组与

SQL --> 次化 查询 (START BY ... CONNECT BY PRIOR)

SQL --> ROLLUP CUBE 算符 实现数 汇总

PL/SQL -->

PL/SQL --> (Exception)

PL/SQL --> 言基

PL/SQL --> 流程控制

PL/SQL --> PL/SQL 记录

PL/SQL --> 包的 管理

PL/SQL --> 式游 (SQL%FOUND)

PL/SQL --> 包重 、初始化

PL/SQL --> DBMS_DDL 包的使用

PL/SQL --> DML 触发

PL/SQL --> INSTEAD OF 触发

PL/SQL --> 储过

PL/SQL -->

PL/SQL --> 动态 SQL

PL/SQL --> 动态 SQL 的常 见错误

ORACLE 特性

Oracle 常用目 录结构 (10g)

使用OEM,SQL*Plus,iSQL*Plus 管理Oracle

日志 记录 模式 (LOGGING 、FORCE LOGGING 、NOLOGGING)

表段、索引段上的LOGGING NOLOGGING

Oralce OMF 功能

Oracle 限、系 统权

Oracle 角色、配置文件

Oracle

Oracle 外部表

使用外部表管理Oracle 告警日志(ALAERT_$SID.LOG)

簇表及簇表管理(Index clustered tables)

EXPDP 出工具的使用

IMPDP 入工具的使用

Oracle

SQL*Loader使用方法

用用 户进 程跟踪

配置非默 端口的 动态

配置ORACLE 接到

system sys,sysoper sysdba 区别

ORACLE_SID、DB_NAME 、INSTANCE_NAME 、DB_DOMIAN 、GLOBAL_NAME

Oracle 丁全集 (Oracle 9i 10g 11g Path)

Oracle 10.2.0.1 10.2.0.4

Oracle kill session

分享到:
评论

相关推荐

    Oracle9i的init.ora参数中文说明

    说明: 与 NLS_TIME_TZ_FORMAT 相似, 其中的一对值指定 TIMESTAMP 数据类型的默认值, 该类型除存储 YEAR, MONTH 和 DAY 日期值, HOUR, MINUTE 和 SECOND 时间值, 还存储 TIMEZONE_HOUR 和 TIMEZONE_MINUTE。...

    ehlib_vcl_src_9_3.26

    Allows keep record in the manner of trees. Each record can have record elements-branches and itself be an element to other parental record. Component TDBGridEh supports to show the tree-type ...

    Linux下的rar解压缩工具

    ver[n] File version control vn Use the old style volume naming scheme vp Pause before each volume w<path> Assign work directory x<file> Exclude specified file x@ Read file names to exclude from ...

    gun tar for windows

    -m, --modification-time don't extract file modified time --same-owner try extracting files with the same ownership --numeric-owner always use numbers for user/group names -p, --same-permissions ...

    BobBuilder_app

    This means that you do a binary search in the page list in log M time and get the value in O(1) time within a page. RaptorDB starts off by loading the page list and it is good to go from there and...

    Araxis Merge Professional 2012.4162 (x86/x64).part2

    Whether you are working with multiple revisions of text files or need to keep multiple folder hierarchies in sync (for example, between a desktop and laptop machine), Merge could help save time and ...

    Araxis Merge Professional 2012.4162 (x86/x64).part1

    Whether you are working with multiple revisions of text files or need to keep multiple folder hierarchies in sync (for example, between a desktop and laptop machine), Merge could help save time and ...

    EurekaLog_7.5.0.0_Enterprise

    4)....Added "--el_injectjcl", "--el_createjcl", and "--el_createdbg" command-line options for ecc32/emake to inject JEDI/JCL debug info, create .jdbg file, and create .dbg file (Microsoft debug format...

    EhLib 9.1.024

    Allows keep record in the manner of trees. Each record can have record elements-branches and itself be an element to other parental record. Component TDBGridEh supports to show the tree-type ...

    Radmin自动登录器v3.0-多国语言绿色版-Release1-20150615

    为了在功能和稳定性方面进一步提高和改进,v2.0版使用VC++ Unicode(MFC)编程,程序在编译时已经集成了VC运行库,可独立运行。 由于MFC越益臃肿笨重,为了提高稳定性和效率,v3.0版使用WTL VC++ Unicode编程,程序...

    Radmin自动登录器v3.0

    为了在功能和稳定性方面进一步提高和改进,v2.0版使用VC++ Unicode(MFC)编程,程序在编译时已经集成了VC运行库,可独立运行。 由于MFC越益臃肿笨重,为了提高稳定性和效率,v3.0版使用WTL VC++ Unicode编程,程序...

    EhLib 8.0 Build 8.0.023 Pro Edition FullSource for D7-XE8

    Allows keep record in the manner of trees. Each record can have record elements-branches and itself be an element to other parental record. Component TDBGridEh supports to show the tree-type ...

    RxLib控件包内含RxGIF,全部源码及DEMO

    current record number (for DBase or Paradox tables). TDateEdit and TDBDateEdit (data-aware version) allows direct typing and has a button to bring up calendar in popup window (combo-box alike) or in ...

    EhLib5.0.13 最新的ehlib源码

    Allows keep record in the manner of trees. Each record can have record elements-branches and itself be an element to other parental record. Component TDBGridEh supports to show the tree-type ...

    EhLib 6.3 Build 6.3.176 Russian version. Full source included.

    Allows keep record in the manner of trees. Each record can have record elements-branches and itself be an element to other parental record. Component TDBGridEh supports to show the tree-type ...

    k7 SRIO参考例程

    - Virtex-4 core has long initialization time - Version fixed : v5.1rev1 - CR#481684 / AR#31617 - Virtex-4 initSM modified to prevent branch to silent when RX PCS resets in DISCOVERY state. - Log...

    计算机网络第六版答案

    22. Five generic tasks are error control, flow control, segmentation and reassembly, multiplexing, and connection setup. Yes, these tasks can be duplicated at different layers. For example, error ...

    微软内部资料-SQL性能优化3

    If no rows satisfy the WHERE condition the first time the range is scanned, no rows should be returned on any subsequent scans. Key range locks are similar to row locks on index keys (whether ...

    FlexGraphics_V_1.79_D4-XE10.2_Downloadly.ir

    Added TFlexFileFormat.StreamSupport property (default True), which difines, is it necessary to open file stream or give the file name only. - FIX: If the TCustomProp.Assign method calls when the ...

Global site tag (gtag.js) - Google Analytics