mdadm:DEVICE行

时间:2017-01-28 20:47:08

标签: ubuntu raid mdadm

当我在mdadm中运行扫描时,我收到此消息:

me@server:/sbin$ mdadm --monitor --scan
mdadm: unreconised word on DEVICE line: UUID=8eac0a3d-a22c-1a92-6ed9-f147f3dea64f
mdadm: unreconised word on DEVICE line: UUID=246226d0-a621-7f34-87b6-ff33b5c55906
mdadm: unreconised word on DEVICE line: UUID=52e1afa6-3ca6-a96e-f3dc-99bd0f56e878
mdadm: unreconised word on DEVICE line: UUID=16843e03-f177-97ef-07a7-6d761de9e99b
mdadm: must be super-user to perform this action

我的/etc/mdadm/mdadm.conf文件的内容如下所示:

# mdadm.conf
#
# Please refer to mdadm.conf(5) for information about this file.
#

# by default (built-in), scan all partitions (/proc/partitions) and all
# containers for MD superblocks. alternatively, specify devices to scan, using
# wildcards if desired.
#DEVICE partitions containers

# auto-create devices with Debian standard permissions
CREATE owner=root group=disk mode=0660 auto=yes

# automatically tag new arrays as belonging to the local system
HOMEHOST <system>

# instruct the monitoring daemon where to send mail alerts

# definitions of existing MD arrays

# This file was auto-generated on Tue, 09 Dec 2014 22:43:32 +0100
# by mkconf $Id$
#DEVICE /dev/sdb1 /dev/sdc1 /dev/sdd1 /dev/sde1
#ARRAY /dev/md0 level=raid10 devices=/dev/sdb1,/dev/sdc1,/dev/sdd1,/dev/sde1

#DEVICE /dev/sda1 /dev/sdb1 /dev/sdc1 /dev/sdd1
#ARRAY /dev/md0 level=raid10 devices=/dev/sda1,/dev/sdb1,/dev/sdc1,/dev/sdd1

#Use UUID so that we don't have to manually assemble the raid array
#each time the mount points change, since UID always stays the same
DEVICE UUID=8eac0a3d-a22c-1a92-6ed9-f147f3dea64f UUID=246226d0-a621-7f34-87b6-ff33b5c55906 UUID=52e1afa6-3ca6-a96e-f3dc-99bd0f56e878 UUID=16843e03-f177-97ef-07a7-6d761de9e99b
ARRAY UUID=bc6fa71d-d452-4cf1-ad73-a3de424c078d level=raid10 devices=UUID=8eac0a3d-a22c-1a92-6ed9-f147f3dea64f,UUID=246226d0-a621-7f34-87b6-ff33b5c55906,UUID=52e1afa6-3ca6-a96e-f3dc-99bd0f56e878,UUID=16843e03-f177-97ef-07a7-6d761de9e99b

是语法错误吗?或者它会是什么?

就我的功能而言,RAID阵列的功能正常。它正在安装,我可以使用它。

如果我能找出导致该消息的原因,我会感觉更舒服。

1 个答案:

答案 0 :(得分:1)

根据mdadm.conf的手册页,DEVICE行必须采用以下格式:

DEVICE /dev/hda* /dev/hdc*
DEV    /dev/sd*
DEVICE /dev/disk/by-path/pci*
DEVICE partitions

默认值为DEVICE partitions containers,这基本上意味着扫描所有分区和任何寻找阵列成员的RAID阵列。似乎UUID不是可以在/etc/fstab中使用的有效标识符。通常,您不必指定磁盘,因为DEVICE行仅扫描设备以查找阵列成员而不要求它是阵列的一部分。如果您需要指定设备,请在/dev/disks/by-*/中找到要使用的相应符号链接。