0

I have two 3TB drives, with a single ext4 partition on each.

I have added both drives to my raid1 array but running

mdadm --detail /dev/md0

outputs:

/dev/md0:
        Version : 1.2
  Creation Time : Tue Dec 27 09:57:07 2016
     Raid Level : raid1
     Array Size : 2930134016 (2794.39 GiB 3000.46 GB)
  Used Dev Size : 2930134016 (2794.39 GiB 3000.46 GB)
   Raid Devices : 1
  Total Devices : 2
    Persistence : Superblock is persistent

  Intent Bitmap : Internal

    Update Time : Wed Dec 28 00:15:06 2016
          State : clean 
 Active Devices : 1
Working Devices : 2
 Failed Devices : 0
  Spare Devices : 1

           Name : i3:0  (local to host i3)
           UUID : fd445401:e6153885:3b3e1a44:7f4e953d
         Events : 32

    Number   Major   Minor   RaidDevice State
       0       8       17        0      active sync   /dev/sdb1
       1       8       33        -      spare   /dev/sdc1

Can anyone tell me why /dev/sdc1 is marked as spare and not active and no sync has occurred?

Thanks in advance.

As requested, cat /proc/mdstat outputs:

Personalities : [raid1] [linear] [multipath] [raid0] [raid6] [raid5] [raid4] [raid10]
md0 : active raid1 sdb1[0] sdc1[1](S)
      2930134016 blocks super 1.2 [1/1] [U]
      bitmap: 0/22 pages [0KB], 65536KB chunk

fdisk -l /dev/sdb outputs:

Disk /dev/sdb: 2.7 TiB, 3000592982016 bytes, 5860533168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier: 81404E26-1A56-409F-9F50-B1BBDF405740

Device     Start        End    Sectors  Size Type
/dev/sdb1   2048 5860532223 5860530176  2.7T Linux filesystem

fdisk -l /dev/sdc outputs:

Disk /dev/sdc: 2.7 TiB, 3000592982016 bytes, 5860533168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier: 81404E26-1A56-409F-9F50-B1BBDF405740

Device     Start        End    Sectors  Size Type
/dev/sdc1   2048 5860532223 5860530176  2.7T Linux filesystem

Looking at these outputs obviously the UUID's are, well, duplicated, so I assume if I make them unique I might then be able to resolve the second device not being active.

However, using tune2fs I cannot set the UUID. No errors but sudo lsblk -fo UUID /dev/sdc1 outputs the original UUID.

3
  • 1
    Your output is garbled, making it hard to read. Can you please also include the output of cat /proc/mdstat, as well as fdisk -l /dev/sdb and fdisk -l /dev/sdc. It's at the very least weird that you are adding ext4 partitions to an mdraid version 1.2 array. Commented Dec 28, 2016 at 1:47
  • So what type should they be added as? I'll get the other outputs now. TIA
    – lazarus
    Commented Dec 28, 2016 at 9:43
  • Looking at these outputs obviously the UUID's are, well, duplicated, so I assume if I make them unique I might then be able to get the second device as active.
    – lazarus
    Commented Dec 28, 2016 at 11:43

1 Answer 1

0

Ok - so I did this:

  • removing the second device from the array
  • removing the superblock from the partition
  • fixing the non-unique disk UUID
  • re-adding the disk

... it has now started rebuilding the array. :)

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .