分类: Oracle
2010-04-17 21:18:57
查看votedisk的存储信息
crsctl query css votedisk
[oracle@inth-rac01 ~]$ /opt/crs/product/10.2.0.1/crs_1/bin/crsctl query css votedisk
0. 0 /dev/raw/raw1
备份votedisk: dd if=/dev/raw/votediskcopied of=/dev/raw/raw1
恢复votedisk: dd if=/dev/raw/raw1 of=/dev/raw/votediskcopied
查看ocrs的信息
ocrcheck
[oracle@inth-rac01 ~]$ /opt/crs/product/10.2.0.1/crs_1/bin/ocrcheck
Status of Oracle Cluster Registry is as follows :
Version : 2
Total space (kbytes) : 401536
Used space (kbytes) : 1992
Available space (kbytes) : 399544
ID : 1913602599
Device/File Name : /dev/raw/raw2
Device/File integrity check succeeded
Device/File not configured
Cluster registry integrity check succeeded
导出导入
可以用raw的命令来备份和恢复,不过ocrconfig提供了专门的命令来导出和导入还提供了镜像的方法
OCR手动导出:ocrconfig -export /tmp/ocr_bak
OCR手动导入:ocrconfig -import /tmp/ocr_bak
恢复OCR ocrconfig -restore /opt/product/10.2.0.1/crs/cdata/crs/backup01.ocr
添加OCR镜像盘:
创建用于镜像OCR的RAW设备,比如为:/dev/raw/ocrcopied
用ocrconfig –export 导出OCR的信息
编辑/etc/oracle/ocr.loc文件,添加ocrmirrorconfig_loc行
$ cat ocr.loc
ocrconfig_loc=/dev/raw/raw2
ocrmirrorconfig_loc=/dev/raw/ocrcopied
local_only=FALSE
用ocrconfig –import 导入OCR的信息
检查ocr设置信息
$ ocrcheck
Status of Oracle Cluster Registry is as follows :
Version : 2
Total space (kbytes) : 103724
Used space (kbytes) : 3824
Available space (kbytes) : 99900
ID : 1086971606
Device/File Name : /dev/raw/raw2 Device/File integrity check succeeded
Device/File Name : /dev/raw/ocrcopied Device/File integrity check succeeded
Cluster registry integrity check succeeded
记得以上使用raw备份的时候 要先停止掉crs的服务。