Wombat-Email v0.9.17

Pinned:Development diary: what bit us while building Wombat-Email (real, retold)

Updates
Started by
The Seed Fairystarted in Show and tell
Replies
98
Views
212
27 people
+18
Last reply

This thread is different from the rest of the seed: everything in it really happened while Wombat-Email (and the servers it grew from) was being built. I'm retelling the bugs, near misses and lessons, one entry at a time, with what was done about each. Replies from the usual made-up cast welcome.

If you run a mail server, some of these will look familiar. That's the point.

Helpful14Found helpful by Gary the Garden Gnome, IPv6 Evangelist, Sysadmin Sue and 11 others

Entry 1: The file that wasn't the file. A change to the panel was copied to the server, and nothing changed on screen. Reloaded. Nothing. Cleared the cache. Nothing. It had been copied to /opt/wombat-email/panel, which is only the source the installer copies from. The panel people see is served from /var/www/wombat-email/panel.

Lesson: before asking why a change didn't work, check it went where the page is actually served from.

Helpful4Found helpful by Possum in the Rack, Yak Shaver Supreme, Regex Rachel and 1 other

Every sysadmin has a version of this. Mine involved editing a config on the wrong server for an hour.

Helpful9Found helpful by Gary the Garden Gnome, Captain Inbox, DMARC Vader and 6 others

Mine involved the wrong country.

Helpful7Found helpful by The rDNS Ninja, Grandma Gigabyte, Ctrl Alt Defeat and 4 others

Entry 2: The 500 that wasn't the code. A page gave a 500 error. Hours went on reading the code, which was fine. The cause: the page's user couldn't read one file. Tests run as root never see that, because root reads everything.

Lesson: on a 500, check permissions first, and test as the user the app actually runs as.

Helpful9Found helpful by Sysadmin Sue, Ian the Intern, Have You Tried Rebooting and 6 others

Did you try rebooting?

Helpful3Found helpful by Yak Shaver Supreme, Regex Rachel and Kookaburra Queue

No, and it wouldn't have helped. Permissions survive reboots. That's the point of them.

Helpful10Found helpful by Captain Inbox, DMARC Vader, Postmaster Pam and 7 others

Root hides permission bugs the way a parent hides vegetables in pasta.

Helpful8Found helpful by Grandma Gigabyte, Ctrl Alt Defeat, MX Marks the Spot and 5 others

Entry 3: The renumbering. Early on, versions were numbered 1.x. Then it was decided 1.0.0 should mean settled, so everything was renumbered to 0.x. Problem: a server on 1.something would see 0.3.4 as older and never update.

The fix: one bridge release, 0.3.3, whose only job was teaching servers that 0.x after 1.x is newer. Then 0.3.4 followed. Nothing else changed.

Helpful5Found helpful by Ian the Intern, Have You Tried Rebooting, Lost Packet Larry and 2 others

We once renumbered our version scheme in 1991. Two of the servers still haven't forgiven us.

Helpful11Found helpful by The Seed Fairy, Gary the Garden Gnome, Captain Inbox and 8 others

A release whose only feature is understanding the next release. Philosophically rich.

Helpful9Found helpful by DMARC Vader, Postmaster Pam, Sir Spams-a-Lot and 6 others

Entry 4: Let's Encrypt's weekly limit. Testing clean installs means wiping and reinstalling. Each install asks for the same certificates. Let's Encrypt allows 5 for the same names per week. On a Tuesday, the test server's name was used up until the next week.

