Commit Graph

233 Commits

Author SHA1 Message Date
Christoph Hellwig 49743070d0 test quota log replay in 087
By mounting the filesystem with quotas enabled in 087 we exercise the
replay of the quota log items in this tests, which we otherwise don't
test in xfstests.  OSS bugzilla #855 is an example of something caught
by this.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Dave Chinner <david@fromorbit.com>
2010-01-12 22:45:26 +01:00
Eric Sandeen 7dcd2217aa Add a test for ENOSPC when fallocating.
Also, add an expected output, not sure how that went missing!

Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
Reviewed-by: Christoph Hellwig <hch@lst.de>
2009-11-25 16:12:09 -06:00
Christoph Hellwig a34e0fddd1 test 220: double inode free in xfs_dqrele_inode
Trivial test case that mounts a filesystem with user quotas, then turns
quotas off an unmounts.  Based on a testcase in a bug report from
Utako Kusaka <u-kusaka@wm.jp.nec.com>.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Alex Elder <aelder@sgi.com>
2009-10-30 06:41:33 +01:00
Christoph Hellwig dfdb145fbc xfstests: fix 192 for external logs and enable it by default
Use _test_mount instead of plain mount to make it work with external logs.

Enable it by default now that it runs everywhere.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Eric Sandeen <sandeen@sandeen.net>
2009-09-02 15:00:17 -03:00
Eric Sandeen ae2c20fd77 Add some very basic quota sanity tests for generic filesystems.
This is based on test 108, but uses the generic quota tools,
not xfs_quota, and therefore cannot test project quota.

Also, the IOs are much smaller (48k) so that ext3 won't get into
indirect blocks and throw off the accounting.  This does
assume 4k blocks though.

Signed-off-by: Eric Sandeen <sandeen@redhat.com>
Reviewed-by: Lachlan McIlroy <lmcilroy@redhat.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
2009-08-10 13:18:39 -05:00
Eric Sandeen 76f4a7b9fa Test a few very basic defragmentation scenarios.
This test creates some files, runs defrag on them,
and compares the before/after fragmentation as well
as file md5sums and timestamps.

The test currently expects to find e4defrag in
/usr/bin

It should be relatively easy to add more interestingly
fragmented files to the tests, as well as to test
that memory-mapped files aren't touched, etc - 
but this gives us a framework.

V2: remount before checking file contents, and create
common.defrag.

Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
Reviewed-by: Christoph Hellwig <hch@lst.de>
2009-08-10 13:10:26 -05:00
Eric Sandeen f11b7e5ff9 actually hook up 198, make it generic
Not entirely sure how I managed this, but 198 was not in groups
so was never run - and wasn't in the makefile, so was never built.
Oops.

Fix that up, make it a generic test, and move it to the
aio-dio-regress subdir.

Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
Reviewed-by: Christoph Hellwig <hch@lst.de>
2009-07-30 10:49:13 -05:00
Dave Chinner f211e17f00 xfstests: add tests to check log size scaling
Add two tests that check that log size scaling works correctly for old
and new maximum log sizes.

Signed-off-by: Dave Chinner <dgc@sgi.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
2009-07-07 15:25:13 +02:00
Christoph Hellwig de5df593e7 xfstests: test c/mtime updates through mapped writes
Check that we correctly update the timestamps when writing to a file
through an mmap mapping.  Currently fails for XFS due a VFS bug but
succeeds for many other filesystems.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Eric Sandeen <sandeen@sandeen.net>
2009-07-07 12:35:56 +02:00
Eric Sandeen 466f161d22 fallocate + read/write tests, ext4 regression tests
New test to test basic mixed fallocate + read & write,
includes a couple regression tests for bugs that ext4
hit.  Uses xfs_io to generate fallocate calls, so requires
git xfsprogs and very recent glibc at this point.

Ext4 folks, this is hopefully a reasonable example of
how to add a new test.   :) 

Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
Reviewed-by: Christoph Hellwig <hch@lst.de>
2009-06-24 12:58:11 -05:00
Eric Sandeen 6db07ff49e basic fallocate boundary tests
This is just like test 072, but using fallocate instead
of the xfs ioctl.  Just very basic fallocate tests.

Also adds a "prealloc" group (./check -g prealloc)
and a _require_xfs_io_falloc check.

Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
Reviewed-by: Christoph Hellwig <hch@lst.de>
2009-06-24 12:58:30 -05:00
Eric Sandeen 6650a673b5 Enable still more tests for generic filesystems
Make the following tests _supported_fs generic:

