← all posts
// hardware · ups

The overlooked hardware upgrade: a small UPS

Buy a UPS sized for five clean minutes, not five hours, and spend whatever is left of the budget on the script that actually uses that window.

That's the rule I settled on after running a small inference box, a router, and a NAS off the same wall socket for a while and getting nervous about it. Everything past those five minutes is spec-sheet vanity, a bigger battery you're paying for and never actually needing.

Why five minutes is the number, not fifty

A home inference server is not one workload, it's several stacked on the same box, and they don't carry the same risk when the power drops. An interactive chat session loses nothing you care about: the request fails, you retry it once the lights come back. A background job is a different animal entirely, document extraction running against a folder, an overnight batch, a vector store being written to while you sleep. Cut that mid-write and you don't lose the last few seconds of work, you lose the index, and rebuilding an index is the kind of afternoon nobody plans for. Model weights themselves are basically read-only once they're on disk, so a power cut doesn't touch them, but everything built on top of them, chat history, embeddings, whatever database backs retrieval, is writable and therefore breakable. Size the battery for the time it takes the box to notice it's on battery, stop the running jobs cleanly, flush anything open, and power down. That's minutes. Buying more runtime than that mostly buys peace of mind you don't need, because if an outage runs long enough to outlast a real UPS, the internet is down too, and a fully charged server in a dark house isn't serving inference to anyone.

The part that quietly stops working

Here's the failure mode that actually bites: the battery is fine, the UPS is fine, and none of it matters because the signal path between the UPS and the host died sometime after the last OS update and nobody noticed. Most small units talk to the server over USB, and that link is exactly the kind of thing a driver update or a udev rule change can sever without throwing an error anywhere obvious. The unit still shows a green light. The battery still holds a charge. But the host never hears that it's on battery, so the automated shutdown never fires, and you find out during the actual outage, which is the worst possible moment to find out. Plugged in is not the same claim as monitored. A UPS you haven't tested with an actual cord pull in months is a UPS you're only assuming about, and specs on a box don't tell you whether the OS is still listening. Pull the plug on purpose sometimes and watch the logs, not the light on the front panel.

The sequence matters more than the hardware

The interesting engineering here isn't the battery, it's the order of operations once the box knows power is gone. Stop the inference server first so nothing is mid-generation, let the database close cleanly, unmount whatever needs unmounting, then let the OS go down last. Get that sequence wrong, or skip a step because the hook was written in a hurry, and you've bought expensive hardware that still lets a two-second brownout corrupt the one file you actually needed. Keep the script boring. A short, readable shutdown hook you can read in thirty seconds beats a clever one you have to debug live during a real outage, and it needs re-checking every time the OS, the UPS driver, or the daemon managing it gets updated, because that update is exactly where the signal path quietly breaks. It's the same instinct behind any resilient AI architecture: the expensive failure is rarely the slow path, it's the one nobody rehearsed.

What the money is actually for

None of this makes inference faster, and that's fine, it was never supposed to. The money buys state protection and a predictable, boring shutdown, not throughput, and if the budget forces a choice between a UPS and a marginally faster GPU for a home inference rig, take the UPS. Here's the tradeoff I accept on purpose: I'm not buying the ability to ride out an hour-long outage with the server still answering requests. If the power stays off past that five-minute window, the box goes down anyway, cleanly, and it stays down until the power comes back, and I'm fine with that. I wouldn't bother sizing a UPS to keep a GPU actually inferencing through a real outage at home. That's a data-center problem with a data-center budget, and chasing it in a home rack would mean spending real money to protect a use case I don't actually have.

#ups#homelab#reliability