RAC节点删除

版本:ORACLE RAC 11.2.0.1 redhat5.3
说明:节点三个,删除节点1和节点2,保留节点3
以下步骤删除节点1,节点2类同(略)。

一、删除数据库节点实例

通过节点3图形化界面调用dbca删除节点1和节点2上的实例(instance)

操作步骤如下:

1. 关闭数据库:
[[email protected] ~]$ sqlplus / as sysdba
SQL> shutdown immediate;
Database closed.
Database dismounted.
ORACLE instance shut down.

[[email protected] ~]$ srvctl status database -d racdb
Instance racdb1 is not running on node rac1
Instance racdb2 is running on node rac2
Instance racdb3 is running on node rac3

2.通过节点3调用dbca,删除节点1、2实例,如下图:
RAC节点删除
RAC节点删除
RAC节点删除

RAC节点删除

RAC节点删除我这里删除节点1实例时候异常,原因是之前配置的service服务,需要先卸载服务。

3. 验证:
[[email protected] ~]$ srvctl config database -d racdb
Database unique name: racdb
Database name: racdb
Oracle home: /u01/app/oracle/product/11.2.0/db_1
Oracle user: oracle
Spfile: +DATABASE/racdb/spfileracdb.ora
Domain:
Start options: open
Stop options: immediate
Database role: PRIMARY
Management policy: AUTOMATIC
Server pools: racdb
Database instances: racdb2,racdb3
Disk Groups: DATABASE
Services:
Database is administrator managed

二、删除Oracle节点软件

1.停掉节点1监听服务:
[[email protected] ~]$ srvctl stop listener -n rac1
PRCC-1017 : LISTENER was already stopped on rac1

[[email protected] ~]$ srvctl status listener -n rac1
Listener LISTENER is enabled on node(s): rac1
Listener LISTENER is not running on node(s): rac1

2.在节点1上更新节点列表信息
[[email protected] ~]# su - oracle
[[email protected] ~]$ cd $ORACLE_HOME

[[email protected] db_1]$ cd oui/bin/
[[email protected] bin]$ ./runInstaller -updateNodeList ORACLE_HOME=$ORACLE_HOME “CLUSTER_NODES={rac1}” -local
Starting Oracle Universal Installer…

Checking swap space: must be greater than 500 MB. Actual 3738 MB Passed
The inventory pointer is located at /etc/oraInst.loc
The inventory is located at /u01/app/oraInventory
‘UpdateNodeList’ was successful.

3.删除Oracle RAC软件
[[email protected] db_1]$ cd deinstall/
[[email protected] deinstall]$ ./deinstall -local
Checking for required files and bootstrapping …
Please wait …
RAC节点删除
4.在节点3上运行更新列表
[[email protected] ~]# su - oracle
[[email protected] ~]$ cd /u01/app/oracle/product/11.2.0/db_1/oui/bin/
[[email protected] bin]$ ./runInstaller -updateNodeList ORACLE_HOME=$ORACLE_HOME “CLUSTER_NODES={rac2,rac3}”
Starting Oracle Universal Installer…

Checking swap space: must be greater than 500 MB. Actual 2252 MB Passed
The inventory pointer is located at /etc/oraInst.loc
The inventory is located at /u01/app/oraInventory
‘UpdateNodeList’ was successful.

三、从集群中删除节点

1.查看节点情况:
[[email protected] ~]# su - grid
[[email protected] ~]$ olsnodes -s -t
rac1 Active Unpinned
rac2 Active Unpinned
rac3 Active Unpinned

如果节点为pinned,这:
RAC节点删除
2.删除节点(节点1)资源信息
[[email protected] install]# pwd
/u01/app/grid/product/11.2.0/grid/crs/install

