mirror of https://github.com/docker/docs.git
89 lines
3.0 KiB
Markdown
89 lines
3.0 KiB
Markdown
---
|
|
title: Monitor the cluster status
|
|
description: Monitor your Docker Universal Control Plane installation, and learn how to troubleshoot it.
|
|
keywords: UCP, troubleshoot, health, cluster
|
|
ui_tabs:
|
|
- version: ucp-3.0
|
|
orhigher: false
|
|
- version: ucp-2.2
|
|
orlower: true
|
|
cli_tabs:
|
|
- version: docker-cli-linux
|
|
next_steps:
|
|
- path: troubleshoot-with-logs/
|
|
title: Troubleshoot with logs
|
|
- path: troubleshoot-node-messages/
|
|
title: Troubleshoot node states
|
|
---
|
|
{% if include.ui %}
|
|
|
|
{% if include.version=="ucp-3.0" %}
|
|
|
|
You can monitor the status of UCP by using the web UI or the CLI.
|
|
You can also use the `_ping` endpoint to build monitoring automation.
|
|
|
|
The first place to check the status of UCP is the UCP web UI, since it
|
|
shows warnings for situations that require your immediate attention.
|
|
Administrators might see more warnings than regular users.
|
|
|
|
{: .with-border}
|
|
|
|
You can also navigate to the **Nodes** page, to see if all the nodes
|
|
managed by UCP are healthy or not.
|
|
|
|
{: .with-border}
|
|
|
|
Each node has a status message explaining any problems with the node.
|
|
In this example, a Windows worker node is down.
|
|
[Learn more about node status](troubleshoot-node-messages.md).
|
|
Click the node to get more info on its status. In the details pane, click
|
|
**Actions** and select **Agent logs** to see the log entries from the
|
|
node.
|
|
|
|
{% elsif include.version=="ucp-2.2" %}
|
|
|
|
Learn how to [monitor the cluster status](/datacenter/ucp/2.2/guides/admin/monitor-and-troubleshoot/index.md).
|
|
|
|
{% endif %}
|
|
{% endif %}
|
|
|
|
{% if include.cli %}
|
|
|
|
{% if include.version=="docker-cli-linux" %}
|
|
|
|
You can also monitor the status of a UCP cluster using the Docker CLI client.
|
|
Download [a UCP client certificate bundle](../../user-access/cli.md)
|
|
and then run:
|
|
|
|
```bash
|
|
docker node ls
|
|
```
|
|
|
|
As a rule of thumb, if the status message starts with `[Pending]`, then the
|
|
current state is transient and the node is expected to correct itself back
|
|
into a healthy state. [Learn more about node status](troubleshoot-node-messages.md).
|
|
|
|
## Monitoring automation
|
|
|
|
You can use the `https://<ucp-manager-url>/_ping` endpoint to check the health
|
|
of a single UCP manager node. When you access this endpoint, the UCP manager
|
|
validates that all its internal components are working, and returns one of the
|
|
following HTTP error codes:
|
|
|
|
* 200, if all components are healthy
|
|
* 500, if one or more components are not healthy
|
|
|
|
If an administrator client certificate is used as a TLS client certificate for
|
|
the `_ping` endpoint, a detailed error message is returned if any component is
|
|
unhealthy.
|
|
|
|
If you're accessing the `_ping` endpoint through a load balancer, you'll have no
|
|
way of knowing which UCP manager node is not healthy, since any manager node
|
|
might be serving your request. Make sure you're connecting directly to the
|
|
URL of a manager node, and not a load balancer. In addition, please be aware that
|
|
pinging the endpoint with HEAD will result in a 404 error code. It is better to
|
|
use GET instead.
|
|
|
|
{% endif %}
|
|
{% endif %}
|