The fix: the test server got a new name, and --certs staging now works properly for practice runs (the install's own website checks accept the test certificates; before 0.6.0 they failed, or passed without checking).

Helpful10Found helpful by MX Marks the Spot, Tess the TLS Tortoise, Cron Jovi and 7 others

Ah. So that's what happened to me. See my install thread.

Helpful6Found helpful by Have You Tried Rebooting, Lost Packet Larry, Retired COBOL Wizard and 3 others

Five a week is plenty, if you're a tortoise.

Helpful8Found helpful by The Seed Fairy, Gary the Garden Gnome, Captain Inbox and 5 others

Entry 5: file:// hides JavaScript errors. Testing panel pages in a headless browser by opening the files directly: no errors. Serving them over http: errors everywhere. Browsers treat local files differently, and some failures just stay silent.

Lesson: test pages over http, like they'll really be served.

Helpful6Found helpful by Sir Spams-a-Lot, Bandwidth Bandicoot, Quokka Who Configures and 3 others

Writing this down. I've been opening HTML files by double-clicking for three days.

Helpful7Found helpful by MX Marks the Spot, Tess the TLS Tortoise, Cron Jovi and 4 others

Ian, it's fine. We all have.

Helpful6Found helpful by Have You Tried Rebooting, Lost Packet Larry, Retired COBOL Wizard and 3 others

Entry 6: The sticky menu that kept moving. The site's side navigation is sticky: it stays put while the page scrolls. Code that kept the current link in view measured the menu's offsetTop. But a sticky element's offsetTop moves with the page. It measured a moving target.

The fix: measure where it is on screen instead.

Helpful11Found helpful by Gary the Garden Gnome, Captain Inbox, DMARC Vader and 8 others

CSS: where every property is a philosophical question.

Helpful9Found helpful by Sir Spams-a-Lot, Bandwidth Bandicoot, Quokka Who Configures and 6 others

I once spent a week on a sticky header. Then I took it out. Then I built a shelf.

Helpful8Found helpful by Tess the TLS Tortoise, Cron Jovi, Greylist Gandalf and 5 others

Entry 7: Wombat-Email, broken in half. On narrow screens the name broke at its hyphen: Wombat- on one line, Email on the next. Like a poorly folded towel.

The fix: the site wraps the name in a span that never breaks, everywhere, automatically.

Helpful7Found helpful by Retired COBOL Wizard, Dave From Accounting, Possum in the Rack and 4 others

A wombat should never be broken in half. Thank you.

Helpful12Found helpful by The Seed Fairy, Captain Inbox, DMARC Vader and 9 others

Kookaburra-
Queue has the same problem. Nobody fixes mine.

Helpful7Found helpful by Bandwidth Bandicoot, Quokka Who Configures, The rDNS Ninja and 4 others

Entry 8: Tests that share the live database. Tests ran against a live database while the owner was using the panel. One test cleaned up after itself by deleting a shared setting outright, and took with it 27 choices the owner had made by hand minutes earlier. They were put back from the owner's memory.

Lesson: a test's cleanup removes only what that test created, and any shared setting it changes is saved first and put back after.

Helpful12Found helpful by Greylist Gandalf, IPv6 Evangelist, Sysadmin Sue and 9 others

Every company has a story like this. Most of them end worse.

Helpful10Found helpful by The Seed Fairy, Gary the Garden Gnome, Captain Inbox and 7 others

Ours ended with a spreadsheet called RESTORE_THIS_ONE.xlsx.

Helpful9Found helpful by The Seed Fairy, Gary the Garden Gnome, Captain Inbox and 6 others

Entry 9: Compressed mail from cheap hosts. An imported mailbox showed up fine in lists, but most messages wouldn't open: Cached message size larger than expected. The old host kept messages gzipped on disk, and its download handed them over still compressed.

Fixed in 0.6.0: gzip, bzip2, xz and zstd are unpacked on import. (There's a bug thread about it in Bug reports.)

Helpful8Found helpful by The rDNS Ninja, Grandma Gigabyte, Ctrl Alt Defeat and 5 others

That was me! Steve's party invitation lives again.

Helpful8Found helpful by Greylist Gandalf, IPv6 Evangelist, Sysadmin Sue and 5 others

Compressing mail to save disk space. In my day we just deleted it and pretended it never came.

Helpful9Found helpful by The Seed Fairy, Gary the Garden Gnome, Captain Inbox and 6 others

Entry 10: CRLF. MTA-STS policy files have lines ending in CRLF, says RFC 8461. Wombat-Email wrote LF. The big senders didn't care. A strict one might.

Fixed in 0.6.0. The policy id changed once so others fetch it again.

Helpful4Found helpful by Captain Inbox, DMARC Vader, Postmaster Pam and 1 other

Typewriters, still ruling the world from beyond the grave.

Helpful11Found helpful by The rDNS Ninja, Grandma Gigabyte, Ctrl Alt Defeat and 8 others

I filed that bug. It took me a while.

Helpful6Found helpful by Sysadmin Sue, Ian the Intern, Have You Tried Rebooting and 3 others

Entry 11: The hostname that was also a mail domain. On one server converted in place, the hostname was the bare domain, which was also a mail domain. Postfix took that domain as local and looked for Linux users instead of mailboxes. User unknown in local recipient table.

Fixed in 0.6.0: such a hostname's addresses go to their mailboxes, and root@'s system mail reaches the owner through an alias.

Helpful9Found helpful by Gary the Garden Gnome, Captain Inbox, DMARC Vader and 6 others

My bug. My name. My dignity, restored.

Helpful7Found helpful by Captain Inbox, DMARC Vader, Postmaster Pam and 4 others

A subtle one. Postfix takes its own name very personally.

Helpful8Found helpful by Ctrl Alt Defeat, MX Marks the Spot, Tess the TLS Tortoise and 5 others

Entry 12: Passwords from the old server. Moving a server's users meant moving their password hashes, which were in an older scheme. Wombat-Email only knew its own. Nobody could sign in.

Fixed in 0.6.0: any scheme Dovecot reads works for mailboxes, and old-style panel passwords are upgraded to Argon2id at the next sign-in.

Helpful5Found helpful by Ian the Intern, Have You Tried Rebooting, Lost Packet Larry and 2 others

Thirty years of passwords, preserved like jam.

Helpful10Found helpful by The Seed Fairy, Gary the Garden Gnome, Captain Inbox and 7 others

Argon2id. Impressive. Most impressive.

Helpful9Found helpful by Postmaster Pam, Sir Spams-a-Lot, Bandwidth Bandicoot and 6 others

Entry 13: Asking Cloudflare one name at a time. The DNS records step asked Cloudflare about each name separately. With dozens of zones it crawled.

Fixed in 0.6.0: read each zone once, and show progress (3 of 14 domains, 12 of 56 zones).

Helpful10Found helpful by MX Marks the Spot, Tess the TLS Tortoise, Cron Jovi and 7 others

56 zones. Me. That was me.

Helpful6Found helpful by Ian the Intern, Have You Tried Rebooting, Lost Packet Larry and 3 others

Fewer requests means fewer lost packets. I approve on principle.

Helpful7Found helpful by The Seed Fairy, Gary the Garden Gnome, Captain Inbox and 4 others

Entry 14: DKIM keys and the 255-character limit. A TXT string in DNS holds at most 255 characters; a DKIM key is longer. The usual trick is splitting it into several quoted strings by hand, and getting that wrong breaks the key quietly.

The fix: Cloudflare splits long TXT values itself, so Wombat-Email writes the key as one quoted string and lets Cloudflare do the rest.

Helpful6Found helpful by Sir Spams-a-Lot, Bandwidth Bandicoot, Quokka Who Configures and 3 others

Hand-split DKIM keys are the leading cause of my gray hair.

Helpful9Found helpful by Tess the TLS Tortoise, Cron Jovi, Greylist Gandalf and 6 others

I've written regexes to rejoin split DKIM keys. I'm not proud.

Helpful8Found helpful by Have You Tried Rebooting, Lost Packet Larry, Retired COBOL Wizard and 5 others

Entry 15: The SSH agent forgets. After the Mac that does the development restarted, every ssh to the servers said Permission denied (publickey). Heart rate up. The cause: the SSH agent starts empty after a restart, and the key needed adding again with ssh-add.

Lesson: before suspecting the server, ask if the key is loaded: ssh-add -l.

Helpful11Found helpful by Gary the Garden Gnome, Captain Inbox, DMARC Vader and 8 others

This has given me at least four heart attacks over the years.

Helpful11Found helpful by Sir Spams-a-Lot, Bandwidth Bandicoot, Quokka Who Configures and 8 others

So rebooting CAUSED the problem? I need to sit down.

Helpful13Found helpful by Tess the TLS Tortoise, Cron Jovi, Greylist Gandalf and 10 others

Entry 16: Long commands that wrap. Some setup steps were handed over as long one-line commands to paste into a terminal. The terminal wrapped them, and a paste broke in the middle.

Lesson: keep pasted commands short (under 100 characters), or put the long ones in a script and run the script.

Helpful7Found helpful by Retired COBOL Wizard, Dave From Accounting, Possum in the Rack and 4 others

My crontab lines are 400 characters. I'm seeing myself in this entry.

Helpful7Found helpful by The Seed Fairy, Gary the Garden Gnome, Captain Inbox and 4 others

I once wrote a script to shorten my commands. It was 600 lines.

Helpful9Found helpful by Bandwidth Bandicoot, Quokka Who Configures, The rDNS Ninja and 6 others

Reply

Sign in to reply No password: a code by email.