On Exadata database servers, it is also possible to set thresholds for metrics and send notifications when they reach these threshold values.
With DBMCLI, we can display the defined metrics in the compute nodes and the current values of the metrics as follows.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 | DBMCLI> LIST METRICCURRENT DS_BBU_CHARGE exadb01 83.3 % DS_BBU_TEMP exadb01 22.0 C DS_CPUT exadb01 21.8 % DS_CPUT_MS exadb01 0.1 % DS_FANS exadb01 16 DS_FSUT / 68 % DS_FSUT /boot 12 % DS_FSUT /u01 27 % DS_MEMUT exadb01 93 % DS_MEMUT_MS exadb01 0.3 % DS_RUNQ exadb01 16.9 DS_SWAP_IN_BY_SEC exadb01 0.0 KB/sec DS_SWAP_OUT_BY_SEC exadb01 0.0 KB/sec DS_SWAP_USAGE exadb01 0 % DS_TEMP exadb01 19.0 C DS_VIRTMEM_MS exadb01 685 MB N_HCA_MB_RCV_SEC exadb01 235 MB/sec N_HCA_MB_TRANS_SEC exadb01 94.133 MB/sec N_IB_MB_RCV_SEC HCA-1:1 106 MB/sec N_IB_MB_RCV_SEC HCA-1:2 129 MB/sec N_IB_MB_TRANS_SEC HCA-1:1 47.552 MB/sec N_IB_MB_TRANS_SEC HCA-1:2 46.580 MB/sec N_IB_UTIL_RCV HCA-1:1 3.2 % N_IB_UTIL_RCV HCA-1:2 3.9 % N_IB_UTIL_TRANS HCA-1:1 1.4 % N_IB_UTIL_TRANS HCA-1:2 1.4 % N_NIC_KB_RCV_SEC exadb01 1,454 KB/sec N_NIC_KB_TRANS_SEC exadb01 2,161 KB/sec |
We can query whether there are threshold values for the defined metrics as follows.
1 2 3 4 5 6 7 8 9 10 | DBMCLI> list threshold detail name: DS_FSUT comparison: > critical: 90.0 warning: 70.0 name: DS_MEMUT comparison: > critical: 90.0 warning: 70.0 |
According to the output above, when the metrics DS_FSUM and DS_MEMUT reach 70%, warning will be generated and critical status will occur when it reaches 90%. When the threshold values are reached, the following records will be created in alerthistory and e-mail alerts will be sent if smtp settings have been set via dmcli.
1 2 3 4 | DBMCLI> list alerthistory 1_1 2018-08-02T13:40:26+03:00 warning "The warning threshold for the following metric has been crossed. Metric Name : DS_FSUT Metric Description : Percentage of total space on this file system that is currently used Object Name : / Current Value : 68.0 % Threshold Value : 50.0 % " 1_2 2018-08-02T13:42:26+03:00 clear "The warning threshold for the following metric has been cleared. Metric Name : DS_FSUT Metric Description : Percentage of total space on this file system that is currently used Object Name : / Current Value : 68.0 % Threshold Value : 70.0 % " 2_1 2018-08-02T14:29:26+03:00 critical "The critical threshold for the following metric has been crossed. Metric Name : DS_MEMUT Metric Description : Percentage of total physical memory on this server that is currently used Object Name : exadb01 Current Value : 96.0 % Threshold Value : 90.0 % " |
You can set a new threshold value below. In the example, when the usage rate in the file system reaches 50%, the warning will be generated, and the critical situation will occur when it reaches 90%.
1 2 | DBMCLI> CREATE THRESHOLD DS_FSUT comparison='>',warning=50,critical=90 Threshold DS_FSUT successfully created |
To change the defined threshold value:
1 2 | DBMCLI> alter THRESHOLD DS_FSUT comparison='>', warning=70 Threshold DS_FSUT successfully altered |
You can see the changes as follows.
1 2 3 4 5 | DBMCLI> list threshold detail name: DS_FSUT comparison: > critical: 90.0 warning: 70.0 |
The threshold values can be set for all defined metrics.