Skip to main content
Escape Characters

Pain Wizards

Hi. Hello. I've been silent for a year and a half. Here's what I've been thinking about since then.

----

I have to spoil a 20 year old fantasy novel. Please forgive me.

When reading fantasy novels, I tend to focus a lot on the magic systems. Why? Well, that's how my conscious brain works: identifying, analyzing, and picking apart complex systems. When reading about magic, I think about how it has to work, what their real-world phenomenon analog or inspiration might be, and what checks and balances have to be in place in the fantasy world to make the magic believable. Great magic systems are subtle, consistent, consequential, understood in a limited scope, and fantastical at scale. It's a hard target to hit while trying to remain unique and intricate while avoiding being tried and derivative. I'd list some stories that do this right and wrong, but that's not really my focus here.

Instead, I want to talk about a fantasy novel I read some time ago (2005 or before), called Wizard's First Rule. Of the eight other books I supposedly read that year, it's probably the one I've thought about the least since.

This isn't to say it was a bad book. It wasn't. Well... it wasn't great. To be honest, it was a little plain in what it brought to the table. The main character was every classic fantasy hero, complete with a sagely tutor, a mysterious past, a more mysterious and sudden woman in distress, and an epic quest to save the very world. It didn't really stand out to me as great storytelling, the characters I've forgotten, and though I read the sequel, I never got past that.

It did, however, have a fun magic system. Magic had to do with absolute truth, and those who practiced magic sought it with sometimes cruel and crippling methods. Magical weapons were forged for the purpose of seeking the truth ("The Sword of Truth"), and an order of women ("Confessors") who could control others absolutely in order to find truth. Truth and knowledge were sought by those with the Sword of Truth or by the Confessors, and "wisdom" seemed to be held by the few remaining "wizards" of the world as the "Wizard's Rules." The first Wizard's rule is:

People are stupid; given proper motivation, almost anyone will believe almost anything.

Maybe not profound, but it was interesting. And subtle. And fairly consistent. And had consequences (Confessors essentially destroyed a person when they used their power). And limited for what the characters understood of their magical powers (the Sword of Truth only worked if one's mind was clear of doubt). On this regard, it did pretty alright.

Reading back over the series wiki article, it saw a good deal of clamor when it came out. Since, it's seen eleven sequels, two prequels, and even had an ABC show from 2008 to 2010 (which I'd never heard about until long after it was canceled). Terry Goodkind is still writing about the two main characters in their own dedicated arc, releasing a book as recently as 2011. Quite successful for a fantasy series, but I guess, not so much with me. But then again, I started reading A Song of Ice and Fire shortly thereafter, which dominated my limited reading time for the remainder of college.

I was reminded recently that the novel did have one bizarre, stand-out thing, though. For what I remember being a strangely long part of the middle of the novel, the main character, Richard, is captured by a group of wizards (the Mord'sith), and is tortured for a series of months in order to turn his gifts over to the forces of evil.

The Mord'sith are fairly threatening villain characters. First, they are all women (by the book's assertion that only women are capable of such cruelties). Second, they all wear an array of all-leather, skin-tight suits depending on the occasion (red to hide the blood during torture sessions, white for formal occasions, etc.). Finally, their entire goal is to break their subjects physically and mentally through torture until they are absolutely submissive, loyal shells to do their bidding.

The interesting thing about the Mord'sith is from where they derive their power. All Mord'sith carry an 'agiel', a metallic necklace that can be worn around the neck or wrapped around one's fist. The agiel devices, when coming into contact with human skin, cause incredible pain on their victims (with the potential to dial the pain and skin damage up or down depending on its user's wishes). With the agiels, the Mord'sith torture their victims to the point of breaking. Some Mord'sith, depending on whether they desire a mate, "condition" their victims with the agiel until they are subservient to the Mord'sith and the agiel, even to the point of relying on the pain from the agiel. Even more cruelly, new Mord'sith are "trained" under an agiel as young children, and are broken by first submitting to an agiel, then using an agiel to kill their father, and then their mother. Only after that are the Mord'sith equipped with a skin-tight blood-stained leather suit and an agiel of their own.

