Oracle Concept

checkpoint

     A data structure that defines an SCN in the redo thread of a database. Checkpoints are recorded in the control file and each datafile header, and are a crucial element of recovery.(检查点记录在控制文件和每个数据文件的头部,对于恢复他是至关重要的)

(参考:Oracle® Database Concepts 11g Release 1 (11.1).pdf

        Oracle Database Backup and Recovery User's Guide, 11g Release 1 (11.1).pdf )

database checkpoint

      The thread checkpoint that has the lowest SCN. All changes in all enabled redo threads with SCNs prior

to the database checkpoint SCN are guaranteed to have been written to disk.

     是最小的SCN号,在所有的变化SCN高于检查点的SCN是为了确保所有的变化,都可以被写入磁盘

datafile checkpoint

     A data structure that defines an SCN in the redo thread of a database for a particular datafile. Every

datafile has a checkpoint SCN, which you can view in V$DATAFILE.CHECKPOINT_CHANGE#. 

Checkpoint Process (CKPT):检查点进程

       When a checkpoint occurs, Oracle Database must update the headers of all datafiles to record the details of  the checkpoint. This is done by the CKPT process. The CKPT process does not write blocks to disk; DBWn  always performs that work. The statistic DBWR checkpoints displayed by the System_Statistics monitor in  Oracle Enterprise Manager indicates the number of checkpoint requests completed.

     检查点:检查点位置(崩溃后,重做流中的实例恢复起点)有DBWN自动前移,这个过程称为“增量检查点(incremental checkpoints)“,除此之外,还有”完整检查点(full checkpoints)“和”局部检查点(partial checkpoints)“。

  如果将所有脏缓冲区都写入磁盘,就会出现完成检查点,在常规运行中,可能存在几十万个脏缓冲区,但对于增量检查点,

DBWn只写入其中的数百条,而对于完整检查点,它将写入这些内容,为此,必须完成大量的工作:在执行检查点时,需要非常高的CPU使用率和磁盘使用率,用户会话的性能会随之降低。完整检查点对业务产生负面影响。鉴于此,只有在两种情况下,才执行完整检查点:第一种情况是数据库有序的关闭,第二种情况是DBA要求这么做。

   当使用NORMAL,IMMEDIATE,TRANSACTIONAL选项关闭数据库时,都会执行检查点,在关闭和卸载数据库时,DBWn会把所有的脏缓冲区刷入到磁盘。这意味着,再次打开数据库时,不需要执行任何恢复操作,在执行某些操作(如启用归档日志模式和闪回数据库功能),始终希望(也有必要)执行干净关闭,使用下面的语句,可以在任何时候发出完整的检查点信号:

alter system checkpoint;

   对于某些操作,局部检查点是必要的,并会自动执行,局部检查点影响的检查点因操作而异。

    注意:只有在执行有序关闭的时候,以及应DBA的请求时,才会执行完整检查点,而局部检查点是根据需要自动执行的。

posted on 2012-07-25 05:47  Coldest Winter  阅读(338)  评论(0编辑  收藏  举报