ITPub博客

首页 > Linux操作系统 > Linux操作系统 > oracle 10g 归档日志清除

oracle 10g 归档日志清除

原创 Linux操作系统 作者:oracle_ace 时间:2009-11-20 16:30:53 0 删除 编辑
正常情况下应该在rman下删除archivelog

rman>delete archivelog all;

 

以下为手动删除archivelog物理文件后要进行的操作

1, 手工清除后,数据库中还会存有记录:
select * from v$flash_recovery_area_usage;

2, 然后:
rman target /
crosscheck archivelog all;
delete expired archivelog all;

说明:2是修复1的办法

 

用rman

run {
    allocate channel ch1 type disk format '/目录/a_log_%d_%p_%c_%s';
    backup archivelog all       # Backs up all archived redo logs.
   delete input;             # Optionally, delete the input logs
    release channel ch1;
}

========================================================

list backup of archivelog all;

 

restore archivelog all;

restore archivelog sequence seqnumber;

===归档当前日志============

 

alter system archive log current;

===============================================================

ORA-32004: obsolete and/or deprecated parameter(s) specified

ALTER SYSTEM RESET log_archive_start SCOPE=SPFILE SID='*';

===============================================================

===数据库启用归档模式=====================

SQL> startup mount;

SQL> alter database archivelog;

SQL> alter system set log_archive_dest_1='E:\ORACLE\ora92\database\archive' scope=both;

SQL> alter system set log_archive_dest_2='service=standby' scope=both;

SQL> alter system set log_archive_start=true scope=spfile;

SQL> alter database open;

SQL> archive log list;

=============================================================================
 

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

请登录后发表评论 登录
全部评论

注册时间:2007-12-10

  • 博文量
    284
  • 访问量
    791635