最新文章专题视频专题问答1问答10问答100问答1000问答2000关键字专题1关键字专题50关键字专题500关键字专题1500TAG最新视频文章推荐1 推荐3 推荐5 推荐7 推荐9 推荐11 推荐13 推荐15 推荐17 推荐19 推荐21 推荐23 推荐25 推荐27 推荐29 推荐31 推荐33 推荐35 推荐37视频文章20视频文章30视频文章40视频文章50视频文章60 视频文章70视频文章80视频文章90视频文章100视频文章120视频文章140 视频2关键字专题关键字专题tag2tag3文章专题文章专题2文章索引1文章索引2文章索引3文章索引4文章索引5123456789101112131415文章专题3
问答文章1 问答文章501 问答文章1001 问答文章1501 问答文章2001 问答文章2501 问答文章3001 问答文章3501 问答文章4001 问答文章4501 问答文章5001 问答文章5501 问答文章6001 问答文章6501 问答文章7001 问答文章7501 问答文章8001 问答文章8501 问答文章9001 问答文章9501
当前位置: 首页 - 科技 - 知识百科 - 正文

Oracle11gRACCRS磁盘丢失后恢复

来源:懂视网 责编:小采 时间:2020-11-09 15:15:35
文档

Oracle11gRACCRS磁盘丢失后恢复

Oracle11gRACCRS磁盘丢失后恢复:一、概述 为了方便相关问题测试,我在本机搭建了一套RAC环境,但昨天打开后却发现RAC无法启动了,不错,就当一次实战演练了。 一、概述 为了方便相关问题测试,我在本机搭建了一套RAC环境,但昨天打开后却发现RAC无法启动了,不错,就当一次实战演练了。
推荐度:
导读Oracle11gRACCRS磁盘丢失后恢复:一、概述 为了方便相关问题测试,我在本机搭建了一套RAC环境,但昨天打开后却发现RAC无法启动了,不错,就当一次实战演练了。 一、概述 为了方便相关问题测试,我在本机搭建了一套RAC环境,但昨天打开后却发现RAC无法启动了,不错,就当一次实战演练了。

一、概述 为了方便相关问题测试,我在本机搭建了一套RAC环境,但昨天打开后却发现RAC无法启动了,不错,就当一次实战演练了。

一、概述

为了方便相关问题测试,我在本机搭建了一套RAC环境,但昨天打开后却发现RAC无法启动了,不错,,就当一次实战演练了。
测试环境:RedHat6.3_x64+ Oracle11gr2 RAC

二、处理过程:
在启动虚拟机一段时间后,通过命令查看,信息如下:

[grid@rac01 ~]$ crs_stat -t

CRS-0184: Cannot communicate with the CRS daemon.
[grid@rac01 ~]$ crsctl status res -t

CRS-4535: Cannot communicate with Cluster Ready Services

CRS-4000: Command Status failed, or completed with errors.

查看CRS服务状态

[root@rac01 rac-cluster]# crsctl check crs

CRS-4638: Oracle High Availability Services is online

CRS-4535: Cannot communicate with Cluster Ready Services

CRS-4530: Communications failure contacting Cluster Synchronization Services daemon

CRS-4534: Cannot communicate with Event Manager

启动Cluster资源

[root@rac01 bin]#crsctl start cluster

CRS-2800: Cannot start resource 'ora.asm' as it is already in the INTERMEDIATE state on server 'rac01'

CRS-4000: Command Start failed, or completed with errors.

相关相关日志,获取到如下信息,并未在其他日志中找到更有效的参考信息,如果有好的建议,请联系在下:

---alter.log

[ohasd(2017)]CRS-2807:Resource 'ora.crsd' failed to start automatically.

---ocssd.log
2015-06-12 03:07:14.722: [ CLSF][2402883328]Allocated CLSF context

2015-06-12 03:07:14.723: [ SKGFD][2402883328]Handle 0x16f57d0 from lib :UFS:: for disk :/dev/asm-diskb:

2015-06-12 03:07:14.723: [ CSSD][2402883328]clssnmlalloccx:phyname rac01

2015-06-12 03:07:14.742: [ CSSD][2402883328]clssnmvDiskAvailabilityChange: voting file /dev/asm-diskb now online

2015-06-12 03:07:14.742: [ CSSD][2402883328]clssnmlgetfileslot: found expired slot 1 for host rac01 leasename rac01

2015-06-12 03:07:14.747: [ SKGFD][2381424384]NOTE: No asm libraries found in the system

