我们专注攀枝花网站设计 攀枝花网站制作 攀枝花网站建设
成都网站建设公司服务热线:400-028-6601

网站建设知识

十年网站开发经验 + 多家企业客户 + 靠谱的建站团队

量身定制 + 运营维护+专业推广+无忧售后,网站问题一站解决

oralce11gracocr和votedisk迁移

1、新建一个磁盘组+NEW
Create diskgroup CRS NORMAL REDUNDANCY
FAILGROUP CRS_0000 disk '/dev/asm-orctest1'
FAILGROUP CRS_0001 disk '/dev/asm-orctest2'
FAILGROUP CRS_0002 disk '/dev/asm-orctest3'
ATTRIBUTE 'compatible.asm' = '11.2';

成都创新互联公司专业IDC数据服务器托管提供商,专业提供成都服务器托管,服务器租用,大邑服务器托管大邑服务器托管,成都多线服务器托管等服务器托管服务。


2、查看ocr备份
[root@rac02 bin]# ./ocrconfig -manualbackup

ocrconfig -showbackup
[root@rac02 bin]# ./ocrconfig -showbackup manual
rac01     2017/08/03 06:47:10     /u01/11.2.0/grid/cdata/rac-cluster/backup_20170803_064710.ocr
rac02     2017/08/01 02:32:01     /u01/11.2.0/grid/cdata/rac-cluster/backup_20170801_023201.ocr

2、2个节点停止集群并修改配置文件(更改里面的磁盘组名字为新建的磁盘组)
./crsctl stop crs

vi /etc/oracle/ocr.loc


3、启动一个节点到独占模式并确认磁盘组+NEW是否mount,如没有,手动mount。

crsctl start crs -excl -nocrs


SQL> select  GROUP_NUMBER, NAME,STATE from  v$asm_diskgroup;

GROUP_NUMBER NAME                           STATE
------------ ------------------------------ -----------
           1 ASM_DATA1                      MOUNTED
           2 ASM_FL                         MOUNTED
           3 CRS                            MOUNTED
           4 DATA                           MOUNTED

4、使用OCR备份恢复OCR到新的磁盘组(注意提前更改ocr.loc)
#./ocrconfig -restore  /u01/11.2.0/grid/cdata/rac-cluster/backup_20170801_023201.ocr


[root@rac02 bin]# ./ocrconfig -manualbackup
rac01     2017/08/03 06:47:10     /u01/11.2.0/grid/cdata/rac-cluster/backup_20170803_064710.ocr
rac02     2017/08/01 02:32:01     /u01/11.2.0/grid/cdata/rac-cluster/backup_20170801_023201.ocr


5、恢复votedisk
[root@rac02 bin]# ./crsctl replace votedisk  +CRS
[root@rac02 bin]# ./ocrconfig -restore  /u01/11.2.0/grid/cdata/rac-cluster/backup_20170801_023201.ocr
[root@rac02 bin]# ./crsctl replace votedisk  +CRS
Successful addition of voting disk 99fc4fb627ab4ffabfa4819288ef362d.
Successful addition of voting disk 69c39aef708f4f0abf39c97b4c55dcea.
Successful addition of voting disk 6bef23769bae4f5fbfb594f99707b160.
Successful deletion of voting disk 264b8b526ac54fe9bf80c5eee1350526.
Successfully replaced voting disk group with +CRS.
CRS-4266: Voting file(s) successfully replaced


检查
ocrcheck---------------------------------------------检查结果未变化
crsctl query css votedisk
[root@rac02 bin]# ./ocrcheck
Status of Oracle Cluster Registry is as follows :
         Version                  :          3
         Total space (kbytes)     :     262120
         Used space (kbytes)      :       3480
         Available space (kbytes) :     258640
         ID                       : 1128199232
         Device/File Name         :      +DATA
                                    Device/File integrity check succeeded

                                    Device/File not configured

                                    Device/File not configured

                                    Device/File not configured

                                    Device/File not configured

         Cluster registry integrity check succeeded

         Logical corruption check succeeded

[root@rac02 bin]# ./crsctl query css votedisk
##  STATE    File Universal Id                File Name Disk group
--  -----    -----------------                --------- ---------
 1. ONLINE   99fc4fb627ab4ffabfa4819288ef362d (/dev/asm-orctest1) [CRS]
 2. ONLINE   69c39aef708f4f0abf39c97b4c55dcea (/dev/asm-orctest2) [CRS]
 3. ONLINE   6bef23769bae4f5fbfb594f99707b160 (/dev/asm-orctest3) [CRS]
Located 3 voting disk(s).


6、删除掉原来
./ocrconfig -delete  +DATA

然后重启集群


新闻标题:oralce11gracocr和votedisk迁移
文章分享:http://shouzuofang.com/article/jhhhhp.html

其他资讯