dba:rac_asm_reame_group_disks
Inhaltsverzeichnis
Oracle 12c - ASM Disk Gruppen und ASM Disks in einer Gruppe umbenennen
Eine leere Disk Gruppe umbennen
Bei einer leeren Gruppe ist das einfach, bei einer Gruppe mit Daten sorgfältig die Doku von Oracle (siehe link unten) prüfen!
Diskgruppe von allen Knoten weg mounten:
ALTER diskgroup VOT dismount;
Umbenennen mit renamedg :
renamedg dgname=VOT newdgname=VOTNFS asm_diskstring='/dev/oracleasm/disks/*,/opt/oracle/VOTNFSDISK/vote_nfs_disk01' verbose=true Parsing parameters.. Parameters in effect: Old DG name : VOT New DG name : VOTNFS Phases : Phase 1 Phase 2 Discovery str : /dev/oracleasm/disks/*,/opt/oracle/VOTNFSDISK/vote_nfs_disk01 Clean : TRUE Raw only : TRUE renamedg operation: dgname=VOT newdgname=VOTNFS asm_diskstring=/dev/oracleasm/disks/*,/opt/oracle/VOTNFSDISK/vote_nfs_disk01 verbose=true Executing phase 1 Discovering the group Performing discovery with string:/dev/oracleasm/disks/*,/opt/oracle/VOTNFSDISK/vote_nfs_disk01 Identified disk UFS:/dev/oracleasm/disks/VOT1_02 with disk number:3 and timestamp (33039887 -1916262400) Identified disk UFS:/dev/oracleasm/disks/VOT1 with disk number:0 and timestamp (33039532 -1177383936) Identified disk UFS:/opt/oracle/VOTNFSDISK/vote_nfs_disk01 with disk number:2 and timestamp (33039765 973622272) Checking for hearbeat... Re-discovering the group Performing discovery with string:/dev/oracleasm/disks/*,/opt/oracle/VOTNFSDISK/vote_nfs_disk01 Identified disk UFS:/dev/oracleasm/disks/VOT1_02 with disk number:3 and timestamp (33039887 -1916262400) Identified disk UFS:/dev/oracleasm/disks/VOT1 with disk number:0 and timestamp (33039532 -1177383936) Identified disk UFS:/opt/oracle/VOTNFSDISK/vote_nfs_disk01 with disk number:2 and timestamp (33039765 973622272) Checking if the diskgroup is mounted or used by CSS Checking disk number:3 Checking disk number:0 Checking disk number:2 Generating configuration file.. Completed phase 1 Executing phase 2 Looking for /dev/oracleasm/disks/VOT1_02 Modifying the header Looking for /dev/oracleasm/disks/VOT1 Modifying the header Looking for /opt/oracle/VOTNFSDISK/vote_nfs_disk01 Modifying the header Completed phase 2 Terminating kgfd context 0x7f21b22650a0
Gruppe wieder neu anmelden:
ALTER diskgroup VOTNFS mount;
siehe https://docs.oracle.com/database/121/OSTMG/GUID-45A0F079-2D23-47D3-A366-569076D2F845.htm#OSTMG94159
Im Cluster umbenennen
Nach dem Umbennen die Ressource auch im Cluster freigeben, damit der alte Name der Disk Group nicht als Offline angezeigt wird.
crs_stat -t Name Type Target State Host ------------------------------------------------------------ ... ora.VOT.dg ora....up.type OFFLINE OFFLINE srvctl status diskgroup -diskgroup VOT Disk Group VOT is not running srvctl remove diskgroup -diskgroup VOT #Offline Resource verschwunden!
Disk Namen anpassen
Auf beiden Knoten dismounten:
ALTER diskgroup VOTNFS dismount;
Auf Knoten 1 im Restrict Modus mounten:
ALTER DISKGROUP VOTNFS MOUNT RESTRICTED;
Umbenennen:
#prüfen SELECT d.name , d.path FROM v$asm_disk d INNER JOIN v$asm_diskgroup g ON ( d.group_number=g.group_number) WHERE g.name = 'VOTNFS'; Disk Disk Name path -------------------- ------------------------------ VOTAS1 /dev/oracleasm/disks/VOT1_02 VOT1S1 /dev/oracleasm/disks/VOT1 VOT_0002 /opt/oracle/VOTNFSDISK/vote_nfs_disk01 # umbenennen ALTER DISKGROUP VOTNFS RENAME DISK 'VOTAS1' TO 'VOT1S1', 'VOT_0002' TO 'VOT1NFS'; # prüfen SELECT d.name , d.path FROM v$asm_disk d INNER JOIN v$asm_diskgroup g ON ( d.group_number=g.group_number) WHERE g.name = 'VOTNFS'; Disk Disk Name path -------------------- ------------------------------ VOT1S2 /dev/oracleasm/disks/VOT1_02 VOT1S1 /dev/oracleasm/disks/VOT1 VOT1NFS /opt/oracle/VOTNFSDISK/vote_nfs_disk01
Wieder „richtig“ mounten:
ALTER diskgroup VOTNFS dismount; ALTER diskgroup VOTNFS mount;
Auf allen Knoten!
⇒ https://docs.oracle.com/database/121/OSTMG/GUID-A2E82BE6-BE5E-42F8-8723-03DF5CD55D90.htm#OSTMG95706
dba/rac_asm_reame_group_disks.txt · Zuletzt geändert: 2016/09/23 10:17 von gpipperr