Servers

Glances

Keep an eye on your Linux boxes without opening a browser tab. Glances already measures each one’s CPU, memory, disks and sensors; these pages put them in the menu bar, a dot for each box, and notify you when a disk fills, memory runs short, the CPU stays flat out or something runs hot.

Install in LegatoSet it up by hand ↓

Glances
Boxes4 of 8 need attention
atlas.local192.0.2.30build.local192.0.2.31garden.local192.0.2.32printer-pi.localgarage.local
Updated 12 min ago

What you’ll see

Glances

A dot for each box on your list, named by its address there (atlas.local, 192.168.1.20), coloured by the same rules as its own page, with its host name and what needs you when you point at it (“atlas · /mnt/media 96% full”). An entry the list can’t read is a grey dot that says why. One that misses a read keeps its colour; after three in a row it says it can’t read that Glances. A click opens the box’s page.

Box

One page for each box, titled with its host name.

  • Health: the box, in Details. When something needs you, it says what: a sensor past its mark, the fullest disk (“/mnt/media 96% full and 1 more”), memory in use, or “CPU 96% for 15 minutes”. The ⓘ button by the page’s title then turns orange or red. Otherwise it says how long the box has been up.
  • CPU and Memory: two small charts from 0 to 100% of Glances’ own readings over the last 2 hours, a point for each time Legato or anything else asked.
  • Disks: every disk Glances can see, fullest first. A disk mounted in two places is listed once, and the files Docker mounts into every container are left out.
  • System: load over 1, 5 and 15 minutes, the CPU and its cores, the system it runs (“Debian GNU/Linux 13”), processes and threads, swap in use and how long the box has been up. Processes opens the box’s Processes page.
  • Temperatures: a dot for each temperature sensor, the CPU’s and the drives’, hottest first, coloured by the marks the hardware reports, with its reading when you point at it. It’s there only when the box has sensors.
  • Recent alerts: the latest four in Glances’ own log (the rest on its own page), such as “Memory critical”, with when it started or ended, the peak and the program Glances saw using the most. Clear finished alerts in the corner empties Glances’ log of the ones that are over, after asking; ones still going stay.

Processes

Opened from a box’s System card: the box’s running processes by CPU and by memory, the 40 busiest in each. When there are more, the list’s title says “40 of 136”. Processes of one program are added together, so postgres shows once with “14 processes”. One using more than one core reads over 100%.

Status

  • Watches every box’s disks, memory, CPU and temperatures, a dot each.
  • Orange when a disk is 90% full, memory is 90% used, CPU averages 90% for 15 minutes or a sensor passes its warning mark.
  • Red when a disk is 95% full, memory is 95% used, a sensor passes its critical mark or Legato can’t read that Glances three times running.
  • Notifies you when it turns orange or red.

How it connects

The pages read Glances’ REST API, version 4, on every box on the list. Glances has no sign-in unless you start it with a password.

Requests it makes on its own 6

  • GET /api/4/system, /uptime, /fs, /sensors, and /mem on Glances or /quicklook on a box’s page

    The host name and how long it’s been up, each disk and how full it is, each sensor with the marks the hardware reports, and memory in use.

    Glances, boxOnce a minute, for each box

  • GET/api/4/quicklook/cpu/history/1200

    Every reading of CPU Glances keeps, with its time: the chart of the last 2 hours, and whether the CPU has stayed high.

    Glances, boxOnce a minute, for each box

  • GET/api/4/mem/percent/history/1200

    Glances’ readings of memory, for the chart.

    BoxOnce a minute while it’s open

  • GET /api/4/quicklook, /system, /load, /memswap, /processcount

    The CPU’s name and cores, the system it runs, load, processes and threads, and swap.

    BoxOnce a minute while it’s open

  • GET /api/4/alert, /cpu

    Glances’ log of alerts. Reading /cpu is also what has Glances log CPU alerts.

    BoxOnce a minute while it’s open

  • GET/api/4/programlist

    The running processes, added together by program, with their CPU and memory.

    ProcessesOnce a minute while it’s open

Requests it makes when you act 1
  • POST/api/4/events/clear/all

    Removes the finished alerts from that Glances’ log, for its web page too.

    BoxWhen you press Clear finished alerts and confirm

That’s 360 requests an hour for each box on the list, 840 more while a box’s page is open and 60 while its Processes is, all to your own boxes. Legato reads four boxes at a time and up to 20 in all. Glances works out its numbers when it’s asked, so these requests are also what fills its history, and Glances logs CPU and load alerts only while a box’s page is open.

Sources and buttons explains each part of a page. Glances’ API documentation lists everything it reports.

Set it up

  1. Run Glances as a web server on the box, with glances -w, or in Docker with the -full image and GLANCES_OPT="-w". It answers on port 61208. Glances’ Docker guide shows the settings that let it see the host: its processes, the Docker socket and the host’s name.
  2. In Docker, mount the disks you want to see, read-only. A container sees only its own files until you mount a disk into it, so without that the Disks card says Glances sees none.
  3. List your boxes: in Settings → Lists, make a list named glances-hosts with each box’s address on its own line, such as http://192.168.1.20:61208 or http://atlas.local:61208. macOS lets Legato use plain http only to an IP address, a .local name or a one-word name, so http://atlas.lan:61208 isn’t read; use its IP address or its .local name.
  4. Add the pages. Use Install in Legato, paste the prompt into your agent, or download the three pages and run /Applications/Legato.app/Contents/Helpers/legato set glances-box-programs glances-box-programs.json, then the same for glances-box and glances-boxes. Keep their IDs: the dots and the Processes row open them.
  5. If a Glances has a password (glances -w --password): save a secret named glances in Settings → Secrets for that box’s address, as glances: and the password, or your own user name if you started Glances with --username. Boxes without a password need nothing, and a box that asks for one with none saved says so on its dot.

