资源描述:
《玩转裸设备的备份恢复》由会员上传分享,免费在线阅读,更多相关内容在教育资源-天天文库。
1、1、裸设备的创建:在/etc/sysconfig/rawdevices下添加如下:/dev/raw/raw1 /dev/sdb1(100M)/dev/raw/raw2 /dev/sdb2(120M)/dev/raw/raw3 /dev/sdb3(130M)/dev/raw/raw4 /dev/sdb4(150M)/dev/raw/raw5 /dev/sdc1(200M)/dev/raw/raw6 /dev/sdc2(230M)/dev/raw/raw7 /dev/sdc3(250M)/dev/raw/raw8
2、/dev/sdc4(320M)/dev/raw/raw9 /dev/sdd1(100M)2、要使映射立即生效,以root用户身份执行以下命令:[root@dg~]#/sbin/servicerawdevicesrestartAssigningdevices: /dev/raw/raw1 --> /dev/sdb1/dev/raw/raw8: boundtomajor8,minor17 /dev/raw/raw2 --> /dev/sdb2/dev/raw/raw2: boundtoma
3、jor8,minor18 /dev/raw/raw3 --> /dev/sdb3/dev/raw/raw3: boundtomajor8,minor19 /dev/raw/raw4 --> /dev/sdb4/dev/raw/raw4: boundtomajor8,minor20 /dev/raw/raw5 --> /dev/sdc1/dev/raw/raw5: boundtomajor8,minor33 /dev/raw/raw6 --> /de
4、v/sdc2/dev/raw/raw6: boundtomajor8,minor34 /dev/raw/raw7 --> /dev/sdc3/dev/raw/raw7: boundtomajor8,minor35 /dev/raw/raw8 --> /dev/sdc4/dev/raw/raw9: boundtomajor8,minor36 /dev/raw/raw9 --> /dev/sdd1Errorsettingrawdevice(Deviceorresource
5、busy)done3、修改权限:#chownoracle:dba/dev/raw/raw[1-9]#chmod660/dev/raw/raw[1-9][root@dg~]#ls-lat/dev/raw/raw*crw-rw---- 1oracleoinstall162,9 9ÔÂ1312:19/dev/raw/raw9crw-rw---- 1oracleoinstall162,7 9ÔÂ1312:19/dev/raw/raw8crw-rw---- 1oracleoinstall162,6 9ÔÂ1312:19/dev/raw/
6、raw7crw-rw---- 1oracleoinstall162,5 9ÔÂ1312:19/dev/raw/raw6crw-rw---- 1oracleoinstall162,4 9ÔÂ1312:19/dev/raw/raw5crw-rw---- 1oracleoinstall162,3 9ÔÂ1312:19/dev/raw/raw4crw-rw---- 1oracleoinstall162,2 9ÔÂ1312:19/dev/raw/raw3crw-rw---- 1oracleoinstall162,8 9ÔÂ1312:19
7、/dev/raw/raw2crw-rw---- 1oracleoinstall162,1 9ÔÂ1311:44/dev/raw/raw14、修改/etc/udev/permissions.d/50-udev.permissions。原始设备在引导时会重新映射。默认情况下,在引导时原始设备的拥有者将更改为root用户。如果拥有者不是oracle用户,则ASM在访问共享分区时会出现问题。在/etc/udev/permissions.d/50-udev.permissions中为原始行“raw/*:root:disk:0660”添加
8、注释,然后添加一个新行“raw/*:oracle:dba:0660”。/etc/udev/permissions.d/50-udev.permissions#rawdevicesram*:root:disk:0660#raw/*:root:disk:0660raw/*:ora