Oracle 10g RAC 升级(CPU Update)之--升级数据库

系统环境:

操作系统:RedHat EL5

Cluster: Oracle CRS 10.2.0.1.0

Oracle:  Oracle 10.2.0.1.0


如图所示:RAC 系统架构

wKiom1NxgZPjSXZdAAGvUOVml00626.jpg

三、升级数据库

数据库的升级需要关闭DataBase,可以采用DBUA以图形的方式升级,也可以采用sqlplus 命令(catupgrd.sql 脚本),本案例采用dbua方式升级。

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
[root @node2  ~]# srvctl start listener -n node1
[root @node2  ~]# srvctl start listener -n node2
[root @node2  ~]# srvctl start asm -n node1
[root @node2  ~]# srvctl start asm -n node2
 
[root @node2  ~]# crs_stat -t
Name           Type           Target    State     Host        
------------------------------------------------------------
ora....SM1.asm application    ONLINE    ONLINE    node1       
ora....E1.lsnr application    ONLINE    ONLINE    node1       
ora.node1.gsd  application    ONLINE    ONLINE    node1       
ora.node1.ons  application    ONLINE    ONLINE    node1       
ora.node1.vip  application    ONLINE    ONLINE    node1       
ora....SM2.asm application    ONLINE    ONLINE    node2       
ora....E2.lsnr application    ONLINE    ONLINE    node2       
ora.node2.gsd  application    ONLINE    ONLINE    node2       
ora.node2.ons  application    ONLINE    ONLINE    node2       
ora.node2.vip  application    ONLINE    ONLINE    node2       
ora.prod.db    application    OFFLINE   OFFLINE               
ora....d1.inst application    OFFLINE   OFFLINE               
ora....d2.inst application    OFFLINE   OFFLINE

以Oracle身份,执行dbua 开始升级:

wKiom1Nxg3jiM6Z3AAV2XwN1Sb4604.jpg

执行dbua,开始升级

wKioL1Nxg2mjcYIsAAOxTHF3tnM620.jpg

选择“Update DataBase"

wKiom1Nxg-3zgSlAAAN7XIvDPAY925.jpg

升级数据库:prod

wKiom1NxhA2CG5BgAAMwV9oB8rQ052.jpg

升级后,编译失效Object

wKiom1NxhDTC9LsbAALSbusFURg411.jpg

指定Recovery Area

wKiom1NxhFnTNcrXAARy3oKLCUs754.jpg

升级summary

wKioL1NxhEbRhLwCAAPg3xgmLwQ024.jpg开始升级

wKioL1NxhFbhyD9xAARygTZYOIQ324.jpg

升级组件


升级完成后,在所有node执行以下脚本:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
[root@node1 ~]# su - oracle
[oracle@node1 ~]$ /u01/app/oracle/product/ 10.2. 0 /db_1/install/changePerm.sh 
-------------------------------------------------------------------------------
Disclaimer: The purpose of  this  script is to relax permissions  on  some of the
files  in  the database Oracle Home so that all clients can access them.
Please note that Oracle Corporation recommends using the most restrictive file
permissions  as  possible  for  your given implementation.  Running  this  script
should be done only  after  considering all security ramifications.
-------------------------------------------------------------------------------
Do you wish to  continue  (y/n) [n]: y
Spooling the error log /tmp/changePerm_err.log...
Finished running the script successfully
[oracle@node2 ~]$ /u01/app/oracle/product/ 10.2. 0 /db_1/install/changePerm.sh
-------------------------------------------------------------------------------
Disclaimer: The purpose of  this  script is to relax permissions  on  some of the
files  in  the database Oracle Home so that all clients can access them.
Please note that Oracle Corporation recommends using the most restrictive file
permissions  as  possible  for  your given implementation.  Running  this  script
should be done only  after  considering all security ramifications.
-------------------------------------------------------------------------------
Do you wish to  continue  (y/n) [n]: y
Spooling the error log /tmp/changePerm_err.log...
Finished running the script successfully

升级后验证:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
[oracle @node2  ~]$ sqlplus  '/as sysdba'
SQL*Plus: Release  10.2 . 0.4 . 0  - Production on Mon May  12  17 : 41 : 19  2014
Copyright (c)  1982 2007 , Oracle.  All Rights Reserved.
Connected to:
Oracle Database 10g Enterprise Edition Release  10.2 . 0.4 . 0  - Production
With the Partitioning, Real Application Clusters, OLAP, Data Mining
and Real Application Testing options
 
SQL> select instance_name,status from gv$instance;
INSTANCE_NAME    STATUS
---------------- ------------
prod2            OPEN
prod1            OPEN
SQL> col COMP_NAME  for  a40
SQL> col version  for  a30
SQL> set linesize  120
SQL> select comp_name,version,status from dba_registry
COMP_NAME                                VERSION                        STATUS
---------------------------------------- ------------------------------ ----------------------
Oracle Enterprise Manager                 10.2 . 0.4 . 0                      VALID
Spatial                                   10.2 . 0.4 . 0                      VALID
Oracle interMedia                         10.2 . 0.4 . 0                      VALID
OLAP Catalog                              10.2 . 0.4 . 0                      VALID
Oracle XML Database                       10.2 . 0.4 . 0                      VALID
Oracle Text                               10.2 . 0.4 . 0                      VALID
Oracle Expression Filter                  10.2 . 0.4 . 0                      VALID
Oracle Rule Manager                       10.2 . 0.4 . 0                      VALID
Oracle Workspace Manager                  10.2 . 0.4 . 3                      VALID
Oracle Data Mining                        10.2 . 0.4 . 0                      VALID
Oracle Database Catalog Views             10.2 . 0.4 . 0                      VALID
COMP_NAME                                VERSION                        STATUS
---------------------------------------- ------------------------------ ----------------------
Oracle Database Packages and Types        10.2 . 0.4 . 0                      VALID
JServer JAVA Virtual Machine              10.2 . 0.4 . 0                      VALID
Oracle XDK                                10.2 . 0.4 . 0                      VALID
Oracle Database Java Packages             10.2 . 0.4 . 0                      VALID
OLAP Analytic Workspace                   10.2 . 0.4 . 0                      VALID
Oracle OLAP API                           10.2 . 0.4 . 0                      VALID
Oracle Real Application Clusters          10.2 . 0.4 . 0                      VALID
18  rows selected.
 
[oracle @node2  ~]$ crs_stat -t
Name           Type           Target    State     Host        
------------------------------------------------------------
ora....SM1.asm application    ONLINE    ONLINE    node1       
ora....E1.lsnr application    ONLINE    ONLINE    node1       
ora.node1.gsd  application    ONLINE    ONLINE    node1       
ora.node1.ons  application    ONLINE    ONLINE    node1       
ora.node1.vip  application    ONLINE    ONLINE    node1       
ora....SM2.asm application    ONLINE    ONLINE    node2       
ora....E2.lsnr application    ONLINE    ONLINE    node2       
ora.node2.gsd  application    ONLINE    ONLINE    node2       
ora.node2.ons  application    ONLINE    ONLINE    node2       
ora.node2.vip  application    ONLINE    ONLINE    node2       
ora.prod.db    application    ONLINE    ONLINE    node2       
ora....d1.inst application    ONLINE    ONLINE    node1       
ora....d2.inst application    ONLINE    ONLINE    node2

@至此,RAC的升级任务全部完成,时长在4个小时左右!










本文转自 客居天涯 51CTO博客,原文链接:http://blog.51cto.com/tiany/1410272,如需转载请自行联系原作者
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值