我的 Ubuntu 中有两个 500 GB 的物理硬盘12.04.4PC,并且它们应该位于 2 磁盘 RAID 阵列中。然而,mdadm -D /dev/md0报告称/dev/sda 似乎不起作用,即使重启后也是如此:
/dev/md0:
Version : 1.2
Creation Time : Sat Oct 12 20:01:52 2013
Raid Level : raid1
Array Size : 471531328 (449.69 GiB 482.85 GB)
Used Dev Size : 471531328 (449.69 GiB 482.85 GB)
Raid Devices : 2
Total Devices : 1
Persistence : Superblock is persistent
Update Time : Tue Jun 24 22:57:41 2014
State : clean, degraded
Active Devices : 1
Working Devices : 1
Failed Devices : 0
Spare Devices : 0
Name : xxxxx:0 (local to host xxxxx)
UUID : d87b72eb:17425250:dfbf806f:60eba0fc
Events : 4482651
Number Major Minor RaidDevice State
0 0 0 0 removed
1 8 17 1 active sync /dev/sdb1
md1 和 sda5/sdb5 类似。磁盘管理可以看到 sda 和 sdb。我在/proc/mdstat:
Personalities : [linear] [multipath] [raid0] [raid1] [raid6] [raid5] [raid4] [raid10]
md1 : active raid1 sdb5[1]
16712576 blocks super 1.2 [2/1] [_U]
md0 : active raid1 sdb1[1]
471531328 blocks super 1.2 [2/1] [_U]
unused devices: <none>
消息显示如下:
[ 2.187963] md: linear personality registered for level -1
[ 2.189389] md: multipath personality registered for level -4
[ 2.190202] md: raid0 personality registered for level 0
[ 2.191153] md: raid1 personality registered for level 1
[ 2.329273] md: bind<sda1>
[ 2.330746] md: bind<sda5>
[ 2.342623] md: bind<sdb1>
[ 2.343018] md: kicking non-fresh sda1 from array!
[ 2.343022] md: unbind<sda1>
[ 2.435343] md: raid6 personality registered for level 6
[ 2.435346] md: raid5 personality registered for level 5
[ 2.435348] md: raid4 personality registered for level 4
[ 2.437993] md: raid10 personality registered for level 10
[ 2.439651] md: export_rdev(sda1)
[ 2.440324] md/raid1:md0: active with 1 out of 2 mirrors
[ 2.440341] md0: detected capacity change from 0 to 482848079872
[ 2.460418] md0: unknown partition table
[ 2.481119] md: bind<sdb5>
[ 2.483049] md: kicking non-fresh sda5 from array!
[ 2.483066] md: unbind<sda5>
[ 2.486916] md: export_rdev(sda5)
[ 2.487564] md/raid1:md1: active with 1 out of 2 mirrors
[ 2.487578] md1: detected capacity change from 0 to 17113677824
[ 2.495906] md1: unknown partition table
这个“非新鲜的 sda1”消息是什么?
我见过这条信息在 linuxquestions.org 上。我应该按照它说的做吗, IE:
/sbin/mdadm /dev/md0 --fail /dev/sda1 --remove /dev/sda1
/sbin/mdadm /dev/md0 --add /dev/sda1
/sbin/mdadm /dev/md1 --fail /dev/sda5 --remove /dev/sda5
/sbin/mdadm /dev/md1 --add /dev/sda5
我认为这不会影响安全数据库无论如何。谢谢。
答案1
以正确的格式提供答案,而不仅仅是关联来自一条评论。
“这可能发生在非正常关机(如电源故障)后。通常,移除并重新添加问题设备即可解决问题。”
请参阅您的特定驱动器配置和 mdadm 版本特定文档以了解如何执行此操作。
另一种方法是使用 Gnome Disks 实用程序。选择“Raid Disks”(Ctrl+R),然后选择 +,然后选择丢失的 raid 驱动器。确认所有数据都将被从正在添加的驱动器中清除后,新添加的驱动器应进入“正在恢复”状态。关闭对话框将带您返回主磁盘屏幕。它应该显示一个进度条,其中显示“正在恢复:xx%”和完成同步的预计时间。