Showing posts with label oracle database. Show all posts
Showing posts with label oracle database. Show all posts

Wednesday 3 June 2020

Enable ArchiveLog Mode on Oracle RAC database fails with ORA-00265

On a test RAC environment, while archiving is being enabled, "ALTER DATABASE ARCHIVELOG" command errored with ORA-00265: instance recovery required, cannot set ARCHIVELOG mode

Below are the steps performed to enable Archivelog mode on a 3-node RAC database environment.

test0115:TEST1011 $ srvctl status database -d TEST101
Instance TEST1011 is running on node test0115
Instance TEST1012 is running on node test0116
Instance TEST1013 is running on node test0117
test0115:TEST1011 $
test0115:TEST1011 $ srvctl stop database -d TEST101


test0115:TEST1011 $ srvctl status database -d TEST101
Instance TEST1011 is not running on node test0115
Instance TEST1012 is not running on node test0116
Instance TEST1013 is not running on node test0117
test0115:TEST1011 $


test0115:TEST1011 $ srvctl start database -d TEST101 -o mount
test0115:TEST1011 $  srvctl status database -d TEST101
Instance TEST1011 is running on node test0115
Instance TEST1012 is running on node test0116
Instance TEST1013 is running on node test0117
test0115:TEST1011 $


test0115:TEST1011 $ sqlplus / as sysdba

SQL*Plus: Release 11.2.0.4.0 Production on Sat May 9 14:13:54 2020

Copyright (c) 1982, 2013, Oracle.  All rights reserved.


Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production
With the Partitioning, Real Application Clusters and Automatic Storage Management options

SQL> select name,open_mode from gv$database;

NAME      OPEN_MODE
--------- --------------------
TEST101   MOUNTED
TEST101   MOUNTED
TEST101   MOUNTED

SQL>SQL> alter database archivelog;
alter database archivelog
*
ERROR at line 1:
ORA-00265: instance recovery required, cannot set ARCHIVELOG mode

Solution:
=========

1. Shutdown the database cleanly

SQL> shutdown immediate (on 3 RAC nodes)

2. Startup the database in mount stage

SQL> startup mount

3. Enable Archivelog mode

SQL> Alter database archivelog;

Database altered.

4. Open the database

SQL> Alter database open.

5. Verify archielog mode is enabled.

SQL> ARCHIVE LOG LIST;

Saturday 25 April 2020

Impdp fails with error ORA-31604

Issue:
When tried to Import a table from one Oracle database to another using IMPDP utility,encountered the error ORA-31604: invalid transform NAME parameter "MODIFY" for object type PROCACT_INSTANCE in function ADD_TRANSFORM

Impdp logfile has the below error:

Starting "<LOGIN_SCHEMA>"."SYS_IMPORT_FULL_10":  <LOGIN>/******** parfile=<PARFILE_NAME>.par logfile=<LOG_NAME>.log dumpfile=<DUMPFILE_NAME>.dmp parallel=1
Processing object type TABLE_EXPORT/TABLE/PROCACT_INSTANCE
ORA-39126: Worker unexpected fatal error in KUPW$WORKER.LOAD_MD_TRANSFORMS []
ORA-31604: invalid transform NAME parameter "MODIFY" for object type PROCACT_INSTANCE in function ADD_TRANSFORM
ORA-06512: at "SYS.DBMS_SYS_ERROR", line 86
ORA-06512: at "SYS.KUPW$WORKER", line 8996


Cause: This is a bug in Oracle Database versio 11g, fixed in Oracle Database version 12c

Solution:

As a workaround, implement any of the below solutions:

1. Use an additional parameter that is exclude=PROCACT_INSTANCE during impdp

2. Redo the export with exclude=PROCACT_INSTANCE and perform import using new dumpfiles.


The use of the exclude=PROCACT_SYSTEM will exclude the resource manager objects such as resource plans and groups. We need to re-create resource plans and groups after impdp is successfully completed.