rac one node rolling PSU不停机打补丁

1. 准备工作(两节点均执行)

(1) upgrade grid's opatch version

root执行:

mv $GRID_HOME/OPatch $GRID_HOME/OPatch112034

cd  $GRID_HOME

unzip /soft/orasoft/p6880880_112000_Linux-x86-64.zip .

chown -R grid:oinstall OPatch

(2) upgrade oracle's opatch version

root执行:

mv $ORACLE_HOME/OPatch $ORACLE_HOME/OPatch112034

cd  $ORACLE_HOME

unzip /soft/orasoft/p6880880_112000_Linux-x86-64.zip .

chown -R oracle:oinstall OPatch

(3) unzip the PSU as grid user

su - grid

cd /tmp

unzip /soft/orasoft/p28813878_112040_Linux-x86-64.zip  

(4) Prepare the ocm.rsp file as grid user for patch apply

$GRID_HOME/OPatch/ocm/bin/emocmrsp  -no_banner -output /tmp/ocm.rsp

(5) precheck the conflicts  

su - grid

$GRID_HOME/OPatch/opatch lsinventory

su - oracle

$ORACLE_HOME/OPatch/opatch lsinventory

(6) check on which node the instance is running

su - oracle

srvctl status database -d cc

2. 用opatch auto同时给grid和oracle打补丁

(1) Apply PSU on the free node which has no instance running and check the results

su - root

$GRID_HOME/OPatch/opatch auto /tmp/28813878 -ocmrf /tmp/ocm.rsp

su - grid

$GRID_HOME/OPatch/opatch lsinventory

su - oracle

$ORACLE_HOME/OPatch/opatch lsinventory

(2) Relocate the instance to the patched node 

su - oracle

srvctl relocate database -d cc      -n node1

(3) Apply the PSU on the other node and check

su - root

$GRID_HOME/OPatch/opatch auto /tmp/28813878 -ocmrf /tmp/ocm.rsp

su - grid

$GRID_HOME/OPatch/opatch lsinventory

su - oracle

$ORACLE_HOME/OPatch/opatch lsinventory

(4)Apply sql patch into the existing instance

11g:

su - oracle

cd $ORACLE_HOME/rdbms/admin

exort ORACLE_SID=cc_1

$sqlplus ‘/as sysdba’

SQL> @catbundle.sql psu apply

SQL> @utlrp.sql

SQL>exit

12c:

su - oracle

$ORACLE_HOME/OPatch/datapatch -verbose

(5) Check if the sql patch is applied successfully

 select * from dba_registry_history;

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值