Thank you Mr. Thornber. This example should work for me.
My dm-validate.ko module is functional, but a bit crude for general use. It has a few "issues":
My dm-validate.ko module is functional, but a bit crude for general use. It has a few "issues":
1) It is only currently tested on x86_64, although it will likely work on 32-bit intel with only a couple of KMAPs added.
2) It uses "load DS:" games to read and write to file space from the kernel (this is where the hashes are stored). I suspect this is nonsensical for some arches.
3) There is no attempt to "sync" the hash "database" so crashes always result in out of sync tests. My testing is mostly with SSDs and SSD arrays, so speed is an issue.
If you would like a copy, please point me at "contribution" guidelines for device mapper target contributions.
If you would like a copy, please point me at "contribution" guidelines for device mapper target contributions.
On Mon, Jan 5, 2015 at 2:21 AM, Joe Thornber <thornber@xxxxxxxxxx> wrote:
Hi Doug,On Wed, Dec 31, 2014 at 02:10:52PM -0800, Doug Dumitru wrote:
> Hello all,
>
> I have a test dm target module that I use to validate storage subsystems
> for data accuracy. It basically builds weak hashes for every sector of a
> device when written, and validates these hashes when the sector is read
> back. Ugly memory usage, but it is just a test tool.
>
> I can deploy this with an iterator target and it will take on the limits of
> the device underneath, or I can skip the iterator target and get limits at
> 2048 sectors. What I would like to do is set the limit manually. I know
> this is "really bad program design", but again, this is a test tool and not
> anything for production use.
>
> Can anyone point me at an example of where the limits are setup explicitly.
This sounds like a useful target for testing, any chance you could
post it here when you finish it please?
dm-thin does lots of tweaking of limits, so that's probably the best one to look at:
https://github.com/jthornber/linux-2.6/blob/thin-dev/drivers/md/dm-thin.c#L3707
- Joe
--
Doug Dumitru
EasyCo LLC
EasyCo LLC
-- dm-devel mailing list dm-devel@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/dm-devel