oracle資料庫的靜默(Quiesce)狀態
B14231 第129頁
一、靜默狀態(quiesce state)的用處
1、在資料庫靜默狀態的時候,只允許dba(這裡dba指sysdba或sysoper)執行資料庫操作;
2、在oracle9i及之前,要達到靜默狀態的功能,只能重啟資料庫到限制模式(restricted mode);
二、將資料庫設定為靜默狀態的方法是使用"ALTER SYSTEM QUIESCE RESTRICTED"語句。
這個語句會等待所有active session變為noactive 狀態時完成。
1、用scott使用者,開啟一個事務,不提交
ora_test@oracle[/home/oracle]> sqlplus scott/tiger SQL*Plus: Release 10.2.0.1.0 - Production on Wed Mar 10 10:17:36 2010 Copyright (c) 1982, 2005, Oracle. All rights reserved. Connected to: Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production With the Partitioning, OLAP and Data Mining options scott@CNHTM> update emp set sal=sal+1 where empno=7934; 1 row updated. scott@CNHTM> |
2、用sys使用者發起將資料庫設定為靜默狀態的語句,發現這個語句處於等待狀態
ora_test@oracle[/home/oracle]> sqlplus / as sysdba SQL*Plus: Release 10.2.0.1.0 - Production on Wed Mar 10 10:23:13 2010 Copyright (c) 1982, 2005, Oracle. All rights reserved. Connected to: Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production With the Partitioning, OLAP and Data Mining options sys@CNHTM> alter system quiesce restricted; |
3、scott使用者提交事務
這裡提交語句不會返回結果,因為只要語句一執行,資料庫馬上進入了靜默狀態,只有資料庫切換到正常狀態後,這裡才會顯示結果
scott@CNHTM> commit; |
4、二.2步驟sys使用者提交的語句成功,資料庫進入靜默狀態
System altered. sys@CNHTM> |
三、當資料庫處於靜默狀態的時候,非dba使用者的操作(如登入),將處於等待狀態,直到資料庫切換到正常狀態後才能完成
sys@CNHTM> conn scott/tiger |
四、查詢資料庫是否處於靜默狀態的方法
sys@CNHTM> select active_state from v$instance; ACTIVE_ST --------- QUIESCED |
五、將資料庫由非靜默狀態切換到正常狀態,步驟"二.3"和步驟"三"處於等待狀態的操作完成
sys@CNHTM> alter system unquiesce; System altered. |
--end--
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/22049049/viewspace-1031718/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- Oracle資料庫的靜默狀態和掛起狀態Oracle資料庫
- 【RAC】資料庫的靜默狀態(QUIESCE RESTRICTED)對RAC環境的影響資料庫UIREST
- 資料庫的三種狀態RESTRICT、QUIESCE和SUSPEND資料庫RESTUI
- 資料庫共有三種狀態:quiesce、resrict、suspend資料庫UI
- 靜默建立oracle資料庫及克隆資料庫Oracle資料庫
- Oracle資料庫靜默安裝實踐Oracle資料庫
- 靜默安裝Oracle12.2資料庫Oracle資料庫
- 靜默安裝Oracle11g資料庫Oracle資料庫
- oracle資料庫狀態Oracle資料庫
- oracle靜默建庫刪庫Oracle
- dbca silent靜默建立資料庫資料庫
- 在CentOS-6.7上靜默安裝Oracle 11g及靜默建立資料庫CentOSOracle資料庫
- 【oracle】靜默安裝oracle軟體和資料庫之三Oracle資料庫
- 【oracle】靜默安裝oracle軟體和資料庫之二Oracle資料庫
- 【oracle】靜默安裝oracle軟體和資料庫之一Oracle資料庫
- 靜默方式安裝、升級oracle(二): 建立資料庫Oracle資料庫
- oracle 11g資料庫軟體靜默安裝Oracle資料庫
- 資料庫靜默安裝總結資料庫
- oracle資料庫例項狀態Oracle資料庫
- Oracle 12C 單例項資料庫靜默安裝Oracle單例資料庫
- 靜默安裝資料庫介質和建立資料庫資料庫
- 靜默安裝資料庫—dbca.rsp資料庫
- Oracle DG資料庫狀態轉換Oracle資料庫
- 靜默方式安裝、升級oracle(三): 升級資料庫軟體及資料庫Oracle資料庫
- 【配置上線】靜默安裝資料庫Oracle 11gR2資料庫Oracle
- Oracle 11g靜默安裝軟體+手工建立資料庫Oracle資料庫
- Oracle 資料庫的各種狀態和模式Oracle資料庫模式
- 使用靜默方式安裝11g資料庫資料庫
- 資料庫靜態脫敏資料庫
- ORACLE 受限RESTRICT模式,只讀READ ONLY模式,靜默QUIESCE模式,延遲SUSPEND模式解釋OracleREST模式UI
- oracle 11g使用DBCA以非互動(靜默)方式建立資料庫Oracle資料庫
- 【DBCA -SILENT】靜默方式安裝11gR2 oracle資料庫軟體Oracle資料庫
- oracle靜默安裝Oracle
- Oracle 靜默安裝Oracle
- ORACLE 11.2 RAC修改資料庫靜態引數Oracle資料庫
- oracle資料庫執行狀態監控SHELLOracle資料庫
- Oracle資料庫檢視使用者狀態Oracle資料庫
- 11gr2 RAC靜默刪除、建立資料庫資料庫