Oracle112.2.0.2升级还没有测试过,不过新版本的安装做过几次了。升级步骤基本上和以前差不多,看着提示应该就能坐下了,除非运气差遇到什么问题。总得来说Oracle的安装(包括RAC)越来越简单人性化,安装过程中都有提示。
后面抽时间实测一遍,下面是转载一个升级过程,比较详尽。
【升级前版本: 】SQL> select * from v$version;BANNER--------------------------------------------------------------------------------Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit ProductionPL/SQL Release 11.2.0.1.0 - ProductionCORE 11.2.0.1.0 ProductionTNS for Linux: Version 11.2.0.1.0 - ProductionNLSRTL Version 11.2.0.1.0 - Production【升级后版本:】SQL> select * from v$version;BANNER--------------------------------------------------------------------------------Oracle Database 11g Enterprise Edition Release 11.2.0.2.0 - 64bit ProductionPL/SQL Release 11.2.0.2.0 - ProductionCORE 11.2.0.2.0 ProductionTNS for Linux: Version 11.2.0.2.0 - ProductionNLSRTL Version 11.2.0.2.0 - Production【升级目的:】解决secure file 的 ora-07445 错误【升级步骤:】1. 准备步骤:导入之前在做 update 和 delete 操作的时候提示 ora-7445 错误的表和相关记录,尝试通过 update 和 delete 操作在测试环境重现 ora-7445 错误2. 下载补丁包、确认系统包足够3. 开始安装 oracle 补丁包
提示是否需要更新相关的软件

可以有如下选择:
(1)选择只安装软件,之后通过DBUA或者手工执行升级脚本来升级
(2)选择升级数据库,之后不需要DBUA升级,也不需要手工执行升级脚本


对单实例的数据库进行升级

选择语言:英语+简体中文
选择企业版
剩下的就和正常安装数据库差不多。4. 软件安装完毕之后:(1)如果之前选择了升级存在的数据库,那么会进入升级界面:
升级程序会检查 recycle bin 是否清空,包括 dba_recycle 和 user_recycle;同时也会检查系统里面的无效对象,最好在升级前就确认无效对象。
如果选择在升级前备份数据,需要确认磁盘空间是否足够做备份。如果磁盘空间不足,那么会出现提示:



