在ORACLE等大型数据库中建议数据文件放到RAW设备中,请问rh8中是否可以建立RAW设备?如何建?
1.编辑 /etc/sysconfig/rawdevices文件,用于定义裸设备:
/etc/sysconfig/rawdevices格式如下:
# raw device bindings
# format: rawdev major minor
# rawdev blockdev
# example: /dev/raw/raw1 /dev/sda1
# /dev/raw/raw2 8 5
/dev/raw/raw1 /dev/sdd1
/dev/raw/raw2 /dev/sdd2
/dev/raw/raw3 /dev/sdd3
/dev/raw/raw4 /dev/sdd4
或
/dev/raw/raw5 /dev/hda5
2.绑定裸设备 /etc/rc.d/init.d/rawdevices.
[root@legolas init.d]# cd /etc/rc.d/init.d
[root@legolas init.d]# sh rawdevices start
Assigning devices:
/dev/raw/raw1 --> /dev/sdd5
/dev/raw/raw1: bound to major 3, minor 5
/dev/raw/raw2 --> /dev/sdd6
/dev/raw/raw2: bound to major 3, minor 6
/dev/raw/raw3 --> /dev/sdd7
/dev/raw/raw3: bound to major 3, minor 7
/dev/raw/raw4 --> /dev/sdd8
/dev/raw/raw4: bound to major 3, minor 8
/dev/raw/raw5 --> /dev/hda5
/dev/raw/raw5: bound to major 3, minor 9
done
3.执行chkconfig命令确保重新启动时裸设备能被绑定。
# /sbin/chkconfig rawdevices on