Servers
jokku top
A live view of your servers, apps, instances and every request, in your terminal.
A live view of the machines, apps, instances and recent events, with CPU, memory and disk for each, refreshed every two seconds. Over SSH it needs a terminal, so use ssh -t jokku@your-server top, or put -t in your alias.
Views#
Switch with the number keys, or with tab:
On a server or app, press enter to see its instances, and l for an app's logs. esc goes back, ? shows help and q quits.
Apps and databases#
The overview and Apps list your external apps and databases apart from your apps, below them: each external app with the address it goes to and the server that reaches it. On Apps, each app has the databases it's linked to under it, with the config var that holds each one's URL, and each database shows the apps that use it. SIZE is what each instance gets, mixed when an app's process types differ; the line under the list names each process type's size for the selected app:
An app or database that's asleep (or stopped) isn't counted as unhealthy: the header says how many of its instances are, as in 21/21 instances healthy · 1 asleep.
Traffic#
Press 6 for Traffic. Every request flies across its app's lane as a dot and lands on the instance and server that answered:
Dots are green for success, cyan for redirects, yellow for 4xx and red for 5xx, and each trails a tail as it goes. A request slower than most of its app's crawls across, trailing amber, and a 5xx bursts where it lands. The instance a request lands on lights up, and busy lanes glow.
After each app's name are its machines: how many, and a dot for each. A dot is green while its machine runs, yellow while it starts, red when it's down, and hollow and dim while the app sleeps, when the lane says asleep. An app with more than one process group, such as web and worker, gets a line for each under its lane. An app's name turns orange while one of its requests is on the way.
The headline shows requests per second, latency and error rate over the last ten seconds. Under it are the p50 and p95 over the last hour and the last 24 hours, for every request any of your servers' proxies handled. Under those is the last minute, a second at a time.
Each server keeps its own record of how long its requests took, rebuilt from its proxy's log when it restarts, and the control server adds them all up. The percentiles are therefore the whole cluster's, to within 5%. A server that's down or doesn't answer is named on the line, and its requests are left out. Below the lanes, you'll see which servers' proxies received the traffic and a list of recent requests.
Press p to pause, c to clear and f to turn the effects off. With them on, the view redraws about 30 times a second: over ssh -t on a slow connection, turning them off keeps it responsive. Run on your own computer, jokku top draws there and fetches only the requests from your server.
Backups#
Press 7 for Backups: every volume and the cluster itself, backed up or not, so you can tell at a glance that everything that matters is safe.
Dots are green when backups are up to date, yellow when one is overdue or hasn't happened yet, red when the last one failed, and grey when there are none. When nothing needs attention, the top line says Everything is backed up. The selected row shows where its backups go, what's kept, and a chart of recent backups by how much each added, with failures in red.
Restoring replaces data, so it stays on the command line: the selected row shows the jokku backups:restore command for it. See Backups.
Databases#
Press 8 for Databases: what your control server sees inside each database, looking every ten seconds.
Each row shows a database's connections against its limit, how many are running a query, its queries a second, how long they take, and how often reads came from memory (for Redis, how often a key was found). w switches between the last minute, hour and day. Postgres shows an average where the others show p50, p95 and p99: see what each engine keeps.
Under the table is the selected database: each span's numbers, who's connected (an app's instance, or clients outside through a server's or edge's proxy), its slowest queries and its users. enter shows its instances and l its logs.
Firewall#
Press 9 for Firewall: what the firewall in front of your sites is doing.
At the top are the rules and the counts for the span: every request the firewall saw, those it blocked from banned addresses, those it slowed for coming too fast, the bans it made, and the pages not found that count toward them. w switches between the last minute, hour and day.
Then the banned addresses, newest first: the site whose pages not found got each one banned, how long ago and how long it has left, the requests it has made since, which proxies banned it, and the last pages it asked for. u lifts the selected ban. Under them are the addresses getting close to a ban, those slowed in the last hour, and each site's counts.
Network#
Press 0 for Network: the latest test of the links between your servers, which you start with t (twice, since it loads each link in turn). Each server sends to each other one as fast as it can for three seconds and pings it 100 times, one link at a time, over the same encrypted network your apps use.
A link that is noticeably slower than the usual one, or lost a ping, is amber; one at half the usual speed or less, or losing more than 2% of its pings, is red. A server with a bad cable or switch port makes every link it's on look wrong, so when most of a server's links do, it's the one named at the top, and the others' links to it don't count against them. The last column compares each server with the test before, so test before you change your network (a new switch, say) and again after. jokku network:test and jokku network:report do the same from the command line.