2015-06-12 03:07:14.747: [ CLSF][2381424384]Allocated CLSF context

2015-06-12 03:07:14.748: [ SKGFD][2381424384]Handle 0x7f4d7008e6b0 from lib :UFS:: for disk :/dev/asm-diskb:

2015-06-12 03:07:14.748: [ SKGFD][2381424384]Lib :UFS:: closing handle 0x7f4d7008e6b0 for disk :/dev/asm-diskb:

2015-06-12 03:07:15.749: [ SKGFD][2381424384]NOTE: No asm libraries found in the system

查看CSS信息

[grid@rac01 ~]$ crsctl query css votedisk

## STATE File Universal Id File Name Disk group

-- ----- ----------------- --------- ---------

1. ONLINE aaaf9f57bc9c4fc7bfb57ac937d2d149 (/dev/asm-diskb) [CRS]

下面我通过ASM实例查看相关ASM磁盘信息:

SQL> select NAME , STATE FROM V$ASM_DISKGROUP;

NAME STATE

------------------------------ -----------

DATA DISMOUNTED

CRS DISMOUNTED

OK,尝试MOUNT磁盘组(后续,整理是发现奇怪问题,既然前边我们查看css信息时 磁盘是online,那么这我们却无法mount,并未尝试强制mount,有待进一步研究)

SQL> alter diskgroup crs mount;

alter diskgroup crs mount

*

ERROR at line 1:

ORA-15032: not all alterations performed

ORA-15040: diskgroup is incomplete

ORA-15042: ASM disk "1" is missing from group number "1"

尝试MOUNT DATA磁盘组

SQL> alter diskgroup data mount;

Diskgroup altered.

SQL> select NAME , STATE FROM V$ASM_DISKGROUP;

NAME STATE

------------------------------ -----------

DATA MOUNTED

CRS DISMOUNTED

注:现在写下当时处理问题的过程,并未过多深入研究问题,在整理文档时有了更多思考,暂且不讨论。
既然磁盘组DATA可以用,那么我们先将CRS等信息存储到DATA磁盘组中,之前并未手动备份过CRS等信息,只能通过自动备份信息恢复。
停止CRS服务,两个节点都执行

[root@rac01 rac-cluster]# crsctl stop has -f

再次启动,以NOCRS方式启动CRS,节点1执行

[root@rac01 rac-cluster]# crsctl start crs -excl -nocrs

CRS-4123: Oracle High Availability Services has been started.

CRS-2672: Attempting to start 'ora.mdnsd' on 'rac01'

CRS-2676: Start of 'ora.mdnsd' on 'rac01' succeeded

CRS-2672: Attempting to start 'ora.gpnpd' on 'rac01'

CRS-2676: Start of 'ora.gpnpd' on 'rac01' succeeded

CRS-2672: Attempting to start 'ora.cssdmonitor' on 'rac01'

CRS-2672: Attempting to start 'ora.gipcd' on 'rac01'

CRS-2676: Start of 'ora.cssdmonitor' on 'rac01' succeeded

CRS-2676: Start of 'ora.gipcd' on 'rac01' succeeded

CRS-2672: Attempting to start 'ora.cssd' on 'rac01'

CRS-2672: Attempting to start 'ora.diskmon' on 'rac01'

CRS-2676: Start of 'ora.diskmon' on 'rac01' succeeded

CRS-2676: Start of 'ora.cssd' on 'rac01' succeeded

CRS-2672: Attempting to start 'ora.drivers.acfs' on 'rac01'

CRS-2679: Attempting to clean 'ora.cluster_interconnect.haip' on 'rac01'

CRS-2672: Attempting to start 'ora.ctssd' on 'rac01'

CRS-2681: Clean of 'ora.cluster_interconnect.haip' on 'rac01' succeeded

CRS-2672: Attempting to start 'ora.cluster_interconnect.haip' on 'rac01'

CRS-2676: Start of 'ora.drivers.acfs' on 'rac01' succeeded

CRS-2676: Start of 'ora.ctssd' on 'rac01' succeeded

CRS-2676: Start of 'ora.cluster_interconnect.haip' on 'rac01' succeeded

CRS-2672: Attempting to start 'ora.asm' on 'rac01'

CRS-2676: Start of 'ora.asm' on 'rac01' succeeded

修改/etc/oracle/ocr.loc文件,将OCR修改为DATA,两个节点都需要修改。
查看备份情况,选择一个最近时间节点恢复

