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

来源:互联网 发布:淘宝支付宝怎么开通 编辑:程序博客网 时间:2024/06/16 19:39
ORA-00257: archiver error. Connect internal only, until freed

登录oracle显示上面的错误

以下是公司大师给出的步骤,谨记录备用:
1、手工删除归档日志的文件夹(按日期那种)
2、在oracle用户下以rman target /
3、crosscheck archivelog all;
4、delete expired archivelog all;--这里删除了一些与第1步中删除的文件日期匹配的文件,目前研究还不深入,不清楚它们之间具体的联系
5、exit;

--如果发现归档日志的空间快使用完了,而没有出现00257的错误,只做到这一步就够了,不用再进行下面的步骤了
--查询归档日志使用的sql:select * from v$flash_recovery_area_usage;

6、接下来是在sqlplus中的操作:
Oracle sqlplus代码
SQL> conn / as sysdba   
  1. Connected.   
  2. SQL> shutdown immediate   
  3. ORA-01013: user requested cancel of current operation   
  4. //一直停不掉,就ctl+c中断了   
  5.   
  6. //再试一次   
  7. SQL> shutdown immediate   
  8. ORA-01013: user requested cancel of current operation   
  9. //还是停不掉,再次ctl+c中断   
  10.   
  11. //强行停止吧   
  12. SQL> shutdown abort   
  13. ORACLE instance shut down.   
  14.   
  15. //再次启动   
  16. SQL> startup                                             
  17. ORACLE instance started.   
  18.   
  19. Total System Global Area 1610612736 bytes   
  20. Fixed Size                  1267740 bytes   
  21. Variable Size             452986852 bytes   
  22. Database Buffers         1140850688 bytes   
  23. Redo Buffers               15507456 bytes   
  24. Database mounted.   
  25. ORA-16014: log 2 sequence# 101 not archived, no available destinations   
  26. ORA-00312: online log 2 thread 1'/oracle/oradata/orcl/redo02.log'  
  27. ORA-00312: online log 2 thread 1:   
  28. '/backup/oracle_archive/redo_data/redo2/redo021.log'  
  29. //数据库没有打开,报上面的错误   
  30.   
  31. SQL> show parameter db_recovery_file_dest_size;   
  32.   
  33. NAME                                 TYPE        VALUE   
  34. ------------------------------------ ----------- ------------------------------   
  35. db_recovery_file_dest_size           big integer 4G   
  36. SQL> select group#,sequence#,archived,status from v$log;   
  37.   
  38.     GROUP#  SEQUENCE# ARC STATUS   
  39. ---------- ---------- --- ----------------   
  40.          1        103 NO  CURRENT   
  41.          3        102 NO  INACTIVE   
  42.          2        101 NO  INACTIVE   
  43.   
  44. //搞一搞SEQUENCE号最小的一个   
  45. SQL> alter database clear logfile group 2;   
  46. alter database clear logfile group 2  
  47. *   
  48. ERROR at line 1:   
  49. ORA-00350: log 2 of instance orcl (thread 1) needs to be archived   
  50. ORA-00312: online log 2 thread 1'/oracle/oradata/orcl/redo02.log'  
  51. ORA-00312: online log 2 thread 1:   
  52. '/backup/oracle_archive/redo_data/redo2/redo021.log'  
  53.   
  54. SQL> alter database clear unarchived logfile group 2;   
  55.   
  56. Database altered.   
  57.   
  58. SQL> alter database open;   
  59.   
  60. Database altered.  

以上是网上搜索到的答案。重启服务后系统运行正常,真正原因还等待公司DBA的分析。