Free novella at Amazon

My SF novella Forever Falls is free on Kindle through 11 May 2015 (next Monday).

This book is only available on Kindle right now — I’m trying their Kindle Select program, which supposedly gives additional visibility and promotion. It doesn’t seem to have helped so far. Come 3 June, when the Select enrollment runs out, I’ll have this piece on iBooks and Kobo and all the other ebook platforms.

But until 11 May 2015 the book is free, from all of the usual Amazon outlets.

  • Amazon US
  • Amazon UK
  • Amazon DE
  • Amazon CA
  • WordPress versus FreeBSD

    I recently migrated my web site to a new FreeBSD install, configured so I could use ZFS boot environments. This upgrade crossed FreeBSD versions (10.0->10.1), filesystems (UFS -> ZFS), and PHP versions (5.5 -> 5.6).

    And my WordPress pointy-clicky upgrades stopped working. Every time I ran an upgrade, the web gui hung with:

    Updating Plugin Honketyblatt (1/1)

    The web site would site there, forever. Enabling WP debugging gave me no error messages.

    If I had the job of running WordPress sites, I would have an automatic tool that processed the upgrades for me. It’s not, so I don’t.

    I use the FreeBSD WordPress package to get all of the dependencies, but manage my actual WordPress sites in a separate directory. It turns out that the FreeBSD WordPress package doesn’t list all of the modules that you need for a self-maintaining WordPress install. My old server had a few packages that the new one didn’t.

    If you want to use WordPress’ self-updating features, be sure to install the following packages in addition to the FreeBSD-recommended defaults.

    php56-tokenizer
    php56-zlib
    php56-zip

    I installed these packages, and everything started working.

    Web site rearrangement

    In case you’re reading this in reverse order in your RSS feeder: ignore the last couple of posts. It’s content I’m moving from my web page to the blog.

    I’ve redesigned and rearranged the fiction section of my web site, so that it more easily answers hard questions like “What have you written?” and “Do you write anything I might like?”

    The nonfiction section is OK, given how many tech books I’ve written. Hopefully the fiction section will now scale as well.

    Ignore the next couple of posts

    I’m in the midst of rearranging my web site. The nonfiction stuff is pretty well organized, but the fiction really is not.

    Most of the fiction can easily be reordered, except for a couple of pages that just won’t fit well anywhere. So I’m putting those pages up as blog posts.

    Unfortunately, I can’t cancel those out of the RSS feeds. And most of my blog readers are already aware of these pages. I’m using the bang-more markup to keep most of the pages out of your feed, though.

    I think I can cancel those pages from spreading to the third-party sites, like Facebook and Twitter and such. If not, I’ll log into those sites and cancel them manually.

    My apologies for the extra traffic.

    FreeBSD and beadm

    One of Solaris’ ZFS features is boot environments, where you can install multiple versions of the core operating systems and choose which one to boot into. Boot environments take a lot of the risk out of upgrades; if an upgrade goes bad, you can easily roll back to the previous version.

    Boot environments are built on top of ZFS. Recent FreeBSD installers create fine-grained datasets rather than a single large dataset, which means you can leverage boot environments on FreeBSD.

    Boot environments will go into FreeBSD Mastery: Advanced ZFS. But the first book needs to be boot-environment compatible–especially the chapter on manual ZFS installations. So here are my rough notes on boot environments, both from my own researches and from poking Allan Jude on Twitter.

    If you’re going to play with boot environments, it’s best to start with a new system. You can migrate an existing system to a boot environment friendly one, but as Dan Langille discovered, it’s a right pain.

    I started by installing a new 10.1/amd64 host. Your initial datasets look like this.

    # zfs list
    NAME USED AVAIL REFER MOUNTPOINT
    zroot 465M 188G 128K none
    zroot/ROOT 463M 188G 128K none
    zroot/ROOT/default 462M 188G 462M /
    zroot/tmp 149K 188G 149K /tmp
    zroot/usr 570K 188G 128K /usr
    zroot/usr/home 186K 188G 186K /usr/home
    zroot/usr/ports 128K 188G 128K /usr/ports
    zroot/usr/src 128K 188G 128K /usr/src
    zroot/var 703K 188G 128K /var
    zroot/var/crash 128K 188G 128K /var/crash
    zroot/var/log 192K 188G 192K /var/log
    zroot/var/mail 128K 188G 128K /var/mail
    zroot/var/tmp 128K 188G 128K /var/tmp

    1
    This list is deceptive. The dataset zroot/usr exists, but it isn’t mounted. Go ahead, run mount(8) or zfs mount and check. I’ll wait. The dataset must exist for you to have child datasets like /usr/ports, but it doesn’t actually contain any data. The files in /usr that aren’t in specific child datasets like /usr/ports or /usr/src are all in the root dataset.

    Run pkg install once to install the package management system, and then install beadm from packages.

    # pkg install
    # pkg install -y beadm

    Now see which boot environments you have.

    # beadm list
    BE Active Mountpoint Space Created
    default NR / 494.0M 2015-04-08 07:18

    The only boot environment is named default. Under active, N means the environment is active now. An R means the environment will be active on reboot.

    I need to upgrade this host to the latest version of FreeBSD 10.1, p9. This is where we need a new boot environment. I’ll name it after the release.

    # beadm create 10.1-p9
    Created successfully
    # beadm list
    BE Active Mountpoint Space Created
    default NR / 646.0M 2015-04-08 07:18
    10.1-p9 - - 10.7K 2015-04-08 11:43

    Activate the new boot environment.

    # beadm activate 10.1-p9
    Activated successfully
    # beadm list
    BE Active Mountpoint Space Created
    default N / 186.0K 2015-04-08 07:18
    10.1-p9 R - 646.2M 2015-04-08 11:43

    While the default environment has an N, indicating it’s active now, the 10.1-p9 environment has an R, so it will be active after a reboot.

    Reboot. After the reboot, you’ll see the new environment is running.

    # beadm list
    BE Active Mountpoint Space Created
    default - - 538.0K 2015-04-08 07:18
    10.1-p9 NR / 646.3M 2015-04-08 11:43

    Now I can install the latest FreeBSD patches without damaging my default system. If it fails, I can fall back by activating the default boot environment.

    Remember how the zroot/usr partition isn’t mounted, so that files on /usr fall through to the root dataset. Your files in /usr and /usr/local are in the boot environment, so you can create new boot environments for package upgrades as well as base system updates. The /var partition works similarly.

    Using boot environments opens another whole crate of weasels, though. Of course you want the core system databases in /var/db to be part of the boot environment–but what about /var/db/mysql? Similarly, postgres stashes data in /usr/local/postgres. You don’t want reverting the core operating system to give you an old version of the system database!

    When using boot environments, create a new dataset for your database data. This also lets you tune ZFS for that application.

    (PS: While you’re here, take a moment to admire how the header image changes every 10 seconds. I am immensely proud of myself for finding the button that made that happen. That’s, like, real web design! And for changing the density of the bookshelf photo so it looked okay in the header. That makes me a graphic designer too, right? Sweet!)

    Sunday Morning Linux Review on “Tarsnap Mastery”

    The Sunday Morning Linux Review crew has reviewed Tarsnap Mastery in episode 148. From the review:

    “If you use any nix-type system, and need offsite backups, then you need Tarsnap. If you want to use Tarsnap efficiently, you need Tarsnap Mastery.”

    The whole episode is worth listening to, but the review itself starts about 1:27 in the unedited video.

    They also review me as an author. All I can say to that is: “Eeep!” Fortunately they didn’t review my personality, so I come out okay.