It's been 2 years, 8 months, 20 days since Danny Wood last posted in
this thread.  Just quickly, really appreciate your efforts attempting to
fix this problem, without even having the hardware.  That's dedicated.

I've just set up a 2x4TB RAID1 mirror in Windows, which of course leads
me to this thread.  Good news, with a patch to Danny's patch, my raid
mirror detects and appears to be working.  My pre-existing 1TB raid1,
continues to function as it did before.

I will re-upload the patch (with a different patch index number to avoid
confusion with the original), which includes my 1 line fix, that allows
the 4TB mirror to detect, activate and work as expected.

-       unsigned pdc_sectors_max = di->sectors - div_up(sizeof(*ret), 512);
+       uint64_t pdc_sectors_max = di->sectors - div_up(sizeof(*ret), 512);

pdc_sectors_max was 32bit, and overflowing, which caused the
pdc_read_metadata function to fail to find the metadata offset from the
end of the disk.

I thought I might also use the opportunity to clear up some confusion
with regards to some people having difficulty finding a partition table
or failing to mount their existing raid setups.

AMD RAIDXpert (pdc format) allows you to choose a logical sector size.
512, 1024, 2048 or 4096 bytes.  In Windows, this configures the drives
logical sector size to match what you chose at the raids creation time.
This is presumably contained within the metadata.

Page 106 of the user manual alludes to why you might want to choose a non 
default sector size, as it affects the maximum LD migration size.  Linked for 
convenience:
https://www2.ati.com/relnotes/AMD_RAIDXpert_User_v2.1.pdf#G8.1017955

dmraid seems to only support 512 byte logical sectors.  If we could read
the logical sector size from the metadata, couldn't we then just set the
logical sector size at the device mapper node's creation time?  This way
the partition table should line up when you use f(g)disk/gparted etc.

In the meantime, just make sure you choose the default 512 byte logical
sectors, if you want to share RAID arrays between Windows and Linux.


** Patch added: "fixed pdc large array support patch"
   
https://bugs.launchpad.net/ubuntu/+source/dmraid/+bug/599255/+attachment/4808494/+files/28_pdc-large-array-support.patch

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/599255

Title:
  dmraid fails to read promise RAID sector count larger than 32-bits

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/dmraid/+bug/599255/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to