Using Glauco
CPU and memory bars
How the usage bars and meters work: usage, requests, limits, percentages and colours.
Usage, requests and limits
- Usage
- What a pod or node uses right now. Glauco reads it from the
metrics.k8s.ioAPI, which metrics-server provides. - Request
- What a container asks for. The scheduler reserves this amount on a node. It is in the pod spec.
- Limit
- The most a container may use. Over the memory limit, the container is killed; over the CPU limit, it is slowed down. It is in the pod spec.
For a pod, Glauco adds up the requests and limits of its containers. Init containers do not count. For a workload, such as a Deployment or a CronJob, Glauco adds up the pods it owns.
How to read a bar
The CPU and memory columns are bars. The whole cell is the bar, and the value sits on the right. The fill shows usage as a share of one number, the percent basis.
What the percentage is a percentage of
Glauco picks the percent basis in this order:
- Pods and workloads
- The limit. If no container sets a limit, the request. If neither is set, the allocatable CPU or memory of all nodes in the cluster. On a node's Pods on this node card, it is that node's allocatable.
- Containers
- The container's own limit, then its request, then allocatable.
- Nodes
- Always the node's allocatable CPU or memory. Never its capacity.
Hover a bar to see the basis. The tooltip shows the amount, the exact percentage and its basis, for example 380m · 38.0% of limit · Click to show percentages. The basis reads of limit, of request or of allocatable.
Show amounts or percentages
Click any CPU or memory bar to switch between amounts (380m, 252.3Mi) and percentages (38%). The switch applies to every table in the app, and Glauco remembers it. Clicking a bar does not open the row.
- CPU is in millicores:
1500mis one and a half cores. - Memory is in
Mi, or inGifrom 1 GiB, with one decimal. - The cell shows a whole percentage. The tooltip shows one decimal.
The switch changes only the table bars. The meters in a detail view and on the dashboard always show percentages.
Colours
Table bars use one colour per resource, and turn red near the basis:
- 42%CPU under 90%: green.
- 61%Memory under 90%: blue.
- 94%90% or more: red, for CPU and memory.
- 140%Over 100%: red stripes past the 100% mark, and a red value.
- —No data: an empty bar and a dash.
The meters in a detail view, the node Capacity card and the dashboard use a different scale:
- green under 70%;
- amber from 70% up to 100%;
- red at 100% or more.
Meters in the detail view
Open a pod or a workload. The Utilization card has a CPU meter and a Memory meter. Each meter shows:
- the percentage of the basis, with two decimals;
- a line chart of the last few minutes, once there are two samples;
- Usage, Requested and Limit. Limit shows Not set when no container sets a limit.
Open a node. The Capacity card shows CPU and Memory as usage over allocatable, for example 850m / 4000m, and Pods as scheduled pods over the node's pod limit.
Node requests and limits
On the Nodes screen, the CPU & Memory: menu above the table has three options:
- Usage
- What the node uses now, from metrics-server.
- Requests
- The sum of the requests of the pods on the node, as a share of its allocatable. This is how full the scheduler thinks the node is.
- Limits
- The sum of the limits of the pods on the node. A container without a limit adds 0.
Finished pods (Succeeded or Failed) do not count. Requests and limits can go over 100% on an overcommitted node. Requests and Limits work without metrics-server, because they come from the pod specs. Glauco remembers your choice.
Without metrics-server
If the cluster has no metrics-server, or it is not ready, Glauco shows this banner above the table:
Glauco shows
Metrics unavailable — install metrics-server to see CPU & Memory usage.
- Every CPU and memory bar is empty and shows a dash.
- The detail meters show a dash for usage. Requested and Limit still show.
- On the dashboard, the top consumer panels show Metrics unavailable.
- A bar also shows a dash when there is data but no basis, for example a pod with no request, no limit and no node data.
See CPU and memory are empty to fix it.
How often values refresh
- Glauco asks metrics-server for pod and node usage every 10 seconds.
- The charts in the detail view keep the last 30 samples, about 5 minutes.
- Requests, limits and the tables themselves do not poll. They update live as objects change in the cluster.
- metrics-server itself collects new values about every 15 seconds by default, so a value can be that old.
- For history beyond these few minutes, see History from Prometheus.
Still stuck? Contact us.