一、 11.2.0.4.0
前提是运行./runInstaller之前步骤已完成
1. 复制响应文件模板
mkdir etc
cp /home/oracle/database/response/* /home/oracle/etc/
2. 设置响应文件权限
chmod 700 /home/oracle/etc/*
-rwx------. 1 oracle oinstall 44533 Aug 27 2013 dbca.rsp
-rwx------. 1 oracle oinstall 25276 Mar 1 12:09 db_install.rsp
-rwx------. 1 oracle oinstall 5871 Aug 27 2013 netca.rsp
3. 修改安装Oracle软件的响应文件
vi /home/oracle/etc/db_install.rsp
#修改以下参数
#安装类型
oracle.install.option=INSTALL_DB_SWONLY
#主机名
ORACLE_HOSTNAME=hostname
#安装组
UNIX_GROUP_NAME=oinstall
#INVENTORY目录(不填就是默认值)
INVENTORY_LOCATION=/data/app/oraInventory
#选择语言
SELECTED_LANGUAGES=en
#ORACLE_HOME
ORACLE_HOME=/data/app/oracle/product/11.2.0.3/dbhome_1
#ORACLE_BASE
ORACLE_BASE=/data/app/oracle
#oracle版本
oracle.install.db.InstallEdition=EE
#自定义安装,否,使用默认组件
oracle.install.db.isCustomInstall=false
#dba用户组
oracle.install.db.DBA_GROUP=dba
#oper用户组
oracle.install.db.OPER_GROUP=oinstall
#通过mos进行安全更新
SECURITY_UPDATES_VIA_MYORACLESUPPORT=false
#设置安全更新(貌似是有bug,这个一定要选true,否则会无限提醒邮件地址有问题,终止安装)
DECLINE_SECURITY_UPDATES=true
4. 开始静默安装
安装中,如果提示[WARNING]不必理会,此时安装程序仍在进行,如果出现[FATAL],则安装程序已经停止了。
./runInstaller -silent -responseFile /home/oracle/etc/db_install.rsp
#正常输出如下
Starting Oracle Universal Installer...
Checking Temp space: must be greater than 120 MB. Actual 32506 MB Passed
Checking swap space: must be greater than 150 MB. Actual 4095 MB Passed
Preparing to launch Oracle Universal Installer from /tmp/OraInstall2018-03-01_12-10-12PM. Please wait ... [WARNING] [INS-13014] Target environment do not meet some optional requirements.
CAUSE: Some of the optional prerequisites are not met. See logs for details. /tmp/OraInstall2018-03-01_12-10-12PM/installActions2018-03-01_12-10-12PM.log
ACTION: Identify the list of failed prerequisite checks from the log: /tmp/OraInstall2018-03-01_12-10-12PM/installActions2018-03-01_12-10-12PM.log. Then either from the log file or from installation manual find the appropriate configuration to meet the prerequisites and fix it manually.
You can find the log of this install session at:
/data/app/oraInventory/logs/installActions2018-03-01_12-10-12PM.log
The installation of Oracle Database 11g was successful.
Please check '/data/app/oraInventory/logs/silentInstall2018-03-01_12-10-12PM.log' for more details.
5. 出现以下提示时,以root用户运行指定脚本
As a root user, execute the following script(s):
1. /data/app/oraInventory/orainstRoot.sh
2. /data/app/oracle/product/11.2.0.3/dbhome_1/root.sh
6. 出现以下提示时,软件安装成功
Successfully Setup Software.
7. 查看安装日志信息了解安装进度
cd /data/app/oraInventory/logs
tail -f installActions*.log
二、 12.1.0.2
1. 12.1 Oracle软件安装
[oracle@euphe database_12c]$ mkdir -p /home/oracle/etc
[oracle@euphe database_12c]$ cp /home/oracle/database_12c/response/* /home/oracle/etc/
[oracle@euphe database_12c]$ chmod 700 /home/oracle/etc/*
[oracle@euphe database_12c]$ cd /home/oracle/etc/
[oracle@euphe etc]$ ll
total 112
-rwx------ 1 oracle oinstall 74822 Apr 23 11:20 dbca.rsp
-rwx------ 1 oracle oinstall 25036 Apr 23 11:20 db_install.rsp
-rwx------ 1 oracle oinstall 6038 Apr 23 11:20 netca.rsp
2. 修改安装Oracle软件的响应文件
vi /home/oracle/etc/db_install.rsp
#修改以下参数
oracle.install.option=INSTALL_DB_SWONLY
ORACLE_HOSTNAME=oracle-test
UNIX_GROUP_NAME=oinstall
INVENTORY_LOCATION=/data/prd/oraInventory
SELECTED_LANGUAGES=en
ORACLE_HOME=/data/prd/oracle/database/12.1.0.2/srm
ORACLE_BASE=/data/prd/oracle/database
oracle.install.db.InstallEdition=EE
oracle.install.db.DBA_GROUP=dba
oracle.install.db.OPER_GROUP=oinstall
oracle.install.db.BACKUPDBA_GROUP=dba
oracle.install.db.DGDBA_GROUP=dba
oracle.install.db.KMDBA_GROUP=dba
oracle.install.db.isRACOneInstall=false
DECLINE_SECURITY_UPDATES=true
SECURITY_UPDATES_VIA_MYORACLESUPPORT=false
3. 安装软件
[oracle@oracle-test database_12c]$ ./runInstaller -silent -responseFile /home/oracle/etc/db_install.rsp
Starting Oracle Universal Installer...
Checking Temp space: must be greater than 500 MB. Actual 53410 MB Passed
Checking swap space: must be greater than 150 MB. Actual 16379 MB Passed
Preparing to launch Oracle Universal Installer from /tmp/OraInstall2018-04-20_11-39-10AM. Please wait ...[oracle@oracle-test database_12c]$ You can find the log of this install session at:
/data/prd/oraInventory/logs/installActions2018-04-20_11-39-10AM.log
The installation of Oracle Database 12c was successful.
Please check '/data/prd/oraInventory/logs/silentInstall2018-04-20_11-39-10AM.log' for more details.
As a root user, execute the following script(s):
1. /data/prd/oraInventory/orainstRoot.sh
2. /data/prd/oracle/database/12.1.0.2/srm/root.sh
以root用户运行上面两个脚本
/data/prd/oraInventory/orainstRoot.sh
/data/prd/oracle/database/12.1.0.2/srm/root.sh
输出以下信息为成功
Successfully Setup Software.
4. dbca建库(非CDB)
[oracle@oracle-test database_12c]$ dbca -silent -createDatabase -templateName General_Purpose.dbc -gdbname orcl -sid orcl -responseFile NO_VALUE -characterSet AL32UTF8 -memoryPercentage 50
Enter SYS user password:
Enter SYSTEM user password:
Copying database files
1% complete
3% complete
11% complete
18% complete
26% complete
37% complete
Creating and starting Oracle instance
40% complete
45% complete
50% complete
55% complete
56% complete
60% complete
62% complete
Completing Database Creation
66% complete
70% complete
73% complete
85% complete
96% complete
100% complete
Look at the log file "/data/prd/oracle/database/cfgtoollogs/dbca/orcl/orcl.log" for further details.
参考
http://blog.itpub.net/28612416/viewspace-1669298/
http://blog.itpub.net/29047826/viewspace-1431667/
三、 12.2.0.1
1. 12.2 Oracle软件安装
mkdir -p /home/oracle/etc
cp /home/oracle/database/response/* /home/oracle/etc/
chmod 700 /home/oracle/etc/*
cd /home/oracle/etc/
[oracle@localhost etc]$ ll
total 60
-rwx------. 1 oracle oinstall 25502 Jul 26 00:11 dbca.rsp
-rwx------. 1 oracle oinstall 22924 Jul 26 00:11 db_install.rsp
-rwx------. 1 oracle oinstall 6209 Jul 26 00:11 netca.rsp
vi /home/oracle/etc/db_install.rsp
# 修改以下参数
oracle.install.responseFileVersion=/oracle/install/rspfmt_dbinstall_response_schema_v12.2.0
oracle.install.option=INSTALL_DB_SWONLY
UNIX_GROUP_NAME=oinstall
INVENTORY_LOCATION=/data/prd/oraInventory
ORACLE_HOME=/data/prd/oracle/database/12.2.0.1/Euphy
ORACLE_BASE=/data/prd/oracle/database
oracle.install.db.InstallEdition=EE
oracle.install.db.OSDBA_GROUP=dba
oracle.install.db.OSOPER_GROUP=dba
oracle.install.db.OSBACKUPDBA_GROUP=dba
oracle.install.db.OSDGDBA_GROUP=dba
oracle.install.db.OSKMDBA_GROUP=dba
oracle.install.db.OSRACDBA_GROUP=dba
SECURITY_UPDATES_VIA_MYORACLESUPPORT=false
DECLINE_SECURITY_UPDATES=true
安装软件
[oracle@euphe database]$ ./runInstaller -silent -responseFile /home/oracle/etc/db_install.rsp
Starting Oracle Universal Installer...
Checking Temp space: must be greater than 500 MB. Actual 81513 MB Passed
Checking swap space: must be greater than 150 MB. Actual 4063 MB Passed
Preparing to launch Oracle Universal Installer from /tmp/OraInstall2018-07-26_02-00-35AM. Please wait ...[oracle@euphe database]$ You can find the log of this install session at:
/data/prd/oraInventory/logs/installActions2018-07-26_02-00-35AM.log
The installation of Oracle Database 12c was successful.
Please check '/data/prd/oraInventory/logs/silentInstall2018-07-26_02-00-35AM.log' for more details.
As a root user, execute the following script(s):
1. /data/prd/oraInventory/orainstRoot.sh
2. /data/prd/oracle/database/12.2.0.1/Euphy/root.sh
root用户运行上面两个脚本
[root@euphe ~]# /data/prd/oraInventory/orainstRoot.sh
Changing permissions of /data/prd/oraInventory.
Adding read,write permissions for group.
Removing read,write,execute permissions for world.
Changing groupname of /data/prd/oraInventory to oinstall.
The execution of the script is complete.
[root@euphe ~]# /data/prd/oracle/database/12.2.0.1/Euphy/root.sh
Check /data/prd/oracle/database/12.2.0.1/Euphy/install/root_euphe_2018-07-26_02-06-04-414749379.log for the output of root script
输出以下信息为成功
Successfully Setup Software.
2. dbca创建数据库(CDB)
dbca -silent -createDatabase -gdbName euphy -sid euphy -createAsContainerDatabase true -templateName General_Purpose.dbc -characterSet AL32UTF8 -memoryPercentage 50
Copying database files
1% complete
2% complete
18% complete
33% complete
Creating and starting Oracle instance
35% complete
40% complete
41% complete
42% complete
46% complete
51% complete
52% complete
53% complete
55% complete
Completing Database Creation
56% complete
58% complete
59% complete
62% complete
hy65% complete
66% complete
Executing Post Configuration Actions
100% complete
Look at the log file "/data/prd/oracle/database/cfgtoollogs/dbca/euphy/euphy.log" for further details.
参考
http://blog.51cto.com/seiang/1946087
四、 19c安装测试
1. 安装包下载
下载地址 https://edelivery.oracle.com/osdc/faces/SoftwareDelivery
等待下载完成即可
2. 安装preinstall包
rpm -ivh oracle-database-preinstall-18c-1.0-1.el7.x86_64.rpm
3. 执行./create_db.sh
4. 解压安装包
12.2后安装包应在ORACLE_HOME目录下解压
cd $ORACLE_HOME
unzip V981623-01.zip
5. 静默模式安装
./runInstaller -ignorePrereq -waitforcompletion -silent
-responseFile ${ORACLE_HOME}/install/response/db_install.rsp
oracle.install.option=INSTALL_DB_SWONLY
ORACLE_HOSTNAME=`hostname`
UNIX_GROUP_NAME=oinstall
INVENTORY_LOCATION=/data/prd/oraInventory
SELECTED_LANGUAGES=en
ORACLE_HOME=${ORACLE_HOME}
ORACLE_BASE=${ORACLE_BASE}
oracle.install.db.InstallEdition=EE
oracle.install.db.OSDBA_GROUP=dba
oracle.install.db.OSBACKUPDBA_GROUP=dba
oracle.install.db.OSDGDBA_GROUP=dba
oracle.install.db.OSKMDBA_GROUP=dba
oracle.install.db.OSRACDBA_GROUP=dba
SECURITY_UPDATES_VIA_MYORACLESUPPORT=false
DECLINE_SECURITY_UPDATES=true
root用户执行两个脚本
/data/prd/oraInventory/orainstRoot.sh
/data/prd/oracle/database/19.0.0.0/hytest/root.sh
6. 静默模式创建数据库
dbca -silent -createDatabase -templateName General_Purpose.dbc -gdbname conantest -sid conantest -responseFile NO_VALUE -characterSet AL32UTF8 -memoryPercentage 50
Enter SYS user password:
Enter SYSTEM user password:
10% complete
Copying database files
40% complete
Creating and starting Oracle instance
42% complete
46% complete
50% complete
54% complete
60% complete
Completing Database Creation
66% complete
69% complete
70% complete
Executing Post Configuration Actions
100% complete
Database creation complete. For details check the logfiles at:
/data/prd/oracle/database/cfgtoollogs/dbca/conantest.
Database Information:
Global Database Name:conantest
System Identifier(SID):conantest
Look at the log file "/data/prd/oracle/database/cfgtoollogs/dbca/conantest/conantest.log" for further details.
7. 测试连接
sqlplus / as sysdba
SQL*Plus: Release 19.0.0.0.0 - Production on Fri Mar 29 19:21:04 2019
Version 19.2.0.0.0
Copyright (c) 1982, 2018, Oracle. All rights reserved.
Connected to:
Oracle Database 19c Enterprise Edition Release 19.0.0.0.0 - Production
Version 19.2.0.0.0
SQL>
服务器托管,北京服务器托管,服务器租用 http://www.fwqtg.net
机房租用,北京机房租用,IDC机房托管, http://www.e1idc.net