Oracle Concepts
Purpose of Instance Recovery 实例恢复的目的 Instance recovery ensures that the database is in a consistent state after an instance failure. The files of a database can be left in an inconsistent state because of how Oracle Database manages
Purpose of Instance Recovery
实例恢复的目的
Instance recovery ensures that the database is in a consistent state after an instance failure. The files of a database can be left in an inconsistent state because of how Oracle Database manages database changes.
实例恢复可确保数据库在一个实例失败后仍能回到一个一致的状态。由于Oracle 数据库对数据文件更改的管理方式所致,数据库的文件可以处于不一致的状态。
A redo thread is a record of all of the changes generated by an instance. A single-instance database has one thread of redo, whereas an Oracle RAC database has multiple redo threads, one for each database instance.
重做线程是对实例生成的所有更改的记录。单实例数据库拥有一个重做线程,而一个 Oracle RAC 数据库拥有多个重做线程——每个数据库实例有一个。
When a transaction is committed, log writer (LGWR) writes both the remaining redo entries in memory and the transaction SCN to the online redo log. However, the database writer (DBW) process writes modified data blocks to the data files whenever it is most efficient. For this reason, uncommitted changes may temporarily exist in the data files while committed changes do not yet exist in the data files.
当事务提交时,日志写入器 (LGWR) 将内存中的重做条目和事务 SCN 同时写入联机重做日志。但是,数据库写入器 (DBWn) 进程只在最有利的时机将已修改的数据块写入数据文件。由于这个原因,未提交的更改可能会暂时存在于数据文件中,而已提交的更改也可能还不在数据文件中。
If an instance of an open database fails, either because of a SHUTDOWN ABORT
statement or abnormal termination, then the following situations can result:
如果某个打开的数据库的实例失败,或者由于 SHUTDOWN ABORT 语句或异常终止,则可能会导致下列情况:
-
Data blocks committed by a transaction are not written to the data files and appear only in the online redo log. These changes must be reapplied to the database.
由某事务已提交的数据块更新还未写入数据文件,而仅写入了联机重做日志中。这些更改必须重新应用到数据库。
-
The data files contains changes that had not been committed when the instance failed. These changes must be rolled back to ensure transactional consistency.
数据文件包含实例失败时尚未提交的更改。这些更改必须回滚,以确保事务一致性。
Instance recovery uses only online redo log files and current online data files to synchronize the data files and ensure that they are consistent.
实例恢复只使用联机重做日志文件和当前在线的数据文件,以同步数据文件,并确保它们一致。
See Also:
-
"Database Writer Process (DBWn)" and "Database Buffer Cache"
-
"Introduction to Data Concurrency and Consistency"

热AI工具

Undresser.AI Undress
人工智能驱动的应用程序,用于创建逼真的裸体照片

AI Clothes Remover
用于从照片中去除衣服的在线人工智能工具。

Undress AI Tool
免费脱衣服图片

Clothoff.io
AI脱衣机

AI Hentai Generator
免费生成ai无尽的。

热门文章

热工具

记事本++7.3.1
好用且免费的代码编辑器

SublimeText3汉化版
中文版,非常好用

禅工作室 13.0.1
功能强大的PHP集成开发环境

Dreamweaver CS6
视觉化网页开发工具

SublimeText3 Mac版
神级代码编辑软件(SublimeText3)

热门话题

Oracle 数据库日志的保留期限取决于日志类型和配置,包括:重做日志:由 "LOG_ARCHIVE_DEST" 参数配置的最大大小决定。归档重做日志:由 "DB_RECOVERY_FILE_DEST_SIZE" 参数配置的最大大小决定。在线重做日志:不归档,在数据库重启时丢失,保留期限与实例运行时间一致。审计日志:由 "AUDIT_TRAIL" 参数配置,默认保留 30 天。

Oracle 数据库启动顺序为:1. 检查前置条件;2. 启动监听器;3. 启动数据库实例;4. 等待数据库打开;5. 连接到数据库;6. 验证数据库状态;7. 启用服务(如果需要);8. 测试连接。

Oracle 所需内存量取决于数据库大小、活动水平和所需性能水平:用于存储数据缓冲区、索引缓冲区、执行 SQL 语句和管理数据字典缓存。具体数量受数据库大小、活动水平和所需性能水平影响。最佳实践包括设置适当的 SGA 大小、调整 SGA 组件大小、使用 AMM 和监控内存使用情况。

要在 Oracle 中查找字符出现的次数,执行以下步骤:获取字符串的总长度;获取字符所在子字符串的长度;计算字符出现的次数:用总长度减去子字符串长度。

Oracle 数据库服务器硬件配置要求:处理器:多核,主频至少 2.5 GHz,大型数据库建议 32 核以上。内存:小型数据库至少 8GB,中等规模 16-64GB,大型数据库或高负载工作负载高达 512GB 或更多。存储:SSD 或 NVMe 磁盘,RAID 阵列提高冗余和性能。网络:高速网络(10GbE 或更高),专用网卡,低延迟网络。其他:稳定电源、冗余组件、兼容操作系统和软件、散热和冷却系统。

Oracle 可以通过以下步骤读取 dbf 文件:创建外部表,引用 dbf 文件;查询外部表,检索数据;将数据导入 Oracle 表。

Oracle 数据库所需内存量取决于数据库大小、工作负载类型和并发用户数量。通常建议:小型数据库:16-32 GB,中型数据库:32-64 GB,大型数据库:64 GB 或更多。其他需考虑因素包括数据库版本、内存优化选项、虚拟化和最佳实践(监视内存使用情况、调整分配)。

要在 Oracle 中创建每天执行一次的定时任务,需要执行以下三个步骤:创建一个作业。为作业添加一个子作业,并设置其计划表达式为“INTERVAL 1 DAY”。启用作业。
