testing fs drivers

Hi all,

we are developing a file system filter driver. Apart from the standard tools
to test it’s reliability, like driver verifier etc, how can I automate
testing of this code. Are tehre scripts available to test all functionality
automatically?

  • amitr0

amitr0 wrote:

Hi all,

we are developing a file system filter driver. Apart from the standard
tools to test it’s reliability, like driver verifier etc, how can I
automate testing of this code. Are tehre scripts available to test all
functionality automatically?

Well, what I use is a bot of my creation that will randomly (or not)
create all sort of files. Let it run for one week, if you don’t have any
assert/bsod/whatever, congratulations. :wink:

Edouard

yes, the bot approach is what was in my mind, here are some criterias for
the bot that i thought of, please add/remove stuff from it to help me out a
bit more…

a. Should be able to excercise all the possible creation, read, write and
other options i support.
b. Should be able to vary the payloads.
c. Multithreading should be excercised.
d. All failure states should be excercised.

regards,

amitr0

amitr0 wrote:

a. Should be able to excercise all the possible creation, read, write
and other options i support.

Yes, it should. Do buffered/unbuffered/mapped/whatever.

b. Should be able to vary the payloads.

What do you mean ?

c. Multithreading should be excercised.

Well simply run several instances of your bot. Be lazy. :stuck_out_tongue:

d. All failure states should be excercised.

Use driver verifier to inject faults. Is your file system meant for
removable devices ? If you do, you should do the “violent removal test”.
Which is, do a long read, remove the device. Same for writing. It should
not crash the system (but of course the read/write will faulty).

You should try your fs on different hardware if possible. Also, test it
on a multi cpu machine. Funny things happen sometimes. ^^

Edouard

> a. Should be able to excercise all the possible creation, read, write

and other options i support.

Yes, it should. Do buffered/unbuffered/mapped
/whatever.

b. Should be able to vary the payloads.

What do you mean ?

Well, what I meant was again related to different threads trying to clog up
the driver at the same time.

c. Multithreading should be excercised.

Well simply run several instances of your bot. Be lazy. :stuck_out_tongue:

He, he, that was good…only then we need to read and write different files
also, to decrease the caching and increase the load on the driver.

d. All failure states should be excercised.

Use driver verifier to inject faults.
This is interesting…honestly, didn’t think of it before reading your
mail.

Is your file system meant for removable devices ? If you do, you should do
the “violent removal test”.

yes, it has to support every possible media type windows supports.

Which is, do a long read, remove the device. Same for writing. It should
not crash the system (but of course the read/write will faulty).

You should try your fs on different hardware if possible. Also, test it
on a multi cpu machine. Funny things happen sometimes. ^^

Yes, multi CPU is also one thing i should add in the list. Is multi CPU
testing too much different from a hyper threaded cpu test??? Or can I use
teh same one for both?

amitr0

amitr0 wrote:

> a. Should be able to excercise all the possible creation, read, write
> and other options i support.

>Yes, it should. Do buffered/unbuffered/mapped
>/whatever.

> b. Should be able to vary the payloads.

>What do you mean ?

Well, what I meant was again related to different threads trying to clog
up the driver at the same time.

Well simply make a fs intensive bot for this purpose. It’s not necessary
useful to test paths that will never be taken in real life.

>Well simply run several instances of your bot. Be lazy. :stuck_out_tongue:

He, he, that was good…only then we need to read and write different
files also, to decrease the caching and increase the load on the driver.

Yeah several bots can do that if their file creation reading/writing is
randomized.

>Is your file system meant for removable devices ? If you do, you should
do the “violent removal test”.

yes, it has to support every possible media type windows supports.

Welcome to hell, population : you. :stuck_out_tongue:

Yes, multi CPU is also one thing i should add in the list. Is multi CPU
testing too much different from a hyper threaded cpu test??? Or can I
use teh same one for both?

You need to make sure it works in an environment where two threads may
be running at the same time (and these two threads working on your
files). If you don’t have a multicore/multicpu machine, hyperthreading
is the second choice, but a real smp system is better for testing purposes.

btw, test defrag on your fs. Also try to test some antivirus,
cryptocontainer etc.

EA

thanks for the tip on SMPs and also about defrag and antivirus testing.
these would be immensely useful.

anything speficic for network redirections etc?

>a. Should be able to excercise all the possible creation, read, write and

other options i support.

There were the FS filter test scripts on MSDN HCT CD.

Maxim Shatskih, Windows DDK MVP
StorageCraft Corporation
xxxxx@storagecraft.com
http://www.storagecraft.com

>Yes, multi CPU is also one thing i should add in the list. Is multi CPU

testing too much different from a hyper threaded cpu test???

Theoretically, they are the same, but the more CPUs - the better.

Maxim Shatskih, Windows DDK MVP
StorageCraft Corporation
xxxxx@storagecraft.com
http://www.storagecraft.com

>There were the FS filter test scripts on MSDN HCT CD.

hi maxim,

I recently got the MSDN subscription this month. So all I have are the set
of CDs that they ship initially. How can I acquire this particular HCT CD?

> I recently got the MSDN subscription this month. So all I

have are the set of CDs that they ship initially. How can
I acquire this particular HCT CD?

IIRC it was free for download from MS. Maybe it’s been changed,
I didn’t check it for some time. Try to search MS for “HCT”.

L.

the page opens, i have already tried it, with a decent download link, only
that the link doesnt work!!!

http://www.microsoft.com/whdc/devtools/HCT12.mspx

“amitr0” wrote in message news:xxxxx@ntfsd…

>There were the FS filter test scripts on MSDN HCT CD.

hi maxim,

I recently got the MSDN subscription this month. So all I have are the set
of CDs that they ship initially. How can I acquire this particular HCT CD?