转如何升级oracle版本?(11.2.0.1至11.2.0.4)

dbua from 11.2,0.2 to 11.2.0.4 need 2hours

 

升级结果:

步骤名             日志文件名       状态

升级前操作   PreUpgrade.log    成功

Oracle ServerOracle_Server.log      成功

升级后操作PostUpgrade.log       成功

*Enterprise Manager 配置emConfigUpgrade.log  失败*

生成概要       generateSummary.log        成功

 

 

http://jingyan.baidu.com/article/cd4c29790b3c2f756f6e6041.html

 

 

sample 1:

--prapare

stop all oracle process

set ORACLE_HOME=D:\app\product\11.2.0.4\dbhome_1
set PATH=%ORACLE_HOME%\OPatch;%ORACLE_HOME%\bin;%PATH%

mkdir -p D:\app\product\11.2.0.4\dbhome_1
mkdir -p c:\app\software
mkdir -p c:\app\software\RSP
mkdir -p c:\app\software\database
mkdir -p C:\app\oracle\archivelog


xcopy \\tsclient\D\OraCD\11204_win64_template\p6880880_112000_MSWIN-x86-64.zip c:\app\software\ /D /E /Y /H /K
xcopy \\tsclient\D\OraCD\11204_win64_template\p26182427_112040_MSWIN-x86-64.zip c:\app\software\ /D /E /Y /H /K
xcopy \\tsclient\D\OraCD\11204_win64_template\p26194138_112040_MSWIN-x86-64.zip c:\app\software\ /D /E /Y /H /K
xcopy \\tsclient\D\OraCD\11204_win64_template\RSP\db.rsp c:\app\software\RSP\ /D /E /Y /H /K
xcopy \\tsclient\D\OraCD\11204_win64_template\p13390677_112040_MSWIN-x86-64_1of7.zip c:\app\software\database\ /D /E /Y /H /K
xcopy \\tsclient\D\OraCD\11204_win64_template\p13390677_112040_MSWIN-x86-64_2of7.zip c:\app\software\database\ /D /E /Y /H /K

---edit
hostname
c:\app\software\RSP\db.rsp
--修改ORACLE_HOSTNAME主机名
检查oracle.install.OracleHomeUserPassword
--检查ORACLE_HOME
--检查ORACLE_BASE

 

cd c:\app\software\database
unzip p13390677_112040_MSWIN-x86-64_1of7.zip -d .
unzip p13390677_112040_MSWIN-x86-64_2of7.zip -d .
/

cd c:\app\software\
unzip p26194138_112040_MSWIN-x86-64.zip -d .\psu
unzip p26182427_112040_MSWIN-x86-64.zip -d .\ojvm
unzip -o p6880880_112000_MSWIN-x86-64.zip -d %ORACLE_HOME%\

/

copy D:\app\Administrator\product\11.2.0\dbhome_1\network\admin\*.ora %ORACLE_HOME%\network\admin\ /D /E /Y /H /K

cd c:\app\software\
%ORACLE_HOME%\OPatch\ocm\bin\emocmrsp.bat


--begin
cd C:\app\software\database\database

setup.exe -silent -debug -force -waitforcompletion -responseFile "C:\app\software\RSP\db.rsp"

--check c:\program files\oracle\inventory\logs\installaction*log

cd c:\app\software\


opatch apply -silent psu\26194138 -ocmrf ocm.rsp
opatch apply -silent ojvm\26182425 -ocmrf ocm.rsp

dbua

----升级时候勾选bakcup database

-- dbua -silent -dbname iypsdev\

--> -oracleHome %ORACLE_HOME% -sysDBAUserName sys \
--> -sysDBAPassword oracle123 -recompile_invalid_objects true -emConfiguration none

--check c:\app\product\cfgtoollogs\dbua\sid\upgrede1\trace.log(Oracle_server.log)

 

--because dbua will only apply psu sql file ,will not apply ovjm sql file, so will do it manaul.

cd %ORACLE_HOME%\sqlpatch\26182425
sqlplus /nolog
CONNECT sys/oracle123 AS SYSDBA
SHUTDOWN
STARTUP UPGRADE
@postinstall.sql
SHUTDOWN
STARTUP
QUIT
/

PS:
issue 1:MDSYS
PL/SQL: Statement ignored

CHECK Oracle_server.log , it can ignore


issue 2:
pls-00302 , because MDSYS delete_sdo,it can ignore
pls-00307
pls-00323

 

issue 3:
ora-00955 it can ignore (20 - 50 ignore)

enter 


issue 4:
ora-01921 it can ignore

issue 5:
ORA-04043 object DROP_AW_ELIST_ALL does not exist
if no ogg ,it can ignore ,or If OGG is being used, then the fix for this issue is included in Patch: 22457613 and Patch:22576728 (for newer patches see Document 1557031.1).

http://blog.csdn.net/yaluo009/article/details/51836756

 

issue 5

 

回退方案

http://blog.itpub.net/26175573/viewspace-1256585/

 

1.Stop all oracle service

 

2 rollback id.

cd \<OLD_ORAHOME>\admin\weixinprod\backup

 

run weixinprod_restore.bat

--checklist
col comp_id for a15
col version for a15
col comp_name for a30
select comp_id,comp_name,version from dba_registry ;
select object_name,owner from dba_objects where status='INVALID';

posted @ 2017-07-18 15:31  feiyun8616  阅读(2854)  评论(0编辑  收藏  举报