The dots fill within a minute, and the charts fill as readings come in.

Prompt for your agent

prompt
Add 3 Legato pages for Glances, starting from https://legatobar.com/examples/glances-boxes.json, https://legatobar.com/examples/glances-box.json, https://legatobar.com/examples/glances-box-programs.json. Use the page IDs glances-boxes, glances-box, glances-box-programs if they’re free: the pages link to each other by those IDs, so with any other ID, change the matching legato://page/ links.

Add the three pages as they are, keeping their page IDs. I’ll make the list glances-hosts in Settings → Lists with each box’s address, such as http://192.168.1.20:61208, and save the secret glances as glances:<password> for any box that has a password, myself. Don’t press Clear finished alerts to test it.

Use the local Legato MCP tools or /Applications/Legato.app/Contents/Helpers/legato.
Use list_pages first and choose an unused page ID. Do not overwrite an existing page. If I explicitly ask to update one, read its full body with get_page, preserve unrelated cards and settings, and use if_match with that version. On version_mismatch, read again before merging.
Ask me only for non-secret setup details that are missing. Never ask me to paste a password, token or API key into chat, page JSON or command arguments. Tell me to save it in Settings → Secrets for the service host, or link it from 1Password there.
Use the downloadable page, not the illustration’s sample data. Never invent readings. Fix any invalid_page paths and verify that the page loads. Do not press buttons that change the service or real devices to test it.

Download the pages

Questions

When does a busy CPU count as a problem?

When Glances’ readings of the last 15 minutes average 90% or more, and each five minutes of them at least 75%. A compile or a backup that runs flat out for a few minutes is the box working, and the chart shows it; a CPU that stays there for a quarter of an hour turns the page orange. It’s an average, so one reading that dips under load doesn’t reset the count, and it’s taken five minutes at a time, so a burst of readings from Glances’ own web page can’t outweigh quiet minutes. Legato needs readings reaching back at least 12 of those minutes, so a Mac that has just woken up waits until it has seen enough. It compares Glances’ times with the Mac’s clock, so keep the box’s clock set (NTP).

Can I change when it counts as a problem?

Yes. The numbers are in the derive of the list’s boxes source and the box page’s glances source, and its host card’s state, the same on both: 90 and 95 for disks, 90 and 95 for memory, and an average of 90% over 900 seconds, 75% each third, for the CPU. Temperatures use the marks the hardware reports, so a sensor without marks never counts as a problem.

Why does Recent alerts show a warning when the page isn’t lit?

Recent alerts is Glances’ own log, at Glances’ own levels, which are lower than the page’s unless you’ve changed them, and it logs one as soon as a reading crosses them. It counts as a problem later, at 90% memory, or CPU averaging 90% for 15 minutes. So the list can say “Memory warning” with a peak of 78% while the page stays quiet. Glances logs CPU, memory, swap and load only while something reads them, and keeps the last ten. To change its levels, see Glances’ configuration.

Why is Processes out of date when I open it?

Glances works out each process’s CPU since the last time it was asked for the list. If you open it after a long while, the first reading is an average over that time, and a process that started since shows 0%. The page asks again a minute later, and from then on it’s the last minute’s.

Why are the charts sometimes short?

Glances keeps its readings in memory and starts again when it restarts. It takes a reading each time it’s asked, so after a restart the charts fill as Legato asks, once a minute. A Glances started with --disable-history keeps none, so the charts aren’t shown and a busy CPU can’t count as a problem.

Why does the page say a request failed with HTTP 400?

Glances answers 400 for a part you’ve turned off with --disable-plugin, and a box is read with all its requests or not at all. If you’ve turned off sensors on a box, remove the sensors request from the pages; the Temperatures card goes with it.

A box’s page is opened by a key Legato makes from its address, so a link can never send a page or its password to another box. Change a box’s address in the list and it has a new key: open it again from its dot.

The pages were filled from Glances 4.5.9 on 12 Nov 2026, running in Docker on a Linux server with its disks mounted, one of them full. A load test took memory past 95%, and a 17-minute one lit the page with “CPU 94% for 15 minutes”. Clear finished alerts was pressed on it, and the alert still going stayed. Again with a password, Legato signed in, a wrong one was refused, and Clear finished alerts went through. On 13 Nov the list read both copies as two boxes: without a password saved, the one with a password said it asks for one, and with it saved both answered, and a box’s page read its box by its key. A box missing a read and one that can’t be read are checked by tests with made-up answers. With --disable-history, Glances answers no history, which the pages allow for. Sensors, a box with no disks visible, uptime under a day and a Glances Legato can’t read are checked by tests with made-up answers. Illustrations are of a made-up box. See the service index for other examples.

Legato is independent and isn’t affiliated with or endorsed by Glances.