查看命令:ocrconfig –showbackup
[root@rac01 rac-cluster]# ocrconfig -restore /grid/crs_home/product/11.2.0/cdata/rac-cluster/week.ocr

[root@rac01 rac-cluster]# ocrcheck

Status of Oracle Cluster Registry is as follows :

Version : 3

Total space (kbytes) : 262120

Used space (kbytes) : 3088

Available space (kbytes) : 259032

ID : 471595559

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

创建VOTEDISK

在创建时出现以下问题,解决办法如下:

[root@rac01 rac-cluster]# crsctl replace votedisk +DATA

CRS-4602: Failed 27 to add voting file 7255773670ae4fa9bf64a150a9fd5915.

Failure 27 with Cluster Synchronization Services while deleting voting disk.

Failed to replace voting disk group with +DATA.

CRS-4000: Command Replace failed, or completed with errors.

设置ASM磁盘搜索路径

SQL> show parameter asm_diskstring

NAME TYPE VALUE

------------------------------------ ----------- ------------------------------

asm_diskstring string

SQL> alter system set asm_diskstring = '/dev/asm*';

System altered.

SQL> create spfile='+DATA' from memory;

File created.

SQL> startup force mount;

再次创建VOTEDISK

[root@rac01 rac-cluster]# crsctl replace votedisk +DATA

Successful addition of voting disk 383b8c3e4db34f72bf9dedd15e47471b.

Successful deletion of voting disk aaaf9f57bc9c4fc7bfb57ac937d2d149.

Successfully replaced voting disk group with +DATA.

CRS-4266: Voting file(s) successfully replaced

停止集群服务,再次启动

[root@rac01 rac-cluster]# crsctl stop has –f
……………………
--两个节点顺序启动
[root@rac01 rac-cluster]# crsctl start crs

CRS-4123: Oracle High Availability Services has been started.

通过下面集群状态检查,我们可以看到CRS状态为OFFLINE,需要我们通过asm管理工具重新整理磁盘。

[root@rac01 bin]# crs_stat –t

Name Type Target State Host

------------------------------------------------------------

ora.CRS.dg ora....up.type ONLINE OFFNLINE

ora.DATA.dg ora....up.type ONLINE ONLINE rac01

ora....ER.lsnr ora....er.type ONLINE ONLINE rac01

ora....N1.lsnr ora....er.type ONLINE ONLINE rac01

ora.asm ora.asm.type ONLINE ONLINE rac01

ora.cvu ora.cvu.type ONLINE ONLINE rac01

ora.gsd ora.gsd.type OFFLINE OFFLINE

ora....network ora....rk.type ONLINE ONLINE rac01

ora.oc4j ora.oc4j.type ONLINE ONLINE rac01

ora.ons ora.ons.type ONLINE ONLINE rac01

ora....SM1.asm application ONLINE ONLINE rac01

ora....01.lsnr application ONLINE ONLINE rac01

ora.rac01.gsd application OFFLINE OFFLINE

ora.rac01.ons application ONLINE ONLINE rac01

ora.rac01.vip ora....t1.type ONLINE ONLINE rac01

ora....SM2.asm application ONLINE ONLINE rac02

ora....02.lsnr application ONLINE ONLINE rac02

ora.rac02.gsd application OFFLINE OFFLINE

ora.rac02.ons application ONLINE ONLINE rac02

ora.rac02.vip ora....t1.type ONLINE ONLINE rac02

ora.racdb.db ora....se.type OFFLINE OFFLINE

ora....ry.acfs ora....fs.type ONLINE ONLINE rac01

ora.scan1.vip ora....ip.type ONLINE ONLINE rac01

声明:本网页内容旨在传播知识,若有侵权等问题请及时与本网联系,我们将在第一时间删除处理。TEL:177 7030 7066 E-MAIL:11247931@qq.com

文档

Oracle11gRACCRS磁盘丢失后恢复

Oracle11gRACCRS磁盘丢失后恢复:一、概述 为了方便相关问题测试,我在本机搭建了一套RAC环境,但昨天打开后却发现RAC无法启动了,不错,就当一次实战演练了。 一、概述 为了方便相关问题测试,我在本机搭建了一套RAC环境,但昨天打开后却发现RAC无法启动了,不错,就当一次实战演练了。
推荐度:
标签: 恢复 丢失 丢失后
  • 热门焦点

最新推荐

猜你喜欢

热门推荐

专题
Top