Hello
While doing some setup, I have came across a diskgroup (OCRDG) missing in CRS registry, however the diskgroup is present in the ASM instance and showing mounted.
[root@oinfo12c-rac1 ~]# crsctl stat res -t
--------------------------------------------------------------------------------
Name Target State Server State details
--------------------------------------------------------------------------------
Local Resources
--------------------------------------------------------------------------------
ora.DATA.dg
ONLINE ONLINE oinfo12c-rac1 STABLE
ONLINE ONLINE oinfo12c-rac2 STABLE
ora.LISTENER.lsnr
ONLINE ONLINE oinfo12c-rac1 STABLE
ONLINE OFFLINE oinfo12c-rac2 STABLE
ora.asm
ONLINE ONLINE oinfo12c-rac1 Started,STABLE
ONLINE ONLINE oinfo12c-rac2 Started,STABLE
ora.net1.network
ONLINE ONLINE oinfo12c-rac1 STABLE
ONLINE ONLINE oinfo12c-rac2 STABLE
ora.ons
ONLINE ONLINE oinfo12c-rac1 STABLE
ONLINE ONLINE oinfo12c-rac2 STABLE
As you see the output shows nothing about OCRDG, Lets look at asmcmd, and the OCRDG is present.
ASMCMD> lsdg
State Type Rebal Sector Block AU Total_MB Free_MB Req_mir_free_MB Usable_file_MB Offline_disks Voting_files Name
MOUNTED EXTERN N 512 4096 1048576 5114 773 0 773 0 Y DATA/
MOUNTED EXTERN N 512 4096 1048576 5114 4852 0 4852 0 N OCRDG/
Seems some permission issue, etc, do not want to spend much time on it. Just want to add it manually.
But hold there, srvctl does not have
srvctl add diskgroup
How to add it then?
We have crsctl commands which you can add resource, Trying my luck.
If you have a any other diskgroup present in the CRS as like mine (DATA diskgroup is there), Just copy and register it as like below
1) crsctl stat resource ora.DATA.dg -p > profile.txt
2) vi profile.txt
### Remove Name,Type from the file rest keep as is.
3) Add the resource
crsctl add resource ora.OCRDG.dg -type ora.diskgroup.type -file profile.txt
4) Check the status again
[root@oinfo12c-rac1 ~]# crsctl stat res -t
--------------------------------------------------------------------------------
Name Target State Server State details
--------------------------------------------------------------------------------
Local Resources
--------------------------------------------------------------------------------
ora.DATA.dg
ONLINE ONLINE oinfo12c-rac1 STABLE
ONLINE ONLINE oinfo12c-rac2 STABLE
ora.LISTENER.lsnr
ONLINE ONLINE oinfo12c-rac1 STABLE
ONLINE OFFLINE oinfo12c-rac2 STABLE
ora.OCRDG.dg
ONLINE ONLINE oinfo12c-rac1 STABLE
ONLINE ONLINE oinfo12c-rac2 STABLE
ora.asm
ONLINE ONLINE oinfo12c-rac1 Started,STABLE
ONLINE ONLINE oinfo12c-rac2 Started,STABLE
If you do not have any other diskgroup, try this
1. crsctl add resource ora.OCRDG.dg -type ora.diskgroup.type -attr ="ACL=owner:oracle:rwx,START_DEPENDENCIES=pullup:always(ora.asm) hard(ora.asm),VERSION=12.1.0.1.0"
This is should add the missing diskgroup.
Have fun.
GeekDBA
hi Geek DBA,
Nice explanation and live saving solution.
regards
Prasen.
Hi,
Thank you very much for this post, resolved my problem ! I was installing HAS on two machines in a RedHat active/passive cluster, so at first node I created the disk group with no problem, but at second node I needed only configure this DG for mount if a failover occur.
Best regards,
Régis