1.前期准备和配置
2.编辑response文件
例如下:
vi /oracle/response/db_install.rsp
oracle.install.responseFileVersion=/oracle/install/rspfmt_dbinstall_response_schema_v11_2_0
oracle.install.option=INSTALL_DB_SWONLY
ORACLE_HOSTNAME=ora11g
UNIX_GROUP_NAME=dba
INVENTORY_LOCATION=/oracle/oraInventory
SELECTED_LANGUAGES=en,zh_CN
ORACLE_HOME=/oracle/product/11.2
ORACLE_BASE=/oracle
oracle.install.db.InstallEdition=EE
oracle.install.db.DBA_GROUP=oinstall
oracle.install.db.OPER_GROUP=dba
DECLINE_SECURITY_UPDATES=true
oracle.install.db.config.starterdb.dbcontrol.enableEmailNotification=false
3.运行静默安装脚步
./runInstaller -silent -noconfig -responseFile "/oracle/response/11g_install.rsp"
过程中查看日志
tail -f /oracle/oraInventory/logs/installActionsYYYY-0MM-DD_HH-MM-SS{A/P}M.log
[oracle@ora11g database]$ ./runInstaller -silent -noconfig -ignoreSysPrereqs -responseFile "/oracle/response/11g_install.rsp"
Starting Oracle Universal Installer...
Checking Temp space: must be greater than 80 MB. Actual 7544 MB Passed
Checking swap space: must be greater than 150 MB. Actual 1982 MB Passed
Preparing to launch Oracle Universal Installer from /tmp/OraInstall2012-02-29_12-14-53PM. Please wait ...[oracle@ora11g database]$
- -- --- ---- ---- -------------------------------------
4.安装完后后,提示需执行脚本
[oracle@ora11g database]$ The following configuration scripts need to be executed as the "root" user.
#!/bin/sh
#Root scripts to run
/oracle/oraInventory/orainstRoot.sh
/oracle/product/11.2/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.
5.执行脚本
/oracle/oraInventory/orainstRoot.sh
/oracle/product/11.2/root.sh
[root@ora11g 11.2]# /oracle/oraInventory/orainstRoot.sh
Changing permissions of /oracle/oraInventory.
Adding read,write permissions for group.
Removing read,write,execute permissions for world.
Changing groupname of /oracle/oraInventory to oinstall.
The execution of the script is complete.
[root@ora11g 11.2]# /oracle/product/11.2/root.sh
Check /oracle/product/11.2/install/root_ora11g_2012-02-29_12-29-36.log for the output of root script
[root@ora11g 11.2]# tail -f /oracle/product/11.2/install/root_ora11g_2012-02-29_12-29-36.log
The following environment variables are set as:
ORACLE_OWNER= oracle
ORACLE_HOME= /oracle/product/11.2
Creating /etc/oratab file...
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.sh script.
Now product-specific root actions will be performed.
Finished product-specific root actions.
6.检查
[oracle@ora11g ~]$ sqlplus -v
SQL*Plus: Release 11.2
.0.1.0 Production