PeopleSoft

How To Recreate OCR/Voting Disk Accidentally Deleted

October 21, 2007 · 1 Comment

How to recreate OCR/Voting disk accidentally deleted

Goal

The goal of this document is to help customers who have accidentally deleted the OCR, voting disk or the files that are required for the operation of Oracle clusterware.

Depending on the issue, it may or may not be good idea to execute the steps provided.

* OCR
o If the OCR has been deleted, then check if the OCR mirror is OK and vice versa. It may be prudent to use the OCR mirror to create the OCR. For steps on this check the documentation Oracle® Database Oracle Clusterware and Oracle Real Application Clusters Administration and Deployment Guide
o If the OCR mirror and OCR have been deleted, then it may be faster to restore the OCR using the OCR backups. For steps on this check the documentation Oracle® Database Oracle Clusterware and Oracle Real Application Clusters Administration and Deployment Guide
* Voting Disk
o If there are multiple voting disks and one was accidentally deleted, then check if there are any backups of this voting disk. If there are no backups then we can add one using the crsctl add votedisk command. The complete steps are in the Oracle® Database Oracle Clusterware and Oracle Real Application Clusters Administration and Deployment Guide
* SCLS directories
o These are internal only directories which are created by root.sh, if this directory is accidentally removed then they can only be created by the steps documented below
* Socket files in /tmp/.oracle or /var/tmp/.oracle
o If these files are accidentally deleted, then stop the Oracle Clusterware on that node and restart it again. This will recreate these socket files. If the socket files for cssd is deleted then the Oracle Clusterware stack may not come down in which case the node has to be bounced.

Solution

If none of the steps documented above can be used to restore the file that was accidentally deleted or is corrupted, then the following steps can be used to re-create/reinstantiate these files. The following steps require complete downtime on all the nodes.

1. Shutdown the Oracle Clusterware stack on all the nodes using command crsctl stop crs as root user.
2. Backup the entire Oracle Clusterware home.
3. Execute /install/rootdelete.sh on all nodes
4. Execute /install/rootdeinstall.sh on the node which is supposed to be the first node
5. The following commands should return nothing
* ps -e | grep -i ‘ocs[s]d’
* ps -e | grep -i ‘cr[s]d.bin’
* ps -e | grep -i ‘ev[m]d.bin’
6. Execute /root.sh on first node
7. After successful root.sh execution on first node Execute root.sh on the rest of the nodes of the cluster
8. Add the database to the OCR using the appropriate srvctl add database command as the user who owns the database. Please ensure that this is not run as root user
9. Add ASM, DB, Instance, services using approproate srvctl add commands. Please refer to the documentation for the exact commands.
10. Add the listener using netca. This may give errors if the listener.ora contains the entries already. If this is the case, move the listener.ora to /tmp from the $ORACLE_HOME/network/admin or from the $TNS_ADMIN directory if the TNS_ADMIN environmental is defined and then run netca. Add all the listeners that were added earlier.
11. execute cluvfy stage -post crsinst -n node1,node2 ### Please ensure to replace node1,node2 with the node names of the cluster

@initialize OCR re-initialize OCR reinitialize recreate OCR ==> Added for improved searchability

Categories: Oracle
Tagged:

1 response so far ↓

  • automotive jacks // March 14, 2009 at 7:40 am | Reply

    It’s the first time I comment here and I must say you provide genuine, and quality information for bloggers! Great job.
    p.s. You have a very good template . Where did you find it?

Leave a Comment