The previous sdb died in my array, so I replaced it. When I try to add the new disk, I get the following error. I can't even add it as a spare.
# mdadm --add /dev/md1 /dev/sdb mdadm: add new device failed for /dev/sdb as 3: Invalid argument # cat /proc/mdstat Personalities : [raid0] [raid1] [raid6] [raid5] [raid4] [raid10] md1 : active raid1 sda[2] 3906852864 blocks super 1.2 [2/1] [U_] bitmap: 12/30 pages [48KB], 65536KB chunk unused devices: <none> # mdadm --manage /dev/md1 --add-spare /dev/sdb mdadm: add new device failed for /dev/sdb as 3: Invalid argument # dmesg -T | tail | grep md [Mon Aug 5 13:53:56 2024] md: sdb does not have a valid v1.2 superblock, not importing! [Mon Aug 5 13:53:56 2024] md: md_import_device returned -22 # mdadm --examine /dev/sdb /dev/sdb: Magic : a92b4efc Version : 1.2 Feature Map : 0x9 Array UUID : 1919e203:1242d469:d56eea7e:80667163 Name : neverpi:1 Creation Time : Thu Jul 8 17:29:41 2021 Raid Level : raid1 Raid Devices : 2 Avail Dev Size : 7813705728 sectors (3.64 TiB 4.00 TB) Array Size : 3906852864 KiB (3.64 TiB 4.00 TB) Data Offset : 264192 sectors Super Offset : 8 sectors Unused Space : before=264112 sectors, after=0 sectors State : clean Device UUID : 42492d32:9b6c9bda:93c938a2:20651bda Internal Bitmap : 8 sectors from superblock Update Time : Mon Aug 5 13:49:02 2024 Bad Block Log : 512 entries available at offset 24 sectors - bad blocks present. Checksum : 8d549512 - correct Events : 0 I have tried clearing the first 100MB of the disk using dd, and I have tried using the zero superblock command. Where do I go from here?
This is a proxmox machine running
# uname -a 6.8.8-4-pve #1 SMP PREEMPT_DYNAMIC PMX 6.8.8-4 (2024-07-26T11:15Z) x86_64 GNU/Linux
mdadm --examine /dev/sda.