All of lore.kernel.org
 help / color / mirror / Atom feed
* Announcing blktests
@ 2017-05-12 18:49 Omar Sandoval
  2017-05-15  7:44 ` Johannes Thumshirn
  2017-05-15 12:13 ` Dmitry Monakhov
  0 siblings, 2 replies; 6+ messages in thread
From: Omar Sandoval @ 2017-05-12 18:49 UTC (permalink / raw)
  To: linux-block; +Cc: kernel-team

Hi, everyone,

At LSF/MM, we talked about the need for somewhere to dump tests for the
block layer/storage stack. I've put together a test suite inspired by
xfstests here: https://github.com/osandov/blktests.

I started out with the opinion that we should reuse xfstests for this,
but it became clear that the requirements for testing block devices are
slightly different, and it diverged significantly from there. In
particular, blktests supports:

- Per-device tests. You can configure a list of test devices and the
  per-device tests will run on each one (currently in serial, we can
  support parallel runs in the future if needed).
- No-device tests. Some tests don't need to run on real hardware, and we
  can just set up a null-blk or scsi-debug device.
- Performance numbers. In addition to the output comparison pass/fail
  that xfstests supports, blktests can also report arbitrary test
  metrics which don't affect whether the test passes but can be useful
  for spotting regressions.

Jens and I wrote up an initial set of tests, but there are a lot more we
can still write. I'm also happy to take feature requests, just email me
or open an issue on the GitHub repo.

Thanks,
Omar

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Announcing blktests
  2017-05-12 18:49 Announcing blktests Omar Sandoval
@ 2017-05-15  7:44 ` Johannes Thumshirn
  2017-05-15 17:30   ` Omar Sandoval
  2017-05-15 12:13 ` Dmitry Monakhov
  1 sibling, 1 reply; 6+ messages in thread
From: Johannes Thumshirn @ 2017-05-15  7:44 UTC (permalink / raw)
  To: Omar Sandoval, linux-block; +Cc: kernel-team

On 05/12/2017 08:49 PM, Omar Sandoval wrote:
> Hi, everyone,
> 
> At LSF/MM, we talked about the need for somewhere to dump tests for the
> block layer/storage stack. I've put together a test suite inspired by
> xfstests here: https://github.com/osandov/blktests.
> 
> I started out with the opinion that we should reuse xfstests for this,
> but it became clear that the requirements for testing block devices are
> slightly different, and it diverged significantly from there. In
> particular, blktests supports:
> 
> - Per-device tests. You can configure a list of test devices and the
>   per-device tests will run on each one (currently in serial, we can
>   support parallel runs in the future if needed).
> - No-device tests. Some tests don't need to run on real hardware, and we
>   can just set up a null-blk or scsi-debug device.
> - Performance numbers. In addition to the output comparison pass/fail
>   that xfstests supports, blktests can also report arbitrary test
>   metrics which don't affect whether the test passes but can be useful
>   for spotting regressions.
> 
> Jens and I wrote up an initial set of tests, but there are a lot more we
> can still write. I'm also happy to take feature requests, just email me
> or open an issue on the GitHub repo.

\o/

You're my hero :-).

Do you only accept github pull requests or do you accept patches via
linux-block as well?

As a side note, I'm currently working on a partition table fuzzer to
stress block/partitions/*.c a bit. I think this could be included into
your framework as well (it's only one .c file currently with no external
dependencies).

Byte,
	Johannes
-- 
Johannes Thumshirn                                          Storage
jthumshirn@suse.de                                +49 911 74053 689
SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nürnberg
GF: Felix Imendörffer, Jane Smithard, Graham Norton
HRB 21284 (AG Nürnberg)
Key fingerprint = EC38 9CAB C2C4 F25D 8600 D0D0 0393 969D 2D76 0850

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Announcing blktests
  2017-05-12 18:49 Announcing blktests Omar Sandoval
  2017-05-15  7:44 ` Johannes Thumshirn
