Swapping Boot Disks on Solaris

The following explains how to swap the bootable internal hard drive in a Solaris system (upgrading it to a larger drive, for example). This requires an additional step over swapping a normal disk in a Solaris system, since the new disk has to be set bootable.

  1. Halt the system and insert the disk that will become the new boot disk in one of the internal slots. If this requires removing another internal disk, comment it out of /etc/vfstab before halting the system.

  2. Boot the system in single-user mode.

  3. Copy the system disk to the new disk. Format the new disk if necessary, build a file system on it with newfs (probably good to do this even if it already had a file system, to erase its contents), and then mount it on /mnt. Then enter:

        ufsdump 0f - /dev/rdsk/c0t0d0s3 | (cd /mnt; ufsrestore xf -)

    to copy it, where the argument to ufsdump is the correct path to the raw device for the old system disk.

  4. Initialize the boot block on the new disk:

        installboot /usr/platform/`uname -i`/lib/fs/ufs/bootblk \

    where the second argument is again the correct path to the raw device for the new system disk.

  5. Halt the system and swap the current and the new boot disks. You can leave the old boot disk out of the system. Remember that SCSI IDs in Solaris systems are determined by what slot the disk is in, so in order for the new boot disk to become active it needs to go into the same slot as the old boot disk.

  6. Boot the system single-user. The new disk should now be able to boot the system. Edit /etc/vfstab to put back in any additional devices if necessary.

  7. Replace any disks you had to remove in step one and boot the system multiuser. You're now done.

Last spun 2022-02-06 from thread modified 2013-01-04