Skip to main content

Silent Oracle 11g R2 install using only the command line

I’ll explain how easy is to install Oracle Software using command line with no need to get a VNC session or a GNOME/KDE environment.
Most of people use the OUI (Oracle Universal Installer) graphic interface to install oracle database software, but sometimes we need a small footprint server installation without installing all the garbage that usually everyone install to run a simple Oracle database.
If you have installed a slimmed down OS installation(or Centos or RHEL) either by only choosing the base components or by using a VM template (OVM or EC2), you can install Oracle software in 3 simple steps.


1. Add Oracle public yum repository.


[root@localhost ~]$ cd /etc/yum.repos.d
[root@localhost ~]$ wget http://public-yum.oracle.com/public-yum-el5.repo


# edit the file public-yum-el5.repo and enable both the [el5_u5_base] and the [ol5_u5_base] repositories in the yum configuration file by changing enable=0 to enable=1 in those sections


2. Install Oracle validated packages


[root@localhost ~]$ yum install oracle-validated


3. Download and Install Oracle software on command line


[root@localhost ~]$ su - oracle
[oracle@localhost ~]$ cd /software/11gr2/database
[oracle@localhost database]$ ./runInstaller -silent -force \
FROM_LOCATION=/software/11gr2/database/stage/products.xml \
oracle.install.option=INSTALL_DB_SWONLY \
UNIX_GROUP_NAME=oinstall \
INVENTORY_LOCATION=/home/oracle/oraInventory \
ORACLE_HOME=/u01/app/oracle/product/11.2/db_1 \
ORACLE_HOME_NAME="OraDb11g_Home1" \
ORACLE_BASE=/u01/app/oracle \
oracle.install.db.InstallEdition=SE \
oracle.install.db.isCustomInstall=false \
oracle.install.db.DBA_GROUP=dba \
oracle.install.db.OPER_GROUP=dba \
DECLINE_SECURITY_UPDATES=true
[oracle@localhost database]$ exit
# As a root user, execute the following script(s):
[root@localhost ~]$ /home/oracle/oraInventory/orainstRoot.sh
[root@localhost ~]$ /u01/app/oracle/product/11.2/db_1/root.sh


In 15 minutes or so, you get the message “Successfully Setup Software” and now you have clean ready Oracle Home installed. Remember, this is only the Oracle Software and not an Oracle Database. Later you can install an Oracle Database using DBCA or manually.


********************************************************************************


In More Details Scenario two.
         


Oracle silent installation is straightforward though it always change a little with every major release. Here I show you tricks and tips during Oracle 11gR2 silent installation.


Steps


1#Create the oraInst.loc file.
2#Prepare a response file.
3#Run Oracle Universal Installer in silent or response file mode.
4#If you completed a software-only installation, then run Net Configuration Assistant and  Database Configuration Assistant in silent or response file mode if required.


Command /2 tricks/


directory_path/runInstaller -silent [-noconfig] -responseFile  absolute_path/response_file
It is case-sensitive !


Real story /tips and tricks/


Oracle 11gR2 Enterprise edition database home installation on Linux (RHEL5) x86_64.


1) Customize value in response file
important note: copy from Oracle sample file: <oracle_installation_dir>/database/response/db_install.rsp
oracle.install.responseFileVersion=/oracle/install/rspfmt_dbinstall_response_schema_v11_2_0
oracle.install.option=INSTALL_DB_SWONLY
UNIX_GROUP_NAME=oinstall
INVENTORY_LOCATION=/oracle/OraInventory
ORACLE_HOME=/oracle/product/11.2.0/template
ORACLE_BASE=/oracle
oracle.install.db.InstallEdition=EE
oracle.install.db.DBA_GROUP=dba
oracle.install.db.OPER_GROUP=dba
DECLINE_SECURITY_UPDATES=true


2) Silent installation


./runInstaller -silent -noconfig -responseFile /u01/download/db11ginstall.rsp
Starting Oracle Universal Installer...

Checking Temp space: must be greater than 120 MB.   Actual 22753 MB    Passed
Checking swap space: must be greater than 150 MB.   Actual 3817 MB    Passed
Preparing to launch Oracle Universal Installer from /tmp/OraInstall2011-06-17_09-02-07PM. Please wait ..
$ You can find the log of this install session at:
 /oracle/OraInventory/logs/installActions2011-06-17_09-02-07PM.log