@ 2017-05-15 12:13 ` Dmitry Monakhov
  2017-05-15 15:30   ` Christoph Hellwig
  2017-05-15 17:35   ` Omar Sandoval
  1 sibling, 2 replies; 6+ messages in thread
From: Dmitry Monakhov @ 2017-05-15 12:13 UTC (permalink / raw)
  To: Omar Sandoval, linux-block; +Cc: kernel-team

Omar Sandoval <osandov@osandov.com> writes:

> Hi, everyone,
>
> At LSF/MM, we talked about the need for somewhere to dump tests for the
> block layer/storage stack. I've put together a test suite inspired by
> xfstests here: https://github.com/osandov/blktests.
>
> I started out with the opinion that we should reuse xfstests for this,
> but it became clear that the requirements for testing block devices are
> slightly different, and it diverged significantly from there. In
> particular, blktests supports:
>
> - Per-device tests. You can configure a list of test devices and the
>   per-device tests will run on each one (currently in serial, we can
>   support parallel runs in the future if needed).
> - No-device tests. Some tests don't need to run on real hardware, and we
>   can just set up a null-blk or scsi-debug device.
> - Performance numbers. In addition to the output comparison pass/fail
>   that xfstests supports, blktests can also report arbitrary test
>   metrics which don't affect whether the test passes but can be useful
>   for spotting regressions.
Cool. Thank you.
It would be nice to have hermetic kvm environment similar to
xfstests-bld [1] . I'm a volunteer to do that.

Also I'm interested in adding my t10-dif csum tests.
Is this ok to add it to separate ./tests/t10-dif group ?

Side observations:
Observation #1
I've run this on fresh fedora kernel and it hit panic on the very first tests,
which is very good sign for regression test framework.
Observation #2
It is appeared that git tree was corrupted after crash  :) Defenitely fsync is missed
somewhere in git-core, I've straced it and found 'git clone' does only
two fsync for tmp-pack-xxx files. It seems git's crash consistency is horrably broken.
>
> Jens and I wrote up an initial set of tests, but there are a lot more we
> can still write. I'm also happy to take feature requests, just email me
> or open an issue on the GitHub repo.
>
> Thanks,
> Omar

Footnotes: 
[1]  https://github.com/tytso/xfstests-bld

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Announcing blktests
  2017-05-15 12:13 ` Dmitry Monakhov
@ 2017-05-15 15:30   ` Christoph Hellwig
  2017-05-15 17:35   ` Omar Sandoval
  1 sibling, 0 replies; 6+ messages in thread
From: Christoph Hellwig @ 2017-05-15 15:30 UTC (permalink / raw)
  To: Dmitry Monakhov; +Cc: Omar Sandoval, linux-block, kernel-team

On Mon, May 15, 2017 at 03:13:52PM +0300, Dmitry Monakhov wrote:
> Observation #2
> It is appeared that git tree was corrupted after crash  :) Defenitely fsync is missed
> somewhere in git-core, I've straced it and found 'git clone' does only
> two fsync for tmp-pack-xxx files. It seems git's crash consistency is horrably broken.

You'll need to add

[core]
	fsyncobjectfiles = yes

to .gitconfig to make git not play lose with data integrity

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Announcing blktests
  2017-05-15  7:44 ` Johannes Thumshirn
@ 2017-05-15 17:30   ` Omar Sandoval
  0 siblings, 0 replies; 6+ messages in thread
From: Omar Sandoval @ 2017-05-15 17:30 UTC (permalink / raw)
  To: Johannes Thumshirn; +Cc: linux-block, kernel-team

