Log Switch Triggers 及Force SCN
A log switch is when Oracle stops writing to the current log file, closes it, opens the next log file, and begins writing to the new log file. There are three conditions that cause LGWR to perform. a log switch.
- The normal cause of a log switch is when a process generating redo is unable to allocate space in the log buffer, because there is insufficient space left in the current log file. That process posts LGWR to perform. a log switch, and the session sleeps on a log file switch completion wait event.
- Log switches may be forced manually in the current thread using the ALTER SYSTEM SWITCH LOGFILE command, or in all enabled threads using the ALTER SYSTEM ARCHIVE LOG CURRENT command.
- Log switches may also be forced automatically in relatively idle threads of an Oracle parallel server database, to secure recoverability. Whenever a log file is reused in any thread, the force SCN recorded in the database entry of the controlfile is advanced to 1 beyond the high SCN of the reused log file (unless the force SCN was already higher). If the low SCN for the current log file in any enabled thread thereby falls behind the force SCN, a log switch is forced in that thread. This allows that log file to be archived. Until that log file is archived, newer redo in the archived copy of the recently reused log file might not be able to be applied in some recovery scenarios, or to a standby database.
If a thread requiring a forced log switch is not open, the instance that raised the force SCN will perform. the log switch on behalf of the closed thread, and the first available ARCn process in any instance will archive the log file. However, if the thread is open, its instance is prompted to perform. these actions itself. This is done by taking a KK instance lock. The LGWR process in each instance holds the KK instance lock on its own thread. The id2 field identifies the thread number. When this lock is taken by another instance, LGWR recognizes that a forced log switch is required.
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/35489/viewspace-695640/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- log file switch
- nologging、force logging、supplemental log的理解
- oracle的scn及sequenceOracle
- 關於log file switch and checkpoint機制
- Oracle 21C TriggersOracle
- 【SCN】Oracle SCN 詳細介紹Oracle
- 【SCN】Oracle推薦scn命令參考Oracle
- 【SCN】Oracle檢查scn值指令碼Oracle指令碼
- Oracle:SCNOracle
- House Of Force
- 如何跟蹤11g vip及SCN IP的輸出
- ACID(Force & Steal)
- Oracle SCN詳解Oracle
- ORACLE -詳解SCNOracle
- 透過修改控制檔案scn推進資料庫scn資料庫
- log4j2使用及log4j2.xml分析XML
- DVWA之Brute Force
- Oracle的DBMS_SCN修正以及SCN的auto-rollover新特性Oracle
- MySQL中undo log介紹及清理MySql
- 深入瞭解SCN(轉)
- 整理jquery中的switch用法及注意問題jQuery
- log4cpp的安裝及使用
- 2.5.11 指定 FORCE LOGGING 模式模式
- 2.5.11.1 使用 FORCE LOGGING 子句
- [20181123]快速提升scn注意.txt
- ora-19706 scn問題
- 【等待事件】standby query scn advance事件
- [譯] 使用 `-force` 被認為是有害的;瞭解 Git 的 `-force-with-lease` 命令Git
- Oracle 檢查點涉及的SCNOracle
- Oracle的SCN顯示問題Oracle
- ordebug 手動修改Oracle sga scnOracle
- oracle基於SCN增量恢復Oracle
- Oracle SCN健康狀態檢查Oracle
- WPF Button Setter Template Setter.Value ControlTemplate Border ContentPresenter ControlTemplate.Triggers
- [20180803]cursor_sharing = force.txt
- DVWA-Brute Force暴力破解
- Quartz.NET 2.x 文件翻譯 - Lesson 2:Jobs 和 Triggersquartz
- Oracle SCN機制詳細解讀Oracle
- 【深入】體系結構-003-SCN