Windows+Oracle10G10.2.0.1Upgrade to 10.2.0.5 (一)

2014-11-24 12:11:02 · 作者: · 浏览: 0
一台测试的单机环境需要将10.2.0.1升级到10.2.0.5,升级步骤比较简单,在此简单记录下。
0. 停掉服务
进入服务管理(services.msc)将oracle的DBConsole、iSQL*Plus、Server和Listener全部停掉
1. 升级DBSOFTWARE
解压升级包,打开升级安装程序,选择已有的安装ORACLE_HOME和安装路径,一路next。安装完成后打开Listener、Server、DBConsole和iSQL*Plus服务。
2. 升级DATABASE
必须执行,否则无法使用已有 数据库
C:\Documents and Settings\ldy>sqlplus "/as sysdba"

SQL*Plus: Release 10.2.0.5.0 - Production on 星期三2月15 09:26:17 2012

Copyright (c) 1982, 2010, Oracle. All Rights Reserved.

已连接到空闲例程。

SQL> startup
ORACLE 例程已经启动。

Total System Global Area 1258291200 bytes
Fixed Size 2077232 bytes
Variable Size 318770640 bytes
Database Buffers 922746880 bytes
Redo Buffers 14696448 bytes
数据库装载完毕。
ORA-01092: ORACLE 实例终止。强制断开连接
这个时候去查看下alert.log:
--------------------
ORA-00704: 引导程序进程失败
ORA-39700: 必须用UPGRADE 选项打开数据库
--------------------
有2种选择:DBUA自动升级和手工脚本执行,两种方式都需要把server和listener服务启动起来。
2.1. DBUA
界面操作,没啥好用的,一路next下去,操作时间看你的选项(是否进行备份、移动数据文件等等操作)和数据库安装的组件,30分钟到50分钟不等。
2.2. SQLPLUS执行脚本升级
操作步骤如下
C:\Documents and Settings\ldy>sqlplus "/as sysdba"

SQL*Plus: Release 10.2.0.5.0 - Production on 星期三2月15 09:28:44 2012

Copyright (c) 1982, 2010, Oracle. All Rights Reserved.

已连接到空闲例程。

SQL> STARTUP UPGRADE
ORACLE 例程已经启动。

Total System Global Area 293601280 bytes
Fixed Size 1296356 bytes
Variable Size 92276764 bytes
Database Buffers 197132288 bytes
Redo Buffers 2895872 bytes
数据库装载完毕。
数据库已经打开。
SQL> SPOOL c:\upgrade_info.log
SQL> @ /rdbms/admin/utlu102i.sql;
Oracle Database 10.2 Upgrade Information Utility 02-15-2012 09:31:15
.
**********************************************************************
Database:
**********************************************************************
--> name: TEST
--> version: 10.2.0.1.0
--> compatible: 10.2.0.1.0
--> blocksize: 8192
.
**********************************************************************
Tablespaces: [make adjustments in the current environment]
**********************************************************************
--> SYSTEM tablespace is adequate for the upgrade.
.... minimum required size: 442 MB
.... AUTOEXTEND additional space required: 2 MB
--> UNDOTBS1 tablespace is adequate for the upgrade.
.... minimum required size: 403 MB
.... AUTOEXTEND additional space required: 173 MB
--> SYSAUX tablespace is adequate for the upgrade.
.... minimum required si