Sun Cluster Quick Start Guide for Solaris OS

ProcedureHow to Mirror the Root (/) File System

Perform this procedure on one node at a time.

This procedure assumes that the cluster node contains the internal nonshared disks c0t0d0 and c0t1d0. Substitute your own internal disk names if necessary in the steps of this procedure.

  1. On phys-sun, place the root slice c0t0d0s0 in a single-slice (one-way) concatenation.

    phys-sun# metainit -f d10 1 1 c0t0d0s0
  2. Create a second concatenation with the other internal disk, c0t1d0s0.

    phys-sun# metainit d20 1 1 c0t1d0s0
  3. Create a one-way mirror with one submirror.

    phys-sun# metainit d0 -m d10
  4. Set up the system files for the root directory.

    phys-sun# metaroot d0

    The metaroot command edits the /etc/vfstab and /etc/system files so that the system can be booted with the root (/) file system on a metadevice or volume. For more information, see the metaroot(1M) man page.

  5. Flush all file systems.

    phys-sun# lockfs -fa

    The lockfs command flushes all transactions from the log and writes the transactions to the master file system on all mounted UFS file systems. For more information, see the lockfs(1M) man page.

  6. Reboot the node to remount the newly mirrored root (/) file system.

    phys-sun# init 6
  7. Attach the second submirror to the mirror.

    phys-sun# metattach d0 d20

    For more information, see the metattach(1M) man page.

  8. Record the alternate boot path for possible future use.

    If the primary boot device fails, you can then boot from this alternate boot device. For more information about alternate boot devices, see Creating a RAID-1 Volume in Solaris Volume Manager Administration Guide.

    phys-sun# ls -l /dev/rdsk/c0t1d0s0
  9. Repeat Step 1 through Step 8 on phys-moon.