What you need to know about OLR in the Oracle 11g GRID
1. Check the status of the OLR:
[Email protected] ~]# ocrcheck-local
Status of Oracle Local Registry is as follows:
Version:3
Total Space (Kbytes): 262120
Used Space (Kbytes): 2748
Available Space (Kbytes): 259372
id:935756415
Device/file Name:/U02/APP/11.2.0.3/GRID/CDATA/VMRAC1.OLR
Device/file Integrity Check Succeeded
Local Registry Integrity Check succeeded
Logical corruption Check Succeeded
2. Dump the contents of the OLR to a TXT document to view the contents of the OLR:
# Ocrdump-local-stdout
3. Export/Import the contents of OLR:
---export OLR
# ocrconfig–local–export file_name
/*file_name for import file, export file name, this file name is custom Eg:olr_myhost1_20090603_0130_export */
---import OLR:
# ocrconfig–local–import file_name
/*file_name for import file, export file name, this file name is custom Eg:olr_myhost1_20090603_0130_export */
Note
"Oracle recommends that's use the-manualbackup and-restorecommands and not the-importand-exportcommands.
"When exporting OLR, Oracle recommends including" OLR ", the host name, and the timestamp in the name string.
For Example:olr_myhost1_20090603_0130_export
4. Manual Backup OLR:
# Ocrconfig–local–manualbackup
The OLR will be upgraded once the grid is installed, or after the backup is completed. It will not be backed up automatically afterwards. Oracle recommends a manual backup of the OLR after the migration of the OCR store.
**OLR Default backup directory: Grid_home/cdata/host_name.
----Modify the OLR backup directory:
Ocrconfig-local-backuploc New_olr_backup_path
----View the contents of the OLR backup file:
Ocrdump-local-backupfile Olr_backup_file_name
It is important to note that Olr:ocrconfig-manualbackup and Ocrconfig-local-restore are used in a complementary, ocrconfig-local-export and Ocrconfig-local-impor T is a companion, which means that ocrconfig-local-export file_name exported files are not used as Ocrconfig-local-restore
5. Restore OLR:
To restore OLR:
----Stop CRS
# Crsctl Stop CRS
----Recovery OLR:
# Ocrconfig-local-restore file_name/*file_name is the file name in the OLR backup path and can be viewed by ocrconfig-local-showbackup */
-----Confirm the status of the OLR (check the logical integrity of the OLR content):
# ocrcheck-local
----Re-start CRS
# Crsctl Start CRS
----Verifying the integrity of OLR in the cluster using CVU (Note: Logical integrity of OLR content is not checked)
$ cluvfy Comp OLR
[email protected] ~]$ cluvfy Comp OLR
Verifying OLR Integrity
Checking OLR Integrity ...
Checking OLR config file ...
OLR Config file check successful
Checking OLR file Attributes ...
OLR file Check Successful
WARNING:
This check does not verify the integrity of the OLR contents. Execute ' ocrcheck-local ' as a privileged user to verify the
Contents of OLR.
OLR Integrity Check Passed
Verification of OLR Integrity was successful.