[INS-30131] Initial setup required for execution of installer validation failed.

When trying to install Oracle client 12c the above error appeared , this issue can happened on windows Or linux.

The cause i really simple :-

On linux there is no enough space under /tmp.

On windows the solution like the following :-

  • Open Windows Services.
  • Stop Oracle Services –> OracleRemExec
  • Remove the OracleRemExecService
  • then try to install Oracle client again

Thank you 
Osama Mustafa

OPATCH : Problems with the lock file

Problems with the lock file
Lock file exists, details are:
Interim Patch is holding the lock from ……
probably due to previous unsuccessful operation

Seems the Opatch has been interrupted or hanged therefore the .opatch_storage still exists under Oracle Home

ls -ltr $ORACLE_HOME

Search for .patch_storage and delete it

Try Again..

Osama Mustafa

Prerequisite check "CheckActiveFilesAndExecutables" failed

Oracle Home       : /u01/app/oracle/product/11.2.0/db_home1
Central Inventory : /u01/app/oraInventory
   from           : /u01/app/oracle/product/11.2.0/db_home1/oraInst.loc
OPatch version    : 11.2.0.3.6
OUI version       : 11.2.0.3.0
Log file location : /u01/app/oracle/product/11.2.0/db_home1/cfgtoollogs/opatch/opatch2015-03-09_16-45-09PM_1.log
Verifying environment and performing prerequisite checks…
Prerequisite check “CheckActiveFilesAndExecutables” failed.
The details are:

Following executables are active :
/u01/app/oracle/product/11.2.0/db_home1/lib/libclntsh.so.11.1
UtilSession failed: Prerequisite check “CheckActiveFilesAndExecutables” failed.
Log file location: /u01/app/oracle/product/11.2.0/db_home1/cfgtoollogs/opatch/opatch2015-03-09_16-45-09PM_1.log

When trying to apply OPatch the above error appear , 
Some process hanged 

oracle@–:~/database_patches/19769496$ fuser /u01/app/oracle/product/11.2.0/db_home1/lib/libclntsh.so.11.1
/u01/app/oracle/product/11.2.0/db_home1/lib/libclntsh.so.11.1:    58536m

Kill -9 58536

Cheers
Thank you 

Configure DBConsole as Active/passive

Sometimes Database Configured as Active/Passive ( Cluster ) Which mean one node working/time and regarding to this if the failover happened on 2nd node the customer will expected that everything will be the same as it was on node 1 include to this Dbconsole.

To do this follow the below steps :-

  • Database should be configured on VIP.
  • Listener should be configured on VIP.
  • Database , Configuration should be installed on Shared Storage
  • inventory Files should be on shared storage as well.
  • ORACLE_HOSTNAME Should be set to VIP Hostname.
Listener example :-

LISTENER  =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = VIP-HOST )(PORT = 1521))
)

Don’t forget to set the LOCAL_LISTENER Parameter :-

SQL> alter system set local_listener=’LISTENER’;

Or

SQL> alter system set local_listener='(ADDRESS = (PROTOCOL = TCP)(HOST = VIP-HOST )(PORT = 1521)) ‘;

Now

export ORACLE_HOSTNAME=VIP-HOSTNAME
emca -config dbcontrol db -repos create

Test the failover on node #2

if for some reason when you try to start emctl and the error still asking for oc4j then export ORACLE_HOSTNAME is bash_profile.

It should work

Cheers
Osama 

Shutdown Immediate Hangs

Today i faced Strange issue with Shutdown immediate command on cluster database which is when run shutdown immediate the command hangs and take so long and sometimes it’s working and most of the time not working.

the below command was working without any problem :-

SQL > shutdown abort

to solve this issue & trace the error since the alertlog not indicating to anything interesting i have to dump systemstate every 5 minutes  to know what going on :-

connect / as sysdba
alter session set events ‘10400 trace name context forever, level 1’; 

After this you can kill the session that preventing shutdown.

The hangs usually happened for two reasons :-

  • Query running on Database.
  • Transaction happened while you are trying to shutdown database.
For the first reason :

use v$session_longops Read more here.

Run the below query to check the query.