开始升级啦,升级和以往一样慢。(2)如果之前选择了只安装软件,简单描述一下手工升级数据字典流程:【步骤1:】 关闭数据库:shut immediate;【步骤2:】 关闭监听器:lsnrctl stop【步骤3:】 修改 $ORACLE_HOME:cd /home/oraclemv app app_old mv appnew app
【步骤4:】不一定必要,取决于 datafile、logfile、controlfile 存储的位置,如果和 $ORACLE_HOME 无关,则不需要修改。mv /home/oracle/app_old/oracle/oradata/$ORACLE_SID/datafile/ /home/oracle/app/oracle/oradata/$ORACLE_SID/datafile/ mv /home/oracle/app_old/oracle/oradata/$ORACLE_SID/onlinelog/ /home/oracle/app/oracle/oradata/$ORACLE_SID/onlinelog/ mv /home/oracle/app_old/oracle/oradata/$ORACLE_SID/controlfile/ /home/oracle/app/oracle/oradata/$ORACLE_SID/controlfile/ 【步骤5:】拷贝密码文件 orapw$ORACLE_SID SPFILE 文件 spfile$ORACLE_SID.ora 监听配置文件 listener.ora 本地 tnsnames.ora sqlnet.ora文件到新 $ORACLE_HOME【步骤6:】重启数据到upgrade,升级数据字典sqlplus / as sysdbastartup upgrade;@?/rdbms/admin/catupgrdshut immediate【步骤7:】重启数据库,编译无效对象sqlplus / as sysdbastartup @?/rdbms/admin/utlrp【步骤8:】确认升级后版本SQL> select * from v$version;BANNER--------------------------------------------------------------------------------Oracle Database 11g Enterprise Edition Release 11.2.0.2.0 - 64bit ProductionPL/SQL Release 11.2.0.2.0 - ProductionCORE 11.2.0.2.0 ProductionTNS for Linux: Version 11.2.0.2.0 - ProductionNLSRTL Version 11.2.0.2.0 - ProductionSQL> col namespace for a20;SQL> col version for a15;SQL> col comments for a40;SQL> select namespace,version,comments from registry$history;NAMESPACE VERSION COMMENTS-------------------- --------------- ----------------------------------------view invalidationSERVER 11.2.0.2.0 Upgraded from 11.2.0.1.0SERVER 11.2.0.2 Patchset 11.2.0.2.0view invalidationSERVER 11.2.0.2.0 Upgraded from 11.2.0.1.0SQL> 【步骤9:】确认 opatch 能用:opatch lsinventory -detailInvoking OPatch 11.2.0.1.1Oracle Interim Patch Installer version 11.2.0.1.1Copyright (c) 2009, Oracle Corporation. All rights reserved.Oracle Home : /home/oracle/app/oracle/product/11.2.0Central Inventory : /home/oracle/app/oraInventoryfrom : /etc/oraInst.locOPatch version : 11.2.0.1.1OUI version : 11.2.0.2.0OUI location : /home/oracle/app/oracle/product/11.2.0/ouiLog file location : /home/oracle/app/oracle/product/11.2.0/cfgtoollogs/opatch/opatch2010-11-10_14-54-16PM.logPatch history file: /home/oracle/app/oracle/product/11.2.0/cfgtoollogs/opatch/opatch_history.txtLsinventory Output file location : /home/oracle/app/oracle/product/11.2.0/cfgtoollogs/opatch/lsinv/lsinventory2010-11-10_14-54-16PM.txt--------------------------------------------------------------------------------Installed Top-level Products (1): Oracle Database 11g 11.2.0.2.0There are 1 products installed in this Oracle Home.Installed Products (136): Agent Required Support Files 10.2.0.4.3Assistant Common Files 11.2.0.2.0Bali Share 1.1.18.0.0Buildtools Common Files 11.2.0.2.0Character Set Migration Utility 11.2.0.2.0Cluster Verification Utility Common Files 11.2.0.2.0Database Configuration and Upgrade Assistants 11.2.0.2.0Database SQL Scripts 11.2.0.2.0Database Workspace Manager 11.2.0.2.0Deinstallation Tool 11.2.0.2.0Enterprise Edition Options 11.2.0.2.0Enterprise Manager Agent 10.2.0.4.3Enterprise Manager Agent Core Files 10.2.0.4.3Enterprise Manager Common Core Files 10.2.0.4.3Enterprise Manager Common Files 10.2.0.4.3Enterprise Manager Database Plugin -- Agent Support 11.2.0.2.0Enterprise Manager Database Plugin -- Repository Support 11.2.0.2.0Enterprise Manager Grid Control Core Files 10.2.0.4.3Enterprise Manager plugin Common Files 11.2.0.2.0Enterprise Manager Repository Core Files 10.2.0.4.3Exadata Storage Server 11.2.0.1.0Expat libraries 2.0.1.0.1Generic Connectivity Common Files 11.2.0.2.0HAS Common Files 11.2.0.2.0HAS Files for DB 11.2.0.2.0Installation Common Files 11.2.0.2.0Installation Plugin Files 11.2.0.2.0Installer SDK Component 11.2.0.2.0JAccelerator (COMPANION) 11.2.0.2.0LDAP Required Support Files 11.2.0.2.0...XDK Required Support Files 11.2.0.2.0XML Parser for Java 11.2.0.2.0XML Parser for Oracle JVM 11.2.0.2.0There are 136 products installed in this Oracle Home.There are no Interim patches installed in this Oracle Home.--------------------------------------------------------------------------------OPatch succeeded.如果 Opatch 不能用,需要确认 /etc/oratab 和 /etc/oraInst.loc 里面指向的值都正确。
拷贝原 oraInventory 到现在的 oraInventory 目录下:
mv /home/oracle/app_old/oraInventory /home/oracle/app/oraInventory
来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/14710393/viewspace-754456/
,如需转载,请注明出处,否则将追究法律责任。