On Mon, May 15, 2017 at 09:44:13AM +0200, Johannes Thumshirn wrote:
> On 05/12/2017 08:49 PM, Omar Sandoval wrote:
> > Hi, everyone,
> > 
> > At LSF/MM, we talked about the need for somewhere to dump tests for the
> > block layer/storage stack. I've put together a test suite inspired by
> > xfstests here: https://github.com/osandov/blktests.
> > 
> > I started out with the opinion that we should reuse xfstests for this,
> > but it became clear that the requirements for testing block devices are
> > slightly different, and it diverged significantly from there. In
> > particular, blktests supports:
> > 
> > - Per-device tests. You can configure a list of test devices and the
> >   per-device tests will run on each one (currently in serial, we can
> >   support parallel runs in the future if needed).
> > - No-device tests. Some tests don't need to run on real hardware, and we
> >   can just set up a null-blk or scsi-debug device.
> > - Performance numbers. In addition to the output comparison pass/fail
> >   that xfstests supports, blktests can also report arbitrary test
> >   metrics which don't affect whether the test passes but can be useful
> >   for spotting regressions.
> > 
> > Jens and I wrote up an initial set of tests, but there are a lot more we
> > can still write. I'm also happy to take feature requests, just email me
> > or open an issue on the GitHub repo.
> 
> \o/
> 
> You're my hero :-).
> 
> Do you only accept github pull requests or do you accept patches via
> linux-block as well?

Patches are fine, just format them with `git format-patch
--subject-prefix="PATCH blktests"` so I don't lose them.

> As a side note, I'm currently working on a partition table fuzzer to
> stress block/partitions/*.c a bit. I think this could be included into
> your framework as well (it's only one .c file currently with no external
> dependencies).

Yup, that sounds like a good fit. Currently we don't have any programs
to build, but it'd be easy to add a src/ directory and do what xfstests
does.

Thanks!

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Announcing blktests
  2017-05-15 12:13 ` Dmitry Monakhov
  2017-05-15 15:30   ` Christoph Hellwig
@ 2017-05-15 17:35   ` Omar Sandoval
  1 sibling, 0 replies; 6+ messages in thread
From: Omar Sandoval @ 2017-05-15 17:35 UTC (permalink / raw)
  To: Dmitry Monakhov; +Cc: linux-block, kernel-team

On Mon, May 15, 2017 at 03:13:52PM +0300, Dmitry Monakhov wrote:
> Omar Sandoval <osandov@osandov.com> writes:
> 
> > Hi, everyone,
> >
> > At LSF/MM, we talked about the need for somewhere to dump tests for the
> > block layer/storage stack. I've put together a test suite inspired by
> > xfstests here: https://github.com/osandov/blktests.
> >
> > I started out with the opinion that we should reuse xfstests for this,
> > but it became clear that the requirements for testing block devices are
> > slightly different, and it diverged significantly from there. In
> > particular, blktests supports:
> >
> > - Per-device tests. You can configure a list of test devices and the
> >   per-device tests will run on each one (currently in serial, we can
> >   support parallel runs in the future if needed).
> > - No-device tests. Some tests don't need to run on real hardware, and we
> >   can just set up a null-blk or scsi-debug device.
> > - Performance numbers. In addition to the output comparison pass/fail
> >   that xfstests supports, blktests can also report arbitrary test
> >   metrics which don't affect whether the test passes but can be useful
> >   for spotting regressions.
> Cool. Thank you.
> It would be nice to have hermetic kvm environment similar to
> xfstests-bld [1] . I'm a volunteer to do that.

Fine with me. Currently I think the only things we shell out to besides
basic coreutils and util-linux stuff are fio and parted.

> Also I'm interested in adding my t10-dif csum tests.
> Is this ok to add it to separate ./tests/t10-dif group ?

Yeah, I think that'd make sense as its own group.

> Side observations:
> Observation #1
> I've run this on fresh fedora kernel and it hit panic on the very first tests,
> which is very good sign for regression test framework.

Awesome! Any idea which test it was? There is a marker in dmesg before
each test is run.

Thanks!

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2017-05-15 17:35 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-05-12 18:49 Announcing blktests Omar Sandoval
2017-05-15  7:44 ` Johannes Thumshirn
2017-05-15 17:30   ` Omar Sandoval
2017-05-15 12:13 ` Dmitry Monakhov
2017-05-15 15:30   ` Christoph Hellwig
2017-05-15 17:35   ` Omar Sandoval

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.