Friday, September 21, 2007

More ZFS Love - Rapid Recovery

I recently scragged my laptop's primary root partition such that I needed to install-from-scratch again. I had a bootable secondary root, but since it was running an experimental BFUed build, this partition could not be upgraded.

Let's quickly look at how I configure my 100-decimal-GB laptop disk (&*%$% disk vendors):

  • c0d0s0 --> Primary root, approx 8GB (and I mean GB the way software geeks mean it, 8 * 1024^3).

  • c0d0s1 --> Secondary root, same size.

  • c0d0s3 --> swap, 3GB, same as main memory size (useful for system dumps).

  • c0d0s7 --> ZFS pool "tank", with 5 ZFS filesystems (tank, CSW, spro, local, and danmcd).


Before I shut it down for upgrade, I simply uttered this:

zpool export tank

That's it!

Then I plugged in my laptop to a local netinstall network, and PXE-booted to a Nevada build 73 install (which includes detangled NAT-Traversal) and started it up. I used the old Solaris installer because I know how to tell it to preserve disk slices. I told it to preserver the secondary root and the zpool.

One install later, I get root, and to recover my miscellaneous backups, CSW software, compilers, local binaires, and home directory, I just did:

zpool import tank

And again, that's it! All of my filesystems got mounted properly, no tables to edit, NOTHING.

I'll be at the University of Michigan Engineering Career Fair this coming Tuesday, and will be wandering campus on Monday. If you're one of the four people who read this blog and are there, drop by the Sun table - and see the very laptop I'm talking about. :)

No comments:

Post a Comment