088 - test out CAP_DAC_OVERRIDE and CAP_DAC_SEARCH code
089 - Emulate the way Linux mount manipulates /etc/mtab
113 - aio-stress (explicitly mark as generic)
126 - tests various file permission options
129 - looptests

These all pass on ext3, ext4, btrfs, and gfs2 as well
as xfs.

Also remove "generic" group from "groups," which was 
accidentally added.

Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
Reviewed-by: Christoph Hellwig <hch@lst.de>
2009-06-09 13:35:28 -05:00
Eric Sandeen c639e76bdb Add aio-dio-regress tests
Pull in the aio-dio-regress test suite from
http://git.kernel.org/?p=linux/kernel/git/zab/aio-dio-regress.git

Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
Reviewed-by: Christoph Hellwig <hch@lst.de>
2009-06-03 15:07:02 -05:00
Eric Sandeen a6c2e775ee Test trim of last small AG for large filesystem resizes
As reported at
http://article.gmane.org/gmane.comp.file-systems.xfs.general/29187
this trimming may cause an overflow in the new size calculation.

Patch to fix it, and testcase at
http://article.gmane.org/gmane.comp.file-systems.xfs.general/29193

Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
Reviewed-by: Christoph Hellwig <hch@lst.de>
2009-05-29 12:48:23 -05:00
Dave Chinner bbcb978f8b xfstests: test 205, test writing to ENOSPC
Use larger files and different writing styles to fill a 100MB filesystem
to being full. In each case we should get very close to the filesystem
being full before getting ENOSPC. This tests different types of ENOSPC
failures to test 203 and requires more changes to pass.

Signed-off-by: Dave Chinner <david@fromorbit.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
2009-04-13 15:55:41 +02:00
Dave Chinner 143368a047 xfstests: add test 204, a simple delayed allocation ENOSPC test
Using a small (100MB) filesystem and writing lots of single block files
can result in spurious ENOSPCs being reported. Reproduce this test case
so we can confirm that it gets fixed.

Signed-off-by: Dave Chinner <david@fromorbit.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
2009-04-13 15:51:58 +02:00
Christoph Hellwig d3592f9b21 add test 203, xfs_io bmap reallocation
Test that we can get all extent/hole information for files with more
than 16 extents and 15 holes which require a reallocation based on
XFS_IOC_FSGETXATTR.

Based on a testcase from Tomasz Majkowski <moosh009@gmail.com>.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Eric Sandeen <sandeen@sandeen.net>
2009-03-21 21:05:51 +01:00
Christoph Hellwig b9f1319261 add "quick" group
Add a new group for test to quickly verify WIP patches.  I've started
it by only taking tests fro mthe auto group that take 20 seconds or less
to complete on the kvm virtual machine on my laptop.  The total run
of the quick group takes about 8 minutes for me.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Eric Sandeen <sandeen@sandeen.net>
2009-02-23 14:28:06 +01:00
Christoph Hellwig 3890cf3a80 remove tests 171, 172 and 173 from auto group
I don't have a single machine where these succeed, and due to the wait
the filestreams allocator works these tests might depend on the phase
on the moon to get their expected output.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Eric Sandeen <sandeen@sandeen.net>
2009-02-20 21:53:02 +01:00
Christoph Hellwig 7d1210aa23 add test 202, xfs_repair handling of single-AG filesystems
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Eric Sandeen <sandeen@sandeen.net>
2009-01-25 21:31:16 +01:00
Christoph Hellwig 33d8a3e4f3 add test 201: btree corruption without CONFIG_LBD
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Dave Chinner <david@fromorbit.com>
2009-01-22 21:19:14 +01:00
Christoph Hellwig 22b88d4f52 xfstests: add test 200, exercise read-only block devices and mounts
Make sure we do the right thing with blockdevices with a hard read-only
flag.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Eric Sandeen <sandeen@sandeen.net>
2009-01-10 21:38:24 +01:00
Christoph Hellwig 0569ea9cbf xfstests: add test 199, bad_features2 correction
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Eric Sandeen <sandeen@sandeen.net>
2009-01-10 21:37:27 +01:00
Christoph Hellwig 1d10ce2d5a test 197, add a testcase for d_off truncation
Make sure our directory offsets fit into a 32 bit value.
Based on a report by John Stanley.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Eric Sandeen <sandeen@sandeen.net>
2008-12-31 12:59:19 +01:00
Christoph Hellwig c96afe9caa test 196, add a testcase for renames across project boundaries
Make sure rename across project boundaries is rejected and doesn't
cause hangs.  Based on a report and testcase from Arkadiusz Miskiewicz.

Signed-off-by: Christoph Hellwig <hch@lst.de>
2008-12-31 12:53:33 +01:00