How to add a new disk in ASM Filesystem:-
/dev/sdi1 259610368 538324 259072044 1% /flash4
/etc/init.d/oracleasm createdisk ASMDISK02
====
/etc/init.d/oracleasm createdisk ASMDISK02 /dev/sdi1
=====
ALTER DISKGROUP DBGROUP1 ADD DISK 'ORCL:ASMDISK02';
alter system set asm_diskstring='/dev/oracleasm/disks/*' scope=both;
ALTER DISKGROUP DBGROUP1 ADD DISK 'ORCL:ASMDISK02' NAME ASMDISK02 REBALANCE POWER 11;
ALTER DISKGROUP DBGROUP1 DROP DISK 'ORCL:ASMDISK02';
=============
select NAME, PATH, MOUNT_STATUS, HEADER_STATUS, MODE_STATUS, TOTAL_MB, FREE_MB
from v$asm_disk;
2. Add new ASM disks to the diskgroup:
alter diskgroup ORADB_DATA01_DG add disk 'ORCL:H_1253_1521';
alter diskgroup ORADB_DATA01_DG add disk 'ORCL:H_1253_1522';
alter diskgroup ORADB_DATA01_DG add disk 'ORCL:H_1253_1523';
alter diskgroup ORADB_DATA01_DG REBALANCE POWER 10; or
alter system set asm_power_limit=10 scope=memory;
-- Check the rebalance operation
select * from v$asm_operation;
Time taken to rebalance the diskgroup: app. 90 min.
3. Identify the disks to drop from the diskgroup:
set linesize 200;
col path format a20;
select NAME, PATH, MOUNT_STATUS, HEADER_STATUS, MODE_STATUS, TOTAL_MB, FREE_MB
from v$asm_disk;
ALTER DISKGROUP ORADB_DATA01_DG DROP DISK B_1530_1091;
ALTER DISKGROUP ORADB_DATA01_DG DROP DISK C_1530_1090;
ALTER DISKGROUP ORADB_DATA01_DG DROP DISK D_1530_1081;
alter diskgroup ORADB_DATA01_DG REBALANCE POWER 10; or
alter system set asm_power_limit=10 scope=memory;
-- Check the rebalance operation
select * from v$asm_operation;
====================
/etc/init.d/oracleasm createdisk ORA_G1D6 /dev/sdn1
ALTER DISKGROUP DBGROUP1 ADD DISK 'ORCL:ORA_G1D5';
ALTER DISKGROUP DBGROUP1 ADD DISK 'ORCL:ORA_G1D6';
ALTER DISKGROUP DBGROUP1 ADD DISK 'ORCL:ORA_G1D7';
ALTER DISKGROUP DBGROUP1 ADD DISK 'ORCL:ORA_G1D8';
alter diskgroup DBGROUP1 REBALANCE POWER 10;
ALTER DISKGROUP DBGROUP1 DROP DISK 'ORCL:ASMDISK02';
ORA_G1D1
ORA_G1D2
ORA_G1D3
ORA_G1D4
ORA_G1D5
ORA_G1D6
ORA_G1D7
ORA_G1D8
/dev/sdi1 259610368 538324 259072044 1% /flash4
/etc/init.d/oracleasm createdisk ASMDISK02
====
/etc/init.d/oracleasm createdisk ASMDISK02 /dev/sdi1
=====
ALTER DISKGROUP DBGROUP1 ADD DISK 'ORCL:ASMDISK02';
alter system set asm_diskstring='/dev/oracleasm/disks/*' scope=both;
ALTER DISKGROUP DBGROUP1 ADD DISK 'ORCL:ASMDISK02' NAME ASMDISK02 REBALANCE POWER 11;
ALTER DISKGROUP DBGROUP1 DROP DISK 'ORCL:ASMDISK02';
=============
select NAME, PATH, MOUNT_STATUS, HEADER_STATUS, MODE_STATUS, TOTAL_MB, FREE_MB
from v$asm_disk;
2. Add new ASM disks to the diskgroup:
alter diskgroup ORADB_DATA01_DG add disk 'ORCL:H_1253_1521';
alter diskgroup ORADB_DATA01_DG add disk 'ORCL:H_1253_1522';
alter diskgroup ORADB_DATA01_DG add disk 'ORCL:H_1253_1523';
alter diskgroup ORADB_DATA01_DG REBALANCE POWER 10; or
alter system set asm_power_limit=10 scope=memory;
-- Check the rebalance operation
select * from v$asm_operation;
Time taken to rebalance the diskgroup: app. 90 min.
3. Identify the disks to drop from the diskgroup:
set linesize 200;
col path format a20;
select NAME, PATH, MOUNT_STATUS, HEADER_STATUS, MODE_STATUS, TOTAL_MB, FREE_MB
from v$asm_disk;
ALTER DISKGROUP ORADB_DATA01_DG DROP DISK B_1530_1091;
ALTER DISKGROUP ORADB_DATA01_DG DROP DISK C_1530_1090;
ALTER DISKGROUP ORADB_DATA01_DG DROP DISK D_1530_1081;
alter diskgroup ORADB_DATA01_DG REBALANCE POWER 10; or
alter system set asm_power_limit=10 scope=memory;
-- Check the rebalance operation
select * from v$asm_operation;
====================
/etc/init.d/oracleasm createdisk ORA_G1D6 /dev/sdn1
ALTER DISKGROUP DBGROUP1 ADD DISK 'ORCL:ORA_G1D5';
ALTER DISKGROUP DBGROUP1 ADD DISK 'ORCL:ORA_G1D6';
ALTER DISKGROUP DBGROUP1 ADD DISK 'ORCL:ORA_G1D7';
ALTER DISKGROUP DBGROUP1 ADD DISK 'ORCL:ORA_G1D8';
alter diskgroup DBGROUP1 REBALANCE POWER 10;
ALTER DISKGROUP DBGROUP1 DROP DISK 'ORCL:ASMDISK02';
ORA_G1D1
ORA_G1D2
ORA_G1D3
ORA_G1D4
ORA_G1D5
ORA_G1D6
ORA_G1D7
ORA_G1D8
No comments:
Post a Comment