[20181225]如何清除註冊的線上日誌.txt
[20181225]如何清除註冊的線上日誌.txt
--//連結http://www.itpub.net/thread-2107381-1-1.html的討論,lz可能使用rman的catalog註冊了線上日誌當作歸檔日誌.
--//我大概演示這個過程,也許作者不是這樣操作的.
1.環境:
SYS@book> @ ver1
PORT_STRING VERSION BANNER
------------------------------ -------------- --------------------------------------------------------------------------------
x86_64/Linux 2.4.xx 11.2.0.4.0 Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production
SYS@book> archive log list
Database log mode Archive Mode
Automatic archival Enabled
Archive destination /u01/app/oracle/archivelog/book/
Oldest online log sequence 703
Next log sequence to archive 705
Current log sequence 705
SELECT RECID
,NAME
,DEST_ID
,THREAD#
,SEQUENCE#
,CREATOR
,REGISTRAR
FROM v$archived_log a
WHERE a.name IS NOT NULL AND sequence# >= 703;
RECID NAME DEST_ID THREAD# SEQUENCE# CREATOR REGISTR
---------- ------------------------------------------------------------ ---------- ---------- ---------- ------- -------
1249 /u01/app/oracle/archivelog/book/1_703_896605872.dbf 1 1 703 ARCH ARCH
1250 /u01/app/oracle/archivelog/book/1_704_896605872.dbf 1 1 704 ARCH ARCH
--//當前並沒有線上日誌檔案在檢視v$archived_log中.
2.使用rman註冊:
RMAN> catalog archivelog '/mnt/ramdisk/book/redo01.log' ;
cataloged archived log
archived log file name=/mnt/ramdisk/book/redo01.log RECID=1251 STAMP=995797230
SELECT RECID
,NAME
,DEST_ID
,THREAD#
,SEQUENCE#
,CREATOR
,REGISTRAR
FROM v$archived_log a
WHERE a.name IS NOT NULL AND sequence# >= 703;
RECID NAME DEST_ID THREAD# SEQUENCE# CREATOR REGISTR
---------- ------------------------------------------------------------ ---------- ---------- ---------- ------- -------
1249 /u01/app/oracle/archivelog/book/1_703_896605872.dbf 1 1 703 ARCH ARCH
1250 /u01/app/oracle/archivelog/book/1_704_896605872.dbf 1 1 704 ARCH ARCH
1251 /mnt/ramdisk/book/redo01.log 1 1 704 RMAN RMAN
--//你可以發現線上日誌檔案註冊為歸檔,但是提示CREATOR=rman.如何取消很簡單執行:
--//參考連結:http://blog.itpub.net/267265/viewspace-748366/
3.如何取消.
SYS@book> execute dbms_backup_restore.resetcfilesection(11);
PL/SQL procedure successfully completed.
SELECT RECID
,NAME
,DEST_ID
,THREAD#
,SEQUENCE#
,CREATOR
,REGISTRAR
FROM v$archived_log a
WHERE a.name IS NOT NULL AND sequence# >= 703;
no rows selected
--//再重新註冊回去歸檔檔案.
RMAN> catalog start with '/u01/app/oracle/archivelog/book/';
searching for all files that match the pattern /u01/app/oracle/archivelog/book/
List of Files Unknown to the Database
=====================================
File Name: /u01/app/oracle/archivelog/book/1_696_896605872.dbf
File Name: /u01/app/oracle/archivelog/book/1_698_896605872.dbf
File Name: /u01/app/oracle/archivelog/book/1_704_896605872.dbf
File Name: /u01/app/oracle/archivelog/book/1_703_896605872.dbf
File Name: /u01/app/oracle/archivelog/book/1_695_896605872.dbf
File Name: /u01/app/oracle/archivelog/book/1_701_896605872.dbf
File Name: /u01/app/oracle/archivelog/book/1_697_896605872.dbf
File Name: /u01/app/oracle/archivelog/book/1_700_896605872.dbf
File Name: /u01/app/oracle/archivelog/book/1_699_896605872.dbf
File Name: /u01/app/oracle/archivelog/book/1_702_896605872.dbf
Do you really want to catalog the above files (enter YES or NO)? yes
cataloging files...
cataloging done
List of Cataloged Files
=======================
File Name: /u01/app/oracle/archivelog/book/1_696_896605872.dbf
File Name: /u01/app/oracle/archivelog/book/1_698_896605872.dbf
File Name: /u01/app/oracle/archivelog/book/1_704_896605872.dbf
File Name: /u01/app/oracle/archivelog/book/1_703_896605872.dbf
File Name: /u01/app/oracle/archivelog/book/1_695_896605872.dbf
File Name: /u01/app/oracle/archivelog/book/1_701_896605872.dbf
File Name: /u01/app/oracle/archivelog/book/1_697_896605872.dbf
File Name: /u01/app/oracle/archivelog/book/1_700_896605872.dbf
File Name: /u01/app/oracle/archivelog/book/1_699_896605872.dbf
File Name: /u01/app/oracle/archivelog/book/1_702_896605872.dbf
SELECT RECID
,NAME
,DEST_ID
,THREAD#
,SEQUENCE#
,CREATOR
,REGISTRAR
FROM v$archived_log a
WHERE a.name IS NOT NULL AND sequence# >= 703;
RECID NAME DEST_ID THREAD# SEQUENCE# CREATOR REGISTR
---------- ------------------------------------------------------------ ---------- ---------- ---------- ------- -------
3 /u01/app/oracle/archivelog/book/1_704_896605872.dbf 1 1 704 RMAN RMAN
4 /u01/app/oracle/archivelog/book/1_703_896605872.dbf 1 1 703 RMAN RMAN
--//現在取消了線上日誌檔案的註冊.不知道還有什麼方法,理論rman應該可以做到,如何做,給測試看看.
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/267265/viewspace-2286296/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- RAC 線上日誌的管理
- 批量註冊歸檔日誌
- Oracle 線上日誌管理Oracle
- 線上日誌損壞
- 如何更改註冊的emailAI
- DrawPad 離線註冊
- [20170303]dg環境下線上日誌損壞8.txt
- [20170309]關於線上日誌與歸檔1.txt
- [20170309]關於線上日誌與歸檔2.txt
- [20170310]關於線上日誌與歸檔3.txt
- [20170310]關於線上日誌與歸檔4.txt
- 非線上日誌丟失
- [20170307]dg環境下線上日誌損壞12.txt
- [20170309]dg環境下線上日誌損壞13.txt
- [20170310]dg環境下線上日誌損壞14.txt
- [20170301]dg環境下線上日誌損壞5.txt
- 如何註冊 ChatGPT ,OpenAIChatGPTOpenAI
- EmEditor 24.4.1 離線註冊分析
- 如何註冊ocx檔案
- [20181225]12CR2 SQL Plan Directives.txtSQL
- DATAGUARD手工註冊歸檔日誌(轉載)
- [20211105]索引分裂 塊清除 日誌增加.txt索引
- [20160830]清除日誌與跟蹤檔案.txt
- [20170518]11G審計日誌清除3.txt
- [20170207]11G審計日誌清除.txt
- 清除SqlServer日誌SQLServer
- windows10系統如何清除事件日誌Windows事件
- win10如何解除dll註冊_win10取消註冊dll的方法Win10
- 如何註冊蘋果開發者賬戶?蘋果
- 微信小程式從註冊到上線系列微信小程式
- 註冊中心 Eureka 原始碼解析 —— 應用例項註冊發現(三)之下線原始碼
- ffmpeg分析系列之一(註冊該註冊的)
- oracle的靜態註冊和動態註冊Oracle
- 微服務下的註冊中心如何選擇微服務
- 06【線上日誌分析】之KafkaOffsetMonitor監控工具的搭建Kafka
- oracle 線上日誌全部丟失的資料恢復Oracle資料恢復
- 【REDO】Oracle 日誌挖掘,分析歸檔日誌線上日誌主要步驟Oracle
- 亞馬遜EC2如何註冊使用亞馬遜