Chinaunix首页 | 论坛 | 博客
  • 博客访问: 1014346
  • 博文数量: 584
  • 博客积分: 2293
  • 博客等级: 大尉
  • 技术积分: 3045
  • 用 户 组: 普通用户
  • 注册时间: 2006-03-28 11:15
文章分类

全部博文(584)

文章存档

2012年(532)

2011年(47)

2009年(5)

我的朋友

分类:

2012-03-27 10:05:29

前面几篇文章介绍了在Oracle 10203 for Solaris sparcRAC双节点环境中,新增一个节点的过程。这里描述删除节点的操作。

这一篇介绍Oracle Clusterware删除节点。

Oracle10203RAC环境删除节点(一):http://yangtingkun.itpub.net/post/468/495334


前面关闭了节点3上的数据库实例和ASM实例,这篇文章继续介绍清除CLUSTER节点的操作。

bash-2.03$ /data/oracle/product/10.2/crs/bin/crs_stat -t名称 类型 目标 状态 主机
------------------------------------------------------------
ora....SM1.asm application
ONLINE ONLINE racnode1
ora....E1.lsnr application
ONLINE ONLINE racnode1
ora....E1.lsnr application
ONLINE OFFLINE
ora....de1.gsd application
ONLINE ONLINE racnode1
ora....de1.ons application
ONLINE ONLINE racnode1
ora....de1.vip application
ONLINE ONLINE racnode1
ora....SM2.asm application
ONLINE ONLINE racnode2
ora....E2.lsnr application
ONLINE ONLINE racnode2
ora....E2.lsnr application
ONLINE OFFLINE
ora....de2.gsd application
ONLINE ONLINE racnode2
ora....de2.ons application
ONLINE ONLINE racnode2
ora....de2.vip application
ONLINE ONLINE racnode2
ora....SM3.asm application
OFFLINE OFFLINE
ora....E3.lsnr application
ONLINE ONLINE racnode3
ora....de3.gsd application
ONLINE ONLINE racnode3
ora....de3.ons application
ONLINE ONLINE racnode3
ora....de3.vip application
ONLINE ONLINE racnode3
ora....TRAC.cs application
OFFLINE OFFLINE
ora....ac1.srv application
OFFLINE OFFLINE
ora....ac2.srv application
OFFLINE OFFLINE
ora.testrac.db application
ONLINE ONLINE racnode1
ora....c1.inst application
ONLINE ONLINE racnode1
ora....c2.inst application
ONLINE ONLINE racnode2
ora....c3.inst application
OFFLINE OFFLINE

检查当前的CLUSTER状态。

首先清除srvctl工具中的实例和ASM配置信息。

bash-3.00$ srvctl status db -d testrac实例 testrac1 正在节点 racnode1 上运行实例 testrac2 正在节点 racnode2 上运行实例 testrac3 没有在 racnode3 节点上运行
bash-3.00$ srvctl remove inst -d testrac -i testrac3
是否从数据库 testrac 中删除实例 testrac3? (y/[n]) y
bash-3.00$ srvctl status asm -n racnode3
ASM
实例 +ASM3 不在节点 racnode3 上运行。

bash-3.00$ srvctl remove asm -n racnode3

然后利用racgons清除rac的配置信息,其中远端端口信息可以从$CRS_HOME/opmn/conf/ons.config文件中获取:

bash-2.03$ more /data/oracle/product/10.2/crs/opmn/conf/ons.config
localport=6100
remoteport=6200
loglevel=3
useocr=on
bash-2.03$ ./racgons remove_config racnode3:6200

下面利用root执行rootdelete.sh

bash-3.00$ su - 口令:
Sun Microsystems Inc.
SunOS 5.10 Generic January 2005
# bash
bash-3.00# cd /data/oracle/product/10.2/crs/install
bash-3.00# ./rootdelete.sh
Shutting down Oracle Cluster Ready Services (CRS):
Jun 16 16:46:12.850 | INF | daemon shutting down
Stopping resources.
Successfully stopped CRS resources
Stopping CSSD.
Shutting down CSS daemon.
Shutdown request successfully issued.
Shutdown has begun. The daemons should exit soon.
Checking to see if Oracle CRS stack is down...
Oracle CRS stack is not running.
Oracle CRS stack is down now.
Removing script for Oracle Cluster Ready services
Updating ocr file for downgrade
Cleaning up SCR settings in '/var/opt/oracle/scls_scr'

CLUSTER的安装节点racnode1上执行脚本:

# bash
bash-2.03# cd /data/oracle/product/10.2/crs/install
bash-2.03# ./rootdeletenode.sh racnode3,3
CRS-0210: Could not find resource 'ora.racnode3.LISTENER_RACNODE3.lsnr'.
PRKO-2112 : Some or all node applications are not removed successfully on node: racnode3
CRS nodeapps are deleted successfully
clscfg: EXISTING configuration version 3 detected.
clscfg: version 3 is 10G Release 2.
Successfully deleted 14 values from OCR.
Key SYSTEM.css.interfaces.noderacnode3 marked for deletion is not there. Ignoring.
Successfully deleted 5 keys from OCR.
Node deletion operation successful.
'racnode3,3' deleted successfully

再次检查CLUSTER配置:

bash-2.03$ crs_stat -t名称 类型 目标 状态 主机
------------------------------------------------------------
ora....SM1.asm application
ONLINE ONLINE racnode1
ora....E1.lsnr application
ONLINE ONLINE racnode1
ora....E1.lsnr application
ONLINE OFFLINE
ora....de1.gsd application
ONLINE ONLINE racnode1
ora....de1.ons application
ONLINE ONLINE racnode1
ora....de1.vip application
ONLINE ONLINE racnode1
ora....SM2.asm application
ONLINE ONLINE racnode2
ora....E2.lsnr application
ONLINE ONLINE racnode2
ora....E2.lsnr application
ONLINE OFFLINE
ora....de2.gsd application
ONLINE ONLINE racnode2
ora....de2.ons application
ONLINE ONLINE racnode2
ora....de2.vip application
ONLINE ONLINE racnode2
ora....TRAC.cs application
OFFLINE OFFLINE
ora....ac1.srv application
OFFLINE OFFLINE
ora....ac2.srv application
OFFLINE OFFLINE
ora.testrac.db application
ONLINE ONLINE racnode1
ora....c1.inst application
ONLINE ONLINE racnode1
ora....c2.inst application
ONLINE ONLINE racnode2
bash-2.03$ olsnodes -n
racnode1
1
racnode2
2

至此,CLUSTER清除的手工操作完成。

阅读(267) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~