我正在尝试恢复一个已经退化和被忽略的池,然后第二个镜像成员失败,导致一个错误池。不管出于什么原因,备用的永远不会自动替换,即使这个选项是为这个池设置的,但这是不重要的。
这是在一个OmniOS服务器上。池信息如下:
pool: dev-sata1
state: UNAVAIL
status: One or more devices are faulted in response to IO failures.
action: Make sure the affected devices are connected, then run 'zpool clear'.
see: http://illumos.org/msg/ZFS-8000-JQ
scan: resilvered 1.53T in 21h6m with 0 errors on Sat Jun 17 13:18:04 2017
config:
NAME STATE READ WRITE CKSUM
dev-sata1 UNAVAIL 227 623 0 insufficient replicas
mirror-0 ONLINE 0 0 0
c1t5000C5003ECEEC42d0 ONLINE 0 0 0
c1t5000C5003ED6D008d0 ONLINE 0 0 0
mirror-1 ONLINE 0 0 0
c1t5000C500930358EAd0 ONLINE 0 0 0
c1t5000C500930318E1d0 ONLINE 0 0 0
mirror-3 ONLINE 0 0 0
c1t5000C5003F362DA7d0 ONLINE 0 0 0
c1t5000C5003F365D94d0 ONLINE 0 0 0
mirror-4 ONLINE 0 0 0
c1t5000C50064D11652d0 ONLINE 0 0 0
c1t5000C500668EC894d0 ONLINE 0 0 0
mirror-5 ONLINE 0 0 0
c1t5000C5007A2DBE23d0 ONLINE 0 0 0
c1t5000C5007A2DF29Cd0 ONLINE 0 0 0
mirror-6 UNAVAIL 457 1.22K 5 insufficient replicas
15606980839703210365 UNAVAIL 0 0 0 was /dev/dsk/c1t5000C5007A2E1359d0s0
c1t5000C5007A2E1BAEd0 FAULTED 37 1.25K 5 too many errors
mirror-7 ONLINE 0 0 0
c1t5000C5007A34981Bd0 ONLINE 0 0 0
c1t5000C5007A3929B6d0 ONLINE 0 0 0
logs
mirror-2 ONLINE 0 0 0
c1t55CD2E404B740DD3d0 ONLINE 0 0 0
c1t55CD2E404B7591BEd0 ONLINE 0 0 0
cache
c1t50025388A0952EB0d0 ONLINE 0 0 0
spares
c1t5000C5002CD7AFB6d0 AVAIL磁盘"c1t5000C5007A2E1BAEd0“目前处于数据恢复设施中,但它们已经耗尽了替换磁头的供应,包括我们提供的捐助磁盘。标记为缺失的磁盘最终被找到,并可能被恢复,但这是最后的结果,因为我不知道它与其他磁盘相比有多过时,以及这对一致性意味着什么。要被认为是一个捐献者,前三个字母的串行需要匹配,以及网站代码。我在池中还有4个符合这个标准的磁盘,并且在池下降时是健康的。
因此,关于我的问题:在使用dd将整个捐助方磁盘复制到每个磁盘之后,是否有可能用4个新磁盘替换其他4个可能与捐助者兼容的磁盘(基于序列号)?
我不清楚池在导入磁盘时是否需要WWN或串行匹配其存储的内容(如果它存储缓存以外的任何内容),还是扫描每个磁盘上的元数据以确定是否可以导入池。如果后者是真的,我的策略是否可行,获得4个更多的捐赠者磁盘?
发布于 2018-10-04 22:50:27
绝对不要使用dd!ZFS有一个内置的命令,在甲骨文文档中描述得相当好。您应该能够使用zpool replace tank <old device> <new device>完成操作的主要部分,但是还有其他一些辅助命令:
以下是替换磁盘的基本步骤:
zpool offline命令脱机磁盘。zpool replace命令。例如:zpool replace tank c1t1d0zpool online命令将磁盘联机。该手册页还提供了一些其他信息:
zpool replace [-f] pool device [new_device]
Replaces old_device with new_device. This is equivalent to attaching
new_device, waiting for it to resilver, and then detaching
old_device.
The size of new_device must be greater than or equal to the minimum
size of all the devices in a mirror or raidz configuration.
new_device is required if the pool is not redundant. If new_device is
not specified, it defaults to old_device. This form of replacement
is useful after an existing disk has failed and has been physically
replaced. In this case, the new disk may have the same /dev path as
the old device, even though it is actually a different disk. ZFS
recognizes this.
-f Forces use of new_device, even if its appears to be in use.
Not all devices can be overridden in this manner.当然,最好首先在配置类似的zpool中具有虚拟磁盘的VM上尝试,而不是第一次在池上尝试使用您关心的恢复数据。
顺便说一句,文档的另一部分解释了更多关于热备件的内容,也许还包括了一些说明为什么您的产品没有被使用的指针。为确保下一次它不会再出故障,四处打听一下可能是有价值的。
https://serverfault.com/questions/934018
复制相似问题