Monday, June 12, 2017

Oracle Bug: kewastUnPackStats(): bad magic 1 (0x2b2b8f4652ad, 0)

Someitmes we may get the error in rdbms alert log...?

It generates thousands of lines each day which will expand the alert log size.

We can override this error by.

ALTER SYSTEM SET control_management_pack_access='NONE' SCOPE=MEMORY;

To get the solution permanantly, we need to deploy the patch.

Thursday, June 1, 2017

Starting a Rac Instance from the spfile of another instance for Oracle Database

At a Glance:
  1. Create pfile.
  2. Modify pfile with the correct location
  3. Start instance with the new pfile.


Step 1: Create pfile from spfile:

create pfile='/tmp/pfile_n1_01062017' from spfile;

Step 2: Transfer the file to target node:

scp /tmp/pfile_n1_01062017 oracle@sdbabut2:/tmp/pfile_n1_01062017.ora

Step 3: Modify the file according to target node:
Fields: thread, instance_number,dispatchers
Replace source node service name by target host service name

:%s/source_host_service_name/target_host_service_name/g




Step 4: Start instance from modified pfile:

sqlplus / as sysdba
> startup mount pfile=’/tmp/modifiedpfile.ora’

If it shows error, in that case modify accordingly.

If case of successfully start up,  need to alter the mode of the database.

sqlplus> alter database open;

If everything seems fine, create the spfile from the memory.
sqlplus> create spfile from memory;