说明归档日志已满,需要删除一些文件,连接到数据库,
ORA-19809: limit exceeded for recovery files
Cause: The limit for recovery files specified by the DB_RECOVERY_FILE_DEST_SIZE was exceeded.
Action: The error is accompanied by 19804. See message 19804 for further details.
ORA-19804: cannot reclaim string bytes disk space from string limit
Cause: Oracle cannot reclaim disk space of specified bytes from the DB_RECOVERY_FILE_DEST_SIZE limit.
Action: There are five possible solutions:
1) Take frequent backup of recovery area using RMAN.
2) Consider changing RMAN retention policy.
3) Consider changing RMAN archivelog deletion policy.
4) Add disk space and increase DB_RECOVERY_FILE_DEST_SIZE.
5) Delete files from recovery area using RMAN.
SQL> archive log list;
SQL> select * from v$recovery_file_dest;
解决方法:删除多余的归档文件。然后设置较大的db_recovery_file_dest_size。
删除多余的归档文件
打开RMAN
rman target /
RMAN>crosscheck archivelog all; -- 运行这个命令可以把无效的expired的archivelog标出来。
RMAN>delete expired archivelog all; -- 直接全部删除过期的归档日志。
RMAN>delete noprompt archivelog until time "sysdate -3"; -- 也可以直接用一个指定的日期来删除。
重新打开数据库:
SQL> alter database open;
Database altered.
action
指定retention的策略,使得archivelog不至于这样增加
RMAN>configure retention policy to recovery window of 7 days;
RMAN>configure retention policy to redundancy 3;
SQL>alter system db_recovery_file_dest_size=4G scope=both;
把archivelog_dest指定到没有限制的地方
当归档日志数量大于2G时,那么就会由于没有更多的空间去容纳更多的归档日志会报无法继续归档的错误。
如:“RA-19809: limit exceeded for recovery files
ORA-19804: cannot reclaim 10017792 bytes disk space from 2147483648 limit
ARC0: Error 19809 Creating archive log file to
'/u01/app/oracle/flash_recovery_area/ORCL/archivelog/2007_04_30/o1_mf_1_220_0_.arc'
”这时我们可以修改它的默认限制,也可以将归档路径重新置到别的路径,就不会有这个限制了。
更改限制语句如下:
alter system set db_recovery_file_dest_size=10737418240