I'm upgrading Solaris 10 release 3/05 to release 8/07 using Live Upgrade on a system running it's root (/) on a Metadevice mirror.

This short setp-by-step guide will show you how to accomplish an upgrade when there is no free slice to create a clone of the running system. This can be solved by using a submirror of an existing Metadevice mirror.

Before performing any of the steps described here, make sure to carefully read the Live Upgrade How-To from SUN!

You can do severe damage to your system if you are not aware of what you are doing!

First check the metastat command for the mirror where the root filesystem resides on. In my case it's d0:

metastat d0

The output should look similar to this:

d0: Mirror

Submirror 0: d1

State: Okay

Submirror 1: d2

State: Okay

Pass: 1

Read option: roundrobin (default)

Write option: parallel (default)

Size: 122773440 blocks (58 GB)

d1: Submirror of d0

State: Okay

Size: 122773440 blocks (58 GB)

Stripe 0:

Device Start Block Dbase State Reloc Hot Spare

/dev/dsk/c4t500000E010E6D970d0s0 0 No Okay Yes

d2: Submirror of d0

State: Okay

Size: 122773440 blocks (58 GB)

Stripe 0:

Device Start Block Dbase State Reloc Hot Spare

/dev/dsk/c4t500000E010EE86E0d0s0 0 No Okay Yes

As we can see, d0 consists of the two submirrors d1 and d2.

To upgrade to a new release, Live Upgrade will clone the running system, perform the upgrade on the clone, activate and boot it. Cloning the system requires a free Slice. On my system, all slices are taken, so I have to use one of the submirrors as a free slice.

Let's detach on of the submirrors, e.g. d2:

metadetach d0 d2

Submirror d2 is now free and can be used as a target for the cloning process:

lucreate -c sol10_3_05 -n sol10_8_07 -m /:d2:ufs

Be patient while the system is being cloned.

Meanwhile make sure the DVD with the new release is in the drive.

Once lucreate has successfully finished, you can perform the actual upgrade on the clone :

luupgrade -u -n sol10_08_07 -s /cdrom/cdrom0/s0

Activate the clone to designate it as the new boot environment:

luactivate sol10_8_07

Reboot after this:

init 6

When the system is back up, check that it's running the new Release :

cat /etc/release

In my case it should state " Solaris 10 8/07 s10s_u4wos_12b SPARC".

If the new boot environment is running smooth and no problems arise, delete the old environment:

ludelete sol10_3_05

Now it's time to recreate the Metadevice mirror.

First, clear the old and currently unsused mirror d0:

metaclear d0

Create the new Mirror with d2 as its first submirror:

metatinit d0 -m d2

The mirror d0 now has the new release as it's base (located on submirror d2).

Attach d1 to the new mirror and have it resync to d2:

metattach d0 d1

You can now check if d0 is resyncing d1:

metastat d0

It should state something like:

d0: Mirror

Submirror 0: d2

State: Okay

Submirror 1: d1

State: Resyncing

Resync in progress: 23 % done

Pass: 1

Read option: roundrobin (default)

Write option: parallel (default)

Size: 122773440 blocks (58 GB)

d2: Submirror of d0

State: Okay

Size: 122773440 blocks (58 GB)

Stripe 0:

Device Start Block Dbase State Reloc Hot Spare

c1t1d0s0 0 No Okay Yes

d1: Submirror of d0

State: Resyncing

Size: 122773440 blocks (58 GB)

Stripe 0:

Device Start Block Dbase State Reloc Hot Spare

c1t0d0s0 0 No Okay Yes

Once both submirrors are in sync you have toswitch the device for the root filesystem.

Open /etc/vfstab with an editor and replace the device d2 for / with d0:

Replace:

/dev/md/dsk/d2 /dev/md/rdsk/d2 / ufs 1 no -

with:

/dev/md/dsk/d0 /dev/md/rdsk/d0 / ufs 1 no -

Now do a final reboot:

init 6

You now should have your System back with Metadevice Mirrors and an up to date release.