Alert description
This alert monitors whether there are non-working OBServer nodes in the OceanBase cluster and triggers when any are found.
Alert principle
The following table lists the key parameters involved in the monitoring logic of this alert.
Parameter |
Value |
|---|---|
| Monitoring Metrics | inactive_server_count: Indicates whether there are non-working OBServer nodes in the OceanBase cluster. An alert is triggered when this metric value exceeds the threshold. |
| Monitoring Metric Expression | max(ob_server_num{status="inactive",@LABELS}) by (@GBLABELS) |
| Collection Metrics | ob_server_num |
| Data Source | Collected from internal views. Collection SQL:select /*+ MONITOR_AGENT READ_CONSISTENCY(WEAK) */ group_concat(svr_ip SEPARATOR ',') as servers, status, count(1) as cnt from __all_server group by statusselect /* MONITOR_AGENT */ group_concat(svr_ip SEPARATOR ',') as servers, status, count(1) as cnt from DBA_OB_SERVERS group by status |
| Collection Cycle | 60 Seconds |
OceanBase Database uses a heartbeat mechanism to determine the status of each OBServer node and updates the status in real time to the __all_server table. Each OBServer node can access this table.
Rule information
Monitoring Metrics |
Default Threshold |
Duration |
Detection Cycle |
Elimination Cycle |
|---|---|---|---|---|
| inactive_server_count | 0 | 30 Seconds | 10 Seconds | 5 Minutes |
Alert information
Alert Trigger Method |
Alert Level |
Scope |
|---|---|---|
| Based on monitoring metric expression | Downtime | Cluster |
Alert template
Alert overview
- Template: ${alarm_target} ${alarm_name}
- Example: alarm_template_id=0:ob_cluster=obcluster-1 An OBServer node is down in the OceanBase cluster.
Alert Details
- Template: Cluster: ${ob_cluster_name}, Alert: ${alarm_name}. The number of non-working OBServer nodes is ${value}, and the IP addresses of the non-working OBServer nodes are ${server_ips}.
- Example: Cluster: obcluster-1, Alert: OceanBase cluster has non-working OBServer nodes. Number of non-working OBServer nodes: 2. Non-working OBServer nodes: xxx.xxx.xxx.1, xxx.xxx.xxx.2.
Alert recovery
- Template: Alert: ${alarm_name}, Number of Non-Working OBServer Nodes in OceanBase Cluster: ${value}
- Example: Alert: OceanBase cluster has non-working OBServer nodes. Number of non-working OBServer nodes in the OceanBase cluster: 0
Here, ${alarm_target} indicates the object that generated the alert. The format is ob_cluster=xxxxxxx, where ob_cluster is the name of the cluster that generated the alert.
Impact on the system
The number of available OBServer nodes decreases, leading to reduced cluster availability.
For example, in a three-node cluster, if one node stops abnormally, the number of replicas drops from three to two. If another node then stops abnormally, the cluster becomes unavailable.
Possible causes
This commonly occurs in the following three scenarios:
Network communication failure.
OBServer node failure or abnormal process stop.
The observer process is alive but unresponsive and does not report a heartbeat.
Solution
Determine whether you still need to use this OBServer node.
If necessary, proceed to the next step to investigate why the OBServer node is not working.
No, you can delete the OBServer node directly.
Check for network communication failures.
Run the following command to check for network failures between OBServer nodes and leader OBServer nodes.
#Ping the leader OBServer node from the OBServer node. xxx.xxx.xxx.1 is an example IP address of the backup storage host. ping xxx.xxx.xxx.1 #Ping the OBServer node from the leader OBServer node. xxx.xxx.xxx.2 is an example IP address of the OCP host. ping xxx.xxx.xxx.2Note
You can execute the following statement in the sys tenant of the OceanBase cluster to obtain the IP address of the leader OBServer node.
select svr_ip,with_rootserver from oceanbase.__all_server;If consecutive data packets are sent, the network is normal. The alert may be triggered by other reasons.
If no consecutive data transmission messages are returned, a network failure has occurred. Please contact the network administrator to troubleshoot the specific network issue. If no network administrator is available, refer to Network troubleshooting to troubleshoot and fix the issue.
Check whether the OBServer node is faulty or its process has stopped abnormally.
Check whether the ob_cannot_connected OB Server Cannot Be Connected alert is reported.
Yes, the OBServer node is faulty or the process is abnormal. First, refer to ob_cannot_connected OB Server Cannot Be Connected to resolve the issue.
No. Other causes may be involved. Proceed to the next step for troubleshooting.
Check whether the observer process is running normally but fails to report a heartbeat.
On the Hosts page of OCP, go to the corresponding OBServer node and check whether the processes on the OCP Agent tab are normal.
If the process is running normally but the OBServer node is still unreachable, it may be that the heartbeat is not being reported. It is recommended to check whether the disk or memory is sufficient.
#Check remaining memory free -m #Check the disk usage of the OBServer node directory (default: /home/admin). df -hInsufficient disk or memory may prevent the OBServer node from reporting its heartbeat.
Insufficient disk space. Expand the disk capacity, clean up useless logs, or reduce the data retention period based on business requirements.
Insufficient memory. Expand the memory or reduce the tenant specification based on business volume.
The disk and memory are sufficient. Proceed to the next step.
Contact OCP technical support for troubleshooting.