Since 2005 aphyr.com has been served by kovacs, a Debian VM running on Linode. I ran my own mail server, web server, and a suite of little tools and toys. I’m shutting it down next week, but in honor of twenty years of service, I wanted to write a little bit about what self-hosting was like.
I’ve been running Linux machines in various forms since the mid-90s. If I recall, I was cobbling together basic HTML and Perl CGI scripts in middle school, but without internet access at home, it was hard to run a web server. I think I had a geocities account, and maybe something provided by the school. At school, I’d download all the software and documentation I thought I might need on to floppies or Zip disks, then ferry them home where I had a little desktop running Red Hat. In one of my notebooks, I still have the specs I wrote down for that machine.
HP Pentium
24.0 MB RAM
MS 95/DOS/Linux
Mitsumi CD-ROM
Iomega Zip 100
It had two hard disks, though there’s no record of their size. Maybe a few gigabytes at most. I remember when drive labels started saying “GB” instead of “MB”, and how vast that seemed. A thousand floppies!
I think my first real web site was around 2001, hosted by a friend from high school, Loren Bruns. He offered accounts to dozens of us nerds, all shared on a machine that lived in his living room. I have no idea how his parents put up with all of us using what must been a very limited modem or DSL connection. You’d write HTML and upload your site via FTP to his machine, and point your browser to http://brunslo.com/~your-handle, and voila! A real live web site, that anyone could see! What magic!
For a while I had another “tilde account” at alt154.org, which was run by another friend from high school. By that point SSH was common, and we could run complex programs, even web servers. The transition from CGI to long-running daemons was underway, and the idea of a “blog” had just come on the scene. I think I ran Movable Type for a few years (which is, astonishingly, still around) and filled it with what I can only imagine were the most embarrassing teenage things possible.
I was getting into photography at the time, and didn’t really like the CMS options available. I wound up writing a blog engine in Perl, and then another in Ruby, and another, and got practice running them. By 2005 I was making real money: $12 an hour as a network/operations intern. I used that hard-earned cash to rent my very own Linode. Linodes were these new-fangled “virtual machines” which let you rent a slice of someone else’s server, rather than having to rack your own at a colo, or buy a dedicated, managed machine, neither of which I could afford.
All my computers were named after fictional badasses. I named that machine kovacs, after a character from Altered Carbon. I set it up with… what was probably Debian 3.0 “Woody” at the time. Configured firewall rules with firehol. Set up Postfix and Dovecot for an SMTP and IMAP server, respectively, and used Procmail for routing. Even got SSL certificates, which back then was a frustrating process that involved (IIRC) paying your registrar extra money and scratching arcane runes into openssl. Thank goodness for Lets Encrypt today. I used Apache to front a Perl blog engine, which had a homegrown templating language based on MediaWiki’s syntax. Here’s the first post I made after getting it running, on May 9th, 2005. It had RSS and ATOM feeds shortly thereafter, and rendered XHTML, because web standards, goshdarnit!
Spam and email deliverability became a major problem. When spamassassin faltered around 2007 I switched to this new machine-learning technique called “bayesian filtering” using DSPAM. I’d retrain miscategorized messages by moving them to “Retrain as Ham” and “Retrain as Spam” folders, and a little script would grab those and feed them back into the DSPAM retraining program. DSPAM’s last release was in 2012—fourteen years ago!—but it’s still processing aphyr.com’s mail today.
I accreted an increasingly convoluted series of procmail rules to deal with persistent senders, and for various one-off projects. For a little bit I fell into Eve Online. One of the challenges in Eve is that markets are local: you don’t know what things cost far away. So users would run a little program that would scan their local market prices and submit it to a central server, and that server would send you emails with price lists. I’d pick up those emails, route them to a little Ruby program with Procmail, and build an SQL database. Then, based on global prices and a map of the faster-than-light jumps you could make between systems, I’d compute trades with the highest profit per hop using some truly absurd recursive table expressions.
In 2006 I rewrote the Perl blog engine in Ruby—probably in Rails. It’d wind up being Sinatra fronted by nginx by 2009 or so. I also changed the URL scheme—REST was becoming a big thing, and I had Strong Opinions about URL design. I set up a long list of nginx rewrites that are still there today—aphyr.com has had stable URLs for twenty years. I think it’s probably time to let those rest now.
rewrite ^/journals/(show)?/name-that-cms$ /posts/1-name-that-cms permanent;
rewrite ^/journals/(show)?/new-server$ /posts/2-new-server permanent;
rewrite ^/journals/(show)?/sbld-the-ssh-blacklist-daemon$ /posts/3-sbld-the-ssh-blacklist-daemon permanent;
I ran a bunch of mini-sites on aphyr.com too—mostly little HTML pages for silly jokes. When the Riemann monitoring system started to get popular, kovacs hosted its packages. Then I had to rate-limit downloads, because sysadmins were deploying Riemann to thousands of machines and hammering the little VM’s bandwidth. Around 2013 I made it to the front page of Hacker News for the first time, and that little CMS crumpled under the load. I added layers of caching and a slew of optimizations, and was able to weather successive bursts of traffic. I’m thankful I did that work early; now AI scrapers are hammering every service I run.Around 2020, frustrated by the constant churn of the Ruby ecosystem, I rewrote the whole blog engine in Clojure. Same Postgres database under the hood, and the same janky templating language.
Kovacs had, I kid you not, uptime measured in years. I upgraded that machine from Debian 3.0 to 13. It made the changeover from 32 to 64-bit, which created a dkpg hellscape that took me years to properly untangle. You form an emotional attachment to machines like that. Pets vs. cattle and all that, but goshdarnit, this machine served me well! When I started aphyr.com, Orkut was still a thing. It survived the collapse of Myspace, Tumblr, and Twitter. I have fought Microsoft’s constant efforts to make mail undeliverable from anyone but the major players, and won several times. This mail server has twenty years of accumulated IP reputation.
Reminiscence aside: the last few months have been brutal. I’m sure other sysadmins are feeling the same thing. Severe RCEs in major software packages are dropping multiple times a week. There is an enormous pile of software we all depend on which is written in languages with poor memory safety, maintained by volunteers (if maintained at all) and which is now under constant assault by an army of persistent, sophisticated AIs. Congratulations, everyone! We made cyberpunk! On November 18th I took down aphyr.com in response to two nginx vulnerabilities that went unpatched in Debian for over a day. I think it is only a matter of time before an RCE drops when I am asleep, and some asshole’s AI agent sneaks in and creates an enormous security headache before I even roll out of bed. As I wrote for woof.group, I don’t know how long part-time sysadmins can stay in the game.
I can’t stay on top of security like this. I can’t even respond to pull requests! So I’ve moved aphyr.com over to Fly.io, and I’m going to pay some company to run my email. I want to establish a stronger firewall between services in the event that one gets compromised, and leave the on-call rotations to the full-time professionals.
End of an era.
Post a Comment