[20171208]强制删除归档日志文件.txt

[20171208]强制删除归档日志文件.txt

--//测试环境,产生日志太多,想强制删除.

RMAN> delete archivelog all ;

released channel: ORA_DISK_1
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=106 device type=DISK
RMAN-08137: WARNING: archived log not deleted, needed for standby or upstream capture process
archived log file name=/u01/app/oracle/archivelog/book/1_790_896605872.dbf thread=1 sequence=790
RMAN-08137: WARNING: archived log not deleted, needed for standby or upstream capture process
archived log file name=/u01/app/oracle/archivelog/book/1_791_896605872.dbf thread=1 sequence=791
RMAN-08137: WARNING: archived log not deleted, needed for standby or upstream capture process

--//提示:RMAN-08137: WARNING: archived log not deleted, needed for standby or upstream capture process

$ oerr rman 08137
8137, 3, "WARNING: archived log not deleted, needed for standby or upstream capture process"
// *Cause: An archived log that should have been deleted was not as it was
//         required by upstream capture process or Data Guard.
//         The next message identifies the archived log.
// *Action: This is an informational message. The archived log can be
//          deleted after it is no longer needed.  See the
//          documentation for Data Guard to alter the set of active
//          Data Guard destinations.  See the documentation for
//          Streams to alter the set of active streams.


--//dataguard 备库已经停用很久了.要强制删除归档日志:

RMAN> delete archivelog all force ;

RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-00558: error encountered while parsing input commands
RMAN-01009: syntax error: found "force": expecting one of: "backed, completed, device, for, like, tag, ;"
RMAN-01007: at line 2 column 23 file: standard input

RMAN> delete
2>
3>

RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-00558: error encountered while parsing input commands
RMAN-01009: syntax error: found "end-of-file": expecting one of: "archivelog, backuppiece, backupset, backup, controlfilecopy, copy, datafilecopy, expired, force, foreign, global, noprompt, obsolete, proxy, script"
RMAN-01007: at line 3 column 1 file: standard input

--//提示看force要写前面...

RMAN> delete force archivelog all;

released channel: ORA_DISK_1
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=106 device type=DISK
List of Archived Log Copies for database with db_unique_name BOOK
=====================================================================

Key     Thrd Seq     S Low Time
------- ---- ------- - -------------------
1330    1    790     A 2017-11-13 09:48:53
        Name: /u01/app/oracle/archivelog/book/1_790_896605872.dbf

...
1497    1    957     A 2017-12-07 13:44:31
        Name: /u01/app/oracle/archivelog/book/1_957_896605872.dbf

Do you really want to delete the above objects (enter YES or NO)? YES

--//我经常习惯性写后面.做一个笔记.

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/267265/viewspace-2148449/,如需转载,请注明出处,否则将追究法律责任。

转载于:http://blog.itpub.net/267265/viewspace-2148449/

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值