How to Restore ASM Based OCR when OCR backup is located in ASM diskgroup

1. Locate the latest automatic OCR backup:

- run the command as root user.

- the command works even when the cluster is down.

# <GI HOME>/bin/ocrconfig -showbackup
rac2 2018/11/03 08:55:57 +DATA:/<cluster name>/OCRBACKUP/backup00.ocr.274.991212953 0

rac2 2018/11/03 04:55:52 +DATA:/<cluster name>/OCRBACKUP/backup01.ocr.271.991198547 0

rac2 2018/11/03 00:55:45 +DATA:/<cluster name>/OCRBACKUP/backup02.ocr.276.991184139 0

rac2 2018/11/02 00:55:09 +DATA:/<cluster name>/OCRBACKUP/day.ocr.278.991097711 0

rac1 2018/10/22 07:11:01 +DATA:/<cluster name>/OCRBACKUP/week.ocr.273.990169863 0

If the command was run as a non privileged user (non root user), it errors as following:

[oracle@rac2 ~]$ ocrconfig -showbackup
PROT-20: Insufficient permission to proceed. Require privileged user
PROC-26: Error while accessing the physical storage Storage layer error [Insufficient quorum to open OCR devices] [0]

2. If the ASM instance can be started and if the disk group that has the OCR backup can be mounted, run below command as root user to restore OCR.

# <GI HOME>/bin/ocrconfig -restore <OCR backup file>

Example:
# <GI HOME>/bin/ocrconfig -restore +OCR_BKP:/<cluster name>/OCRBACKUP/backup00.ocr.260.991346585

3. If the disk group cannot be mounted, use below procedure.

NOTE: the below procedure assumes the disks part of the OCR backup disk group are available at OS.

- run the commands as grid OS user:

- the command will crate a OCR backup image file (.f extension) on the current directory.

$ <GI HOME>/bin/amdu -diskstring '<asm diskstring>' -extract <file name to extract>

Example:

$ <GI HOME>/bin/amdu -diskstring '/dev/xvd[c-i]1' -extract data.274  

Here data is the disk group name and 274 is the file number which can be found from +DATA:/<cluster name>/OCRBACKUP/backup00.ocr.274.991212953

4. The above amdu extract command will create a OCR backup image file on the current directory. Now the OCR can be restored using the procedure given in: How to Restore ASM Based OCR After Complete Loss of the CRS Diskgroup on Linux/Unix Systems (Doc ID 1062983.1)


來源資料:
How to Restore ASM Based OCR when OCR backup is located in ASM diskgroup? (Doc ID 2569847.1)

張貼留言

0 留言