Richard (the novel's "Seeker of Truth") survives his months of torture by teaching himself to (magically) partition his mind, separating his true self from the one the Mord'sith were breaking. He eventually escapes by feigning submission in becoming his Mord'sith torturer's mate, and at the last moment, breaks free of his mental and physical jail, and escapes certain death.

What makes this interesting is the fact that the agiel device affects all who come into contact with it, including the Mord'sith themselves. Whenever they torture their victims, they experience the same pain, or at least, would feel it the same if they weren't conditioned to it. At some point during the conclusion of the book, Richard discovers this, and finds a way to pity his torturer, given that she had suffered the same as he, and likely more in having to become a Mord'sith. Richard wears his torturer's agiel for some time after his escape out of respect.

The Mord'sith and the agiels are an interesting facet of the magic system, as they really aren't magic at all. The truth to their function is simply that only in enduring an inhuman amount of suffering do the Mord'sith gain their power. That there is an unspeakable tragedy behind every Mord'sith makes them pitiable villains, which is a fairly clever (if oddly BDSM) use of a magic system to give depth to the world and characters.

The Mord'sith are the only pain wizards I can recall in a fantasy series. Dune sort of has them, I think, but not in the same way. But then again, I'm not particularly well-read.

----

Some time ago, somebody asked me to look at a dead hard drive they found in a used computer. I looked at it with a couple of my tools and determined that the hardware surrounding the disk had failed, rendering the contents inaccessible. After collecting dust on my shelf for a few months, I decided to take it apart (as I had never taken apart a hard drive). It was strangely fun, if destructive and slightly wasteful. Inside were a number of rare earth magnets that make refrigerator magnets you have to plan around (incredibly powerful). There is also the disk platter, which I was surprised to see was almost mirror-reflective, despite being coated in magnetic silica dust. The rest is tiny screws and circuit boards, none of which make good conversation pieces or fridge adornments.

Currently, the disk platter/mirror sits at an angle just above the monitor at my work desk so I can see when people walk up behind me. My fingerprint is smudged from when I was carelessly angling it towards my cubicle door. It made it all the way through life, me taking it apart, putting it into a ziplock bag, into my backpack, into work, and onto a fastidiously constructed binder clip mount before I lost focus for a brief moment. Though broken before, it serves as a reminder that I'm one smudge, one dust particle, or one errant disk head touchdown from disk failure, data loss, and vindication of my zealous fervor for data redundancy.

People just don't realize the lesser miracle of modern data storage, or that even modern storage has a failure rate that approaches 100% after five years. People don't realize that every file they store, every program they install, every DRM-riddled iTunes album they buy incurs a technical debt that must be paid now, or at the next upgrade, or after hardware failure. That computing, while ubiquitous, is not the shiny future it's marketed to be. That when they ask me to fix things, I may not be able to fix them. And that when they ask me about things, I can't tell them what they want to hear.

...But really, the smudged computer garbage hanging from my desk just reminds me that I've become sort of an asshole about these things. And I wonder if I didn't used to be.

----

A good computer system is based on truths. A bad computer system is based on promises.

A truth is something that is, for all known cases, cannot be broken. Like scientific theories, or even laws, they are the unshakeable, subtle, simple things that keep computer universes from dissolving back into the electronic noise whence they came. A truth cannot turn into a lie, for if it did, all things that depended on such a truth would fall apart. Without a truth, nothing will work. When nothing works, a truth will have failed.

A promise is something that is upheld, but with enough uncertainty, deviation, or special condition, can be broken. A promise can turn into a lie, given the expectation that what is being lied about isn't all that important. A programmatic ecosystem of promises guarantees a level of distrust and paranoia among promises, such that each promise has to determine if another is a lie before determining if it can uphold its promise.

Often I'm tasked with learning new systems: ones I've never seen before, heard of, or even heard of the problem they attempt solve. Rather than attempt to read the manuals or the marketing information, I instead try to find a program's truths. And as a programmer, looking at the work of other programmers, truths are usually apparent. Most are old, dependable truths, ones that make you celebrate a little when you come across them. A novel truth is a rare thing for a programmer to find, and when they do, they are proud, and put it as far towards the front as possible. A truth tends to be easy to find, provided that it exists.

The software I enjoy dealing with most is software that deals in truths. Truths like:

The software I enjoy least are those that have to make promises. Promises like:

This might seem like an argument against complexity, but it isn't. While frustrating, complexity isn't the root of a problem in software design. For instance, it is massively complex for even so simple a thing as reading and writing to a hard drive (given that you are balancing a magnetic needle above a platter spinning at least 5400 revolutions per minute). Decades of study, experimentation, pain and anguish went into something that is so central to the function of computing devices today. However, when wrapped in the truth,"I can read and write to a file," the complexity disappears, and while this may fail in certain cases, nothing else will be able to work so long as this truth is false.

Most people in using a program, new or old, don't consider whether something is a truth or a promise. Instead, they establish their own level of trust, depending on how often the software lies (or is perceived to have lied). The trick is to make software reliable enough to manufacture trust, and hopefully, establish truth that can be relied upon by its users. People live and breathe on trust, which makes human-computer interaction incredibly difficult: how do you make software that does complex things engender trust in a fickle, emotional, distrustful, irrational creature?

My answer: You try to communicate in truths, and make no promises you don't plan on keeping. My projects are, at times, frustratingly single-minded. However, nothing I set out to create is without some central truth that I can come back to at any time.

----

I have a favorite story when it comes to hard drive failure.

My grandmother's hairdresser is a nice lady who owns a salon in Spenard. In her salon, there is a small iMac computer sitting on the reception desk. On that computer was data that was critical to her business: her client contact information, her appointment and scheduling information, and billing. That information was stored in a small, salon-specific application called STX. Within that application, all data was stored in a third party, binary database called FrontBase that STX interfaced with to store and retrieve its data.

That is, until the iMac's hard drive began to fail.

No backups were being performed, and the iMac model and the Mac OSX software was the iteration before external Time Machine backups were available.

The salon owner immediately took her computer to the MacHaus (another local Spenard business). They investigated, and concluded that the drive had failed. They helped her to buy a new hard drive, to reinstall the operating system, and to get the computer to a functioning state again. However, this was as far as they could take it: they were not hard drive recovery specialists, nor would they be able to take on that liability. They gave the salon owner a brochure, and warned her that the service was very expensive (starting at $1000).

Hearing this story, my grandmother recommended me to the salon owner. It was winter 2010. I'd recently gotten a business license with the idea that I'd try to do freelance computer programming and technical consulting on the side. Other than a small website for a coworker's brother, I'd done nothing to justify the cost of the business license. This seemed like a way forward.

I went to the salon, and listened to the story from the distraught owner. As she had no scheduling, her plan was to just wait around during her normal business hours for a few months until she was able to catch all of her appointments and reschedule on paper. I hoped I could help her. I explained what I could do, and while she didn't fully understand what I planned to do, gave me her failed hard drive.

I came home and plugged the drive into my external drive adaptor. To my surprise, the device came up, mounted, and I was able to browse the files on my computer. I wondered if maybe I had misheard the owner describe the problem, or if the problem had miraculously fixed itself.

It was neither. I soon discovered that after a few minutes of spinning and coming to room tempurature, each file I read was immediately corrupted the second time I tried to access it.

While terrifying and destructive, it meant one thing: it was possible for me to recover files, provided I knew exactly where they were, and I could copy them just once. The problem was, though, I had no idea what I was looking for. The salon application provided no documentation for its database file storage. I couldn't simply copy the whole disk, as there was no telling what I might be destroying if I copied the wrong files, and no certainty that I could get what was necessary before the disk finally quit. I tried to come up with a plan, and hoped that what I'd browsed/destroyed thus far wasn't what I was looking for.

I put the hard drive outside my front door. It was 10°F, and if it was going to be any help, it needed to cool down.

I tried to get more information. The STX web site had no technical support information, and I had no example to work from (trying to install the program required entering a license key, which I didn't have). I also saw from the STX install media that it was installing using a "package," which meant that the installation wouldn't necessarily be limited to just the "/Applications" directory on the drive. The FrontBase documentation indicated that while they often named their database files with ".fb," there was no requirement that the database files had to be named like that. I was going to have to guess, or hope that I could find something that ended in ".fb" in time.

My hard drive chilled, I plugged in my external adaptor again, snaking the cables out the door while I lay just inside. I navigated a number of file structures quickly to check where I thought the program would have set up shop. I was wrong. I began to panic. I only had so much time.

In the end, I was lucky. I found the files, and had the wherewithal to copy absolutely everything I saw in the folder. Not only were the files those I needed, but also the ones I needed to be able to copy straight to the new hard drive to be accessible again.

I emailed the salon owner with the good news. I came in a few days later to put her program and data back on her computer. After a few days of surprise appointments she couldn't prepare for, she was incredibly happy to have it all back. She asked what I wanted for money. She was a small business, and she was a friend to my grandmother. Asking anywhere near the fees commensurate for my laying of hands were out of the question. I told her I didn't need anything, but my grandmother would probably need hair stuff at some point. She said that was an acceptable exchange.

Then I started talking about how to avoid the problem in the future. About her aging iMac with no updates since its purchase, sitting unsecured (physically, or by password) on a tiny, cluttered desk in the middle of a high-crime area in town. About it being connected directly to the Internet via a small, cellular data service, exposed to any port scanner that happened by her Internet doorstep.

She looked at me blankly. She said she didn't have the money to upgrade it, and that the costs from the MacHaus had already set her back. Buying more stuff wasn't in her cards. I told her that at the very least, she needed a backup drive. She agreed, and I left. I came back a few days later, and she proudly handed me a small thumb drive she had bought to serve as her backup. It would not even begin to serve her Time Machine backups, and given the relatively fragile nature of flash media, would probably fail before her main drive did.

I sighed, and before I left I wrote a small script at that cluttered desk. Running every few minutes, it would compare the critical contents of her main drive to that of her backup drive. If the main drive had more updated information, the script would copy the new files over to the backup drive, and hopefully limit the number of writes to the wearable flash drive.

It only took me a few minutes, but used a sophisticated program (rsync) in the system that I'd used in the same fashion to keep server configs synchronized on our infrastructure at work. I also used it at home to create efficient, timestamped, Time Machine-esque backups of all of my computers (including those without Time Machine).

For someone who knew what they were looking for, it documented the critical portions of the drive, how often it was updated, and how. But, in Anchorage, there are maybe only a few dozen people that would know what to look for. I like to assume that one of them might find my script, wonder how it got there, and laugh at the snarky comments embedded in the script.

But not everyone has my appreciation for computer archaeology. Likely, the script will be lost with the next drive failure. Or, better yet, ignored by the next tech geek who, in fighting the clock against entropy and drive failure, races to copy only the most critcal files while laying next to his barely opened door in the middle of the Alaskan winter.

I still maintain a copy of the files I recovered for her. I never heard back from the salon owner. But my grandmother did thank me for her free haircut.

----

My smudged disk platter cubicle mirror is my reminder that computer storage is only a promise. And that drive backups are a promise that when storage fails your important data will still be there. They are only promises because there are no truths when the random universe outside the computer exerts its indifference. Outside the computer, there are no truths, only promises, and barely that.

And it is truly painful to have those promises broken. I've sat on my bed hearing the frenzied death-click of a drive that had taken everything with it. My music, my games, my downloads. It was my backup/external drive, but it was the extension of my otherwise tiny and questionable laptop hard drive. I had recently cleared out my laptop because I no longer needed to store anything but the "important" stuff on it. My classwork was saved, but my music, my movies, everything else was gone.

It's the same story whether it was the main drive, the backup drive, the movies, music, writing, or programming drive. Something will fail, and you won't expect it. You will have thought about doing a backup the week before, but didn't because you didn't have time. I've apologized as my sixteen hour drive reconstruction yielded only a corrupted music collection. And I've apologized as I/O Error (-1) streams past the system log and there's nothing I can do. With each process you learn new ways that things can fail, and you carry them with you, and endeavor to make better on it for the next time.

Dealing with computer failure is one of the pains I no longer feel any more, not because it is any easier or less painful, but because you just grow accustomed to it. The same could be said of my love of archaic or obscure computer systems, network and system security paranoia, or my over-simplistic ("truth-y") approach to software design. I wear the requisite pain like gaudy, geeky jewelry, and tend to torture anybody who comes into contact with it.

People will ask me how to upgrade their computers, or how to buy new ones. I start immediately into them by laying on the backup and data redundancy guilt. They ask what I do personally for backups and I proceed to sound like a crazy person. You have to buy two drives when one drive will store the data just fine? You have to buy two computers just to own one? You have to let Josh install bizarre things that few in the state will be able to find, let alone recognize or support, in order to satisfy some strange requirement for an event that likely won't happen over the lifetime of the computer?

The time, effort, and money are all the same to me. The magic is gone. I have become a pain wizard.

----

In the end, it's $400-$700 to do it right, plus a dozen or so hours to get everything set up and configured (depending on what you need to do). People usually budget between $500 and $2000 for 3-5 years worth of a reliable day-to-day computer. Backup hardware is an investment to ensure that the things you don't want to lose will survive your current computer, upgrades, configuration changes, expansion, mistakes, oversights, and disaster.

Unfortunately, to justify the investment you have to weigh it against the value of your data. When it comes down to it, your data is your money and your time, or records of their existence. Your compendium of Star Trek movies and TV shows? It took you months to get them, but maybe you could find them again. Your DRM-laden iTunes library? Maybe they'd let you download them again if you asked nicely. Photos you took at a party? They weren't flattering to begin with. Photos of your vacation? Somebody else should have the copies. Photos of your children when they were young? Ah... there it is.

So why, if computers are not a reliable storage medium, do we elect to use them to contain the things we cannot lose? Aside from convenience, or ubiquity, or popularity, why do we use these things like this? Why don't we just print everything?

Paper fades and crumbles, but human memory is so much worse. We are adapting to overcome it. It's a slow, subtle process, but we are becoming accustomed to using computer memory to augment our own. Computer memory will continue to become more reliable, and will far outstrip the capacity and capability for human memory in our lifetime. Every time we store something on a computer, we are possibly creating something that will outlive us.

It will not be boxes of photographs that our descendants (theoretical, or otherwise) will have to sort through after we're gone. With any luck, it will be a hard drive, or flash media, or whatever holographic crystal storage medium supersedes them with a password sticky note hastily taped to its side. It won't seem like much to them. Tiny files with old, old timestamps. Maybe there will be gaps, or just nothing before a certain date. Hopefully the contents will help them to realize it's a hollow, horrible, dark feeling to be unable to account for lost time.