跳过导航链接 | |
退出打印视图 | |
Solaris Volume Manager 管理指南 Oracle Solaris 10 1/13 Information Library (简体中文) |
4. Solaris Volume Manager for Sun Cluster(概述)
5. 配置和使用 Solaris Volume Manager(方案)
20. 维护 Solaris Volume Manager(任务)
21. Solaris Volume Manager 的最佳做法
25. Solaris Volume Manager 故障排除(任务)
Solaris Volume Manager 故障排除(任务列表)
Solaris Volume Manager 故障排除的一般原则
如何使用 Solaris Volume Manager 配置来恢复系统
A. 重要的 Solaris Volume Manager 文件
B. Solaris Volume Manager 快速参考
即使在不同于原始系统的系统上也可以恢复 Solaris Volume Manager 配置。
如果遇到系统故障,则可以将存储连接到另一个系统,然后从本地磁盘集恢复完整的配置。例如,假设您的系统有一个由六个磁盘组成的外部磁盘组,某些磁盘上具有 Solaris Volume Manager 配置(至少包括一个状态数据库副本)。如果系统出现故障,则可以将这个磁盘组以物理方式移到新系统中,并使新系统能够识别该配置。此过程说明如何将磁盘移到另一个系统以及如何从本地磁盘集恢复配置。
注 - 此恢复过程仅适用于 Solaris 9 及更高版本的 Solaris Volume Manager 卷。
# reboot -- -r
运行 ls -lL,并记下组名和日期之间的两个数字。这两个数字就是此分片的主/从设备号。
# ls -Ll /dev/dsk/c1t9d0s7 brw-r----- 1 root sys 32, 71 Dec 5 10:05 /dev/dsk/c1t9d0s7
# grep " 32" /etc/name_to_major sd 32
例如,在以 mddb_bootlist1 开头的行中,使用在步骤 4 中找到的主设备名称替换 sd。使用在步骤 3 中确定的从设备号替换本示例中的 71。
#pragma ident "@(#)md.conf 2.2 04/04/02 SMI" # # Copyright 2004 Sun Microsystems, Inc. All rights reserved. # Use is subject to license terms. # # The parameters nmd and md_nsets are obsolete. The values for these # parameters no longer have any meaning. name="md" parent="pseudo" nmd=128 md_nsets=4; # Begin MDD database info (do not edit) mddb_bootlist1="sd:71:16:id0"; # End MDD database info (do not edit)
您将看到类似于以下内容的消息显示在控制台上。
volume management starting. Dec 5 10:11:53 host1 metadevadm: Disk movement detected Dec 5 10:11:53 host1 metadevadm: Updating device names in Solaris Volume Manager The system is ready.
# metadb flags first blk block count a m p luo 16 8192 /dev/dsk/c1t9d0s7 a luo 16 8192 /dev/dsk/c1t10d0s7 a luo 16 8192 /dev/dsk/c1t11d0s7 a luo 16 8192 /dev/dsk/c1t12d0s7 a luo 16 8192 /dev/dsk/c1t13d0s7 # metastat d12: RAID State: Okay Interlace: 32 blocks Size: 125685 blocks Original device: Size: 128576 blocks Device Start Block Dbase State Reloc Hot Spare c1t11d0s3 330 No Okay Yes c1t12d0s3 330 No Okay Yes c1t13d0s3 330 No Okay Yes d20: Soft Partition Device: d10 State: Okay Size: 8192 blocks Extent Start Block Block count 0 3592 8192 d21: Soft Partition Device: d10 State: Okay Size: 8192 blocks Extent Start Block Block count 0 11785 8192 d22: Soft Partition Device: d10 State: Okay Size: 8192 blocks Extent Start Block Block count 0 19978 8192 d10: Mirror Submirror 0: d0 State: Okay Submirror 1: d1 State: Okay Pass: 1 Read option: roundrobin (default) Write option: parallel (default) Size: 82593 blocks d0: Submirror of d10 State: Okay Size: 118503 blocks Stripe 0: (interlace: 32 blocks) Device Start Block Dbase State Reloc Hot Spare c1t9d0s0 0 No Okay Yes c1t10d0s0 3591 No Okay Yes d1: Submirror of d10 State: Okay Size: 82593 blocks Stripe 0: (interlace: 32 blocks) Device Start Block Dbase State Reloc Hot Spare c1t9d0s1 0 No Okay Yes c1t10d0s1 0 No Okay Yes Device Relocation Information: Device Reloc Device ID c1t9d0 Yes id1,sd@SSEAGATE_ST39103LCSUN9.0GLS3487980000U00907AZ c1t10d0 Yes id1,sd@SSEAGATE_ST39103LCSUN9.0GLS3397070000W0090A8Q c1t11d0 Yes id1,sd@SSEAGATE_ST39103LCSUN9.0GLS3449660000U00904NZ c1t12d0 Yes id1,sd@SSEAGATE_ST39103LCSUN9.0GLS32655400007010H04J c1t13d0 Yes id1,sd@SSEAGATE_ST39103LCSUN9.0GLS3461190000701001T0 # # metadb flags first blk block count a m p luo 16 8192 /dev/dsk/c1t9d0s7 a luo 16 8192 /dev/dsk/c1t10d0s7 a luo 16 8192 /dev/dsk/c1t11d0s7 a luo 16 8192 /dev/dsk/c1t12d0s7 a luo 16 8192 /dev/dsk/c1t13d0s7 # metastat d12: RAID State: Okay Interlace: 32 blocks Size: 125685 blocks Original device: Size: 128576 blocks Device Start Block Dbase State Reloc Hot Spare c1t11d0s3 330 No Okay Yes c1t12d0s3 330 No Okay Yes c1t13d0s3 330 No Okay Yes d20: Soft Partition Device: d10 State: Okay Size: 8192 blocks Extent Start Block Block count 0 3592 8192 d21: Soft Partition Device: d10 State: Okay Size: 8192 blocks Extent Start Block Block count 0 11785 8192 d22: Soft Partition Device: d10 State: Okay Size: 8192 blocks Extent Start Block Block count 0 19978 8192 d10: Mirror Submirror 0: d0 State: Okay Submirror 1: d1 State: Okay Pass: 1 Read option: roundrobin (default) Write option: parallel (default) Size: 82593 blocks d0: Submirror of d10 State: Okay Size: 118503 blocks Stripe 0: (interlace: 32 blocks) Device Start Block Dbase State Reloc Hot Spare c1t9d0s0 0 No Okay Yes c1t10d0s0 3591 No Okay Yes d1: Submirror of d10 State: Okay Size: 82593 blocks Stripe 0: (interlace: 32 blocks) Device Start Block Dbase State Reloc Hot Spare c1t9d0s1 0 No Okay Yes c1t10d0s1 0 No Okay Yes Device Relocation Information: Device Reloc Device ID c1t9d0 Yes id1,sd@SSEAGATE_ST39103LCSUN9.0GLS3487980000U00907AZ1 c1t10d0 Yes id1,sd@SSEAGATE_ST39103LCSUN9.0GLS3397070000W0090A8Q c1t11d0 Yes id1,sd@SSEAGATE_ST39103LCSUN9.0GLS3449660000U00904NZ c1t12d0 Yes id1,sd@SSEAGATE_ST39103LCSUN9.0GLS32655400007010H04J c1t13d0 Yes id1,sd@SSEAGATE_ST39103LCSUN9.0GLS3461190000701001T0 # metastat -p d12 -r c1t11d0s3 c1t12d0s3 c1t13d0s3 -k -i 32b d20 -p d10 -o 3592 -b 8192 d21 -p d10 -o 11785 -b 8192 d22 -p d10 -o 19978 -b 8192 d10 -m d0 d1 1 d0 1 2 c1t9d0s0 c1t10d0s0 -i 32b d1 1 2 c1t9d0s1 c1t10d0s1 -i 32b #
在 Solaris Volume Manager 中引入了对磁盘集设备 ID 的支持,这允许您从已知磁盘集恢复存储并将该磁盘集导入另一个系统。通过 metaimport 命令,可以将已知磁盘集从一个系统导入另一个系统。这两个系统都必须包含现有的 Solaris Volume Manager 配置(包括设备 ID 支持)。有关设备 ID 支持的详细信息,请参阅磁盘集中的异步共享存储。有关 metaimport 命令的更多信息,请参见 metaimport(1M) 手册页。
# metaimport -r -v
提供可导入到系统上的未配置磁盘集的报告。
提供有关以下内容的详细信息:状态数据库副本的位置;可导入到系统上的未配置磁盘集中各磁盘的状态。
示例 25-3 报告可导入的磁盘集
以下示例说明如何打印有关可导入磁盘集的报告。
# metaimport -r Drives in regular diskset including disk c1t2d0: c1t2d0 c1t3d0 More info: metaimport -r -v c1t2d0 Import: metaimport -s <newsetname> c1t2d0 Drives in replicated diskset including disk c1t4d0: c1t4d0 c1t5d0 More info: metaimport -r -v c1t4d0 Import: metaimport -s <newsetname> c1t4d0 # metaimport -r -v c1t2d0 Import: metaimport -s <newsetname> c1t2d0 Last update: Mon Dec 29 14:13:35 2003 Device offset length replica flags c1t2d0 16 8192 a u c1t3d0 16 8192 a u c1t8d0 16 8192 a u
# metaimport -r -v
# metaimport -s diskset-name drive-name
指定要创建的磁盘集的名称。
标识要导入的磁盘集中包含状态数据库副本的磁盘 (c#t#d#)。
# metaset -s diskset-name
示例 25-4 导入磁盘集
以下示例说明如何导入磁盘集。
# metaimport -s red c1t2d0 Drives in diskset including disk c1t2d0: c1t2d0 c1t3d0 c1t8d0 More info: metaimport -r -v c1t2d0# metaset -s red Set name = red, Set number = 1 Host Owner host1 Yes Drive Dbase c1t2d0 Yes c1t3d0 Yes c1t8d0 Yes