💾 Archived View for thrig.me › blog › 2024 › 07 › 06 › ups-story.gmi captured on 2024-08-31 at 12:52:34. Gemini links have been rewritten to link to archived content
⬅️ Previous capture (2024-07-09)
-=-=-=-=-=-=-
So at some point management decided to buy the UPS; it was a budget model from a budget vendor and not the more expensive pair the IT group had recommended. There was a pair as all the rack-mounted servers had two power supplies, and in theory there were different circuits feeding the UPS, and if you're really fancy you'll have two different power lines coming into the building, from two different providers. (A single earthquake can still ruin all this redundancy.) Anyways it turned out that the Linux software shipped by the budget vendor was only for Fedora 12, which may not be the right number, but if you think "at least a decade out of date and clearly not getting security updates" you wouldn't be far wrong. Also it was only for 32-bit linux, while in production we had already in some past year migrated everything to 64-bit. So to actually run the vendor's software—apart from running some Windows system, nope, not happening—we would have had to install a Fedora 12 32-bit system and wire up the UPS to that. At least the UPS used USB and not $100 serial cables with some janky non-standard pinout as was common back in the good old days.
There is the open-source Network UPS Tools (NUT) which avoids having to run whatever the vendor shipped, though here the budget UPS ran into the problem that over USB the two different UPS (there's a pair of them, remember) identified as the exact same thing. So one could not simply plug both UPS into one host, as they looked the same as far as USB was concerned. A clever trick was to plug the UPS into two different systems, run NUT on each, and then to write some new software that talked to a different instance of that same software running on the other host to figure out whether the communication was up, whether the UPS were on battery, and whether a both should power off their respestive UPS. There was not time to actually test this software across a critical shutdown or two, as the need to write this software was discovered after the new UPS had already been installed and wired up (whoops, or an event that would have required the UPS to force powerdown the hosts I had never seen in at least 20 years). It's not like we had a lot of UPS to benefit from scale, nor did we have spares to test on. That would cost money!
One might wonder whether it would have been less expensive and have wasted less time to buy the more expensive UPS (what had been installed prior, from when there were more favorable budgetary conditions) rather than spending who knows how many hours figuring all of the above out.
Apparently things are even sillier in other areas of the economy,
gemini://gemini.sensorstation.co/~winduptoy/journal.homebuilding.gmi
"Cut Every Corner". The Simpsons. 1997.
P.S. Hopefully I said UPS when talking about the UPS and USB when talking about USB.
One probably shouldn't blame the programmer of the UPS software; it might have been someone given too little time and oh we also want you to write something for linux, too. Maybe if the documentation, source code, and API were available, that would be more useful, though too many vendors try to hide all that. Did you know that most all operating systems claim to be Windows (or Darwin) on the ACPI front?
There's a long history related to _OSI that I won't go into, but basically every OS claims to be Windows now, except on Apple hardware, where we all claim to be Darwin, because it's easier for other OSes to behave like Windows and macOS than for the hardware vendors to update their BIOS code when a driver issue in Linux is fixed.