select count(*) from v$session_longops where time_remaining>0;

Second reason you can use

v$transaction Read from here.

Useful Document :-
Alert Log: Shutdown Waiting for Active Calls to Complete (Doc ID 1039389.6)

Thank you
Osama Mustafa

Oracle Database Patches Information

A number of questions has been asked here and in Oracle Community Forum When/What/Date for Next Database patches ?

in the all way you should have valid account for http://support.oracle.com.

I see it’s worth it to post and share the information how to find the desire patch number and how to know next patch release, i will only share MOS document number that will help you understand what i mean.

How to Find Patch ? 

  • Oracle Recommended Patches — Oracle Database (Doc ID 756671.1)
  • Quick Reference to Patch Numbers for Database PSU, SPU(CPU), Bundle Patches and Patchsets [1454618.1]
  • Release Schedule of Current Database Releases [742060.1]
  • Introduction to Oracle Recommended Patches [756388.1]
  • Oracle Database Patchset Information, Versions 10.2.0 to 12.1.0 (Doc ID 268895.1)
  • ALERT: Oracle 11g Release 1 (11.1) Support Status and Alerts (Doc ID 454507.1)
The above MOS document will guide you and help you to know the next release of database patch, also as you see i included some document that helps for recommended patch.
REGISTRY$HISTORY contains information about the applied patches PSU, SRU or CPU and you can use Oracle Base Script from here.
Or 
$ORACLE_HOME/OPatch/opatch lsinventory
Cheers
Osama Mustafa

ORA-27102: out of memory

Operating system : Solaris Sparc 11.2
Database Version : 11.2.0.3.0

When Trying to startup the database the following error appeared :-

SQL> startup nomount ;
ORA-27102: out of memory
SVR4 Error: 22: Invalid argument

Even when trying to know which instance process do this :-

SQL> oradebug setmypid
ORA-01034: ORACLE not available
ORA-27101: shared memory realm does not exist
SVR4 Error: 2: No such file or directory
ORA-01034: ORACLE not available
ORA-27101: shared memory realm does not exist
SVR4 Error: 2: No such file or directory 

SQL> oradebug ipc
ORA-01034: ORACLE not available
ORA-27101: shared memory realm does not exist
SVR4 Error: 2: No such file or directory
ORA-01034: ORACLE not available
ORA-27101: shared memory realm does not exist
SVR4 Error: 2: No such file or directory 

After investigation i found the cause for this error, the solaris SHMMAX was not set correctly on OS level which mean the database was configured more than permitted memory on OS.

to solve the above error

Find which project oracle user run using the below command :-

id -p
uid=59008(oracle) gid=10001(dba) projid=3(default)  

Then

prctl -n project.max-shm-memory -i project 3 

project: 3: default
NAME    PRIVILEGE       VALUE    FLAG   ACTION                       RECIPIENT
project.max-shm-memory
        privileged      35GB      –   deny                                 –
        system          24EB    max   deny                                 –

So i have to increase it

prctl -n project.max-shm-memory -r -v 40G -i project 3

Note the above changes will be temporary till the next restart.

Cheers
Osama  

sshUserSetup.sh & runcluvfy.sh

Oracle 11gR2 RAC Grid install includes a useful script that can be used to make your life easier no more copying and waiting for errors the above scripts will make your easier simply.

./sshUserSetup.sh 

useful script to establish and exchange ssh keys between all the nodes of the cluster called sshUserSetup.sh

And Can Be Used like the below :-

./sshUserSetup.sh -user oracle -hosts “node1 node2” -noPromptPassphrase
./sshUserSetup.sh -user grid   -hosts “node1 node2” -noPromptPassphrase

./runcluvfy.sh

Cluster Verification Utility

Regarding to Oracle documentation :-

“performs system checks in preparation for installation, patch updates, or other system changes. Using CVU ensures that you have completed the required system configuration and preinstallation steps so that your Oracle Grid Infrastructure or Oracle Real Application Clusters (Oracle RAC) installation, update, or patch operation completes successfully.”

you can learn More Here

Example :-
./runcluvfy.sh stage -pre crsinst -n  node1,node -fixup -verbose