Custom Alert - CPU Utilization[1]


This alert will calculate the average CPU Utilization in the last 5 minutes based on Ignite CPU metric data collected once every minute by default.

Note: The example below uses the "CPU Utilization" metric, but a very similar query can be used for other metrics as well. For example, if you wanted to monitor O/S Memory Utilization, you could modify the "where mn.NAME = 'CPU Utilization'" line to "where mn.NAME = 'Memory Utilization'".  For a list of all metric names, you can run these queries:

select id, name from cond; -- use the ID for the instance in the query below for <DBID>

select name from con_metrics_names_<DBID> order by name; -- substitute the value of name into the alert query


To create the alert, click on Alerts > Manage Alerts tab and create a Custom Alert of type Custom SQL Alert - Multiple Numeric Return. Configure the alert with values similar to these:

Alert Name: CPU Utilization

Execution Interval: 5 Minutes

Notification Text: The average CPU utilization for the last 5 minutes has exceeded thresholds

SQL Statement:

SELECT NVL(AVG(md.V*1.0),-1) avg_cpu_5min

FROM con_metrics_names_#DBID# mn

INNER JOIN con_metrics_#DBID# m ON m.metric_name_id =

INNER JOIN con_metrics_detail_#DBID# md ON = md.metrics_id

WHERE = 'CPU Utilization'

AND md.d >= SYSDATE - (5/1440)

Execute Against: Repository

Units: % CPU Utilization

High Threshold: Min 90, Max empty

Medium Threshold: Min 80, Max 90