Unable to collect specific KPIs using CA
Unable to collect specific KPIs using CA in CA KPI Issues.
Unable to collect specific KPIs using CA#
The following KPIs could not be collected using the CA.
1. KPI — PROC_FILE_HANDLES
Cause: the CA may be running as a non-root user. This KPI uses the pfiles command in Solaris; pfiles has execute permission for non-root users, but it cannot read the File_Handle information of root-owned processes.
Solution: run the CA as root to collect this KPI; otherwise it cannot be collected.
2. KPI — CAP_VALUE
Cause: no pool has been configured to monitor.
Solution: if uploading metadata, check that the pool is present; configure the pools you want to monitor. If missed during metadata upload, configure the pools in the comp_instance_kpi_group_details table.
Note: CAP_VALUE is a Solaris KPI. Verify the available pools with
zpool list.
bash-3.2$ zpool list
NAME SIZE ALLOC FREE CAP HEALTH ALTROOT
rpool 29.8G 26.0G 3.79G 87% ONLINE -
seconddisk 14.9G 12.2G 2.71G 81% ONLINE -
3. KPI — DB_Sequence
Problem: the DB_Sequence KPI is collected and stored in Cassandra, but it is not visible in the UI.
Reason: the data is not shown because the DB_Sequence KPI was mapped to WebLogic during upgrade (affecting users who upgraded sequentially from 5.0.2). Remap the KPI to the Oracle component.
Solution: log in to Percona and execute:
update mst_component_version_kpi_mapping set
mst_common_version_id=20, mst_component_id=19
where mst_kpi_details_id = 410;
4. KPI — HOLDERWAIT SESSION COUNT
Problem: the HolderWait Session Count KPI cannot be collected; the SQL query times out.
Reason: the SQL query was wrong in agent-details.json and Percona.
Solution: update the query for producer 156 in Percona and restart the CA after removing agent-details.json:
update jdbc_producer set query = 'select /*+rule*/ count(*) as
HOLDERWAITSESSIONSCOUNT from v$lock where
(id1,id2,type) in (select id1,id2,type from v$lock where request>?)
and lmode=? order by id1,request'
where mst_producer_id=156;
5. KPI — Oracle DiskGroup KPIs (TOTAL_SIZE_MB, AVAIL_SIZE_MB, AVAIL_SIZE_PER)
Problem: the DiskGroup KPIs cannot be collected by the CA, though running the query manually on the DB returns the value.
Reason: a build issue in the jdbc-producer library — the DiskGroup name is not parsed in the query. A new CA build is required; use the workaround below in the meantime.
Solution: in agent-details.json, for each DiskGroup KPI, update the value field in the Parameters section from {DiskGroup} to the DiskGroup you want to monitor (hard-code it).
Note: For this step you must provide a dummy DS URL in
basic.properties.
6. KPI — Tablespace_Full
Problem: the Tablespace_Full KPI is not collected; error code E1046 appears in the CA logs.
Reason: the collection query uses the alias TABLESPACEFULL, but the KPI name is TABLESPACE_FULL. This mismatch causes a parsing error.
Solution: in agent-details.json, change the alias TABLESPACEFULL to TABLESPACE_FULL.
Note: Apply the same in Percona so the CA retrieves the corrected query via the DS call.
update jdbc_producer set query="select /*+RULE*/ count(*) as TABLESPACE_FULL
from ( select tablespace_name, sum(bytes) physical_bytes,
sum(decode(autoextensible,'NO',bytes,'YES',maxbytes)) bytes_alloc
from dba_data_files group by tablespace_name ) a,
( select tablespace_name, sum(bytes) tot_used from dba_segments
group by tablespace_name ) b
where a.tablespace_name = b.tablespace_name (+)
and (nvl(b.tot_used,0)/a.bytes_alloc)*100 > ?
and a.tablespace_name not in (select distinct tablespace_name from dba_temp_files)"
where mst_producer_id=168;
Unable to Gather Data from All Data Sources' KPIs#
Case 1: Component Agent producers unable to discover all data sources#
Cause: a data source has two producers — one for JRockit and one for JDK (producer IDs 130 and 131 respectively). By default it is set to 130 (JRockit). If WebLogic is deployed with JDK, the default producer cannot discover all KPIs.
Solution:
1. Check whether WebLogic is deployed with JDK or JRockit. If JDK, change the producer ID to 131 in agent-details.json and validate that all data sources are discovered in the CA logs.
2. Make the change permanent in Percona:
-- Get the instance id from comp_instance
select * from comp_instance_kpi_group_details
where comp_instance_id = <weblogic_comp_instance_id> and mst_producer_id = 130;
update comp_instance_kpi_group_details set mst_producer_id=131
where id in (<ids from previous statement>);