1

Am running Ubuntu 16.04 and setup a raid with 2 4tb hdd's. When I run this:

sudo cat /proc/mdstat
Personalities : [raid1] [linear] [multipath] [raid0] [raid6] [raid5] [raid4] [raid10] 
md0 : active raid1 sda[0] sdb[1]
      3906887488 blocks super 1.2 [2/2] [UU]
      bitmap: 0/30 pages [0KB], 65536KB chunk

unused devices: <none>

Yet, when I run this:

sudo mdadm --detail /mnt/md0
mdadm: /mnt/md0 does not appear to be an md device

So I am confused. It is in raid, but not with mdadm? How do I ensure that I have this raid setup correctly?

Additionally, how can I ensure this is mounted correctly? Lots to read on the net, but first time doing this in Linux.

2
  • How'd you set up the raid? Anything to do with dmraid? Anything in /dev/mapper/ or any /dev/dm*?
    – Xen2050
    Sep 15, 2017 at 6:02
  • Another setup style (dmraid) uses an assembled "name" in /dev/mapper/ but it looks like yours should be /dev/md# or in /dev/md/ I haven't found a simple command to check for sure, unfortunately. man mdadm has a section for "DEVICE NAMES" at the end, a few options
    – Xen2050
    Sep 18, 2017 at 11:56

1 Answer 1

3

You probably wanted to write /dev/md0 and not /mnt/md0.

Device files are always generated in the /dev folder while /mnt is generally used to only mount them (connect the storage device content to the current filesystem).

7
  • But I have no md0 or mnt folder in the dev folder.
    – Mark
    Sep 15, 2017 at 4:56
  • There shouldn't be mnt folder inside /dev, just md0 device file. Try searching the folder automatically then, like find /dev -type b -iname md*
    – Marek Rost
    Sep 15, 2017 at 5:04
  • Cool, there is that device file in the dev/ folder. Now when I run sudo mdadm --detail /mnt/md0, it gives me the right info. Thanks for that. Now in my search, I am wondering if raid if better that a simple sync? Any thoughts on that?
    – Mark
    Sep 18, 2017 at 2:35
  • So now though, do I need to mount this or something?
    – Mark
    Sep 18, 2017 at 3:07
  • Yes, to use the device, you have to mount it or add it to fstab( askubuntu.com/q/417286/593050 ). The raid device behaves like normal harddisk. I'm not sure what you mean by 'raid better than simple sync'. It will depend on your use-case and is outside of the scope of the current question.
    – Marek Rost
    Sep 18, 2017 at 9:16

You must log in to answer this question.

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