On Tue, May 09, 2017 at 05:22:57PM -0400, Jes Sorensen wrote: > On 05/09/2017 05:16 PM, Martin K. Petersen wrote: > > > > Jes, > > > > > This is fine within the kernel, however it is not overly useful for > > > mdadm to determine which strategy to apply when syncing devices. > > > > BLKZEROOUT > > > > Trying to read the code, as this ioctl doesn't seem to be documented > anywhere I can find.... it looks like this ioctl zeroes out a device. > > It doesn't help me obtain the information I need to make a decision in mdadm > as whether to overwrite all or compare+write when resyncing a RAID array. The best way I can think is if we find the disks are SSD, trim the disks, and read some random places. If all return 0, the guess is the SSD returns 0 after trim, so do compare-write resync otherwise overwrite. Surely this needs extra mdadm option to enable. We can only reliably detect a SSD, others lie. Thanks, Shaohua -- To unsubscribe from this list: send the line "unsubscribe linux-raid" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html