在alter tablespace_datafile begin backup_offline_oracle block之fileq和ckptq變化
/*********確認下block fileq與tablespace or datafile offline或alter tablespace backup begin的關係***********/
/******************************insert into t_cr且commit一條記錄*********************************************/
BH (0x000007FF40FF2CC8) file#: 5 rdba: 0x0140bc5d (5/48221) class: 1 ba: 0x000007FF40ED4000
set: 3 pool 3 bsz: 8192 bsi: 0 sflg: 2 pwc: 990,28
dbwrid: 0 obj: 72974 objn: 72974 tsn: 5 afn: 5 hint: f
hash: [0x000007FF40FF3A88,0x000007FF606A7528] lru: [0x000007FF40FF2EE0,0x000007FF40FF2C80]
obj-flags: object_ckpt_list
-----------fileq即為檔案檢查點,用於alter tablespace or datafile begin backup and offline and online
ckptq: [0x000007FF40FF2A68,0x000007FF40FF2F28] fileq: [0x000007FF40FF2A78,0x000007FF40FF2F38] objq: [0x000007FF40FF2F08,0x000007FF40FF2CA8]
st: XCURRENT md: NULL tch: 3
flags: buffer_dirty redo_since_read
LRBA: [0xc2.8507.0] LSCN: [0x0.5b4935] HSCN: [0x0.5b4937] HSUB: [1]
cr pin refcnt: 0 sh pin refcnt: 0
/**********表空間熱備**************/
SQL> alter tablespace tbl_bck begin backup;
Tablespace altered
/**********表空間熱備開始的block dump**********/
BH (0x000007FF40FF2CC8) file#: 5 rdba: 0x0140bc5d (5/48221) class: 1 ba: 0x000007FF40ED4000
set: 3 pool 3 bsz: 8192 bsi: 0 sflg: 2 pwc: 985,28
dbwrid: 0 obj: 72974 objn: 72974 tsn: 5 afn: 5 hint: f
hash: [0x000007FF40FF3A88,0x000007FF606A7528] lru: [0x000007FF40FF2EE0,0x000007FF40FF2C80]
--表空間熱備模式,fileq檔案檢查點為空
ckptq: [NULL] fileq: [NULL] objq: [0x000007FF40FF2F08,0x000007FF40FF2CA8]
st: XCURRENT md: NULL tch: 3
flags: block_written_once redo_since_read
--表空間熱備模式 lrba也為空
LRBA: [0x0.0.0] LSCN: [0x0.0] HSCN: [0xffff.ffffffff] HSUB: [1]
cr pin refcnt: 0 sh pin refcnt: 0
/***********表空間熱備劃式開始後進行了dml事務的block dump*************/
BH (0x000007FF40FEF758) file#: 5 rdba: 0x0140bc5d (5/48221) class: 1 ba: 0x000007FF40E7A000
set: 3 pool 3 bsz: 8192 bsi: 0 sflg: 2 pwc: 985,28
dbwrid: 0 obj: 72974 objn: 72974 tsn: 5 afn: 5 hint: f
hash: [0x000007FF40FF2D78,0x000007FF606A7528] lru: [0x000007FF40FEF970,0x000007FF607C46F0]
obj-flags: object_ckpt_list
----表空間熱備模式下fileq佇列又有值了
ckptq: [0x000007FF607C7B48,0x000007FF47FCF9E8] fileq: [0x000007FF607C7BE8,0x000007FF607C7BE8] objq: [0x000007FF5C2A33A0,0x000007FF5C2A33A0]
st: XCURRENT md: NULL tch: 1
flags: buffer_dirty block_written_once redo_since_read
LRBA: [0xc2.8ed3.0] LSCN: [0x0.5b4bf7] HSCN: [0x0.5b4bfa] HSUB: [1]
cr pin refcnt: 0 sh pin refcnt: 0
/*********結束表空間熱備模式的block dump********/
BH (0x000007FF40FEF758) file#: 5 rdba: 0x0140bc5d (5/48221) class: 1 ba: 0x000007FF40E7A000
set: 3 pool 3 bsz: 8192 bsi: 0 sflg: 2 pwc: 985,28
dbwrid: 0 obj: 72974 objn: 72974 tsn: 5 afn: 5 hint: f
hash: [0x000007FF40FF2D78,0x000007FF606A7528] lru: [0x000007FF40FEF970,0x000007FF41F9EC40]
obj-flags: object_ckpt_list
ckptq: [0x000007FF47FD1B28,0x000007FF47FCF9E8] fileq: [0x000007FF607C7BE8,0x000007FF607C7BE8] objq: [0x000007FF5C2A33A0,0x000007FF5C2A33A0]
st: XCURRENT md: NULL tch: 1
flags: buffer_dirty block_written_once redo_since_read
LRBA: [0xc2.8ed3.0] LSCN: [0x0.5b4bf7] HSCN: [0x0.5b4bfa] HSUB: [1]
cr pin refcnt: 0 sh pin refcnt: 0
小結:1,alter tablespace begin|end backup開始fileq為空,下來和非熱備模式一樣fileq
2,這個也說明alter tablespace begin backup會發生檢查點把檢查點及檔案佇列的髒資料寫入到資料檔案中
3,所以ckptq及fileq才會一開始為空
/************表空間離線開始************/
SQL> alter tablespace TBL_BCK offline;
Tablespace altered
BH (0x000007FF40FEF758) file#: 5 rdba: 0x0140bc5d (5/48221) class: 1 ba: 0x000007FF40E7A000
set: 3 pool 3 bsz: 8192 bsi: 0 sflg: 2 pwc: 985,28
dbwrid: 0 obj: 72974 objn: 72974 tsn: 5 afn: 5 hint: f
hash: [0x000007FF40FF2D78,0x000007FF606A7528] lru: [0x000007FF40FEF970,0x000007FF41F9EC40]
ckptq: [NULL] fileq: [NULL] objq: [0x000007FF40FF2B78,0x000007FF5C2A3390]
st: XCURRENT md: NULL tch: 1
flags: block_written_once redo_since_read
LRBA: [0x0.0.0] LSCN: [0x0.0] HSCN: [0xffff.ffffffff] HSUB: [1]
cr pin refcnt: 0 sh pin refcnt: 0
/**************表空間離線結束**********************/
BH (0x000007FF40FEF758) file#: 5 rdba: 0x0140bc5d (5/48221) class: 1 ba: 0x000007FF40E7A000
set: 3 pool 3 bsz: 8192 bsi: 0 sflg: 2 pwc: 984,12
dbwrid: 0 obj: 72974 objn: 72974 tsn: 5 afn: 5 hint: f
hash: [0x000007FF40FF2D78,0x000007FF606A7528] lru: [0x000007FF40FF2DB0,0x000007FF41FA86A0]
lru-flags: moved_to_tail on_auxiliary_list
ckptq: [NULL] fileq: [NULL] objq: [NULL]
st: FREE md: NULL tch: 0 lfb: 6
flags:
cr pin refcnt: 0 sh pin refcnt: 0
小結:1,表空間離線和表空間熱備一樣,離線發生馬上把ckptq及fileq寫入到資料檔案
/*************資料檔案離線**********************/
SQL> alter database datafile 5 offline;
Database altered
BH (0x000007FF42F8A4C8) file#: 5 rdba: 0x0140bc5d (5/48221) class: 1 ba: 0x000007FF423D4000
set: 3 pool 3 bsz: 8192 bsi: 0 sflg: 2 pwc: 984,12
dbwrid: 0 obj: 72974 objn: 72974 tsn: 5 afn: 5 hint: f
hash: [0x000007FF41FBFB48,0x000007FF606A7528] lru: [0x000007FF41FABC10,0x000007FF607C46F0]
ckptq: [NULL] fileq: [NULL] objq: [0x000007FF42FB0A98,0x000007FF41F956C8]
use: [NULL] wait: [NULL]
st: XCURRENT md: NULL tch: 2 txn: 0x7ff5ed05358
flags: private
LRBA: [0x0.0.0] LSCN: [0x0.0] HSCN: [0xffff.ffffffff] HSUB: [65535]
cr pin refcnt: 0 sh pin refcnt: 0
小結:資料檔案離線同上,發生ckptq及fileq
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/9240380/viewspace-758898/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- oracle block資料塊結構續(二)之dml_ckptq_fileq_objqOracleBloCOBJ
- Oracle備份與恢復系列(三)alter tablspace begin backupOracle
- Oracle OCP 1Z0 053 Q559(Alter Database Begin Backup)OracleDatabase
- for (auto it = _list.begin(); it != _list.end(); )關於在for迴圈中使用std::vector中的begin和end
- alter database和alter system和alter session的區別DatabaseSession
- 深入研究Block捕獲外部變數和__block實現原理BloC變數
- block沒那麼難(二):block和變數的記憶體管理BloC變數記憶體
- alter session force parallel query與執行計劃變化SessionParallel
- Block學習②--block的變數捕獲BloC變數
- begin plsqlSQL
- Block學習⑤--block對物件變數的捕獲BloC物件變數
- 在PL/SQL中存在v$,alter sytem之類的命令。SQL
- Oracle效能最佳化之提升block的效率(轉)OracleBloC
- 深入理解Block之Block的型別BloC型別
- ios之Block研究iOSBloC
- alter table move 和 alter table shrink space的區別
- alter system archive log current和alter system switch logfileHive
- 【MySQL】MySQL效能優化之Block Nested-Loop Join(BNL)MySql優化BloCOOP
- Block自動截獲變數BloC變數
- iOS - block變數捕獲原理iOSBloC變數
- 忍不住問下alter system 和alter database的區別Database
- Unused Block Compression和Null Block CompressionBloCNull
- Block深入學習,授人以漁。—— Block與各種變數BloC變數
- 開心檔之MySQL ALTER命令MySql
- 【MySQL】MySQL效能最佳化之Block Nested-Loop Join(BNL)MySqlBloCOOP
- NVIDIA CUDA 程式設計模型之Grid和Block程式設計模型BloC
- 表使用的資料塊在事務未提交及提交且強制重新整理緩衝池的block scn及obj變化之系列一BloCOBJ
- position:absolute和float隱式改變display為inline-blockinlineBloC
- 透過Buffer cache瞭解data block在DML操作下的狀態演變BloC
- iOS之輕鬆上手blockiOSBloC
- alter system switch logfile和alter system archive log current的區別Hive
- alter system switch logfile 和 alter system archive log current 的區別Hive
- 淺談 block(2) – 截獲變數方式BloC變數
- block 對外部引用變數的處理BloC變數
- begin use english in my daily lifeAI
- [轉]alter system switch logfile和alter system archive log current的區別Hive
- MySQL優化之系統變數優化MySql優化變數
- v$lock之alter table drop column與alter table set unused column區別系列五