Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to replace ocr and votingdisk disk groups

2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)05/31 Report--

This article mainly explains "how to replace ocr and votingdisk groups". The explanation in this article is simple and clear, easy to learn and understand. Please follow the ideas of Xiaobian slowly and deeply to study and learn "how to replace ocr and votingdisk disk groups" together!

#Replace OCR

[root@ray31 ~]# /u01/app/gridhome/product/11.2.0/grid_1/bin/ocrcheck

Status of Oracle Cluster Registry is as follows :

Version : 3

Total space (kbytes) : 262120

Used space (kbytes) : 2948

Available space (kbytes) : 259172

ID : 717216655

Device/File Name : +OCR

Device/File integrity check succeeded

Device/File not configured

Device/File not configured

Device/File not configured

Device/File not configured

Cluster registry integrity check succeeded

Logical corruption check succeeded

[root@ray31 ~]# /u01/app/gridhome/product/11.2.0/grid_1/bin/ocrconfig -add +OCR02

[root@ray31 ~]# /u01/app/gridhome/product/11.2.0/grid_1/bin/ocrcheck

Status of Oracle Cluster Registry is as follows :

Version : 3

Total space (kbytes) : 262120

Used space (kbytes) : 2964

Available space (kbytes) : 259156

ID : 717216655

Device/File Name : +OCR

Device/File integrity check succeeded

Device/File Name : +OCR02

Device/File integrity check succeeded

Device/File not configured

Device/File not configured

Device/File not configured

Cluster registry integrity check succeeded

Logical corruption check succeeded

[root@ray31 ~]# /u01/app/gridhome/product/11.2.0/grid_1/bin/ocrconfig -delete +OCR

[root@ray31 ~]# /u01/app/gridhome/product/11.2.0/grid_1/bin/ocrcheck

Status of Oracle Cluster Registry is as follows :

Version : 3

Total space (kbytes) : 262120

Used space (kbytes) : 2964

Available space (kbytes) : 259156

ID : 717216655

Device/File Name : +OCR02

Device/File integrity check succeeded

Device/File not configured

Device/File not configured

Device/File not configured

Device/File not configured

Cluster registry integrity check succeeded

Logical corruption check succeeded

#Replace votingdisk

[root@ray31 ~]# /u01/app/gridhome/product/11.2.0/grid_1/bin/crsctl query css votedisk

## STATE File Universal Id File Name Disk group

-- ----- ----------------- --------- ---------

1. ONLINE 062be79c0d644f2ebf102c21b47b3f3b (/dev/sdb) [OCR]

Located 1 voting disk(s).

[root@ray31 ~]# /u01/app/gridhome/product/11.2.0/grid_1/bin/crsctl replace votedisk +OCR02

Successful addition of voting disk 082d31c3fd1e4f5ebf0310f8cef501d8.

Successful deletion of voting disk 062be79c0d644f2ebf102c21b47b3f3b.

Successfully replaced voting disk group with +OCR02.

CRS-4266: Voting file(s) successfully replaced

[root@ray31 ~]# /u01/app/gridhome/product/11.2.0/grid_1/bin/crsctl query css votedisk

## STATE File Universal Id File Name Disk group

-- ----- ----------------- --------- ---------

1. ONLINE 082d31c3fd1e4f5ebf0310f8cef501d8 (/dev/sde) [OCR02]

Located 1 voting disk(s).

#Migrate asm instance spfile

SQL> conn / as sysdba

Connected.

SQL> show parameter pfile;

NAME TYPE VALUE

------------------------------------ ----------- ------------------------------

spfile string +OCR/raccluster/asmparameterfi

le/registry.253.1019126787

SQL> create pfile='/home/grid/initASM.ora' from spfile;

File created.

[root@ray31 ~]# /u01/app/gridhome/product/11.2.0/grid_1/bin/srvctl stop instance -d racdb -n ray32

[root@ray31 ~]# /u01/app/gridhome/product/11.2.0/grid_1/bin/srvctl stop instance -d racdb -n ray31

[root@ray31 ~]# /u01/app/gridhome/product/11.2.0/grid_1/bin/srvctl stop asm -o abort -f

SQL> startup pfile='/home/grid/initASM.ora';

ASM instance started

Total System Global Area 1135747072 bytes

Fixed Size 2260728 bytes

Variable Size 1108320520 bytes

ASM Cache 25165824 bytes

ASM diskgroups mounted

SQL> show parameter spfile

NAME TYPE VALUE

------------------------------------ ----------- ------------------------------

spfile string

SQL> create spfile='+OCR02' from pfile='/home/grid/initASM.ora';

File created.

[root@ray31 ~]# /u01/app/gridhome/product/11.2.0/grid_1/bin/srvctl stop asm -o abort -f

[grid@ray31 ~]$ sqlplus /nolog

SQL*Plus: Release 11.2.0.4.0 Production on Mon Nov 18 15:57:40 2019

Copyright (c) 1982, 2013, Oracle. All rights reserved.

SQL> conn / as sysasm

Connected to an idle instance.

SQL> startup

ASM instance started

Total System Global Area 1135747072 bytes

Fixed Size 2260728 bytes

Variable Size 1108320520 bytes

ASM Cache 25165824 bytes

ASM diskgroups mounted

SQL> show parameter spfile

NAME TYPE VALUE

------------------------------------ ----------- ------------------------------

spfile string +OCR02/raccluster/asmparameter

file/registry.253.1024674953

SQL>

[root@ray31 ~]# /u01/app/gridhome/product/11.2.0/grid_1/bin/crsctl stop cluster -all

[root@ray31 ~]# /u01/app/gridhome/product/11.2.0/grid_1/bin/crsctl start cluster -all

#Delete disk group

#Executed at other nodes

SQL> alter diskgroup ocr dismount;

Diskgroup altered.

#One of the nodes performs a delete disk group

SQL> drop diskgroup OCR including contents;

Diskgroup dropped.

Thank you for reading, the above is "how to replace ocr and votingdisk group" content, after the study of this article, I believe we have a deeper understanding of how to replace ocr and votingdisk group, the specific use of the situation also needs to be verified by practice. Here is, Xiaobian will push more articles related to knowledge points for everyone, welcome to pay attention!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report