Monday, September 26, 2011

Just Test - Install Oracle GI (standalone server) on OL6

I was just curious Oracle GI 11.2.0.3 (10404530) with Oracle Linux 6 (maybe RHEL6). I had to fix something about Upstart (Oracle GI 11.2.0.2 on OL6). I posted "Oracle Restart - Installation and... SILENT Mode" and "Install Grid Infra - clscfg.bin: error while loading shared libraries: libcap.so.1: cannot open shared object file: No such file or directory". They depends on Oracle Linux 6 (RHEL6) and Oracle GI 11.2.0.2. So, this post I just tested (Oracle GI 11.2.0.3 works on OL6). NO Fixed anything... by manual.
[oracle@mytest ~]$ cat /etc/oracle-release
Oracle Linux Server release 6.1
[oracle@mytest ~]$ uname -r
2.6.32-100.34.1.el6uek.i686
I use Oracle Linux 6.1, then install Grid Infrastructure for stand alone server (11.2.0.3) !!!
- Download and install Oracle GI for stand alone server
[oracle@mytest SRC]$ ls p10404530_112030_LINUX_3of7.zip
p10404530_112030_LINUX_3of7.zip
[oracle@mytest SRC]$ unzip p10404530_112030_LINUX_3of7.zip
[oracle@mytest SRC]$ cd grid
[oracle@mytest grid]$ ./runInstaller -silent -ignoreSysPrereqs -ignorePrereq -responseFile /u01/SRC/grid/response/grid_install.rsp ORACLE_HOME="/u01/app/oracle/product/11.2.0/grid" ORACLE_BASE="/u01/app/oracle" oracle.install.option="HA_CONFIG" oracle.install.asm.OSDBA=oinstall oracle.install.asm.OSOPER=oper oracle.install.asm.OSASM=dba oracle.install.asm.diskGroup.name=DATA oracle.install.asm.diskGroup.redundancy=EXTERNAL oracle.install.asm.diskGroup.diskDiscoveryString="/dev/raw/raw*" oracle.install.asm.diskGroup.disks="/dev/raw/raw1" oracle.install.asm.SYSASMPassword=password oracle.install.asm.monitorPassword=password
You can find the log of this install session at:
/u01/app/oraInventory/logs/installActions2011-09-26_01-25-52PM.log

The installation of Oracle Grid Infrastructure was successful.
Please check '/u01/app/oraInventory/logs/silentInstall2011-09-26_01-25-52PM.log' for more details.

As a root user, execute the following script(s):
1. /u01/app/oracle/product/11.2.0/grid/root.sh

As install user, execute the following script to complete the configuration.
1. /u01/app/oracle/product/11.2.0/grid/cfgtoollogs/configToolAllCommands

Note:
1. This script must be run on the same system from where installer was run.
2. This script needs a small password properties file for configuration assistants that require passwords (refer to install guide documentation).

Successfully Setup Software.
- Run root.sh (just curious about Upstart, so check before)
[oracle@mytest grid]$ su -
[root@mytest ~]# cat /etc/inittab
id:3:initdefault:
[root@mytest ~]# /u01/app/oracle/product/11.2.0/grid/root.sh
Check /u01/app/oracle/product/11.2.0/grid/install/root_mytest_2011-09-26_13-35-40.log for the output of root script

[root@mytest ~]# cat /u01/app/oracle/product/11.2.0/grid/install/root_mytest_2011-09-26_13-35-40.log

Performing root user operation for Oracle 11g

The following environment variables are set as:
ORACLE_OWNER= oracle
ORACLE_HOME= /u01/app/oracle/product/11.2.0/grid
Entries will be added to the /etc/oratab file as needed by
Database Configuration Assistant when a database is created
Finished running generic part of root script.
Now product-specific root actions will be performed.
Using configuration parameter file: /u01/app/oracle/product/11.2.0/grid/crs/install/crsconfig_params
Creating trace directory
/u01/app/oracle/product/11.2.0/grid/bin/clscfg.bin: error while loading shared libraries: libcap.so.1: cannot open shared object file: No such file or directory
Failed to create keys in the OLR, rc = 127, Message:

Failed to write the checkpoint:'' with status:FAIL.Error code is 256
/u01/app/oracle/product/11.2.0/grid/perl/bin/perl -I/u01/app/oracle/product/11.2.0/grid/perl/lib -I/u01/app/oracle/product/11.2.0/grid/crs/install /u01/app/oracle/product/11.2.0/grid/crs/install/roothas.pl execution failed
ERROR - about libcap.so.1, so fix!!!
[root@mytest ~]# yum install compat-libcap1
ol6_ga_base | 1.1 kB 00:00
ol6_u1_base | 1.1 kB 00:00
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package compat-libcap1.i686 0:1.10-1 will be installed
--> Finished Dependency Resolution

