PRCD-1120 : The resource for database racpdb could not be found.PRCR-1001 : Resource ora.racpdb.db d

2022/1/9 6:05:28

本文主要是介绍PRCD-1120 : The resource for database racpdb could not be found.PRCR-1001 : Resource ora.racpdb.db d,对大家解决编程问题具有一定的参考价值,需要的程序猿们随着小编来一起学习吧!

PRCD-1120 : The resource for database racpdb could not be found.PRCR-1001 : Resource ora.racpdb.db d

shayuwei 2019-12-30 15:45:48 1768 收藏 3
分类专栏: 笔记 Oracle 文章标签: oracle
版权

笔记
同时被 2 个专栏收录
157 篇文章1 订阅
订阅专栏

Oracle
124 篇文章0 订阅
订阅专栏
问题描述
RAC异机恢复后无法查看实例状态

[oracle@new-rac2 ~]$ srvctl status database -d racpdb
PRCD-1120 : The resource for database racpdb could not be found.
PRCR-1001 : Resource ora.racpdb.db does not exist
1
2
3
开始以为是因为没有注册remote_listener导致监听不可用

SQL> show parameter remote_listener

NAME TYPE VALUE
------------------------------------ ---------------------- ------------------------------
remote_listener string racpdb:1521

SQL> alter system set remote_listener='testpro:1521';

System altered.

SQL> alter system register;

System altered.

SQL> show parameter remote_listener;

NAME TYPE VALUE
------------------------------------ ---------------------- ------------------------------
remote_listener string testpro:1521

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
但其实原因是修改了scan IP的name后,remote_listener没有注册新的name,而且grid记录的scan IP也不是这个名字,需要修改scan IP

解决办法:
查看scan信息
[oracle@new-rac1 ~]$ srvctl config scan
SCAN name: rac, Network: 1/192.168.1.0/255.255.255.0/em1
SCAN VIP name: scan1, IP: /rac/192.168.1.218
SCAN VIP name: scan2, IP: /isis/192.168.1.219
1
2
3
4
查看hosts文件
[oracle@new-rac1 ~]$ cat /etc/hosts
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6

# Public Network - (eth1)
192.168.1.214 new-rac1 testpdb1
192.168.1.216 new-rac2 testpdb2

# Private Interconnect - (eth4)
172.16.1.214 testpdb1-priv
172.16.1.216 testpdb2-priv

# Public Virtual IP (VIP) addresses
192.168.1.215 testpdb1-vip
192.168.1.217 testpdb2-vip

# Single Client Access Name (SCAN)
192.168.1.218 testpro
192.168.1.219 testpro
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
通过srvctl config scan看到scan name是rac,但是在hosts文件里scan name却是testpro

修改scan name
[oracle@new-rac1 ~]$ su - grid
Password:
[grid@new-rac1 ~]$ srvctl status scan
SCAN VIP scan1 is enabled
SCAN VIP scan1 is running on node new-rac2
SCAN VIP scan2 is enabled
SCAN VIP scan2 is running on node new-rac1
[grid@new-rac1 ~]$ srvctl stop scan
PRCR-1065 : Failed to stop resource ora.scan1.vip
CRS-2529: Unable to act on 'ora.scan1.vip' because that would require stopping or relocating 'ora.LISTENER_SCAN1.lsnr', but the force option was not specified
PRCR-1065 : Failed to stop resource ora.scan2.vip
CRS-2529: Unable to act on 'ora.scan2.vip' because that would require stopping or relocating 'ora.LISTENER_SCAN2.lsnr', but the force option was not specified
1
2
3
4
5
6
7
8
9
10
11
12
关闭顺序:需要先停掉scan监听,才能停掉scan

[grid@new-rac1 ~]$ srvctl stop scan_listener
[grid@new-rac1 ~]$ srvctl stop scan
1
2
修改scan
[grid@new-rac1 ~]$ srvctl modify scan -n testpro
PRCS-1034 : Failed to modify Single Client Access Name testpro.nsfc.gov.cn
PRCR-1071 : Failed to register or update resource type ora.scan_vip.type
CRS-0245: User doesn't have enough privilege to perform the operation
1
2
3
4
没有权限,必须是root用户

[grid@new-rac1 ~]$ exit
logout
[root@new-rac1 rman_bak]# /u01/app/11.2.0/grid/bin/srvctl modify scan -n testpro
[root@new-rac1 rman_bak]# /u01/app/11.2.0/grid/bin/srvctl config scan
SCAN name: testpro, Network: 1/192.168.1.0/255.255.255.0/em1
SCAN VIP name: scan1, IP: /testpro/192.168.1.218
SCAN VIP name: scan2, IP: /testpro/192.168.1.219
1
2
3
4
5
6
7
修改后重启scan
打开顺序:先开启scan,再开启scan监听
[root@new-rac1 rman_bak]# /u01/app/11.2.0/grid/bin/srvctl start scan
[root@new-rac1 rman_bak]# /u01/app/11.2.0/grid/bin/srvctl start scan_listener
[root@new-rac1 rman_bak]# /u01/app/11.2.0/grid/bin/srvctl status scan
SCAN VIP scan1 is enabled
SCAN VIP scan1 is running on node new-rac2
SCAN VIP scan2 is enabled
SCAN VIP scan2 is running on node new-rac1
1
2
3
4
5
6
7
重新注册remote_listener
SQL> alter system set remote_listener='testpro:1521';

System altered.

SQL> alter system register;

System altered.

SQL> show parameter remote_listener

NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
remote_listener string testpro:1521
1
2
3
4
5
6
7
8
9
10
11
12
13
因为是异机恢复,sid不同,因此需要重新添加实例名称

添加实例racpdb
[oracle@new-rac2 ~]$ srvctl add database -d racpdb -o /u01/app/oracle/product/11.2.0/dbhome_1 -p /u01/app/oracle/product/11.2.0/dbhome_1/dbs/spfileracpdb2.ora
[oracle@new-rac2 ~]$ srvctl add instance -d racpdb -i racpdb1 -n new-rac1
[oracle@new-rac2 ~]$ srvctl add instance -d racpdb -i racpdb2 -n new-rac2
[oracle@new-rac2 ~]$ srvctl config database -d racpdb
Database unique name: racpdb
Database name:
Oracle home: /u01/app/oracle/product/11.2.0/dbhome_1
Oracle user: oracle
Spfile: /u01/app/oracle/product/11.2.0/dbhome_1/dbs/spfileracpdb2.ora
Domain:
Start options: open
Stop options: immediate
Database role: PRIMARY
Management policy: AUTOMATIC
Server pools: racpdb
Database instances: racpdb1,racpdb2
Disk Groups:
Mount point paths:
Services:
Type: RAC
Database is administrator managed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
查看实例状态
[oracle@new-rac2 ~]$ srvctl status database -d racpdb
Instance racpdb1 is not running on node new-rac1
Instance racpdb2 is not running on node new-rac2
[oracle@new-rac2 ~]$ srvctl start database -d racpdb
[oracle@new-rac2 ~]$ srvctl status database -d racpdb
Instance racpdb1 is running on node new-rac1
Instance racpdb2 is running on node new-rac2
————————————————
版权声明:本文为CSDN博主「shayuwei」的原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接及本声明。
原文链接:https://blog.csdn.net/shayuwei/article/details/103767074



这篇关于PRCD-1120 : The resource for database racpdb could not be found.PRCR-1001 : Resource ora.racpdb.db d的文章就介绍到这儿,希望我们推荐的文章对大家有所帮助,也希望大家多多支持为之网!


扫一扫关注最新编程教程