闪回恢复区大小不够报ORA-19809、ORA-19804错误

RMAN> backup database;

Starting backup at 01-July-19

using target database control file instead of recovery catalog

allocated channel: ORA_DISK_1

channel ORA_DISK_1: SID=39 device type=DISK

channel ORA_DISK_1: starting full datafile backup set

channel ORA_DISK_1: specifying datafile(s) in backup set

input datafile file number=00006 name=/home/oracle/app/oradata/orcl/ogg01.dbf

input datafile file number=00001 name=/home/oracle/app/oradata/orcl/system01.dbf

input datafile file number=00002 name=/home/oracle/app/oradata/orcl/sysaux01.dbf

input datafile file number=00005 name=/home/oracle/app/oradata/orcl/tbtb01.dbf

input datafile file number=00003 name=/home/oracle/app/oradata/orcl/undotbs01.dbf

input datafile file number=00004 name=/home/oracle/app/oradata/orcl/users01.dbf

channel ORA_DISK_1: starting piece 1 at 01-July-19

RMAN-03009: failure of backup command on ORA_DISK_1 channel at 07/01/2019 06:43:49

ORA-19809: limit exceeded for recovery files

ORA-19804: cannot reclaim 52428800 bytes disk space from 2147483648 limit

continuing other job steps, job failed will not be re-run

channel ORA_DISK_1: starting full datafile backup set

channel ORA_DISK_1: specifying datafile(s) in backup set

including current control file in backup set

including current SPFILE in backup set

channel ORA_DISK_1: starting piece 1 at 01-July-19

channel ORA_DISK_1: finished piece 1 at 01-July-19

piece handle=/home/oracle/app/flash_recovery_area/ORCL/backupset/2019_07_01/o1_mf_ncsnf_TAG20141201T064122_b7ro3pt5_.bkp tag=TAG20141201T064122 comment=NONE

channel ORA_DISK_1: backup set complete, elapsed time: 00:00:02

RMAN-00571: ===========================================================

RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============

RMAN-00571: ===========================================================

RMAN-03009: failure of backup command on ORA_DISK_1 channel at 07/01/2019 06:43:49

ORA-19809: limit exceeded for recovery files

ORA-19804: cannot reclaim 52428800 bytes disk space from 2147483648 limit

原因:闪回恢复区大小不够

oracle10g,11g在默认情况下,归档日志是保存在闪回恢复区的,如果你建库的时候用的默认设置,

闪回恢复区应该是2G,空间不够,没办备份。(同理归档日志保存也可能碰到这个问题,导致无法再归档)

解决:

(1)调整添加闪回区大小

(2)将备份的目录换成其他路径。

如果是归档报错,即将归档目录设置到其他目录,修改alter system set log_archive_dest = 其他路径

步骤:

1、查看db_recovery_file_dest 大小

SQL> show parameter recover

NAME TYPE VALUE

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

db_recovery_file_dest string/home/oracle/app/flash_recover

y_area

db_recovery_file_dest_size big integer 2G

recovery_parallelism integer0

2、 查看闪回恢复区使用情况

SQL> select file_type, percent_space_used as used,percent_space_reclaimable as reclaimable, number_of_files as "number" from v$flash_recovery_area_usage;

FILE_TYPE USED RECLAIMABLE number

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

CONTROL FILE 0 0 0

REDO LOG 0 0 0

ARCHIVED LOG 46.76 0 23

BACKUP PIECE .46 0 1

IMAGE COPY 0 0 0

FLASHBACK LOG 0 0 0

3、 扩展db_recovery_file_dest 大小

SQL> alter system set db_recovery_file_dest_size=10G scope=both;

System altered.

4、利用run批脚本指定备份路径来备份 (建议归档与备份分开放置)

run{

allocate channel ch1 type disk;

allocate channel ch2 type disk;

backup incremental level 0 database plus archivelog delete input

format '/home/oracle/rmanbak/db_%d_%U'

tag=db_inc_0;

release channel ch1;

release channel ch2;

}

allocated channel: ch1

。。。。。。

released channel: ch1

released channel: ch2

转载于:https://my.oschina.net/u/3635497/blog/3082255

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
这个错误一般是由于 undo 表空间损坏或不存在导致的。 首先,你可以检查一下数据库中是否存在该 undo 表空间,可以通过执行以下 SQL 语句进行检查: ``` SELECT tablespace_name FROM dba_tablespaces WHERE tablespace_name='<undo_tablespace_name>'; ``` 其中 `<undo_tablespace_name>` 应该替换成你要检查的 undo 表空间的名称。 如果查询结果为空,说明该表空间不存在,你需要创建一个新的 undo 表空间。如果查询结果不为空,则需要进一步检查该 undo 表空间是否正常。 你可以执行以下 SQL 语句检查 undo 表空间是否正常: ``` SELECT status FROM v$rollstat WHERE segment_name='<undo_tablespace_name>'; ``` 其中 `<undo_tablespace_name>` 应该替换成你要检查的 undo 表空间的名称。 如果查询结果为 `ONLINE`,则说明该 undo 表空间正常。如果查询结果为 `OFFLINE` 或者其他异常状态,则说明该 undo 表空间存在问题,需要进行修复或者重建。 如果你需要创建一个新的 undo 表空间,可以执行以下 SQL 语句: ``` CREATE UNDO TABLESPACE <undo_tablespace_name> DATAFILE '<path_to_undo_datafile>' SIZE <size_in_MB>; ``` 其中 `<undo_tablespace_name>` 是你要创建的 undo 表空间名称,`<path_to_undo_datafile>` 是你要指定的 undo 数据文件路径,`<size_in_MB>` 是你要指定的 undo 表空间大小,单位为 MB。 如果你需要修复一个存在问题的 undo 表空间,可以参考以下步骤: 1. 首先备份该 undo 表空间对应的数据文件,以防止数据丢失。 2. 尝试在线修复该 undo 表空间,你可以执行以下 SQL 语句: ``` ALTER TABLESPACE <undo_tablespace_name> BEGIN BACKUP; ALTER TABLESPACE <undo_tablespace_name> END BACKUP; ``` 这两条 SQL 语句可以将该 undo 表空间置于备份模式,然后再退出备份模式。如果该 undo 表空间存在一些逻辑损坏,这两条 SQL 语句可能会修复这些问题。 3. 如果在线修复失败,你可以尝试离线修复该 undo 表空间,你可以执行以下 SQL 语句: ``` ALTER DATABASE DATAFILE '<path_to_undo_datafile>' OFFLINE; RECOVER DATAFILE '<path_to_undo_datafile>'; ALTER DATABASE DATAFILE '<path_to_undo_datafile>' ONLINE; ``` 这三条 SQL 语句可以将该 undo 数据文件置为离线状态,然后进行数据文件恢复,最后再将该数据文件置为在线状态。 4. 如果无法修复该 undo 表空间,你可以考虑重建该 undo 表空间,你可以执行以下 SQL 语句: ``` DROP TABLESPACE <undo_tablespace_name> INCLUDING CONTENTS AND DATAFILES; CREATE UNDO TABLESPACE <undo_tablespace_name> DATAFILE '<path_to_undo_datafile>' SIZE <size_in_MB>; ``` 这两条 SQL 语句可以先删除存在问题的 undo 表空间,然后重新创建一个新的 undo 表空间。请注意,这个操作会删除该 undo 表空间中的所有数据,所以请务必提前备份数据。

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值