前言

最近用 EMCC 13c 纳管了一套 Oracle RAC,纳管数据库后前端显示报错信息:

本文分享一下解决方案,安装 EMCC 可参考:

问题分析

首先,检查被纳管主机是否配置 rac_global_cache_10i 收集任务:

1
2
3
4
5
6
7
8
9
10
11
## 在被纳管主机端执行
## 检查是否配置 rac_global_cache_10i
## 节点一
[oracle@lucifer01:/u01/app/emagent/agent_13.5.0.0.0/bin]$ ./emctl status agent scheduler | grep rac_global_cache_10i

2025-06-04 11:46:05.097 : oracle_database:lucifer01:rac_global_cache_10i

## 节点二
[oracle@lucifer02:/u01/app/emagent/agent_13.5.0.0.0/bin]$ ./emctl status agent scheduler | grep rac_global_cache_10i

2025-06-04 11:47:32.035 : oracle_database:lucifer02:rac_global_cache_10i

如果没有输出,则不会遇到上述问题,一般存在收集任务,才会报错 Metrics Global Cache Blocks Lost is at XXX

解决方案

以下操作均需在 OMS 服务端执行:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
## 在 OMS 服务端执行
[oracle@emcc:/home/oracle]$ source ~/.oms

[oracle@emcc:/home/oracle]$ emcli login -username=sysman
Enter password

Login successful

[oracle@emcc:/home/oracle]$ emcli sync
Synchronized successfully

## 这里的 targetNames 要写被纳管的数据库实例名称
[oracle@emcc:/home/oracle]$ emcli modify_collection_schedule -targetType="oracle_database" -targetNames="lucifer01" -collectionName="rac_global_cache_10i" -collectionStatus=Disabled -preview="N"
Collection Name : rac_global_cache_10i
lucifer01 : Collection Schedule updated successfully.
The collection schedule of the following metrics might be affected :
rac_global_cache

[oracle@emcc:/home/oracle]$ emcli modify_collection_schedule -targetType="oracle_database" -targetNames="lucifer02" -collectionName="rac_global_cache_10i" -collectionStatus=Disabled -preview="N"
Collection Name : rac_global_cache_10i
lucifer02 : Collection Schedule updated successfully.
The collection schedule of the following metrics might be affected :
rac_global_cache

如果遇到报错:

1
2
[oracle@emcc:/home/oracle]$ emcli modify_collection_schedule -targetType="oracle_database" -targetNames="lucifer" -collectionName="rac_global_cache_10i" -collectionStatus=Disabled -preview="N"
oracle_database : Collection Name not valid.

一般就是数据库实例名写错了,这个数据库实例要么没有配置 rac_global_cache_10i,要么是单实例数据库,需要通过在被纳管主机执行 emctl status agent scheduler 进行检查,确认正确的数据库实例,再进行修改。


参考 MOS: