Tuesday, November 30, 2021

ORA-10458 when opening Oracle physical standby read only after duplicating (restoring from another physical standby)

You might get the following errors stack when trying to open physical standby database read only. In my case it was duplicated (restored from service from different active physical standby), and I got the errors :

SQL> alter database open read only                   
*                                                                                              
ERROR at line 1:                                
ORA-10458: standby database requires recovery                                                  
ORA-01194: file 1 needs more recovery to be consistent                                         
ORA-01110: data file 1: '+DATAC8/BARS12_TST/DATAFILE/system.266.1089980259' 

Actually, all files was consistent, all checkpoints was equal etc., but some datafiles was fuzzy (fhsta=64) :

SQL> select count(*) ,fhsta from x$kcvfh group by fhsta;                                                                                              
      COUNT(*)|          FHSTA                                                                                                                                                               
===============|=============== 

            28|              0                                                                
           103|             64                                                                                                                                                               
             1|           8256                 

What did not help :

- register/catalog next not applied archived log and run 'recover database' from rman ;

- register/catalog next not applied archived log and run 'recover standby database' from sqlplus.

What really helped :

- register next not applied archived log and run 'alter database recover managed standby database disconnect' from sqlplus (equals to run 'recover managed standby database disconnect' sqlplus command); next wait while last archived log is implemented, then cancel media recovery and finally open standby database read only without issues.

Good Luck !



No comments:

Post a Comment