11gR2CRSRAC

Adding OCR and Voting Disk on NFS mount – 11gR2

From 11gR2 as the OCR and voting disk are stored on ASM storage the grid installer doesn’t show the option to specify multiple OCR and voting disk locations.We have the ocr and voting disk stored on NFS mounted file system and during the installation only one location was specified.

xx4040: (test1) /anand> crsctl query crs activeversion
Oracle Clusterware active version on the cluster is [11.2.0.2.0]
xx4040: (test1) /anand> ocrcheck
Status of Oracle Cluster Registry is as follows :
         Version                  :          3
         Total space (kbytes)     :     262120
         Used space (kbytes)      :       3232
         Available space (kbytes) :     258888
         ID                       : 2122021496
         Device/File Name         : /u01/oraadmin/test/CRS_DISK/ocr
                                    Device/File integrity check succeeded
                                    Device/File not configure
                                    ......
         Cluster registry integrity check succeeded
         Logical corruption check bypassed due to non-privileged user
xx4040: (test1) /anand> crsctl query css votedisk
##  STATE    File Universal Id                File Name Disk group
--  -----    -----------------                --------- ---------
 1. ONLINE   2a7efe06a2e04f61bfd833fqsd354ec02 (/u01/oraadmin/test/CRS_DISK/vdsk) []
Located 1 voting disk(s).

These are the files created during the installation. As we need multiple OCR and voting disk it was time to add them.The ocr and voting disk has to be added to /u02/oraadmin/test/CRS_DISK location.
To add the ocr and voting disk the commands needs to be executed as ROOT user.Before adding/change make sure you have the latest backup using ocrconfig -showbackup

[[email protected] test]# cd /u01/app/grid/11.2.0.2/bin/
[[email protected] bin]# ./ocrconfig -add /u02/oraadmin/test/CRS_DISK/ocr
PROT-30: The Oracle Cluster Registry location to be added is not accessible
PROC-8: Cannot perform cluster registry operation because one of the parameters is invalid. Operating System error [No such file or directory] [2]
[[email protected] bin]#

For running the command successfully, the device should already exists.

[[email protected] test]# cd CRS_DISK/
[[email protected] CRS_DISK]# ls -lrt
total 0
[[email protected] CRS_DISK]# touch ocr
[[email protected] CRS_DISK]# ls -lrt
total 1
-rw-r--r-- 1 root root 0 Oct 12 00:52 ocr
[[email protected] CRS_DISK]# chown root:dba ocr
[[email protected] CRS_DISK]# ls -lrt
total 1
-rw-r--r-- 1 root dba 0 Oct 12 00:52 ocr
[[email protected] CRS_DISK]# chmod 640 ocr
[[email protected] CRS_DISK]# ls -lrt
total 1
-rw-r----- 1 root dba 0 Oct 12 00:52 ocr

As ocr device is created, execute the ocrconfig -add to add another ocr

[[email protected] CRS_DISK]# cd /u01/app/grid/11.2.0.2/bin/
[[email protected] bin]# ./ocrconfig -add /u02/oraadmin/test/CRS_DISK/ocr
[[email protected] bin]# cd /u02/oraadmin/test/CRS_DISK
[[email protected] CRS_DISK]# ls -lrt
total 7689
-rw-r----- 1 root dba 272756736 Oct 12 00:55 ocr
[[email protected] bin]# ./ocrcheck
Status of Oracle Cluster Registry is as follows :
         Version                  :          3
         Total space (kbytes)     :     262120
         Used space (kbytes)      :       3232
         Available space (kbytes) :     258888
         ID                       : 2122021496
         Device/File Name         : /u01/oraadmin/test/CRS_DISK/ocr
                                    Device/File integrity check succeeded
         Device/File Name         : /u02/oraadmin/test/CRS_DISK/ocr
                                    Device/File integrity check succeeded
                                    .........
         Cluster registry integrity check succeeded
         Logical corruption check succeeded
[[email protected] bin]# cat /etc/oracle/ocr.loc
#Device/file  getting replaced by device /u02/oraadmin/test/CRS_DISK/ocr
ocrconfig_loc=/u01/oraadmin/test/CRS_DISK/ocr
ocrmirrorconfig_loc=/u02/oraadmin/test/CRS_DISK/ocr

The ocr is added, now got to add voting disk.From 11.1 we can use crsctl add css votedisk online. Till 10.2 versions we had to shutdown the clusterware (crsctl stop crs) on all the nodes before adding/making any changes to the voting disk.
In a similar fashion to ocr, i created/touced vdsk in /u02/oraadmin/test/CRS_DISK/ location and gave proper permissions and ownership.

-rw-r----- 1 oracle dba         0 Oct 12 01:12 vdsk
[[email protected] bin]# ./crsctl add css votedisk /u02/oraadmin/test/CRS_DISK/vdsk
Now formatting voting disk: /u02/oraadmin/test/CRS_DISK/vdsk.
Failed to initialize voting file /u02/oraadmin/test/CRS_DISK/vdsk.
Change to configuration failed, but was successfully rolled back.
CRS-4000: Command Add failed, or completed with errors.

Removed the vdsk from /u02/oraadmin/test/CRS_DISK and executed the command again

[[email protected] bin]# rm /u02/oraadmin/test/CRS_DISK/vdsk
[[email protected] bin]#
[[email protected] bin]#
[[email protected] bin]# ./crsctl add css votedisk /u02/oraadmin/test/CRS_DISK/vdsk
Now formatting voting disk: /u02/oraadmin/test/CRS_DISK/vdsk.
CRS-4603: Successful addition of voting disk /u02/oraadmin/test/CRS_DISK/vdsk.
[[email protected] bin]#
xx4040: (test1) /anand> crsctl query css votedisk
##  STATE    File Universal Id                File Name Disk group
--  -----    -----------------                --------- ---------
 1. ONLINE   2a7efe06a2e04f61bfd833f52054ec02 (/u01/oraadmin/test/CRS_DISK/vdsk) []
 2. ONLINE   aec514d603aa4fbbbf83c2768f8b6afc (/u02/oraadmin/test/CRS_DISK/vdsk) []

To verify OCR and voting disk integrity after adding them use cluvfy comp ocr -verbose and cluvfy comp vdisk -verbose respectively.

2 thoughts on “Adding OCR and Voting Disk on NFS mount – 11gR2

Leave a Reply