oracle votedisk ocr,Oracle RAC 重建OCR和Votedisk
哈哈,刚说最后一篇,闲的无聊又搞了个测试。
环境:
OS:redhat 5.8
DB:Oracle 10.2.0.5 raw device
我们要养成经常备份ocr跟votedisk的习惯。但是ocr跟votedisk没有备份也是可以重建的。就像控制文件。但是过程较为麻烦。以下为详细步骤:
首先备份ocr跟votedisk:
[root@rac1 ~]#
[root@rac1 ~]# ocrcheck
Status of Oracle Cluster Registry is as follows :
Version : 2
Total space (kbytes) : 1048296
Used space (kbytes) : 3292
Available space (kbytes) : 1045004
ID : 1891074113
Device/File Name : /dev/raw/raw1
Device/File integrity check succeeded
Device/File Name : /dev/raw/raw2
Device/File integrity check succeeded
Cluster registry integrity check succeeded
[root@rac1 ~]# crsctl qeury css votedisk
Unknown parameter: qeury
[root@rac1 ~]# crsctl query css votedisk
0. 0 /dev/raw/raw3
1. 0 /dev/raw/raw4
2. 0 /dev/raw/raw5
[root@rac1 ~]# dd if=/dev/raw/raw3 of=/opt/votedisk.bak
2097152+0 records in
2097152+0 records out
1073741824 bytes (1.1 GB) copied, 462.285 seconds, 2.3 MB/s
[root@rac1 ~]# ocrconfig -export /opt/ocr.bak
[root@rac1 ~]# cd /opt/
[root@rac1 opt]# ls
ocr.bak ORCLfmap votedisk.bak删除配置:
[root@rac1 install]# ./rootdelete.sh
Shutting down Oracle Cluster Ready Services (CRS):
Stopping resources. This could take several minutes.
Error while stopping resources. Possible cause: CRSD is down.
Shutdown has begun. The daemons should exit soon.
Checking to see if Oracle CRS stack is down...
Oracle CRS stack is not running.
Oracle CRS stack is down now.
Removing script for Oracle Cluster Ready services
Updating ocr file for downgrade
Cleaning up SCR settings in '/etc/oracle/scls_scr'
Cleaning up Network socket directories
[root@rac2 install]# ./rootdelete.sh
Shutting down Oracle Cluster Ready Services (CRS):
Stopping resources. This could take several minutes.
Error while stopping resources. Possible cause: CRSD is down.
Shutdown has begun. The daemons should exit soon.
Checking to see if Oracle CRS stack is down...
Oracle CRS stack is not running.
Oracle CRS stack is down now.
Removing script for Oracle Cluster Ready services
Updating ocr file for downgrade
Cleaning up SCR settings in '/etc/oracle/scls_scr'
Cleaning up Network socket directories
在安装节点执行:
[root@rac1 install]# ./rootdeinstall.sh
Removing contents from OCR mirror device
2560+0 records in
2560+0 records out
10485760 bytes (10 MB) copied, 0.521651 seconds, 20.1 MB/s
Removing contents from OCR device
2560+0 records in
2560+0 records out
10485760 bytes (10 MB) copied, 0.496207 seconds, 21.1 MB/s重跑root脚本:
[root@rac1 crs]# ./root.sh
WARNING: directory '/u01/app/oracle' is not owned by root
WARNING: directory '/u01/app' is not owned by root
WARNING: directory '/u01' is not owned by root
No value set for the CRS parameter CRS_OCR_LOCATIONS. Using Values in paramfile.crs
Checking to see if Oracle CRS stack is already configured
Setting the permissions on OCR backup directory
Setting up NS directories
Oracle Cluster Registry configuration upgraded successfully
WARNING: directory '/u01/app/oracle' is not owned by root
WARNING: directory '/u01/app' is not owned by root
WARNING: directory '/u01' is not owned by root
Successfully accumulated necessary OCR keys.
Using ports: CSS=49895 CRS=49896 EVMC=49898 and EVMR=49897.
node :
node 1: rac1 rac1-priv rac1
node 2: rac2 rac2-priv rac2
Creating OCR keys for user 'root', privgrp 'root'..
Operation successful.
Now formatting voting device: /dev/raw/raw3
Now formatting voting device: /dev/raw/raw4
Now formatting voting device: /dev/raw/raw5
Format of 3 voting devices complete.
Startup will be queued to init within 30 seconds.
Adding daemons to inittab
Expecting the CRS daemons to be up within 600 seconds.
CSS is active on these nodes.
rac1
CSS is inactive on these nodes.
rac2
Local node checking complete.
Run root.sh on remaining nodes to start CRS daemons.
[root@rac2 crs]# ./root.sh
WARNING: directory '/u01/app/oracle' is not owned by root
WARNING: directory '/u01/app' is not owned by root
WARNING: directory '/u01' is not owned by root
No value set for the CRS parameter CRS_OCR_LOCATIONS. Using Values in paramfile.crs
Checking to see if Oracle CRS stack is already configured
Setting the permissions on OCR backup directory
Setting up NS directories
Oracle Cluster Registry configuration upgraded successfully
WARNING: directory '/u01/app/oracle' is not owned by root
WARNING: directory '/u01/app' is not owned by root
WARNING: directory '/u01' is not owned by root
clscfg: EXISTING configuration version 3 detected.
clscfg: version 3 is 10G Release 2.
Successfully accumulated necessary OCR keys.
Using ports: CSS=49895 CRS=49896 EVMC=49898 and EVMR=49897.
node :
node 1: rac1 rac1-priv rac1
node 2: rac2 rac2-priv rac2
clscfg: Arguments check out successfully.
NO KEYS WERE WRITTEN. Supply -force parameter to override.
-force is destructive and will destroy any previous cluster
configuration.
Oracle Cluster Registry for cluster has already been initialized
Startup will be queued to init within 30 seconds.
Adding daemons to inittab
Expecting the CRS daemons to be up within 600 seconds.
CSS is active on these nodes.
rac1
rac2
CSS is active on all nodes.
Waiting for the Oracle CRSD and EVMD to start
Oracle CRS stack installed and running under init(1M)
Running vipca(silent) for configuring nodeapps
Invalid syntax used for option "nodevips". Check usage (vipca -help) for proper syntax.
配置VIP
[root@rac2 crs]# oifcfg getif
[root@rac2 crs]# oifcfg iflist
eth0 192.168.56.0
eth1 192.168.11.0
[root@rac2 crs]# oifcfg setif -global eth0/192.168.56.0:public
[root@rac2 crs]# oifcfg setif -global eht1/192.168.11.0:cluster_interconnect
[root@rac2 crs]# oifcfg getif
eth0 192.168.56.0 global public
eht1 192.168.11.0 global cluster_interconnect
运行vipca配置VIP
查看结果:
[root@rac1 crs]# crs_stat -t
Name Type Target State Host
------------------------------------------------------------
ora.rac1.gsd application ONLINE ONLINE rac1
ora.rac1.ons application ONLINE ONLINE rac1
ora.rac1.vip application ONLINE ONLINE rac1
ora.rac2.gsd application ONLINE ONLINE rac2
ora.rac2.ons application ONLINE ONLINE rac2
ora.rac2.vip application ONLINE ONLINE rac2
配置监听:
[root@rac1 admin]# mv listener.ora listener.ora.bak
[root@rac2 admin]# mv listener.ora listener.ora.bak
使用netca创建监听
[root@rac1 admin]# crs_stat -t
Name Type Target State Host
------------------------------------------------------------
ora....C1.lsnr application ONLINE ONLINE rac1
ora.rac1.gsd application ONLINE ONLINE rac1
ora.rac1.ons application ONLINE ONLINE rac1
ora.rac1.vip application ONLINE ONLINE rac1
ora....C2.lsnr application ONLINE ONLINE rac2
ora.rac2.gsd application ONLINE ONLINE rac2
ora.rac2.ons application ONLINE ONLINE rac2
ora.rac2.vip application ONLINE ONLINE rac2将数据库加入CRS:
[oracle@rac1 ~]$ srvctl add database -d zhdb -o $ORACLE_HOME
启动数据库:
srvctl start database -d zhdb
[oracle@rac1 dbs]$ crs_stat -t
Name Type Target State Host
------------------------------------------------------------
ora....C1.lsnr application ONLINE ONLINE rac1
ora.rac1.gsd application ONLINE ONLINE rac1
ora.rac1.ons application ONLINE ONLINE rac1
ora.rac1.vip application ONLINE ONLINE rac1
ora....C2.lsnr application ONLINE ONLINE rac2
ora.rac2.gsd application ONLINE ONLINE rac2
ora.rac2.ons application ONLINE ONLINE rac2
ora.rac2.vip application ONLINE ONLINE rac2
ora.zhdb.db application ONLINE ONLINE rac1
ora....b2.inst application ONLINE ONLINE rac2 自此OCR跟Votedisk重建成功
oracle votedisk ocr,Oracle RAC 重建OCR和Votedisk相关推荐
- oracle rac 中的ocr,11g rac中 ocr和 votingdisk疑问
一直对这个配置比较混乱,我看文档上写推荐都是300m,我选的是externalmos,三个磁盘组成磁盘组,但我看他只在raw1 上啊,那我其他两个是怎么个工作原理啊,还请教正确的配置方法和大小设置,我 ...
- oracle 11g votedisk,Oracle 11gR2 RAC恢复OCR和VOTE DISK
Oracle 11gR2 RAC恢复OCR和VOTE DISK 原文链接: http://www.askmaclean.com/archives/11-2-lost-ocr-votedisk-grou ...
- oracle votedisk ocr,Oracle rac 11g在线添加ocr 和votedisk
在线添加ocr 以前看过,里面ricky_zhu说过可以在线添加ocr和votedisk的,刚好今天试验环境需要添加ocr,就顺便作了个实验. 环境:aix 5.3+ oracle rac 11.1. ...
- oracle 10g 更换ocr,Oracle10g RAC在线更换OCR votedisk
操作之前确认集群状态都正常 1.替换OCR # ./ocrconfig -replace ocrmirror /dev/rhdisk11 # ./ocrcheck Status of Oracle C ...
- oracle rac 创建ocr,Oracle rac 11g在线添加ocr,votedisk
/client/ocrconfig_.log. Please ensure you have file creation privileges in the above directory befor ...
- Oracle 11gR2 RAC恢复OCR和VOTE DISK
Oracle 11gR2 RAC恢复OCR和VOTE DISK 原文链接: http://www.askmaclean.com/archives/11-2-lost-ocr-votedisk-grou ...
- oracle+restore+pfile,RAC(11gR2) OCR BACKUP RESTORE
首先检查下OCR盘 [grid@rac1cdata]$ ocrcheck Status of OracleCluster Registry is as follows : Version ...
- Oracle RAC中OCR整个磁盘的故障模拟恢复
测试目的: 模拟整个CRS盘损坏后,如何处理 处理过程: 重新创建一个同名的磁盘组给OCR使用.restore OCR信息,重新创建voting file. 即可. RDBMS 11.2.0.4 参 ...
- ocr oracle,Oracle RAC备份和恢复OCR-Oracle
Oracle RAC备份和恢复OCR Oracle RAC 备份和恢复OCR voting disks备份恢复参考: /database/201303/195593.html 1.OCR有两种备份方式 ...
最新文章
- BZOJ1058 [ZJOI2007]报表统计 set
- 如何在App中实现朋友圈功能之二快速实现用户信息的自定义——箭扣科技Arrownock...
- docker update_DevOps核心:使用Docker部署Jenkins持续集成服务器
- java创建线程的两种方法区别
- Jquery中bind和live的区别
- mysql中explain命令
- iis7怎么安装php7,Linux下如何安装php7
- 支付系统灰度发布原理图
- 《Spring Data实战》——导读
- JS 阻止浮层弹窗下滚动
- java解析数据_java解析txt里的数据
- uwp浏览器java源码_从网站打开UWP应用程序
- VPU/NPU/TPU/GPU/CPU眼花缭乱,傻傻分不清楚?三百字讲明白
- 维谛技术(Vertiv):致力于“新基建”的数字基石
- 执行npm出现“Error:Cannot find module ‘fs/promises”的问题
- spring 配置相关
- (笔记)Bison 的使用说明
- Android拍照指定尺寸,相机在Android中,如何获得最佳尺寸,预览尺寸...
- 【新年祝福】散去2009分,祝大家新年快乐,祝所有朋友新的一年里万事如意。
- php计算根据出生日期计算年龄
热门文章
- 小程序进入页面图片渲染会拉伸闪下变形优化bug
- hutol json null值没了_一篇长文带你在python里玩转Json数据
- android秋招面试题及答案,阿里巴巴2019秋招客户端开发工程师在线笔试题和面试题答案...
- springboot热部署之spring-boot-devtools
- boa+php 嵌入式,boa 0.94.13 在嵌入式平台的安装与配置
- kubesphere_KubeSphere容器混合云一个人也能轻松运维的K8s
- 修改10g RAC public or private or virtual IP [Oracle]
- cli vue 卸载_记录使用@vue/cli搭建Vue3项目完整流程
- 不搞虚的!快速把你拉入Docker 的门里
- android 显示清除缓存