11.2的静默安装改变了很多,简单记录一下碰到的错误。
在11.1及以前的版本中,静默安装只需要提供必须的参数即可,但是在11.2中responseFile似乎需要所有的参数,即使是那些根本不使用的。
最开始尝试只给出下面的参数:
oracle.install.responseFileVersion=/oracle/install/rspfmt_dbinstall_response_schema_v11_2_0
oracle.install.option=INSTALL_DB_SWONLY
ORACLE_HOSTNAME=Oracle111
UNIX_GROUP_NAME=dba
INVENTORY_LOCATION=/opt/oracle/oraInventory
SELECTED_LANGUAGES=en,zh_CN
ORACLE_HOME=/opt/oracle/product/11.2.0/db
ORACLE_BASE=/opt/oracle
oracle.install.db.InstallEdition=EE
oracle.install.db.EEOptionsSelection=false
oracle.install.db.optionalComponents=oracle.rdbms.partitioning:11.2.0.2.0,oracle.oraolap:11.2.0.2.0,oracle.rdbms.dm:11.2.0.2.0,oracle.rdbms.dv:11.2.0.2.0,orcle.rdbms.lbac:11.2.0.2.0,oracle.rdbms.rat:11.2.0.2.0
oracle.install.db.DBA_GROUP=dba
尝试静默安装报错:
[oracle@Oracle111 database]$ ./runInstaller -silent -noconfig -responseFile /data1/database/response/myinstall.rsp
Starting Oracle Universal Installer...
Checking Temp space: must be greater than 120 MB. Actual 7328 MB Passed
Checking swap space: must be greater than 150 MB. Actual 8191 MB Passed
Preparing to launch Oracle Universal Installer from /tmp/OraInstall2011-02-16_10-55-12PM. Please wait ...[oracle@Oracle111 database]$ [FATAL] [INS-10105] The given response file /data1/database/response/myinstall.rsp is not valid.
CAUSE: Syntactically incorrect response file. Either unexpected variables are specified or expected variables are not specified in the response file.
ACTION: Refer the latest product specific response file template
SUMMARY:
- cvc-complex-type.2.4.b: The content of element 'properties' is not complete. One of '{"":oracle.install.db.CLUSTER_NODES, "":oracle.install.db.isRACOneInstall, "":oracle.install.db.racOneServiceName, "":oracle.install.db.OPER_GROUP, "":oracle.install.db.config.starterdb.type, "":oracle.install.db.config.starterdb.SID, "":oracle.install.db.config.starterdb.globalDBName, "":oracle.install.db.config.starterdb.characterSet, "":oracle.install.db.config.starterdb.memoryLimit, "":oracle.install.db.config.starterdb.enableSecuritySettings, "":oracle.install.db.config.starterdb.installExampleSchemas, "":oracle.install.db.config.starterdb.memoryOption, "":oracle.install.db.config.starterdb.storageType, "":oracle.install.db.config.starterdb.fileSystemStorage.recoveryLocation, "":oracle.install.db.config.starterdb.fileSystemStorage.dataLocation, "":oracle.install.db.config.starterdb.password.ALL, "":oracle.install.db.config.starterdb.password.SYS, "":oracle.install.db.config.starterdb.password.DBSNMP, "":oracle.install.db.config.starterdb.password.SYSMAN, "":oracle.install.db.config.starterdb.password.SYSTEM, "":oracle.install.db.config.starterdb.control, "":oracle.install.db.config.starterdb.gridcontrol.gridControlServiceURL, "":oracle.install.db.config.starterdb.automatedBackup.enable, "":oracle.install.db.config.starterdb.automatedBackup.osuid, "":oracle.install.db.config.starterdb.automatedBackup.ospwd, "":oracle.install.db.config.asm.diskGroup, "":oracle.install.db.config.asm.ASMSNMPPassword, "":SECURITY_UPDATES_VIA_MYORACLESUPPORT, "":DECLINE_SECURITY_UPDATES, "":MYORACLESUPPORT_USERNAME, "":MYORACLESUPPORT_PASSWORD, "":PROXY_PORT, "":PROXY_HOST, "":PROXY_USER, "":PROXY_PWD, "":COLLECTOR_SUPPORTHUB_URL, "":AUTOUPDATES_MYORACLESUPPORT_USERNAME, "":AUTOUPDATES_MYORACLESUPPORT_PASSWORD, "":oracle.installer.autoupdates.option, "":oracle.installer.autoupdates.downloadUpdatesLoc}' is expected.
A log of this session is currently saved as: /tmp/OraInstall2011-02-16_10-55-12PM/installActions2011-02-16_10-55-12PM.log. Oracle recommends that if you want to keep this log, you should move it from the temporary location to a more permanent location.
于是尝试将所有不需要的参数留空,再次执行,仍然报错:
[oracle@Oracle111 database]$ ./runInstaller -silent -noconfig -responseFile /data1/database/response/myinstall.rsp
Starting Oracle Universal Installer...
Checking Temp space: must be greater than 120 MB. Actual 7326 MB Passed
Checking swap space: must be greater than 150 MB. Actual 8191 MB Passed
Preparing to launch Oracle Universal Installer from /tmp/OraInstall2011-02-16_11-00-06PM. Please wait ...[oracle@Oracle111 database]$ [SEVERE] - My Oracle Support Username/Email Address Not Specified
A log of this session is currently saved as: /tmp/OraInstall2011-02-16_11-00-06PM/installActions2011-02-16_11-00-06PM.log. Oracle recommends that if you want to keep this log, you should move it from the temporary location to a more permanent location.
不提供metalink帐号居然无法静默安装,Oracle现在的策略还真是有点意思。
随便输入一个用户名,再次运行:
[oracle@Oracle111 database]$ ./runInstaller -silent -noconfig -responseFile /data1/database/response/myinstall.rsp
Starting Oracle Universal Installer...
Checking Temp space: must be greater than 120 MB. Actual 7326 MB Passed
Checking swap space: must be greater than 150 MB. Actual 8191 MB Passed
Preparing to launch Oracle Universal Installer from /tmp/OraInstall2011-02-16_11-04-50PM. Please wait ...[oracle@Oracle111 database]$ [SEVERE] - This is an invalid email address. The email address must contain one "@" symbol and at least one dot("."). If you have a My Oracle Support account, specify the email address you use to log in to My Oracle Support, for example, johndoe@mycompany.com
A log of this session is currently saved as: /tmp/OraInstall2011-02-16_11-04-50PM/installActions2011-02-16_11-04-50PM.log. Oracle recommends that if you want to keep this log, you should move it from the temporary location to a more permanent location.
Oracle还去检查了语法是否正确,安装语法输入oracle@oracle.com,再次尝试安装:
[oracle@Oracle111 database]$ ./runInstaller -silent -noconfig -responseFile /data1/database/response/myinstall.rsp
Starting Oracle Universal Installer...
Checking Temp space: must be greater than 120 MB. Actual 7326 MB Passed
Checking swap space: must be greater than 150 MB. Actual 8191 MB Passed
Preparing to launch Oracle Universal Installer from /tmp/OraInstall2011-02-16_11-09-29PM. Please wait ...[oracle@Oracle111 database]$
安装的命令退出了,但是从后台看,安装进程还在,不知道停在了什么地方。
看了11.2的responseFile方式很不靠谱,最终使用命令行的方式安装完成:
[oracle@Oracle111 database]$ ./runInstaller -silent -debug -force \
> FROM_LOCATION=/data1/database/stage/products.xml \
> oracle.install.option=INSTALL_DB_SWONLY \
> UNIX_GROUP_NAME=oinstall \
> INVENTORY_LOCATION=/opt/oracle/oraInventory \
> ORACLE_HOME=/opt/oracle/product/11.2.0/db \
> ORACLE_HOME_NAME="Oracle111" \
> ORACLE_BASE=/opt/oracle \
> oracle.install.db.InstallEdition=EE \
> oracle.install.db.isCustomInstall=false \
> oracle.install.db.DBA_GROUP=dba \
> oracle.install.db.OPER_GROUP=dba \
> DECLINE_SECURITY_UPDATES=true
最后检查了一下metalink,发现oracle还居然在专门的文档ID 883714.1描述了这个问题,错误原因是:
'My Oracle Support' Account user name and password were not specified in the response file.
而解决方法居然就是:
Specify the My Oracle Support Account User name and password in your response file
不过从Oracle对于metalink帐号要求越来越严格,也可以看出Oracle策略的趋势。