ORA-00257: archiver error. Connect internal only, until freed——解決

參考http://www.2cto.com/database/201109/104615.html,html

開啓歸檔後,操做一個大表遷移表空間,執行了1個多小時沒完成就手動給中斷了,可是再次用plsql登錄時提示「ORA-00257: archiver error. Connect internal only, until freed」,原來是日誌滿了,根據上述網址提供的步驟操做後就能夠,即刪除部分歸檔日誌。sql

1.首先查看當前flash recovery area使用狀況數據庫

C:\windows\system32>sqlplus sys/fyzh@orcl as sysdbawindows

SQL*Plus: Release 11.2.0.1.0 Production on 星期三 9月 4 18:08:48 2013spa

Copyright (c) 1982, 2010, Oracle.  All rights reserved.日誌

鏈接到:htm

Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Productionget

With the Partitioning, OLAP, Data Mining and Real Application Testing optionsstring

SQL> show parameter log_archive_dest;flash

NAME                                 TYPE        VALUE

------------------------------------ ----------- ------------------------------

log_archive_dest                     string                                         --日誌路徑的value沒有值

log_archive_dest_1                   string

.............................................................省略

log_archive_dest_state_1             string      enable

 ............................................................省略

 

SQL> set linesize 200

SQL> select * from V$FLASH_RECOVERY_AREA_USAGE;

FILE_TYPE            PERCENT_SPACE_USED PERCENT_SPACE_RECLAIMABLE NUMBER_OF_FILES

-------------------- ------------------ ------------------------- ---------------

CONTROL FILE                          0                         0               0

REDO LOG                              0                         0               0

ARCHIVED LOG                      99.98                         0              97    發現已經使用了99.98%

BACKUP PIECE                          0                         0               0

IMAGE COPY                            0                         0               0

FLASHBACK LOG                         0                         0               0

FOREIGN ARCHIVED LOG                  0                         0               0

已選擇7行。

 

2.清除部分日誌

採用rman方式清除日誌

 

C:\windows\system32>rman target sys/fyzh

恢復管理器: Release 11.2.0.1.0 - Production on 星期三 9月 4 18:35:02 2013

Copyright (c) 1982, 2009, Oracle and/or its affiliates.  All rights reserved.

鏈接到目標數據庫: ORCL (DBID=1351232595)

RMAN> crosscheck archivelog all;  --先檢查下

使用目標數據庫控制文件替代恢復目錄

分配的通道: ORA_DISK_1

通道 ORA_DISK_1: SID=68 設備類型=DISK

對歸檔日誌的驗證成功

歸檔日誌文件名=E:\APP\FUYINZHEN\FLASH_RECOVERY_AREA\ORCL\ARCHIVELOG\2013_09_04\O1_MF_1_329_92FRDR8G_.ARC RECID=77 STAMP=825262239

對歸檔日誌的驗證成功

..........................................................

RMAN> delete expired archivelog all; --刪除過時的日誌,本庫沒有過時的

釋放的通道: ORA_DISK_1

分配的通道: ORA_DISK_1

通道 ORA_DISK_1: SID=68 設備類型=DISK

說明與資料檔案庫中的任何歸檔日誌都不匹配

--沒有過時的,爲了騰出空間,就指定到具體的時間將其刪除。

RMAN>delete archivelog until time "to_date('2013-09-04 13:00:00','yyyy-mm-dd hh24:mi:ss')";

 --刪除後在看日誌使用的空間狀況,發現已使用的只有21.73%

SQL> select * from V$FLASH_RECOVERY_AREA_USAGE;

FILE_TYPE            PERCENT_SPACE_USED PERCENT_SPACE_RECLAIMABLE NUMBER_OF_FILES

-------------------- ------------------ ------------------------- ---------------

CONTROL FILE                          0                         0               0

REDO LOG                              0                         0               0

ARCHIVED LOG                      21.73                         0              21

BACKUP PIECE                          0                         0               0

IMAGE COPY                            0                         0               0

FLASHBACK LOG                         0                         0               0

FOREIGN ARCHIVED LOG                  0                         0               0

已選擇7行。

相關文章
相關標籤/搜索