Upgrading from Solaris 9 with a Root SVM Mirror to Solaris 10 with a Root ZFS Mirror with < 10 Minutes of Downtime
As sysadmins, many times the entire task laid out in front of us has no documentation. One of the biggest skill an admin can have is the ability to problem solve, breaking down a large task into smaller sub-tasks. Often times, you might be able to find documentation on some of those sub-tasks. A perfect example is upgrading a server from Solaris 9 with root in an SVM mirror to Solaris 10 with a ZFS mirror. Not only is this large task doable, but thanks to LiveUpgrade, it can be done with less than 10 minutes of downtime (3 reboots @ roughly 3 minutes each)!
Part of the beauty of Solaris when compared to Linux is the tools made available to the admin. I didn't even like working in Solaris until I started learning about zones, ZFS, LiveUpgrade, DTrace, etc. Now, on the server-side, I can't use it enough. I would be hard-pressed to do a similar upgrade with Linux - it's almost impossible to do in 10 minutes of downtime on RHEL. Debian might be able to do it, but LiveUpgrade gives you the ability to roll back to the previous state, which I don't believe 'apt-get dist-upgrade' allows. Anyways, enough evangelism, onto the howto!
If you're subscribed to my RSS feed you may not even have noticed, but all of the steps have been already laid out over the past few posts. All that remains is to put them back together into one big chain of subtasks.
Step One: Break the SVM Mirror
- Total Downtime: One reboot (3 minutes)
- Link to Article: Unmirroring a RAID 1 Root Volume on Solaris
Step Two: Upgrade Solaris 9 to Solaris 10 using LiveUpgrade
- Total Downtime: One reboot (3 minutes)
- Link to Article: LiveUpgrade from Solaris 9 to Solaris 10
Step Three: Migrate from UFS to ZFS root using LiveUpgrade
- Total Downtime: One reboot (3 minutes) - possibly a minute or so service downtime if files are stored on separate UFS filesystems
- Link to Article: Use LiveUpgrade to Migrate from UFS to ZFS with Minimal Downtime
Step Four: Add the Second Disk to a ZFS Root Mirror
- Total Downtime: None
- Link to Article: Adding a 2nd Disk to a ZFS Root Pool
We've taken a large behemoth of a task that sounds like a large amount of downtime would have been incurred, and broken it down into smaller, more manageable substeps. As an added bonus, using Solaris technologies, downtime is kept to a minimum!

Comments
Awesome
That's just awesome.
Like you said there are some learning curves when you're used to doing it one way, but once you learn the new system there's always cool stuff.
Very fun, but time on reboot
Very fun, but time on reboot 3 minuts sound too much optimistic.
solaris live upgrade
hi is there any way directly migrating ufs(solaris 9) to zfs(solaris 10). In the above discription u upgrade solaris 9(ufs) to solaris 10(ufs) and after u upgrade solaris 10 ufs to solaris 10 zfs.
Nope, unfortunately not. In
Nope, unfortunately not. In fact, you can't even upgrade from the initial release of Solaris 10 UFS to latest Solaris 10 ZFS, you have to do the upgrade first, then migrate to ZFS. I can't remember which release, but there's one where they added support to booting from ZFS to the kernel. You have to upgrade to this release or higher first, then migrate to ZFS.
bug in lucreate - gotcha if you have /tmp on its own slice
An absolutely fine guide!
I ran into a problem (I have an open case with Sun) with lucreate, and I've figured out a workaround.
In your section LiveUpgrade from Solaris9 to Solaris 10 there is a step that uses the lucreate command to clone the existing system to another disk prior to the actual upgrade.
This lucreate will fail if you have /tmp mounted as its own disk slice, e.g. in /etc/vfstab:
My lucreate blew up with these errors:
I modified my /etc/vfstab by commenting out the mount of /tmp and instead used the default Solaris practice of having /tmp be part of the swap space:
After a reboot, the lucreate was run again, this time with success.
addendum to above post
I forgot to mention:
If you have the same issue that I had, you may need to
to clear the remnants of the failed lucreate command before trying it again.
"One reboot (3 minutes)" It
"One reboot (3 minutes)"
It took me about 12 minutes for one reboot:)
Sebastian
------------------------
css hover
Post new comment