Hi Daniel,
Got it fixed, though not by this method. Just didn't stick. For reference:
fdisk /dev/sda (in my case sda and sdb)
o (create dos partitiontable
d (delete all)
n (new partition)
p (primary)
1 (first partition)
ENTER (twice: first and last block definition)
t (change file type)
fd (set to Linux raid autodetect)
w (write config)
(steps can be found at: https://www.linuxbabe.com/linux-server/linux-software-raid-1-setup )
I assume mdadm has been installed (or otherwise install via GUI / CLI)
mdadm --examine /dev/sda /dev/sdb
create RAID1
mdadm --create /dev/md0 --level=mirror --raid-devices=2 /dev/sda1 /dev/sdb1
check with:
cat /proc/mdstat
mdadm --detail /dev/md0
mdadm --examine /dev/sda1 /dev/sdb1
make filesystem:
mkfs.ext4 /dev/md0
create mountpoint
mkdir /mnt/raid1
mount /dev/md0 /mnt/raid1
check:
df -h /mnt/raid1
Again: courtesy of https://www.linuxbabe.com/linux-server/linux-software-raid-1-setup
To make it stick after a reboot:
mdadm --detail --scan --verbose
This will give the devices and UUID
ARRAY /dev/md0 level=raid1 num-devices=2 metadata=1.2 name=OpenWrt:0 UUID=e99573a9: 2a6df929:89b60e0c:901ad80e
devices=/dev/sda1,/dev/sdb1
Then to make it stick:
cd /etc/mdadm/
vi mdadm.conf
copy both lines ('ARRAY...' and 'devices...')
vi /etc/config/mdadm
copy UUID (instead of the UUID in the file)
uncomment 'list devices /dev/sda1' (and sdb1)
Then the permanent mount: found it on https://openwrt.org/docs/guide-user/storage/usb-drives
Thanks a lot for helping, awesome that it works on an old NAS.
If I may add something: the wiki you created contains the typo in respect to the ubidetach (missing '--dev-path' in front of '/dev/mtd4').
Now starting to get syncthing up and running