Dependencies Resolved
=========================================================================================================================
Package Arch Version Repository Size
=========================================================================================================================
Installing:
compat-libcap1 i686 1.10-1 ol6_ga_base 16 k

Transaction Summary
=========================================================================================================================
Install 1 Package(s)

Total download size: 16 k
Installed size: 24 k
Is this ok [y/N]: y
Downloading Packages:
compat-libcap1-1.10-1.i686.rpm | 16 kB 00:00
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
Installing : compat-libcap1-1.10-1.i686 1/1

Installed:
compat-libcap1.i686 0:1.10-1

Complete!
- Run again ...if error then fix and run again !!!
[root@mytest ~]# /u01/app/oracle/product/11.2.0/grid/root.sh
Check /u01/app/oracle/product/11.2.0/grid/install/root_mytest_2011-09-26_13-38-34.log for the output of root script
[root@mytest ~]# cat /u01/app/oracle/product/11.2.0/grid/install/root_mytest_2011-09-26_13-38-34.log
Performing root user operation for Oracle 11g

The following environment variables are set as:
ORACLE_OWNER= oracle
ORACLE_HOME= /u01/app/oracle/product/11.2.0/grid
Entries will be added to the /etc/oratab file as needed by
Database Configuration Assistant when a database is created
Finished running generic part of root script.
Now product-specific root actions will be performed.
Using configuration parameter file: /u01/app/oracle/product/11.2.0/grid/crs/install/crsconfig_params
Improper Oracle Grid Infrastructure configuration found on this host
Deconfigure the existing cluster configuration before starting
to configure a new Grid Infrastructure
run '/u01/app/oracle/product/11.2.0/grid/crs/install/roothas.pl -deconfig'
to configure existing failed configuration and then rerun root.sh
/u01/app/oracle/product/11.2.0/grid/perl/bin/perl -I/u01/app/oracle/product/11.2.0/grid/perl/lib -I/u01/app/oracle/product/11.2.0/grid/crs/install /u01/app/oracle/product/11.2.0/grid/crs/install/roothas.pl execution failed
[root@mytest ~]# /u01/app/oracle/product/11.2.0/grid/crs/install/roothas.pl -deconfig
Using configuration parameter file: /u01/app/oracle/product/11.2.0/grid/crs/install/crsconfig_params
Oracle Restart stack is not active on this node
Restart the SIHA stack (use /u01/app/oracle/product/11.2.0/grid/bin/crsctl start has) and retry
Failed to write the checkpoint:'' with status:FAIL.Error code is 256
Failed to verify HA resources
[root@mytest ~]# /u01/app/oracle/product/11.2.0/grid/root.sh
Check /u01/app/oracle/product/11.2.0/grid/install/root_mytest_2011-09-26_13-39-12.log for the output of root script
[root@mytest ~]# cat /u01/app/oracle/product/11.2.0/grid/install/root_mytest_2011-09-26_13-38-34.log
Performing root user operation for Oracle 11g

The following environment variables are set as:
ORACLE_OWNER= oracle
ORACLE_HOME= /u01/app/oracle/product/11.2.0/grid
Entries will be added to the /etc/oratab file as needed by
Database Configuration Assistant when a database is created
Finished running generic part of root script.
Now product-specific root actions will be performed.
Using configuration parameter file: /u01/app/oracle/product/11.2.0/grid/crs/install/crsconfig_params
Improper Oracle Grid Infrastructure configuration found on this host
Deconfigure the existing cluster configuration before starting
to configure a new Grid Infrastructure
run '/u01/app/oracle/product/11.2.0/grid/crs/install/roothas.pl -deconfig'
to configure existing failed configuration and then rerun root.sh
/u01/app/oracle/product/11.2.0/grid/perl/bin/perl -I/u01/app/oracle/product/11.2.0/grid/perl/lib -I/u01/app/oracle/product/11.2.0/grid/crs/install /u01/app/oracle/product/11.2.0/grid/crs/install/roothas.pl execution failed
[root@mytest ~]# /u01/app/oracle/product/11.2.0/grid/crs/install/roothas.pl -deconfig
Using configuration parameter file: /u01/app/oracle/product/11.2.0/grid/crs/install/crsconfig_params
Oracle Restart stack is not active on this node
Restart the SIHA stack (use /u01/app/oracle/product/11.2.0/grid/bin/crsctl start has) and retry
Failed to write the checkpoint:'' with status:FAIL.Error code is 256
Failed to verify HA resources
[root@mytest ~]# cat /etc/oracle/olr.loc
olrconfig_loc=/u01/app/oracle/product/11.2.0/grid/cdata/localhost/mytest.olr
crs_home=/u01/app/oracle/product/11.2.0/grid
[root@mytest ~]# mv /etc/oracle/olr.loc /etc/oracle/olr.loc.old
[root@mytest ~]# /u01/app/oracle/product/11.2.0/grid/root.sh
Check /u01/app/oracle/product/11.2.0/grid/install/root_mytest_2011-09-26_13-39-55.log for the output of root script
[root@mytest ~]# cat /u01/app/oracle/product/11.2.0/grid/install/root_mytest_2011-09-26_13-39-55.log
Performing root user operation for Oracle 11g

