Thursday, November 29, 2012

ORA-00600: [ksmlsge1] , ORA-12518

This error indicates O/S lack of resources due to heavy load on the system. Clients usually when trying to connect recieve ORA-12518: TNS:listener could not hand off client connection which is an other idication for lacking of resources, cause listener cannot open the required server process/thread to handle the new conenction request.

DB alert.log should have similiar entries to the follwoing :

Error: skgmattach - Unable to register map, error 4210

ORA-00600: internal error code, arguments: [ksmlsge1], [], [], [], [], [], [], [] ORA-27103: internal error OSD-00013: Message 13 not found; product=RDBMS; facility=SOSD






Thursday, November 8, 2012

Change on Redo Logs on a Data Guard Configuration

Some times for perfomance reason there is a need to recreate the Online Redo logs on the primary database. Based on Oracles recomendation  there should exist also Stanby Redo Log files which will need also to be recreated. If you do not recreate a new control file fo the standby you compromise the DG configuration. So here are the steps for this operation (10g & 11g):

1. Find the location of the control files , Standby and Online Redo Log files on standby and check if the db_file_name_convert & log_file_name_convert has been set.

     As sysdba on standby issue (using SQLPLUS) :

     show parameter control_files
     show parameter db_file_name_convert
     show parameter log_file_name_convert
     select * from v$logfile

2. Shutdown the stanby database.

3. Make all the changes related to the Online and Standby Redo log Groups in the Primary Database.

4. Drop all  old Online and Standby Redo log Groups from the Standby Database.

5. Recreate the Standby Controlfile

    a. On primary as sysdba issue :
        alter database create standby controlfile as '/tmp/myfile';

    b. Transfer the new control file to location of the control files to the standby server

    c. With the Standby Database still down drop the old control files and rename the new one to the same    name(s)
 
    d. Mount the standby database
        startup mount

    e. Switch Flashback off on standby if has been enabled (If you are in a Fast FailOver Configuration it will be enabled)
        alter database flashback off;

    e. Wait a few minutes for the standby to clear the online redo logfiles and recreate everything on the correct locations

    g. If you do not have set the  db_file_name_convert & log_file_name_convert  parameters  you must manulally rename all files

    h. Stop Managed Recovery
        alter database recover managed standby database cancel;

    i. Re-Enable FlashBack Database and restart database
       alter database flashback on;
       shutdown immediate;
       startup;

And you are again in sync.
 
REFERENCES
Oracle Support Notes : 740675.1 & 459411.1
 


Tuesday, November 6, 2012

RMAN crashes with kgefec: fatal error 0 kgepop: no error frame to pop to for error 603

If an RMAN session crashes with the following error report :

kgefec: fatal error 0

kgepop: no error frame to pop to for error 603

Then the problem is the stack size of the UNIX user running the RMAN session (Usually oracle).

Check the stack size of the user : 

[oracle@s-eacea-rh-dbo02-p ~]$ ulimit -a | grep stack
stack size              (kbytes, -s) 10240
[oracle@s-eacea-rh-dbo02-p ~]$




The as root add the following lines in /etc/profile (RHEL , OEL):

if [ $USER = "oracle" ]; then
  ulimit -s unlimited
fi

To verify , open a ne terminal login an oracle and repeat :

[oracle@s-eacea-rh-dbo02-p ~]$ ulimit -a | grep stack
stack size              (kbytes, -s) unlimited
[oracle@s-eacea-rh-dbo02-p ~]$

Add/Change as appropriate the etnries on /etc/security/limits.conf

oracle              soft    stack   unlimited
oracle              hard    stack   unlimited


REFERENCES
Oracle Support Note ID : 1458718.1






Monday, November 5, 2012

Oracle 11g Online Patching

In 11g a new feature is the Online Patching of an Oracle Home with no DB Instance Shutdown.You will know that a patch can be from its README file.

e.g

unzip p11111111_112030_Linux-x86-64.zip

cd 11111111

$ORACLE_HOME/OPatch/opatch apply online -connectString mySID:sys:syspass

The previous commands will apply online the 11111111 to SID : mySID

If you have another SID running on the same home then you must issue the following command to enable the patch.

$ORACLE_HOME/OPatch/opatch util enableonlinepatch -connectString mySID2:sys:syspass -id 11111111

In order to uninstall an online patch run from a single instance :

$ORACLE_HOME/OPatch/opatch rollback -id 11111111 -connectString mySID:sys:syspass 

In order to uninstall an online patch run from multiple instances :

$ORACLE_HOME/OPatch/opatch rollback -id 11111111 -connectString mySID:sys:syspass,mySID2:sys:syspass 

ATTENTION

If you do not know in how many SIDs an online patch has been applied issue the command to remove it from the first instance and then opatch will report if its has been applied to other instances. In this situation, cancel the opatch session (answer n in the question if you want to proceed) and run the command for all the instances as decsribed above.