签到成功

知道了

CNDBA社区CNDBA社区

Oracle 11g 静默安装软件 创建监听 手册

2016-12-02 01:39 6899 0 原创 Oracle 11g
作者: dave


云主机没有安装桌面,所有整个过程采用无界面方式进行。 这篇重点介绍静默方面的操作。 关于操作系统和相关参数及环境变量部分参考如下博客:

64 Linux Oracle 11gR2 单实例 安装手册

http://www.cndba.cn/dave/article/211

 

 

1       静默安装DB软件

1.1         创建/etc/oraInst.loc文件并添加如下内容:

inventory_loc=/u01/app/oraInventory 

inst_group=oinstallhttp://www.cndba.cn/dave/article/1604

  更改文件的权限 chown oracle:oinstall /etc/oraInst.loc chmod 664 /etc/oraInst.loc

 

1.2         创建response文件

修改response文件db_install.rsp,在文件在安装目录的response目录下,根据需求修改这个配置文件。

 

[root@dg1 response]# pwd
/u01/software/database/response
[root@dg1 response]# ls
dbca.rsp  db_install.rsp  netca.rsp

 

文件看上去很长,实际上我们过滤一下无关内容就剩如下:

[root@dg1 response]# cat db_install.rsp |grep -v "#"|grep -v "^$"
oracle.install.responseFileVersion=/oracle/install/rspfmt_dbinstall_response_schema_v11_2_0
oracle.install.option=
ORACLE_HOSTNAME=
UNIX_GROUP_NAME=
INVENTORY_LOCATION=
SELECTED_LANGUAGES=en
ORACLE_HOME=
ORACLE_BASE=
oracle.install.db.InstallEdition=
oracle.install.db.EEOptionsSelection=false
oracle.install.db.optionalComponents=oracle.rdbms.partitioning:11.2.0.4.0,oracle.oraolap:11.2.0.4.0,oracle.rdbms.dm:11.2.0.4.0,oracle.rdbms.dv:11.2.0.4.0,oracle.rdbms.lbac:11.2.0.4.0,oracle.rdbms.rat:11.2.0.4.0
oracle.install.db.DBA_GROUP=
oracle.install.db.OPER_GROUP=
oracle.install.db.CLUSTER_NODES=
oracle.install.db.isRACOneInstall=
oracle.install.db.racOneServiceName=
oracle.install.db.config.starterdb.type=
oracle.install.db.config.starterdb.globalDBName=
oracle.install.db.config.starterdb.SID=
oracle.install.db.config.starterdb.characterSet=AL32UTF8
oracle.install.db.config.starterdb.memoryOption=true
oracle.install.db.config.starterdb.memoryLimit=
oracle.install.db.config.starterdb.installExampleSchemas=false
oracle.install.db.config.starterdb.enableSecuritySettings=true
oracle.install.db.config.starterdb.password.ALL=
oracle.install.db.config.starterdb.password.SYS=
oracle.install.db.config.starterdb.password.SYSTEM=
oracle.install.db.config.starterdb.password.SYSMAN=
oracle.install.db.config.starterdb.password.DBSNMP=
oracle.install.db.config.starterdb.control=DB_CONTROL
oracle.install.db.config.starterdb.gridcontrol.gridControlServiceURL=
oracle.install.db.config.starterdb.automatedBackup.enable=false
oracle.install.db.config.starterdb.automatedBackup.osuid=
oracle.install.db.config.starterdb.automatedBackup.ospwd=
oracle.install.db.config.starterdb.storageType=
oracle.install.db.config.starterdb.fileSystemStorage.dataLocation=
oracle.install.db.config.starterdb.fileSystemStorage.recoveryLocation=
oracle.install.db.config.asm.diskGroup=
oracle.install.db.config.asm.ASMSNMPPassword=
MYORACLESUPPORT_USERNAME=
MYORACLESUPPORT_PASSWORD=
SECURITY_UPDATES_VIA_MYORACLESUPPORT=
DECLINE_SECURITY_UPDATES=
PROXY_HOST=
PROXY_PORT=
PROXY_USER=
PROXY_PWD=
PROXY_REALM=
COLLECTOR_SUPPORTHUB_URL=
oracle.installer.autoupdates.option=
oracle.installer.autoupdates.downloadUpdatesLoc=
AUTOUPDATES_MYORACLESUPPORT_USERNAME=
AUTOUPDATES_MYORACLESUPPORT_PASSWORD=
[root@dg1 response]#

 

可以根据我们的需要手工进行修改,实际上最简单的就是在GUI安装的时候,生成response文件,这样照葫芦画瓢就可以了。http://www.cndba.cn/dave/article/1604

 