[[email protected] install]# ./rootcrs.pl -deconfig -force
2020-11-19 12:13:07: Parsing the host name
2020-11-19 12:13:07: Checking for super user privileges
2020-11-19 12:13:07: User has super user privileges
Using configuration parameter file: ./crsconfig_params
VIP exists.:rac1
VIP exists.: /rac1-vip/192.168.190.13/255.255.255.0/eth0
VIP exists.:rac2
VIP exists.: /rac2-vip/192.168.190.14/255.255.255.0/eth0
VIP exists.:rac3
VIP exists.: /rac3-vip/192.168.190.24/255.255.255.0/eth0
GSD exists.
ONS daemon exists. Local port 6100, remote port 6200
eONS daemon exists. Multicast port 24328, multicast IP address 234.58.55.70, listening port 2016
ACFS-9200: Supported
CRS-2673: Attempting to stop ‘ora.registry.acfs’ on ‘rac1’
CRS-2677: Stop of ‘ora.registry.acfs’ on ‘rac1’ succeeded
CRS-2791: Starting shutdown of Oracle High Availability Services-managed resources on ‘rac1’
CRS-2673: Attempting to stop ‘ora.crsd’ on ‘rac1’
CRS-2790: Starting shutdown of Cluster Ready Services-managed resources on ‘rac1’
CRS-2673: Attempting to stop ‘ora.DATA.dg’ on ‘rac1’
CRS-2673: Attempting to stop ‘ora.DATABASE.dg’ on ‘rac1’
CRS-2677: Stop of ‘ora.DATA.dg’ on ‘rac1’ succeeded
CRS-2677: Stop of ‘ora.DATABASE.dg’ on ‘rac1’ succeeded
CRS-2673: Attempting to stop ‘ora.asm’ on ‘rac1’
CRS-2677: Stop of ‘ora.asm’ on ‘rac1’ succeeded
CRS-2792: Shutdown of Cluster Ready Services-managed resources on ‘rac1’ has completed
CRS-2677: Stop of ‘ora.crsd’ on ‘rac1’ succeeded
CRS-2673: Attempting to stop ‘ora.cssdmonitor’ on ‘rac1’
CRS-2673: Attempting to stop ‘ora.ctssd’ on ‘rac1’
CRS-2673: Attempting to stop ‘ora.evmd’ on ‘rac1’
CRS-2673: Attempting to stop ‘ora.asm’ on ‘rac1’
CRS-2673: Attempting to stop ‘ora.drivers.acfs’ on ‘rac1’
CRS-2673: Attempting to stop ‘ora.mdnsd’ on ‘rac1’
CRS-2677: Stop of ‘ora.cssdmonitor’ on ‘rac1’ succeeded
CRS-2677: Stop of ‘ora.mdnsd’ on ‘rac1’ succeeded
CRS-2677: Stop of ‘ora.ctssd’ on ‘rac1’ succeeded
CRS-2677: Stop of ‘ora.evmd’ on ‘rac1’ succeeded
CRS-2677: Stop of ‘ora.drivers.acfs’ on ‘rac1’ succeeded
CRS-2677: Stop of ‘ora.asm’ on ‘rac1’ succeeded
CRS-2673: Attempting to stop ‘ora.cssd’ on ‘rac1’
CRS-2677: Stop of ‘ora.cssd’ on ‘rac1’ succeeded
CRS-2673: Attempting to stop ‘ora.gpnpd’ on ‘rac1’
CRS-2673: Attempting to stop ‘ora.diskmon’ on ‘rac1’
CRS-2677: Stop of ‘ora.gpnpd’ on ‘rac1’ succeeded
CRS-2673: Attempting to stop ‘ora.gipcd’ on ‘rac1’
CRS-2677: Stop of ‘ora.gipcd’ on ‘rac1’ succeeded
CRS-2677: Stop of ‘ora.diskmon’ on ‘rac1’ succeeded
CRS-2793: Shutdown of Oracle High Availability Services-managed resources on ‘rac1’ has completed
CRS-4133: Oracle High Availability Services has been stopped.
Successfully deconfigured Oracle clusterware stack on this node

说明:
如果要删除多个节点,需要每个节点执行以上命令。
如果全部删除节点,在最后一个节点执行以下命令:
/u01/app/11.2.0/grid/crs/install/rootcrs.pl -deconfig -force -lastnode
-lastnode只能用于全部删除。

3.删除节点信息
[[email protected] bin]# ./crsctl delete node -n rac1
CRS-4661: Node rac1 successfully deleted.

4.更新列表信息
[[email protected] bin]# pwd
/u01/app/grid/product/11.2.0/grid/oui/bin

[[email protected] bin]$ ./runInstaller -updateNodeList ORACLE_HOME=$ORACLE_HOME “CLUSTER_NODES={rac1}” CRS=TRUE -silent -local
Starting Oracle Universal Installer…

Checking swap space: must be greater than 500 MB. Actual 3965 MB Passed
The inventory pointer is located at /etc/oraInst.loc
The inventory is located at /u01/app/oraInventory
‘UpdateNodeList’ was successful.

RAC节点删除

四、卸载GI目录

1.卸载节点目录
[[email protected] deinstall]$ ./deinstall -local
RAC节点删除

2.保留节点更新CRS 信息
[[email protected] ~]$ cd O R A C L E H O M E [ g r i d @ r a c 3 g r i d ] ORACLE_HOME [[email protected] grid] ORACLEHOME[grid@rac3grid] cd oui/bin/
[[email protected] bin]$ ./runInstaller -updateNodeList ORACLE_HOME=Grid_home “CLUSTER_NODES={rac2,rac3}” CRS=TRUE -silent

RAC节点删除

五、验证

1.cvu验证
[[email protected] bin]$ cluvfy stage -post nodedel -n rac1 -verbose

Performing post-checks for node removal
Checking CRS integrity…
The Oracle clusterware is healthy on node “rac2”
The Oracle clusterware is healthy on node “rac3”
CRS integrity check passed
Result:
Node removal check passed
Post-check for node removal was successful.

2.crsctl验证
RAC节点删除后续说明:
(1)删除节点2,略。
(2)添加新节点1和节点2,请看下章节。

相关文章:

  • 2022-12-23
  • 2021-10-13
  • 2022-12-23
  • 2022-01-15
  • 2021-06-29
  • 2022-12-23
  • 2021-12-09
  • 2022-02-16
猜你喜欢
  • 2021-06-12
  • 2021-10-13
  • 2021-10-24
  • 2022-12-23
  • 2022-12-23
  • 2021-05-05
  • 2021-07-05
相关资源
相似解决方案