ORA-00257: archiver error. Connect internal only,

作者:网络 来源:佚名 更新时间:2008-02-09 10:07:54 点击:

conn scott/[email protected]
i number;
select s.nextval into i from dual;
while i<1000
insert into b values (i);
end loop;
sql> conn scott/[email protected]
sql> select sid,serial#,username from v$session;

      sid   serial# username
--------- --------- ------------------------------
        1         1
        2         1
        3         1
        4         1
        5         1
        6         1
        7         1
        8         1
        9         1
       10         1
       11         1
       12        14
       13         5 scott
       14        15 scott
       15         4
       16         1
       17         1
       18         1
       19         1
       20         4 nccwgs


已用时间:  00: 00: 00.01
sql> alter system kill session '13,5';


已用时间:  00: 00: 00.00

sql> conn scott/[email protected]
ora-00257: archiver error. connect internal only, until freed.


二、problem description ------------------- 

the database is running in archive log mode with automatic archiving turned on. when the archive log destination diskspace becomes full the automatic archiving will stop.  this is expected to happen.  at this point a message should appear  on the screen:  oracle instance v816 - can not allocate log, archival required  when all of the online redo logs are filled up, the database will be in a hang  state.  after freeing up diskspace the online redo logs are still not archiving.  in  most cases this is the correct behaviour. 

if you attempt to manually archive the files you may receive the following errors: 

svrmgr> archive log next ora-16014: log 1 sequence# 199 not archived, no available destinations ora-00312: online log 1 thread 1: 'c:oracleoradatav816redo01.log' 

svrmgr> archive log all ora-16020: less destinations available than specified by log_archive_min_succeed_dest  

solution description -------------------- 

some of the possible ways to fix this problem: 

1.  use the command:     

  alter system archive log all to 'c:oracleoradatav816archive';        *note:  you must specify a location ref - ora-16014 

2.  shutdown and restart the database.  it may be necessary to do a shutdown     abort. 

3. use the reopen attribute of the log_archive_dest_n init.ora parameter.    

  reopen=30'     or run the following comand:      

  alter system set log_archive_dest_n = 'reopen' 

4. use the commands:        

alter system archive log stop;     alter system archive log start;  

explanation ----------- 

the error ora-16014 is the real clue for this problem.  once the archive  destination becomes full the location also becomes invalid.  normally oracle  does not do a recheck to see if space has been made available. 

1.  using the command: alter system archive log all to 'c:oracleoradatav816archive';   gives oracle a valid location for the archive logs.  even after using this the  archive log destination parameter is still invalid and automatic achive does not work.  this solution is best for systems that do not archive regularly but cannot be shutdown.  you can also use this to allow you to do a shutdown  immediate instead of shutdown abort. 

2.  shutdown and restart of the database resets the archive log destinstation  parameter to be valid.  do not forget to make disk space available before  starting the database. 

3. use the reopen attribute of the log_archive_dest_n parameter to determine  whether and when arcn attempts to re-archive to a failed destination following an error.  reopen applies to all errors, not just open errors.   reopen=n sets the minimum number of seconds before arcn should try to reopen a failed destination.  the default value for n is 300 seconds.  a value of 0 is the same as turning off the reopen option, in other words, arcn will not  attempt to archive after a failure.  if you do not specify the reopen keyword,  arcn will never reopen a destination following an error.  the server  administration guide has more information on reopen.  

references ---------- 

[bug:1271752] automatic archiving has not resumed after space is freed up server administration guide:  chapter 7 

[note:74324.1] auto archive stopped - 8i log_archive_dest_n issues .

sql> shutdown abort;
oracle instance shut down.
sql> startup
oracle instance started.

total system global area  542712360 bytes
fixed size                   455208 bytes
variable size             427819008 bytes
database buffers          109051904 bytes
redo buffers                5386240 bytes
database mounted.
database opened.
sql> conn scott/tiger