ITPub博客

首页 > 数据库 > 数据库开发技术 > Quiesce Database (330)

Quiesce Database (330)

原创 数据库开发技术 作者:tsinglee 时间:2007-12-08 13:44:08 0 删除 编辑

You can put the system into quiesced state. The system is in quiesced state if there are
no active sessions, other than SYS and SYSTEM. An active session is defined as a
session that is currently inside a transaction, a query, a fetch or a PL/SQL procedure,
or a session that is currently holding any shared resources (for example,
enqueues--enqueues are shared memory structures that serialize access to database
resources and are associated with a session or transaction). Database administrators
are the only users who can proceed when the system is in quiesced state.

Database administrators can perform certain actions in the quiesced state that cannot
be safely done when the system is not quiesced. These actions include:
■ Actions that might fail if there are concurrent user transactions or queries. For
example, changing the schema of a database table will fail if a concurrent
transaction is accessing the same table.
■ Actions whose intermediate effect could be detrimental to concurrent user
transactions or queries. For example, suppose there is a big table T and a PL/SQL
package that operates on it. You can split table T into two tables T1 and T2, and
change the PL/SQL package to make it refer to the new tables T1 and T2, instead
of the old table T.
When the database is in quiesced state, you can do the following:
CREATE TABLE T1 AS SELECT ... FROM T;
CREATE TABLE T2 AS SELECT ... FROM T;
DROP TABLE T;
You can then drop the old PL/SQL package and re-create it.

For systems that must operate continuously, the ability to perform such actions
without shutting down the database is critical.

The Database Resource Manager blocks all actions that were initiated by a user other
than SYS or SYSTEM while the system is quiesced. Such actions are allowed to proceed
when the system goes back to normal (unquiesced) state. Users do not get any
additional error messages from the quiesced state.

静默数据库
1. 静默状态是指数据库中只存在 SYS 和 SYSTEM 用户建立的活动会话
2. 活动会话的定义是: 正在执行事务,查询,数据提???PL/SQL过程的会话,或者是当前拥有
某种共享资源的会话
3. 队列是一个共享的内存结构,她总是和事务或会话相关,用于串行化地访问数据库资源

[@more@]

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

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