▣ ASM 설치
▣ Oracle 서비스 파일 이름 변경
[root@edrsr4p1 ~]# cd /etc/init.d
[root@edrsr4p1 init.d]# mv oracle oracle_old
▣ ASM을 위한 파티션 설정
[root@edrsr4p1 init.d]# ls /dev/sd*
/dev/sda /dev/sda1 /dev/sda2 /dev/sda3
[root@edrsr4p1 init.d]# fdisk /dev/sda
The number of cylinders for this disk is set to 1958.
There is nothing wrong with that, but this is larger than 1024,
and could in certain setups cause problems with:
1) software that runs at boot time (e.g., old versions of LILO)
2) booting and partitioning software from other OSs
(e.g., DOS FDISK, OS/2 FDISK)
Command (m for help): p
Disk /dev/sda: 16.1 GB, 16106127360 bytes
255 heads, 63 sectors/track, 1958 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 1230 9775552+ 83 Linux
/dev/sda3 1231 1421 1534207+ 82 Linux swap
Command (m for help): n
Command action
e extended
p primary partition (1-4)
e
Selected partition 4
First cylinder (1422-1958, default 1422):
Using default value 1422
Last cylinder or +size or +sizeM or +sizeK (1422-1958, default 1958):
Using default value 1958
Command (m for help): n
First cylinder (1422-1958, default 1422):
Using default value 1422
Last cylinder or +size or +sizeM or +sizeK (1422-1958, default 1958): +400M
Command (m for help): n
First cylinder (1472-1958, default 1472):
Using default value 1472
Last cylinder or +size or +sizeM or +sizeK (1472-1958, default 1958): +400M
Command (m for help): n
First cylinder (1522-1958, default 1522):
Using default value 1522
Last cylinder or +size or +sizeM or +sizeK (1522-1958, default 1958): +400M
Command (m for help): n
First cylinder (1572-1958, default 1572):
Using default value 1572
Last cylinder or +size or +sizeM or +sizeK (1572-1958, default 1958): +400M
Command (m for help): n
First cylinder (1622-1958, default 1622):
Using default value 1622
Last cylinder or +size or +sizeM or +sizeK (1622-1958, default 1958): +400M
Command (m for help): n
First cylinder (1672-1958, default 1672):
Using default value 1672
Last cylinder or +size or +sizeM or +sizeK (1672-1958, default 1958):
Using default value 1958
Command (m for help): p
Disk /dev/sda: 16.1 GB, 16106127360 bytes
255 heads, 63 sectors/track, 1958 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 1230 9775552+ 83 Linux
/dev/sda3 1231 1421 1534207+ 82 Linux swap
/dev/sda4 1422 1958 4313452+ 5 Extended
/dev/sda5 1422 1471 401593+ 83 Linux
/dev/sda6 1472 1521 401593+ 83 Linux
/dev/sda7 1522 1571 401593+ 83 Linux
/dev/sda8 1572 1621 401593+ 83 Linux
/dev/sda9 1622 1671 401593+ 83 Linux
/dev/sda10 1672 1958 2305296 83 Linux
Command (m for help): w
The partition table has been altered!
Calling ioctl() to re-read partition table.
WARNING: Re-reading the partition table failed with error 16: Device or resource busy.
The kernel still uses the old table.
The new table will be used at the next reboot.
Syncing disks.
▣ O/S 재부팅
[root@edrsr4p1 init.d]# reboot
Broadcast message from root (pts/4) (Wed Aug 19 11:23:00 2009):
The system is going down for system halt NOW!
▣ RAW 서비스 셋팅
[root@edrsr4p1 ~]# cat >> /etc/sysconfig/rawdevices << EOF => Hard disk를 장비로 인식 - O/S 버퍼를 따로 사용하지 않음
> /dev/raw/raw1 /dev/sda5
> /dev/raw/raw2 /dev/sda6
> /dev/raw/raw3 /dev/sda7
> /dev/raw/raw4 /dev/sda8
> /dev/raw/raw5 /dev/sda9
> /dev/raw/raw6 /dev/sda10
> EOF
[root@edrsr4p1 ~]# more /etc/sysconfig/rawdevices
# This file and interface are deprecated.
# Applications needing raw device access should open regular
# block devices with O_DIRECT.
# raw device bindings
# format: <rawdev> <major> <minor>
# <rawdev> <blockdev>
# example: /dev/raw/raw1 /dev/sda1
# /dev/raw/raw2 8 5
/dev/raw/raw1 /dev/sda5
/dev/raw/raw2 /dev/sda6
/dev/raw/raw3 /dev/sda7
/dev/raw/raw4 /dev/sda8
/dev/raw/raw5 /dev/sda9
/dev/raw/raw6 /dev/sda10
▣ RAW 서비스 재시작
[root@edrsr4p1 ~]# cd /etc/init.d/
[root@edrsr4p1 init.d]# ./rawdevices restart
Assigning devices:
/dev/raw/raw1 --> /dev/sda5
/dev/raw/raw1: bound to major 8, minor 5
/dev/raw/raw2 --> /dev/sda6
/dev/raw/raw2: bound to major 8, minor 6
/dev/raw/raw3 --> /dev/sda7
/dev/raw/raw3: bound to major 8, minor 7
/dev/raw/raw4 --> /dev/sda8
/dev/raw/raw4: bound to major 8, minor 8
/dev/raw/raw5 --> /dev/sda9
/dev/raw/raw5: bound to major 8, minor 9
/dev/raw/raw6 --> /dev/sda10
/dev/raw/raw6: bound to major 8, minor 10
done
▣ RAW device 확인
[root@edrsr4p1 raw]# raw -qa
/dev/raw/raw1: bound to major 8, minor 5
/dev/raw/raw2: bound to major 8, minor 6
/dev/raw/raw3: bound to major 8, minor 7
/dev/raw/raw4: bound to major 8, minor 8
/dev/raw/raw5: bound to major 8, minor 9
/dev/raw/raw6: bound to major 8, minor 10
[root@edrsr4p1 raw]#
[root@edrsr4p1 raw]# pwd
/dev/raw
[root@edrsr4p1 raw]# ls
raw1 raw2 raw3 raw4 raw5 raw6
▣ oracle 유저가 raw 디바이스에 접근 가능하도록 권한 변경
[root@edrsr4p1 raw]# pwd
/dev/raw
[root@edrsr4p1 raw]# chown oracle:oinstall *
[root@edrsr4p1 raw]# chmod 660 *
[root@edrsr4p1 raw]# ls -als
total 0
0 drwxr-xr-x 2 root root 160 Aug 19 12:30 .
0 drwxr-xr-x 11 root root 5680 Aug 19 12:29 ..
0 crw-rw---- 1 oracle oinstall 162, 1 Aug 19 12:30 raw1
0 crw-rw---- 1 oracle oinstall 162, 2 Aug 19 12:30 raw2
0 crw-rw---- 1 oracle oinstall 162, 3 Aug 19 12:30 raw3
0 crw-rw---- 1 oracle oinstall 162, 4 Aug 19 12:30 raw4
0 crw-rw---- 1 oracle oinstall 162, 5 Aug 19 12:30 raw5
0 crw-rw---- 1 oracle oinstall 162, 6 Aug 19 12:30 raw6
▣ 디바이스 자체에 대한 oracle 유저의 접근 권한 설정
[root@edrsr4p1 raw]# vi /etc/udev/permissions.d/50-udev.permissions
# raw devices
ram*:root:disk:0660
# raw/*:root:disk:0660
raw/*:oracle:oinstall:0660
▣ DBCA 설정
▣ 확인
▣ Migration
- High : Data를 2중으로 미러링합니다.
- Normal : 기본적인 미러링 구성입니다.
- External : ASM의 디스크를 미러링 하지 않습니다 이 옵션은 일반적으로 하드웨어 어레이가 구성된 경우에 사용합니다.
댓글 없음:
댓글 쓰기