本文主要是介绍mdadm 删除 软件 RAID,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!
mdadm 删除 软件 RAID
- 1,查看
- 2,删除
1,查看
# mdadm -D /dev/md0
/dev/md0:Version : 1.2Creation Time : Sun Sep 20 16:28:18 2020Raid Level : raid0Array Size : 62511153152 (59615.28 GiB 64011.42 GB)Raid Devices : 8Total Devices : 8Persistence : Superblock is persistentUpdate Time : Sun Sep 20 16:28:18 2020State : cleanActive Devices : 8Working Devices : 8Failed Devices : 0Spare Devices : 0Chunk Size : 512KConsistency Policy : noneName : ubuntu-server:0UUID : 6800c526:128831d0:fd0d9f7b:be6faef7Events : 0Number Major Minor RaidDevice State0 8 0 0 active sync /dev/sda1 8 16 1 active sync /dev/sdb2 8 32 2 active sync /dev/sdc3 8 48 3 active sync /dev/sdd4 8 64 4 active sync /dev/sde5 8 80 5 active sync /dev/sdf6 8 96 6 active sync /dev/sdg7 8 112 7 active sync /dev/sdh
- raid0
# cat /proc/mdstat
Personalities : [raid0] [linear] [multipath] [raid1] [raid6] [raid5] [raid4] [raid10]
md0 : active raid0 sdd[3] sda[0] sdc[2] sdb[1] sdh[7] sdg[6] sde[4] sdf[5]62511153152 blocks super 1.2 512k chunksunused devices: <none>
# cat /etc/mdadm/mdadm.conf
ARRAY /dev/md0 metadata=1.2 name=ubuntu-server:0 UUID=6800c526:128831d0:fd0d9f7b:be6faef7
MAILADDR root
# df -Th
/dev/md0p1 ext4 58T 100K 56T 1% /chain
umount /chain
2,删除
# mdadm -S /dev/md0
mdadm: stopped /dev/md0
# lsblk -o NAME,SIZE,FSTYPE,TYPE,MOUNTPOINT
NAME SIZE FSTYPE TYPE MOUNTPOINT
sda 7.3T linux_raid_member disk
sdb 7.3T linux_raid_member disk
sdc 7.3T linux_raid_member disk
sdd 7.3T linux_raid_member disk
sde 7.3T linux_raid_member disk
sdf 7.3T linux_raid_member disk
sdg 7.3T linux_raid_member disk
sdh 7.3T linux_raid_member disk
# cat /etc/mdadm/mdadm.conf
ARRAY /dev/md0 metadata=1.2 name=ubuntu-server:0 UUID=6800c526:128831d0:fd0d9f7b:be6faef7
MAILADDR root
# cat /dev/null > /etc/mdadm/mdadm.conf
- 删除元数据
# mdadm --zero-superblock /dev/sda
# mdadm --zero-superblock /dev/sdb
# mdadm --zero-superblock /dev/sdc
# mdadm --zero-superblock /dev/sdd
# lsblk -o NAME,SIZE,FSTYPE,TYPE,MOUNTPOINT
NAME SIZE FSTYPE TYPE MOUNTPOINT
sda 7.3T disk
sdb 7.3T disk
sdc 7.3T disk
sdd 7.3T disk
sde 7.3T disk
sdf 7.3T linux_raid_member disk
sdg 7.3T linux_raid_member disk
sdh 7.3T linux_raid_member disk
参考:
- mdadm彻底删除software RAID
这篇关于mdadm 删除 软件 RAID的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!