ITPub博客

首页 > 数据库 > 数据库开发技术 > Open a Database in Read-Only Mode (301)

Open a Database in Read-Only Mode (301)

原创 数据库开发技术 作者:tsinglee 时间:2007-12-03 09:11:17 0 删除 编辑

You can open any database in read-only mode to prevent its data from being modified
by user transactions. Read-only mode restricts database access to read-only
transactions, which cannot write to the datafiles or to the redo log files.

Disk writes to other files, such as control files, operating system audit trails, trace files,
and alert logs, can continue in read-only mode. Temporary tablespaces for sort
operations are not affected by the database being open in read-only mode. However,
you cannot take permanent tablespaces offline while a database is open in read-only
mode. Also, job queues are not available in read-only mode.

Read-only mode does not restrict database recovery or operations that change the
database’s state without generating redo data. For example, in read-only mode:
■ Datafiles can be taken offline and online
■ Offline datafiles and tablespaces can be recovered
■ The control file remains available for updates about the state of the database
One useful application of read-only mode is that standby databases can function as
temporary reporting databases.

以只读模式打开数据库
1. 可以以只读模式打开数据库来阻止用户事务修改数据 , 只有只读事务才能访问只读数据库,
只读事务不能向数据文件及重做日志文件写入信息
2. 在只读模式下,控制文件,审计文件,跟踪文件及告警日志依然可以被写入.
用于进行排序操作的临时表空间在只读模式下依然可用.
用户不能在只读模式下将永久表空间脱机.
作业队列在只读模式下无法使用.
3. 在只读模式下,可以执行数据库恢复,也可以执行改变数据库状态的操作(该类操作不产生重做数据).例如,在只读模式下:
* 可以令数据文件联机或脱机
* 可以恢复脱机的数据文件与表空间
* 控制文件可以用于记录数据库状态变化

[@more@]

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

请登录后发表评论 登录
全部评论
  • 博文量
    740
  • 访问量
    1897759