Thursday, November 22, 2007

STANDBY DB ISSUES

These are some of the issues which i have faced while managing the physical standby database:

1. ORA-00368: Checksum error
2. ORA-01119: Error in creating database file


1. ORA-00368: Checksum error
ORA-00368: checksum error in redo log block
ORA-00353: log corruption near block 10241 change 2700 time 11/22/2007

ORA-00334: archived log: '/archivelog/oradb1_arc_10444_596803436.arc'

Reason for the above error:
If checksum of the archive file at the production and standby

database is different. Compare the checksum using md5sum.

Solution:

a. If archive log file is present at the production box.
Then move the file to standby box.
b. Else Restore the archive log file from RMAN backup.
RMAN> restore archivelog logseq=42603 thread=1;
Transferred the file to standby box.
c. Make sure the checksum of the file ar prod and standbby box is same.
Use md5sum command.
d. Register the logfile:

SQL> alter database register or replace
logfile '/archivelog/oradb1_arc_42603_596803436.arc';

2. ORA-01119: Error in creating database file
ORA-01119: error in creating database file '/opt/oraprod/tbs2.dbf'
ORA-27054: NFS file system where the file is created or resides is not mounted with correct options
Linux-x86_64 Error: 13: Permission denied
Some recovered datafiles maybe left media fuzzy


Reason for the above error:
File system of production and standby database were different. So when New datafile '/opt/oraprod/tbs2.dbf'
was added to production db at the standby it could not create the same file as of production.

Solution:
At the standby database:
sql> recover managed standby database cancel;
sql> select file#,name from v$datafile where name like '%UNNAMED%';

sql> alter database create datafile '/opt/oracle/product/10.2.0/DB/dbs/UNNAMED00049' as '/opt/orastd/tbs2.dbf';
sql> recover managed standby database disconnect from session;

To avoid the above error just execute this statement:
sql> alter system set
STANDBY_FILE_MANAGEMENT=auto scope=both;


No comments: