查看當前歸檔模式
成都創(chuàng)新互聯(lián)企業(yè)建站,10多年網(wǎng)站建設(shè)經(jīng)驗,專注于網(wǎng)站建設(shè)技術(shù),精于網(wǎng)頁設(shè)計,有多年建站和網(wǎng)站代運營經(jīng)驗,設(shè)計師為客戶打造網(wǎng)絡(luò)企業(yè)風格,提供周到的建站售前咨詢和貼心的售后服務(wù)。對于成都網(wǎng)站設(shè)計、成都網(wǎng)站制作、外貿(mào)網(wǎng)站建設(shè)中不同領(lǐng)域進行深入了解和探索,創(chuàng)新互聯(lián)在網(wǎng)站建設(shè)中充分了解客戶行業(yè)的需求,以靈動的思維在網(wǎng)頁中充分展現(xiàn),通過對客戶行業(yè)精準市場調(diào)研,為客戶提供的解決方案。
SQL archive log list;
Database log mode???????????? No Archive Mode
Automatic archival???????????? Disabled
Archive destination??????????? USE_DB_RECOVERY_FILE_DEST
Oldest online log sequence?????
Current log sequence??????????
重啟數(shù)據(jù)庫到mount狀態(tài)
SQL shutdown immediate;
Database closed
Database di *** ounted
ORACLE instance shut down
SQL startup mount;
ORACLE instance started
Total System Global Area?????? bytes
Fixed Size????????????????? bytes
Variable Size???????????????? bytes
Database Buffers????????????? bytes
Redo Buffers?????????????? bytes
Database mounted
開啟歸檔模式
SQL alter database archivelog;
Database altered
打開數(shù)據(jù)庫
SQL alter database open;
Database altered
SQL archive log list;
Database log mode?????????? Archive Mode
Automatic archival?????????? Enabled
Archive destination?????????? USE_DB_RECOVERY_FILE_DEST
Oldest online log sequence????
Next log sequence to archive???
Current log sequence?????????
SQL archive log start;
Statement processed
關(guān)閉歸檔模式的步驟
SQL startup mount;
SQL alter database noarchivelog;
SQL alter database open;
i和 g的區(qū)別
i中需要修改初始化參數(shù)
log_archive_start = true
lishixinzhi/Article/program/Oracle/201311/17367
非歸檔
數(shù)據(jù)能恢復到最后一次備份
只能做全部恢復 不能做部分恢復
只能脫機備份
歸檔
數(shù)據(jù)能恢復到失敗點 無數(shù)據(jù)丟失
可以熱備份
完全恢復和部分恢復都行 部分恢復文件中不一致的檢查點可以用歸檔補齊
默認配置歸檔模式是關(guān)閉的 歸檔空間用滿時可能會影響redo log的正常IO
產(chǎn)生歸檔的條件
數(shù)據(jù)庫必須是歸檔模式
歸檔進程必須啟動
自動啟動 (配置參數(shù))
手工啟動(本次有效 重啟無效)
SQL select log_mode from v$database;
LOG_MODE
NOARCHIVELOG
SQL select archiver from v$instance;
ARCHIVE
STOPPED
SQL archive log list;
Database log mode????????????? No Archive Mode
Automatic archival???????????? Disabled
Archive destination??????????? USE_DB_RECOVERY_FILE_DEST
Oldest online log sequence????
Current log sequence??????????
SQL
由非歸檔改成歸檔
關(guān)閉數(shù)據(jù)庫 除了abort 模式
startup mount
改歸檔模式
alter database archivelog;
alter database open;
SQL shutdown immediate???? 一致性停庫
Database closed
Database di *** ounted
ORACLE instance shut down
編輯此文件
vim /u /app/oracle/product/ /db_ /dbs/initorcl ora
* log_archive_dest_ = location=/u /app/oracle/archive/archive
* log_archive_dest_ = location=/u /app/oracle/archive/archive
* log_archive_dest_ = location=/u /app/oracle/archive/archive
* log_archive_format=arch_log_sunsyk%s_%t_%r arc
SQL startup mount???? mount庫
SQL alter database archivelog;?? 改歸檔模式
SQL alter database open;???? 打開庫
SQL archive log list;??? 查詢庫是否是歸檔
Database log mode????????????? Archive Mode
Automatic archival???????????? Enabled
Archive destination??????????? USE_DB_RECOVERY_FILE_DEST
Oldest online log sequence????
Next log sequence to archive??
Current log sequence??????????
lishixinzhi/Article/program/Oracle/201311/17210
則按下方法修改數(shù)據(jù)庫歸檔模式。
1. 關(guān)閉數(shù)據(jù)庫
SQL shutdown immediate;
2. 啟動數(shù)據(jù)mount狀態(tài):
SQL startup mount;
3. 修改數(shù)據(jù)庫為歸檔模式:
SQL alter database archivelog;
4. 打開數(shù)據(jù)庫:
SQL alter database open;