Knowledge Base

How to store Oracle Cluster Registry (OCR) for 11gR2 Oracle Clusterware

Applies to:

Operating System(s): RHEL 4.x, OEL 4.x, RHEL 5.x, OEL 5.x
Oracle Version(s): 11.2.x.x


Kai Yu


How do I store Oracle Cluster Registry for 11gR2 Oracle clusterware?


Oracle Cluster Registry (OCR) is a component of Oracle Clusterware that is used to store clusterware and RAC database configuration information such as the metadata for all the resources that the clusterware manages. Within Oracle’s clusterware, Oracle requires at least one OCR copy with the ability to add up to five copies of OCR. Oracle stores your OCR copies based on the number of ASM diskgroups allocated. For instance, one ASM diskgroup will result in one copy of OCR. However, multiple ASM diskgroups will result in multiple OCR copies, one stored within each ASM diskgroup.
NOTE: During Oracle 11gR2 fresh installation, Oracle only supports shared file system and ASM diskgroups for OCR. However, during Oracle 11gR2 upgrade OCR can be kept in its original location such as raw device or block device. It is recommended to move OCR from original location to an ASM diskgroup or shared file system after upgrade.

The following example displays multiple copies of OCR:
$ ocrcheck
Status of Oracle Cluster Registry is as follows :
Version : 3
Total space (kbytes) : 262120
Used space (kbytes) : 2860
Available space (kbytes) : 259260
ID : 2322227200
Device/File Name :+OCRVOTDS Device/File integrity check succeeded Device/File Name :+DATA1 Device/File integrity check succeeded
Device/File Name :+DATA2 Device/File integrity check succeeded
Device/File not configured
Device/File not configured
Cluster registry integrity check succeeded

In this example, there are three copies of OCR. They are stored in three ASM diskgroups +OCRVOTDSK, +DATA1, +DATA2 respectively.
NOTE: Since we only have three copies, the other two entries display as ‘Device/File not configured’.

During the clusterware installation, to specify the location of the OCR, you need to select either ASM or shared file system for the OCR.

Oracle Cluster Registry
Figure 1: Oracle Cluster Registry

The storage option chosen above will be used for both voting disk files and OCR. After the installation, additional copies of OCR can be added either on an ASM diskgroup or a shared file system.

For example, in order to add additional copies of OCR on a different ASM diskgroup, i.e. DATA3, you can use the following command:

$ocrconfig -add +DATA3

Another example would be to move the original OCR to a different ASM diskgroup OCR2 as shown below:

$ocrconfig –replace +OCRVOTDSK replacement +OCR2

An example on how to add an additional copy of your OCR on a shared file system labeled / u01/data:

$ocrconfig –add /u01/data/ocr.dbf

Article ID: SLN310272

Last Date Modified: 08/14/2018 02:53 AM

Rate this article

Easy to understand
Was this article helpful?
Yes No
Send us feedback
Comments cannot contain these special characters: <>()\
Sorry, our feedback system is currently down. Please try again later.

Thank you for your feedback.