最终我们修改了db_install.rsp中的如下内容:http://www.cndba.cn/dave/article/1604

http://www.cndba.cn/dave/article/1604

oracle.install.responseFileVersion=/oracle/install/rspfmt_dbinstall_response_schema_v11_2_0
oracle.install.option=INSTALL_DB_SWONLY
DECLINE_SECURITY_UPDATES=true
UNIX_GROUP_NAME=oinstall
INVENTORY_LOCATION=/u01/app/oraInventory
SELECTED_LANGUAGES=en,zh_CN
ORACLE_HOME=/u01/app/oracle/product/11.2.0/db_1
ORACLE_BASE=/u01/app/oracle
oracle.install.db.InstallEdition=EE
oracle.install.db.DBA_GROUP=dba
oracle.install.db.OPER_GROUP=dba
DECLINE_SECURITY_UPDATES=true

 http://www.cndba.cn/dave/article/1604

    其中DECLINE_SECURITY_UPDATES一定要设置成true,否则在安装的时候会出现以下的告警:

[WARNING] - My Oracle Support Username/Email Address Not Specified

[SEVERE] - Provide the My Oracle Support password.
无法继续安装。

 

 

1.3         使用response 文件静默安装db软件

 

[oracle@dg1 database]$ ./runInstaller -silent -force -ignorePrereq -ignoreSysPrereqs -responseFile /u01/software/database/response/db_install.rsp
Starting Oracle Universal Installer...
 
Checking Temp space: must be greater than 120 MB.   Actual 35973 MB    Passed
Checking swap space: 0 MB available, 150 MB required.    Failed <<<<
 
>>> Ignoring required pre-requisite failures. Continuing...
 
Preparing to launch Oracle Universal Installer from /tmp/OraInstall2016-12-02_01-12-58AM. Please wait ...[oracle@dg1 database]$ You can find the log of this install session at:
 /u01/app/oraInventory/logs/installActions2016-12-02_01-12-58AM.log
The installation of Oracle Database 11g was successful.
Please check '/u01/app/oraInventory/logs/silentInstall2016-12-02_01-12-58AM.log' for more details.
 
As a root user, execute the following script(s):
         1. /u01/app/oracle/product/11.2.0/db_1/root.sh
 
 
Successfully Setup Software.

 

2       netca静默创建监听

 

netca.rsp不需要修改,直接建立监听

 

http://www.cndba.cn/dave/article/1604

[oracle@dg1 database]$ netca -silent -responsefile /u01/software/database/response/netca.rsp
 
Parsing command line arguments:
    Parameter "silent" = true
    Parameter "responsefile" = /u01/software/database/response/netca.rsp
Done parsing command line arguments.
Oracle Net Services Configuration:
Profile configuration complete.
Oracle Net Listener Startup:
    Running Listener Control:
      /u01/app/oracle/product/11.2.0/db_1/bin/lsnrctl start LISTENER
    Listener Control complete.
    Listener started successfully.
Listener configuration complete.
Oracle Net Services configuration successful. The exit code is 0
[oracle@dg1 database]$

3       手工建库

 

手工建库部分直接参考:

Oracle 11g 单实例 中手工建库 示例

http://www.cndba.cn/dave/article/209

 http://www.cndba.cn/dave/article/1604

Oracle 11g RAC 中手工建库 示例

http://www.cndba.cn/dave/article/210http://www.cndba.cn/dave/article/1604

 http://www.cndba.cn/dave/article/1604

Oracle 12c RAC 中手工建库 示例

http://www.cndba.cn/dave/article/227

 

Oracle 12c 单实例 中手工建库 示例

http://www.cndba.cn/dave/article/226

 

 http://www.cndba.cn/dave/article/1604

 


版权声明:本文为博主原创文章,未经博主允许不得转载。

用户评论
* 以下用户言论只代表其个人观点,不代表CNDBA社区的观点或立场
dave

dave

关注

人的一生应该是这样度过的:当他回首往事的时候,他不会因为虚度年华而悔恨,也不会因为碌碌无为而羞耻;这样,在临死的时候,他就能够说:“我的整个生命和全部精力,都已经献给世界上最壮丽的事业....."

  • 2237
    原创
  • 2
    翻译
  • 535
    转载
  • 185
    评论
  • 访问:6530344次
  • 积分:4229
  • 等级:核心会员
  • 排名:第1名
精华文章
    最新问题
    查看更多+
    热门文章
      热门用户
      推荐用户
        Copyright © 2016 All Rights Reserved. Powered by CNDBA · 皖ICP备2022006297号-1·

        QQ交流群

        注册联系QQ