root用户登录,在所有节点执行:
[root@node1 ~]# crsctl stop crs Stopping resources. This could take several minutes. Successfully stopped CRS resources. Stopping CSSD. Shutting down CSS daemon. Shutdown request successfully issued.
还原所有节点的配置文件
[root@node2 etc]# cp -a /etc/hosts.bak /etc/hosts cp:是否覆盖“/etc/hosts”? y # 2. 还原tnsnames.ora和listener.ora [root@node2 admin]# cp -a tnsnames.ora.bak tnsnames.ora cp:是否覆盖“tnsnames.ora”? y [root@node2 admin]# cp -a listener.ora.bak listener.ora cp:是否覆盖“listener.ora”? y # 注意文件权限是否正确 [root@node2 admin]# ll tnsnames.ora -rw-r--r-- 1 oracle oinstall 1878 06-16 10:21 tnsnames.ora [root@node2 admin]# ll listener.ora -rw-r--r-- 1 oracle oinstall 552 06-19 14:35 listener.or
还原OCR
root用户登录,只需在一个节点还原即可:
# 最初备份的OCR文件为: [root@node1 /]# ll /ocr_backup/ocr201706.bak -rw-r--r-- 1 root root 107241 06-16 16:53 /ocr_backup/ocr201706.bak # 还原OCR [root@node1 /]# ocrconfig -import /ocr_backup/ocr201706.bak # OCR还原成功后没有任何输出
还原操作系统IP
编辑/etc/sysconfig/network-scripts/目录下的网卡文件,将之前修改的网卡IP地址还原,然后重启网络服务。
启动CRS,查看集群状态
root用户登录,所有节点执行:
[root@node1 ~]# crs_stat -t Name Type Target State Host ------------------------------------------------------------ ora.iesdb.db application ONLINE ONLINE node1 ora....b1.inst application ONLINE ONLINE node1 ora....b2.inst application ONLINE ONLINE node2 ora....srac.cs application ONLINE ONLINE node2 ora....db1.srv application ONLINE ONLINE node1 ora....db2.srv application ONLINE ONLINE node2 ora....SM1.asm application ONLINE ONLINE node1 ora....E1.lsnr application ONLINE ONLINE node1 ora.node1.gsd application ONLINE ONLINE node1 ora.node1.ons application ONLINE ONLINE node1 ora.node1.vip application ONLINE ONLINE node1 ora....SM2.asm application ONLINE ONLINE node2 ora....E2.lsnr application ONLINE ONLINE node2 ora.node2.gsd application ONLINE ONLINE node2 ora.node2.ons application ONLINE ONLINE node2 ora.node2.vip application ONLINE ONLINE node2此时可以看到CRS各资源都从处于ONLINE状态,最后,重新修改local_listener的IP为oracle VIP即可。
修改local_listener