How do I properly access Windows software RAID 0?

I finally got this working thanks to this Stack Overflow post: Windows Spanned Disks (LDM) restoration with Linux?

It was extremely difficult to uncover this elusive information. It took days of searching, and I guess I wasn't finding it because the post makes no mention of RAID, so it wasn't coming up in my search results. It definitely works for my Windows software RAID 0, though.

The solution:

The solution is actually quite simple. There's a wonderful tool built specifically for this purpose, called ldmtool. It is capable of reading and working with Windows dynamic disks which use LDM (Logical Disk Manager). It is not installed by default, but is included in the Ubuntu repositories. All I had to do was execute two commands:

sudo apt-get install ldmtool
sudo ldmtool create all

The first command installs ldmtool, and the second has it automagically create device mappings for all of the connected Windows dynamic disks. These mappings are located in /dev/mapper/ and can be mounted manually with mount -t ntfs /dev/mapper/mapfilename, but I didn't need to do that - Ubuntu mounted them for me automatically after I ran the above two commands. That's all I had to do, and I could immediately access them from the file browser!

The linked post includes a suggestion for doing this automatically every boot. Just open the file /etc/init/mountall.conf and add the line [ -x /usr/bin/ldmtool ] && ldmtool create all >/dev/null || true immediately before the exec mountall ... line near the end of the file.

Full credit for this solution goes to Christian Hudon, the guy who posted it as an answer over on Stack Overflow. Thanks!

To add some further information to this, I used some other ldmtool commands to query my volumes for information:

sudo ldmtool scan /dev/sdd
[
  "e856a65f-e558-11e1-ae19-bc5ff435f790"
]

sudo ldmtool show diskgroup e856a65f-e558-11e1-ae19-bc5ff435f790
{
  "name" : "Dan-PC-Dg0",
  "guid" : "e856a65f-e558-11e1-ae19-bc5ff435f790",
  "volumes" : [
    "Volume1",
    "Volume2"
  ],
  "disks" : [
    "Disk1",
    "Disk2",
    "Disk3"
  ]
}

sudo ldmtool show volume e856a65f-e558-11e1-ae19-bc5ff435f790 Volume1
{
  "name" : "Volume1",
  "type" : "striped",
  "size" : 1048578048,
  "chunk-size" : 128,
  "hint" : "D:",
  "partitions" : [
    "Disk1-01",
    "Disk2-01",
    "Disk3-01"
  ]
}

sudo ldmtool show volume e856a65f-e558-11e1-ae19-bc5ff435f790 Volume2
{
  "name" : "Volume2",
  "type" : "striped",
  "size" : 4811194368,
  "chunk-size" : 128,
  "hint" : "E:",
  "partitions" : [
    "Disk1-02",
    "Disk2-02",
    "Disk3-02"
  ]
}

It isn't necessary to run the above commands, as ldmtool create all does all the necessary work to create the mappings. I just included them because I already included information about my setup in the question, so this information might be helpful for anyone coming across this post later. In particular, we can see that according to ldmtool, both of my dynamic volumes use a chunk size of 128, despite being created with different block sizes in Windows. I guess this means that block size and chunk size are not synonymous terms. The commands ldmtool show disk and ldmtool show partition can be used to display further information.


Ubuntu 14.04 LTS mount raid 1 created by windows 7 using ldmtool by a newby.** **

I had the same problem. Using the above answer I lucked out and got it mounted with

gksu gedit /etc/init/mountall.conf 

by changing the line

 [ -x /usr/bin/ldmtool ] && ldmtool create all >/dev/null || true

to

/bin/ldmtool create all >/dev/null || true

then added

/bin/mount /dev/mapper/ldm_vol_NAME-Dg0_volume1 /media/WHEREVER

My mountall.conf looks like this now

     **fi
/usr/bin/ldmtool create all >/dev/null || true
/bin/mount -o rw /dev/mapper/ldm_vol_OCTO-CORE-Dg0_Volume1 /media/m
    exec mountall --daemon $force_fsck $fsck_fix $debug_arg
end script**

previously I had a script to do the same with the 2 lines

/usr/bin/ldmtool create all >/dev/null || true

/bin/mount -o rw /dev/mapper/ldm_vol_OCTO-CORE-Dg0_Volume1 /media/m

and added

sh /home/ron/mirror to the end of /etc/rc.local 

now it is mounted when ubuntu starts

I don't know that this will work for you!


The others answers worked only partially in Mint 18.3.

Auto-mounting the Raid0 drives was a bit more challenging since editing /etc/init/mountall.conf never worked in my system and I wanted to be able to mount the spanned volume using a definition in /etc/fstab, and not use a script in /etc/rc.local.

So here's what I did:

sudo apt-get install ldmtool

Checked that the volume was recognized and could be mounted correctly with:

sudo ldmtool create all

Knowing that that my system could see and write into the drives. I created a service (following the directions from this site:(https://wiki.archlinux.org/index.php/Dynamic_Disks)

created a file in etc/systemd/system/ called ldmtool.service with the description of the service:

[Unit]
Description=Windows Dynamic Disk Mount
Before=local-fs-pre.target
DefaultDependencies=no
[Service]
Type=simple
User=root
ExecStart=/usr/bin/ldmtool create all
[Install]
WantedBy=local-fs-pre.target

To enable the service on startup:

sudo systemctl is-enabled ldmtool

To find the UUID of the volume used:

sudo blkid

Which gave me the following info: /dev/mapper/ldm_vol_XXX-Dg0_Volume1: LABEL="6TB_Raid" UUID="0A281FC6281FAFA5" TYPE="ntfs"

So I created a line in /etc/fstab that reads:

UUID=0A281FC6281FAFA5 /media/6TB_Raid ntfs-3g  auto,users,uid=1000,gid=100,dmask=027,fmask=137,utf8  0  0

The volume is there everytime I boot.