참고글 및 문제해결/관련, 참고글

RHEL5 rawdevice 사용하기(bind, permission설정)

에몽이ㅋ 2012. 3. 14. 22:19
아래 파일을 디스크에 맞게 수정합니다.

각 디스크 파티션작업 후

vi /etc/udev/rules.d/60-raw.rules

ACTION=="add", KERNEL=="sdb1", RUN+="/bin/raw /dev/raw/raw1 %N"
ACTION=="add", KERNEL=="sdc1", RUN+="/bin/raw /dev/raw/raw2 %N"
ACTION=="add", KERNEL=="sdd1", RUN+="/bin/raw /dev/raw/raw3 %N"
ACTION=="add", KERNEL=="sde1", RUN+="/bin/raw /dev/raw/raw4 %N"
ACTION=="add", KERNEL=="sdf1", RUN+="/bin/raw /dev/raw/raw5 %N"
ACTION=="add", KERNEL=="sdg1", RUN+="/bin/raw /dev/raw/raw6 %N"
ACTION=="add", KERNEL=="raw*", OWNER=="oracle", GROUP=="dba", MODE=="0660"   << 마지막줄은 permission설정입니다.

재부팅 후 결과확인

[root@rac1 ~]# raw -qa
/dev/raw/raw1:  bound to major 8, minor 17
/dev/raw/raw2:  bound to major 8, minor 33
/dev/raw/raw3:  bound to major 8, minor 49
/dev/raw/raw4:  bound to major 8, minor 65
/dev/raw/raw5:  bound to major 8, minor 81
/dev/raw/raw6:  bound to major 8, minor 97

[root@rac1 ~]# ls -l /dev/raw
합계 0
crw-rw---- 1 oracle dba 162, 1  3월 14 22:16 raw1
crw-rw---- 1 oracle dba 162, 2  3월 14 22:16 raw2
crw-rw---- 1 oracle dba 162, 3  3월 14 22:16 raw3
crw-rw---- 1 oracle dba 162, 4  3월 14 22:16 raw4
crw-rw---- 1 oracle dba 162, 5  3월 14 22:16 raw5
crw-rw---- 1 oracle dba 162, 6  3월 14 22:16 raw6


RHEL4는  http://gyh214.tistory.com/154 참조하세요