어떠한 이점이 제공되는가 ?
> 관리 복잡성이 제거된다(스토리지 관리가 단순해 진다)
■ 매일 처리해야만 하는 스토리지 관리항목이 줄어들거나 제거된다
■ 모든 Application load에 대해 자동적인 I/O tuning이 수행된다.
■ 생성되는 데이터파일에 대해 의미 있는 이름이 자동적으로 부여된다.
■ 관리대상이 혁신적으로 줄어든다(파일시스템과 LVM 관리범위가 ASM Diskgroup으로 통합 관리됨).
■ 디스크 구성 변경이 쉽다(구성이 변경될 때, 자동적으로 데이터 재 분배가 일어남).
■ 실수로 파일을 삭제할 가능성 배제(파일시스템 상에 데이터파일이 있는 것이 아니기 때문).
> 스토리지 제품 구입비용 절약
■ Logical volume manager와 파일시스템 기능이 데이터베이스에 포함되어 있다.
■ 저렴한 JBOD 형태의 디스크부터 고가의 SAN 디스크 Array 까지 지원한다.
> 성능/확장성/안정성 증대
■ 모든 파일에 대해서 RAW disk 수준의 I/O 성능을 보장한다.
■ 다른 디스크 Array에 걸쳐 저장되어 있는 데이터파일 들에 대해 striping 할 수 있다.
■ 스토리지 활용도를 증대 시킨다.
■ 일반적인 파일시스템 크기 제한을 극복할 수 있다.
■ Software mirroring 지원
> RAC(Real Application Clusters) 지원
■ 3rd party Logical volume manager와 Cluster 파일시스템이 필요 없다.
■ Asm instance에 마운트되어 있는 모든 Disk group의 정보
SQL> select group_number,name,type,state from v$asm_diskgroup;
■ Disk에 대한 정보
: Disk group당 add되어 있는 디스크정보를 확인할 수 있습니다. asm인스턴스에서 쿼리시 diskgroup에 추가하지 않은 모든 disk가 포함되어 보여지며 db instance에서 쿼리시 사용중인 disk정보만 보여줍니다.
(아래는 asm instance에서 조회한 정보입니다.)
SQL> select group_number,disk_number,name,mount_status,path,total_mb
from v$asm_disk
■ Asm 인스턴스에 mount 된 disk group에 포함된 asm file에 대한 정보
(db instance 에서는 no rows로 보여짐)
SQL>select group_number,file_number,bytes,redundancy,type from v$asm_file;
■ Asm 인스턴스에 mount된 disk group에 있는 모든 template에 대한 정보
SQL> select * from v$asm_template where group_number=1;
■ V$ASM_ALIAS
Asm 인스턴스에 mount된 disk group에 있는 모든 alias에 대한 정보
■ V$ASM_OPERATION
Asm instance내에서 수행중인 active한 long running operation에 대한 정보
(db instance에서는 no rows로 보여짐)
■ V$ASM_CLIENT
Asm instance가 관리하는 disk group 을 사용하는 database에 대한 정보
1. oracleasm 데몬 설치
ocp@orcl : /home/oracle> su -
Password:
[root@ocp ~]# ls
anaconda-ks.cfg Desktop install.log install.log.syslog
[root@ocp ~]# cp /mnt/hgfs/shared/oracleasm* ./
[root@ocp ~]# ls
anaconda-ks.cfg oracleasm-2.6.9-42.ELsmp-2.0.3-1.i686.rpm
Desktop oracleasmlib-2.0.2-1.i386.rpm
install.log oracleasm-support-2.0.3-1.i386.rpm
install.log.syslog
[root@ocp ~]# rpm -Uvh oracleasm-support-2.0.3-1.i386.rpm \
> oracleasm-2.6.9-42.ELsmp-2.0.3-1.i686.rpm \
> oracleasmlib-2.0.2-1.i386.rpm
Preparing... ########################################### [100%]
1:oracleasm-support ########################################### [ 33%]
2:oracleasm-2.6.9-42.ELsm########################################### [ 67%]
3:oracleasmlib ########################################### [100%]
[root@ocp ~]# rpm -qa | grep oracleasm
oracleasmlib-2.0.2-1
oracleasm-2.6.9-42.ELsmp-2.0.3-1
oracleasm-support-2.0.3-1
[root@ocp ~]#
■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■
2. oracleasm 서비스 구성 및 활성화
ocp@orcl : /home/oracle/labs> su -
Password:
[root@ocp ~]# /etc/init.d/oracleasm configure
Configuring the Oracle ASM library driver.
This will configure the on-boot properties of the Oracle ASM library
driver. The following questions will determine whether the driver is
loaded on boot and what permissions it will have. The current values
will be shown in brackets ('[]'). Hitting <ENTER> without typing an
answer will keep that current value. Ctrl-C will abort.
Default user to own the driver interface []: oracle
Default group to own the driver interface []: oinstall
Start Oracle ASM library driver on boot (y/n) [n]: y
Fix permissions of Oracle ASM disks on boot (y/n) [y]: y
Writing Oracle ASM library driver configuration: [ OK ]
Loading module "oracleasm": [ OK ]
Mounting ASMlib driver filesystem: [ OK ]
Scanning system for ASM disks: [ OK ]
[root@ocp ~]# /etc/init.d/oracleasm enable
Writing Oracle ASM library driver configuration: [ OK ]
Scanning system for ASM disks: [ OK ]
[root@ocp ~]# /etc/init.d/oracleasm createdisk diskg1 /dev/sdb1
Marking disk "/dev/sdb1" as an ASM disk: [ OK ]
■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■
3. fdisk를 이용한 디스크 마운트 작업.
[root@ocp dev]# fdisk /dev/sdb
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-130, default 1):
Using default value 1
Last cylinder or +size or +sizeM or +sizeK (1-130, default 130):
Using default value 130
Command (m for help): w
The partition table has been altered!
Calling ioctl() to re-read partition table.
Syncing disks.
[root@ocp dev]# fdisk /dev/sdc
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-130, default 1):
Using default value 1
Last cylinder or +size or +sizeM or +sizeK (1-130, default 130):
Using default value 130
Command (m for help): w
The partition table has been altered!
Calling ioctl() to re-read partition table.
Syncing disks.
[root@ocp dev]# fdisk /dev/sdd
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-130, default 1):
Using default value 1
Last cylinder or +size or +sizeM or +sizeK (1-130, default 130):
Using default value 130
Command (m for help): w
The partition table has been altered!
Calling ioctl() to re-read partition table.
Syncing disks.
[root@ocp dev]# 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-130, default 1):
Using default value 1
Last cylinder or +size or +sizeM or +sizeK (1-130, default 130):
Using default value 130
Command (m for help): w
The partition table has been altered!
Calling ioctl() to re-read partition table.
Syncing disks.
[root@ocp dev]# 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-130, default 1):
Using default value 1
Last cylinder or +size or +sizeM or +sizeK (1-130, default 130):
Using default value 130
Command (m for help): w
The partition table has been altered!
Calling ioctl() to re-read partition table.
Syncing disks.
[root@ocp dev]# fdisk /dev/sdg
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-130, default 1):
Using default value 1
Last cylinder or +size or +sizeM or +sizeK (1-130, default 130):
Using default value 130
Command (m for help): w
The partition table has been altered!
Calling ioctl() to re-read partition table.
Syncing disks.
> 확인
[root@ocp ~]# fdisk -l
Disk /dev/sda: 21.4 GB, 21474836480 bytes
255 heads, 63 sectors/track, 2610 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sda1 * 1 13 104391 83 Linux
/dev/sda2 14 2610 20860402+ 8e Linux LVM
Disk /dev/sdb: 1610 MB, 1610612736 bytes
255 heads, 63 sectors/track, 195 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sdb1 1 195 1566306 83 Linux
Disk /dev/sdc: 1610 MB, 1610612736 bytes
255 heads, 63 sectors/track, 195 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sdc1 1 195 1566306 83 Linux
Disk /dev/sdd: 1610 MB, 1610612736 bytes
255 heads, 63 sectors/track, 195 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sdd1 1 195 1566306 83 Linux
Disk /dev/sde: 1610 MB, 1610612736 bytes
255 heads, 63 sectors/track, 195 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sde1 1 195 1566306 83 Linux
Disk /dev/sdf: 1610 MB, 1610612736 bytes
255 heads, 63 sectors/track, 195 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sdf1 1 195 1566306 83 Linux
Disk /dev/sdg: 1610 MB, 1610612736 bytes
255 heads, 63 sectors/track, 195 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sdg1 1 195 1566306 83 Linux
[root@ocp ~]#
■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■
4. oracleasm 서비스를 이용한 ASM diskgroup에 사용되는 disk 생성
[root@ocp ~]# cd /etc/init.d/
[root@ocp init.d]# ./oracleasm createdisk VOL1 /dev/sdb1
Marking disk "/dev/sdb1" as an ASM disk: [ OK ]
[root@ocp init.d]# ./oracleasm createdisk VOL2 /dev/sdc1
Marking disk "/dev/sdc1" as an ASM disk: [ OK ]
[root@ocp init.d]# ./oracleasm createdisk VOL3 /dev/sdd1
Marking disk "/dev/sdd1" as an ASM disk: [ OK ]
[root@ocp init.d]# ./oracleasm createdisk VOL4 /dev/sde1
Marking disk "/dev/sde1" as an ASM disk: [ OK ]
[root@ocp init.d]# ./oracleasm createdisk VOL5 /dev/sdf1
Marking disk "/dev/sdf1" as an ASM disk: [ OK ]
[root@ocp init.d]# ./oracleasm createdisk VOL6 /dev/sdg1
Marking disk "/dev/sdg1" as an ASM disk: [ OK ]
[root@ocp init.d]# ./oracleasm createdisk VOL7 /dev/sdh1
Marking disk "/dev/sdh1" as an ASM disk: [ OK ]
[root@ocp init.d]# ./oracleasm createdisk VOL8 /dev/sdi1
Marking disk "/dev/sdi1" as an ASM disk: [ OK ]
[root@ocp init.d]# ./oracleasm listdisks
VOL1
VOL2
VOL3
VOL4
VOL5
VOL6
VOL7
VOL8
■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■
5. dbca를 이용한 ASM instance 생성.
[root@ocp ~]# /u01/app/oracle/product/10.2.0/db_1/bin/localconfig add
[root@ocp ~]# ps -ef | grep cssd
[ocp@orcl : /home/oracle]$ dbca
dgroup01(VOL1, VOL2), dgroup02(VOL3, VOL4) 설정
> 각 disk group 추가 시 [Mount]를 그룹별로 재 수행 !!!
※
ocp@orcl : /home/oracle> emctl start dbconsole
[ocp@orcl : /home/oracle]$ su -
Password:
■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■
6. EM에 ASM instance 등록하기 (XML 이용)
ocp@+ASM : /home/oracle> vi asm.txt
<Target TYPE="osm_instance" NAME="+ASM" DISPLAY_NAME="+ASM">
<Property NAME="SID" VALUE="+ASM"/>
<Property NAME="MachineName" VALUE="ocp.mycorpdomain.com"/>
<Property NAME="OracleHome" VALUE="/u01/app/oracle/product/10.2.0/db_1"/>
<Property NAME="UserName" VALUE="sys"/>
<Property NAME="password" VALUE="oracle" ENCRYPTED="FALSE"/>
<Property NAME="Role" VALUE="sysdba"/>
<Property NAME="Port" VALUE="1521"/>
</Target>
:wq
ocp@orcl : /home/oracle> emctl config agent addtarget /home/oracle/asm.txt
TZ set to ROK
Oracle Enterprise Manager 10g Database Control Release 10.2.0.1.0
Copyright (c) 1996, 2005 Oracle Corporation. All rights reserved.
>> EM page에 ASM 등록하기...
■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■
7. +ASM instance 정보 조회
ocp@+ASM : /home/oracle> sqlplus 'sys/oracle as sysdba'
SQL> !vi disk_stat.sql
col path for a50
select group_number, path, mount_status from v$asm_disk_stat;
SQL> @disk_stat.sql
GROUP_NUMBER PATH MOUNT_STATUS
------------ ----------------------------------- ---------------------
0 ORCL:VOL5 CLOSED
0 ORCL:VOL6 CLOSED
0 ORCL:VOL7 CLOSED
0 ORCL:VOL8 CLOSED
1 ORCL:VOL1 CACHED
1 ORCL:VOL2 CACHED
2 ORCL:VOL3 CACHED
2 ORCL:VOL4 CACHED
6 rows selected.
SQL> !vi diskg.sql
col disk_name for a15
col header_status for a15
col group_name for a15
col state for a8
set linesize 150
set pagesize 200
SELECT A.GROUP_NUMBER ,A.NAME AS GROUP_NAME,B.DISK_NUMBER ,B.NAME AS DISK_NAME, B.HEADER_STATUS, B.STATE,B.FREE_MB
FROM V$ASM_DISKGROUP A INNER JOIN V$ASM_DISK B
ON (A.GROUP_NUMBER = B.GROUP_NUMBER);
set linesize 80
set pagesize 100
:wq
SQL> @diskg.sql
GROUP_NUMBER GROUP_NAME DISK_NUMBER DISK_NAME
------------ --------------- ----------- ------------------------------
1 DGROUP01 0 VOL1
1 DGROUP01 1 VOL2
2 DGROUP02 0 VOL3
2 DGROUP02 1 VOL4
SQL> create diskgroup dgroup03 normal redundancy disk
2 'ORCL:VOL5','ORCL:VOL6';
Diskgroup created.
SYS> @diskg.sql
GROUP_NUMBER GROUP_NAME DISK_NUMBER DISK_NAME
------------ --------------- ----------- ------------------------------
1 DGROUP01 0 VOL1
1 DGROUP01 1 VOL2
2 DGROUP02 0 VOL3
2 DGROUP02 1 VOL4
3 DGROUP03 0 VOL5
3 DGROUP03 1 VOL6
6 rows selected.
SYS> @disk_stat.sql
GROUP_NUMBER PATH MOUNT_STATUS
------------ -------------------------------------------------- --------------
0 ORCL:VOL7 CLOSED
0 ORCL:VOL8 CLOSED
1 ORCL:VOL1 CACHED
1 ORCL:VOL2 CACHED
2 ORCL:VOL3 CACHED
2 ORCL:VOL4 CACHED
3 ORCL:VOL5 CACHED
3 ORCL:VOL6 CACHED
8 rows selected.
SYS > !vi asm_disk.sql
col path for a20
col name for a20
select group_number, mount_status, path, name, total_mb
from v$asm_disk;
SYS > @asm_disk.sql
GROUP_NUMBER MOUNT_STATUS PATH NAME TOTAL_MB
----------------------------------------------------------------------
1 CACHED ORCL:VOL1 VOL1 1529
1 CACHED ORCL:VOL2 VOL2 1529
2 CACHED ORCL:VOL3 VOL3 1529
2 CACHED ORCL:VOL4 VOL4 1529
3 CACHED ORCL:VOL5 VOL5 1529
3 CACHED ORCL:VOL6 VOL6 1529
1 CACHED ORCL:VOL7 VOL7 1529
2 CACHED ORCL:VOL8 VOL8 1529
8 rows selected.
SYS> !vi asm_oper.sql
Set pages 1000
set lines 120
col name for a20
select d.name, o.operation, o.state, o.power, o.est_minutes
from v$asm_disk d, v$asm_operation o
where d.group_number=o.group_number
order by 1;
■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■
8. EM에서 +ASM 찾기
> orcl EM에 접속
> 호스트 : ocp.mycorpdomain.com 선택
> 상단 탭에 대상(target) 선택
> +ASM 이 보이면 선택
■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■
9. ASM DB shutdown에 대한 주의사항
[ASM DB shutdown]
- ASM instance가 일반 RDBMS에 연결되어 있다면 반드시 RDBMS를 우선 shutdown해야 함.
[ocp@+ASM : /home/oracle]$ asm
[ocp@+ASM : /home/oracle]$ ss
SQL*Plus: Release 10.2.0.1.0 - Production on Mon Jan 19 21:31:49 2009
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
SQL> shutdown immediate
ORA-15097: cannot SHUTDOWN ASM instance with connected RDBMS instance
-- 일반 RDBMS가 연결된 상태이므로 에러!!!
> DBCA를 이용하여 asmdb 구축.
[ocp@+ASM : /home/oracle]$ export ORACLE_SID=asmdb
[ocp@asmdb : /home/oracle]$ ss
SQL*Plus: Release 10.2.0.1.0 - Production on Mon Jan 19 21:33:36 2009
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
SQL> select instance_name, status from v$instance;
INSTANCE_NAME STATUS
---------------- ------------
asmdb OPEN
SQL> shutdown immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL>
###########################################################
[ocp@+ASM : /home/oracle]$ asm
[ocp@+ASM : /home/oracle]$ ss
SQL*Plus: Release 10.2.0.1.0 - Production on Mon Jan 19 21:34:17 2009
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
SQL> shutdown immediate
ASM diskgroups dismounted
ASM instance shutdown
###########################################################
■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■
10. asmcmd 사용하기
[ocp@+ASM : /home/oracle]$ export ORACLE_SID=asmdb
[ocp@asmdb : /home/oracle]$ ss
SQL> startup
SQL> select name from v$tablespace
2 union
3 select name from v$datafile;
NAME
--------------------------------------------------------------------------------
+DGROUP1/asmdb/datafile/example.265.676588417
+DGROUP1/asmdb/datafile/sysaux.257.676588349
+DGROUP1/asmdb/datafile/system.256.676588349
+DGROUP1/asmdb/datafile/undotbs1.258.676588349
+DGROUP1/asmdb/datafile/users.259.676588349
EXAMPLE
SYSAUX
SYSTEM
TEMP
UNDOTBS1
USERS
11 rows selected.
ocp@+ASM : /home/oracle> export ORACLE_SID=+ASM
ocp@+ASM : /home/oracle> asmcmd -p
ASMCMD [+] > help
asmcmd [-p] [command]
The environment variables ORACLE_HOME and ORACLE_SID determine the
instance to which the program connects, and ASMCMD establishes a
bequeath connection to it, in the same manner as a SQLPLUS / AS
SYSDBA. The user must be a member of the SYSDBA group.
Specifying the -p option allows the current directory to be displayed
in the command prompt, like so:
ASMCMD [+DATAFILE/ORCL/CONTROLFILE] >
[command] specifies one of the following commands, along with its
parameters.
Type "help [command]" to get help on a specific ASMCMD command.
commands:
--------
cd
du
find
help
ls
lsct
lsdg
mkalias
mkdir
pwd
rm
rmalias
ASMCMD [+] > ls
DISKG01/
DISKG02/
DISKG3/
ASMCMD [+] > cd DISKG01
ASMCMD [+DISKG01] > ls
ASMDB/
ASMCMD [+DISKG01] > cd ASMDB
ASMCMD [+DISKG01/ASMDB] > ls
1_3_672594117.dbf
ARCHIVELOG/
CONTROLFILE/
DATAFILE/
ONLINELOG/
PARAMETERFILE/
control01.ctl
control02.ctl
control03.ctl
redo01.log
redo02.log
redo03.log
spfileasmdb.ora
sysaux01.dbf
system01.dbf
ASMCMD [+DISKG01/ASMDB] > cd datafile
ASMCMD [+DISKG01/ASMDB/datafile] > ls
SYSAUX.256.672593963
SYSTEM.257.672593963
ASMCMD [+DISKG01/ASMDB/datafile] > du
Used_MB Mirror_used_MB
724 1450
EM에서도 확인가능!!!
■ tablespace ASM에 생성하기 ■
SQL> create tablespace sample datafile '+dgroup01';
Tablespace created.
SQL> select name from v$datafile;
NAME
--------------------------------------------------------------------------------
+DGROUP1/asmdb/datafile/system.256.676588349
+DGROUP1/asmdb/datafile/undotbs1.258.676588349
+DGROUP1/asmdb/datafile/sysaux.257.676588349
+DGROUP1/asmdb/datafile/users.259.676588349
+DGROUP1/asmdb/datafile/example.265.676588417
+DGROUP1/asmdb/datafile/sample.267.676590353
6 rows selected.
SQL> exit
Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
[ocp@asmdb : /home/oracle]$ asm
[ocp@+ASM : /home/oracle]$ asmcmd -p
ASMCMD [+] > ls
DGROUP1/
DGROUP2/
DISKG3/
ASMCMD [+] > cd dgroup1
ASMCMD [+dgroup1] > ls
ASMDB/
ASMCMD [+dgroup1] > cd asmdb
ASMCMD [+dgroup1/asmdb] > cd datafile
ASMCMD [+dgroup1/asmdb/datafile] > ls
EXAMPLE.265.676588417
SAMPLE.267.676590353
SYSAUX.257.676588349
SYSTEM.256.676588349
UNDOTBS1.258.676588349
USERS.259.676588349
ASMCMD [+dgroup1/asmdb/datafile] >
EM에서 생성!!
■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■
11. disk 추가하여 새로운 그룹 및 기존 disk group에 disk 추가하기.
ocp@+ASM : /home/oracle> asm
ocp@+ASM : /home/oracle> ss
SQL*Plus: Release 10.2.0.1.0 - Production on Tue Jul 14 21:47:51 2009
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
SYS> @disk_stat.sql
GROUP_NUMBER PATH MOUNT_STATUS
------------ -------------------------------------------------- --------------
0 ORCL:VOL7 CLOSED
0 ORCL:VOL8 CLOSED
1 ORCL:VOL1 CACHED
1 ORCL:VOL2 CACHED
2 ORCL:VOL3 CACHED
2 ORCL:VOL4 CACHED
3 ORCL:VOL5 CACHED
3 ORCL:VOL6 CACHED
8 rows selected.
SYS> alter diskgroup dgroup01 add disk 'ORCL:VOL7' rebalance power 10;
Diskgroup altered.
SYS> alter diskgroup dgroup02 add disk 'ORCL:VOL8' rebalance power 10;
Diskgroup altered.
SYS> @disk_stat.sql
GROUP_NUMBER PATH MOUNT_STATUS
------------ -------------------------------------------------- --------------
1 ORCL:VOL1 CACHED
1 ORCL:VOL2 CACHED
2 ORCL:VOL3 CACHED
2 ORCL:VOL4 CACHED
3 ORCL:VOL5 CACHED
3 ORCL:VOL6 CACHED
1 ORCL:VOL7 CACHED
2 ORCL:VOL8 CACHED
8 rows selected.
SYS> @diskg.sql
GROUP_NUMBER GROUP_NAME DISK_NUMBER DISK_NAME
------------ --------------- ----------- ------------------------------
1 DGROUP01 2 VOL7
1 DGROUP01 1 VOL2
1 DGROUP01 0 VOL1
2 DGROUP02 2 VOL8
2 DGROUP02 0 VOL3
2 DGROUP02 1 VOL4
3 DGROUP03 0 VOL5
3 DGROUP03 1 VOL6
8 rows selected.
SYS>
■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■
'oracle10R2' 카테고리의 다른 글
Row Chain 실습 (0) | 2011.06.20 |
---|---|
Logminer (0) | 2011.06.20 |
oracle 10g partition 적용 가이드 (0) | 2011.06.18 |
SQL Regular expression (0) | 2011.06.18 |
Oracle Database 10g:SQL Fundamentals (0) | 2011.06.17 |