Hi,
I have an issue with mdadm:
root@LEDE:~# mdadm --create --verbose /dev/md0 --level=stripe --raid-devices=2 --chunk=4K /dev/sda /dev/sdb
mdadm: /dev/sda appears to be part of a raid array:
level=raid0 devices=2 ctime=Mon Apr 9 19:52:46 2018
mdadm: partition table exists on /dev/sda but will be lost or
meaningless after creating array
mdadm: /dev/sdb appears to be part of a raid array:
level=raid0 devices=2 ctime=Mon Apr 9 19:52:46 2018
mdadm: partition table exists on /dev/sdb but will be lost or
meaningless after creating array
Continue creating array? y
mdadm: unexpected failure opening /dev/md0
root@LEDE:~# ls /dev/md*
/dev/md0
root@LEDE:~# lsmod |grep md
md_mod 101776 3 raid10,raid1,raid0
root@LEDE:~# ls -l /dev/md0
brw------- 1 root root 9, 0 Apr 10 20:39 /dev/md0
root@LEDE:~# cat /proc/mdstat
Personalities : [raid0] [raid1] [raid10]
unused devices: <none>
It's seem that it is the same problem that:RAID not working after Update LEDE 17.01.0 final GoFlexNet - #6 by chunkeey
Just in case somebody stumbles into this. The mdadm uses O_DIRECT when opening the devices in /dev. O_DIRECT requires the CONFIG_KERNEL_DIRECT_IO option to be set in OpenWRT/LEDE’s configuration. Sadly CONFIG_KERNEL_DIRECT_IO is not enabled by default, so this will require you to compile a custom kernel/image with the option enabled.
Is it a good guess?