The following configuration scripts need to be executed as the "root" user.
 #!/bin/sh
 #Root scripts to run

/oracle/product/11.2.0/template/root.sh
To execute the configuration scripts:
         1. Open a terminal window
         2. Log in as "root"
         3. Run the scripts
         4. Return to this window and hit "Enter" key to continue

Successfully Setup Software.
/ * tricks and tips  */


Trick 1 # If oracle home is not empty and we didn’t use runInstaller *** -force option, it will die with following messages
CAUSE: The chosen installation conflicted with software already installed in the given Oracle home.
   ACTION: Install into a different Oracle home.


Trick 2 # If system are not satisfied with Oracle installation requirement, it  will show  following messages.


CAUSE: Some of the optional prerequisites are not met. See logs for details. /oracle/OraInventory/logs/…log
   ACTION: Identify the list of failed prerequisite checks from the log: /oracle/OraInventory/logs/….log. Then either from the log file or from installation manual find the appropriate configuration to meet the prerequisites and fix it manually.
[WARNING] [INS-13014] Target environment do not meet some optional requirements.


Trick 3 # If DECLINE_SECURITY_UPDATES is not set to FALSE, Oracle will try to set up OCM (Oracle configuration management with metalink credential), it will die with following messages.
[SEVERE] – Email Address Not Specified


Trick 4 # If DBA and OS group is not specified properly, it may die with following messages
   CAUSE: User is not a member of one or more of the chosen OS groups.
   ACTION: Please choose OS groups of which user is a member.


Conclusion
Silent installation is still easy with patience.


Update at Sept 9, 2013
For Oracle 11.2.0.4 silent installation, I record response file and it shows off following related parameters.
SECURITY_UPDATES_VIA_MYORACLESUPPORT=false
DECLINE_SECURITY_UPDATES=true
oracle.installer.autoupdates.option=SKIP_UPDATES 

Comments

Popular posts from this blog

Hard dependency with ip address Oracle RAC Cluster.

Command error out due to hard dependency with ip address [-Node1]/app/grid/oracle/product/11.2.0/grid/bin>./crsctl relocate resource RDBMS_DB -n Node2 CRS-2527: Unable to start 'RDBMS_DB' because it has a 'hard' dependency on 'sDB' CRS-2525: All instances of the resource 'sDB' are already running; relocate is not allowed because the force option was not specified CRS-4000: Command Relocate failed, or completed with errors. [-Node1]/app/grid/oracle/product/11.2.0/grid/bin>./crsctl relocate resource sDB  -n Node2 CRS-2529: Unable to act on 'DB' because that would require stopping or relocating 'LISTENER_DB', but the force option was not specified CRS-4000: Command Relocate failed, or completed with errors. [-Node1]/app/grid/oracle/product/11.2.0/grid/bin>./crsctl relocate resource LISTENER_DB  -n Node2 CRS-2527: Unable to start 'LISTENER_DB' because it has a 'hard' dependency on 'sD...

19C NID ( Rename Database)

 [oracle@localhost ~]$ nid DBNEWID: Release 19.0.0.0.0 - Production on Thu Dec 23 00:05:36 2021 Copyright (c) 1982, 2019, Oracle and/or its affiliates.  All rights reserved. Keyword     Description                    (Default) ---------------------------------------------------- TARGET      Username/Password              (NONE) DBNAME      New database name              (NONE) LOGFILE     Output Log                     (NONE) REVERT      Revert failed change           NO SETNAME     Set a new database name only   NO APPEND      Append to output log           NO HELP        Displays these messages    ...

ORA-01017/ORA-28000 with AUDIT_TRAIL

With default profile in Oracle 11g, accounts are automatically locked 1 day ( PASSWORD_LOCK_TIME ) after 10 failed login attempt ( FAILED_LOGIN_ATTEMPTS ): SQL > SET lines 200 SQL > SET pages 200 SQL > SELECT * FROM dba_profiles WHERE PROFILE = 'DEFAULT' ORDER BY resource_name; PROFILE                         RESOURCE_NAME                      RESOURCE LIMIT ------------------------------ -------------------------------- -------- ---------------------------------------- DEFAULT                         COMPOSITE_LIMIT                 ...