Sunteți pe pagina 1din 3

Article ID : 1004663.

1
Article Type : Technical Instructions (SURE)
Last reviewed : 2008-11-04
Audience : SPECTRUM
Copyright Notice: Copyright © 2010, Oracle Corporation and/or its affiliates.

Solstice DiskSuite[TM] 4.X Software and Solaris[TM] Volume Manager Software - Mirrored
Boot Disk Recovery

Description
This document provides the procedures to repair a failed boot device under DiskSuite or Solaris[TM] Volume Manager control.

Steps to Follow
You will need the following info on hardcopy to proceed with the process:

1. ls -l /dev/dsk/c#t#d#s# of the alternate sub-mirror boot device

2. partition table layout of the failed boot device

Part I Creating an openboot prom alias to alternate boot device

1. Run metadb -i to confirm the state database replicas on boot device is non-operational. For example:

# metadb -i
flags first blk block count
M p unknown unknown /dev/dsk/c0t0d0s0
M p unknown unknown /dev/dsk/c0t0d0s0
a u 16 1034 /dev/dsk/c0t1d0s6
a u 16 1034 /dev/dsk/c1t2d0s3
o - replica active prior to last mddb configuration change
u - replica is up to date
l - locator for this replica was read successfully
c - replica's location was in /etc/opt/SUNWmd/mddb.cf
p - replica's location was patched in kernel
m - replica is master, this is replica selected as input
W - replica has device write errors
a - replica is active, commits are occurring to this replica
M - replica had problem with master blocks
D - replica had problem with data blocks
F - replica had format problems
S - replica is too small to hold current data base
R - replica had device read errors

2. The state replicas with flags in uppercase are bad. Use the metadb command to delete them. For example:

# metadb -d c0t0d0s0

(This will delete all state replicas on /dev/dsk/c0t0d0s0.)

If you have already defined a backup boot disk alias, go to part Part II

3. Bring system down to ok prompt.

4. From hardcopy output of ls -l of alternate boot device. For example:

lrwxrwxrwx 1 root root 86 Sep 15 1997 /dev/dsk/c1t3d0s0 ->


../../devices/iommu@0,10000000/sbus@0,10001000/espdma@4,8400000/esp@4,8800000/sd@3,0:a

The device path string beginning after "../../devices/" will be used to create the nvalias.

If you do not have a ls -l hardcopy, you can use 'show-disks' command to guess what is the correct device path

Create the alias with this command syntax:

ok nvalias backup_root /iommu@0,10000000/sbus@0,10001000/espdma@4,8400000/esp@4,8800000/sd@3,0:a

5. Test the nvalias by booting from the alternate boot device by:

ok boot backup_root

Part II: Replacing failed boot device


1. Gracefully power-down the system with this command:

# init 5

2. Physically replace the failed boot device.

3. Boot from alternate boot device (ok boot backup_root)

4. Repartition new boot disk in the exact configuration as specified in the hardcopy printout of the original boot device partition table layout.

Part III: Repairing state replica database

1. If you use Solaris[TM] Volume Manager on Solaris[TM] 9 or later, update the state database with the device ID for the new disk using
metadevadm -u c#t#d# .

# metadevadm -u c0t0d0

2. Once new boot disk is repartitioned, add new working state replicas back into the newly replaced disk drive. For example:

# metadb -a -c 2 c0t0d0s0

(The -c #; specifies how many replicas to put into the specified partition)

Part IV: Resyncing the sub-mirrors

1. Run metstat to find all the metadevices that the failed boot device belongs to. For example:

d0: Mirror
Submirror 0: d1
State: Needs maintenance
Submirror 1: d2
State: Okay
Pass: 1
Read option: roundrobin (default)
Write option: parallel (default)
Size: 205200 blocks
d1: Submirror of d0
State: Needs maintenance
Size: 205200 blocks
Stripe 0:
Device Start Block Dbase State Hot Spare
c0t0d0s0 0 No Okay
d2: Submirror of d0
State: Okay
Size: 205200 blocks
Stripe 0:
Device Start Block Dbase State Hot Spare
c1t2d0s0 0 No Okay

2. Use the metareplace command to re-enable the sub-mirror. For example:

# metareplace -e d0 c0t0d0s0

(Resync operation may take about 15-20 minutes per every gigabyte of filesystem)

3. Repeat metareplace command to re-enable the other sub-mirrors located on the same disk:

# metareplace -e d<mirror> c0t0d0s<slice of submirror in need maintenance>

4. Reboot system to have it boot from the newly repaired boot device:

Before rebooting, wait for the resync : all metadevices must be in 'Okay' state, then :

# init 6

Product
Solaris Volume Manager Software
Solstice DiskSuite 4.2.1
Solstice DiskSuite 4.2
Solstice DiskSuite 4.1
Solstice DiskSuite 4.0
Attachments

This solution has no attachment

About Oracle | Oracle and Sun | | Subscribe | Careers | Contact Us | Site Maps | Legal Notices | Terms of Use | SunSolve Terms of
Use | Your Privacy Rights | Copyright © 2010, Oracle Corporation and/or its affiliates | SunSolve Version 7.5.2 (build #1)

S-ar putea să vă placă și