The following environment variables are set as:
ORACLE_OWNER= oracle
ORACLE_HOME= /u01/app/oracle/product/11.2.0/grid
Entries will be added to the /etc/oratab file as needed by
Database Configuration Assistant when a database is created
Finished running generic part of root script.
Now product-specific root actions will be performed.
Using configuration parameter file: /u01/app/oracle/product/11.2.0/grid/crs/install/crsconfig_params
/u01/app/oracle/product/11.2.0/grid/bin/crsctl query crs activeversion ... failed rc=1 with message:
CRS-4046: Invalid Oracle Clusterware configuration. CRS-4000: Command Query failed, or completed with errors.

LOCAL ADD MODE
Creating OCR keys for user 'oracle', privgrp 'oinstall'..
Operation successful.
CRS-4639: Could not contact Oracle High Availability Services
CRS-4000: Command Check failed, or completed with errors.
PROT-29: The Oracle Cluster Registry location is already configured
Replace of older local-only OCR failed
CRS-4664: Node mytest successfully pinned.
Adding Clusterware entries to upstart

mytest 2011/09/26 13:40:27 /u01/app/oracle/product/11.2.0/grid/cdata/mytest/backup_20110926_134027.olr
Successfully configured Oracle Grid Infrastructure for a Standalone Server
- After "root.sh" done, Check about Upstart and learn from it.
[root@mytest ~]# cat /etc/inittab
id:3:initdefault:
[root@mytest ~]# ls /etc/init/oracle-ohasd.conf
/etc/init/oracle-ohasd.conf
[root@mytest ~]# cat /etc/init/oracle-ohasd.conf
# Copyright (c) 2001, 2011, Oracle and/or its affiliates. All rights reserved.
#
# Oracle OHASD startup

start on runlevel [35]
stop on runlevel [!35]
respawn
exec /etc/init.d/init.ohasd run >/dev/null 2>&1 </dev/null
- Back to "oracle" user again.
[oracle@mytest grid]$ /u01/app/oracle/product/11.2.0/grid/cfgtoollogs/configToolAllCommands
Setting the invPtrLoc to /u01/app/oracle/product/11.2.0/grid/oraInst.loc

perform - mode is starting for action: configure

perform - mode finished for action: configure

You can see the log file: /u01/app/oracle/product/11.2.0/grid/cfgtoollogs/oui/configActions2011-09-26_01-48-49-PM.log
OK!!! Oracle GI 11.2.0.3 works on Oracle Linux 6 (Upstart).
On 11.2.0.3, Oracle GI created /etc/init/oracle-ohasd.conf file to support Upstart.

Related Post:
Oracle Restart - Installation and... SILENT Mode Oracle Linux 6.1
Install Grid Infra - clscfg.bin: error while loading shared libraries: libcap.so.1: cannot open shared object file: No such file or directory Oracle Linux 6.1
Upgrade Grid Infrastructure for cluster (11.2.0.2 to 11.2.0.3)
Upgrade - Oracle Database 11.2.0.2 to 11.2.0.3
Upgrade database 11.2.0.1.0 to 11.2.0.2.0 : dbua -silent
struggle to Upgrade Oracle Database 11.2.0.1 to 11.2.0.2
Just upgrade Oracle Database 10gR2 to 11gR2 by command-line
Just Step to upgrade (RAC) 10.2.0.4 to 11.1.0.6
Creating Database 11gR1 on ASM 11gR2

1 comment:

Johnny Koen said...

Hi Surachart,

What is fantastic post dude. You saved my bacon. Keep up the good work.

Cheers
Johnny