The system i’ll be adding the disk on is a linux system using asmlib.
Current Set-up
In the current set-up we have 3 disks with 1 disk in the FLASH disk group and the 2 remaning disks in the DATA diskgroup
SQL> select PATH, HEADER_STATUS, MODE_STATUS, STATE from v$asm_disk;
PATH HEADER_STATU MODE_ST STATE
————— ———— ——- ——–
ORCL:VOLUA MEMBER ONLINE NORMAL
ORCL:VOLUB MEMBER ONLINE NORMAL
ORCL:VOLUC MEMBER ONLINE NORMAL
SQL> select name, type, total_mb, free_mb from v$asm_diskgroup;
NAME TYPE TOTAL_MB FREE_MB
—————————— —— ———- ———-
DATA EXTERN 4094 3273
FLASH EXTERN 2047 1820
Set-up the 2 new disks
We have 2 new disks added /dev/sde & /dev/sdf so we need to set-up a parttaion on these disks and configure them in asmlib
# fdisk /dev/sde
Device contains neither a valid DOS partition table, nor Sun, SGI or OSF disklabel
Building a new DOS disklabel. Changes will remain in memory only,
until you decide to write them. After that, of course, the previous
content won’t be recoverable.
Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite)
Command (m for help): n
Command action
e extended
p primary partition (1-4)
p
Partition number (1-4): 1
First cylinder (1-261, default 1):
Using default value 1
Last cylinder or +size or +sizeM or +sizeK (1-261, default 261):
Using default value 261
Command (m for help): w
The partition table has been altered!
Calling ioctl() to re-read partition table.
Syncing disks.
# fdisk /dev/sdf
Device contains neither a valid DOS partition table, nor Sun, SGI or OSF disklabel
Building a new DOS disklabel. Changes will remain in memory only,
until you decide to write them. After that, of course, the previous
content won’t be recoverable.
Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite)
Command (m for help): n
Command action
e extended
p primary partition (1-4)
p
Partition number (1-4): 1
First cylinder (1-261, default 1):
Using default value 1
Last cylinder or +size or +sizeM or +sizeK (1-261, default 261):
Using default value 261
Command (m for help): w
The partition table has been altered!
Calling ioctl() to re-read partition table.
Syncing disks.
#
# /etc/init.d/oracleasm createdisk VOLUD /dev/sde1
Marking disk “/dev/sde1” as an ASM disk: [ OK ]
# /etc/init.d/oracleasm createdisk VOLUE /dev/sdf1
Marking disk “/dev/sdf1” as an ASM disk: [ OK ]
# /etc/init.d/oracleasm listdisks
VOLUA
VOLUB
VOLUC
VOLUD
VOLUE
#
Create the new diskgroup
Now we can create the new diskgroup as we have the 2 new disks VOLUD & VOLUE
SQL> select PATH, NAME, HEADER_STATUS, MODE_STATUS, STATE from v$asm_disk;
PATH NAME HEADER_STATU MODE_ST STATE
————— —————————— ———— ——- ——–
ORCL: VOLUD PROVISIONED ONLINE NORMAL
ORCL:VOLUE PROVISIONED ONLINE NORMAL
ORCL:VOLUA VOLUA MEMBER ONLINE NORMAL
ORCL:VOLUB VOLUB MEMBER ONLINE NORMAL
ORCL:VOLUC VOLUC MEMBER ONLINE NORMAL
SQL> create diskgroup DATA2
2 external redundancy
3 disk ‘ORCL:VOLUD’, ‘ORCL:VOLUE’;
Diskgroup created.
SQL> select PATH, NAME, HEADER_STATUS, MODE_STATUS, STATE from v$asm_disk;
PATH NAME HEADER_STATU MODE_ST STATE
————— —————————— ———— ——- ——–
ORCL:VOLUA VOLUA MEMBER ONLINE NORMAL
ORCL:VOLUB VOLUB MEMBER ONLINE NORMAL
ORCL:VOLUC VOLUC MEMBER ONLINE NORMAL
ORCL:VOLUD VOLUD MEMBER ONLINE NORMAL
ORCL:VOLUE VOLUE MEMBER ONLINE NORMAL
SQL> select name, type, total_mb, free_mb from v$asm_diskgroup;
NAME TYPE TOTAL_MB FREE_MB
—————————— —— ———- ———-
DATA EXTERN 4094 3273
FLASH EXTERN 2047 1820
DATA2 EXTERN 4094 4042
DATA2 diskgroup created.
No comments:
Post a Comment