linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] xfstests: 277 new test to check freeze/unfreeze works well or not under heavy load.
@ 2011-12-09  5:52 Masayoshi MIZUMA
  2011-12-09  7:17 ` Dave Chinner
  0 siblings, 1 reply; 3+ messages in thread
From: Masayoshi MIZUMA @ 2011-12-09  5:52 UTC (permalink / raw)
  To: Christoph Hellwig; +Cc: linux-fsdevel, xfs, linux-ext4

Hi,

unfreeze function, thaw_super(), sometimes hangs up if flush kernel
thread does writeback to the same filesystem concurrently.
(the problem is reported at
 http://marc.info/?l=linux-ext4&m=132339590004560&w=2)

This test runs freeze/unfreeze under heavy load. If the problem is
reproduced, this test will hang up...

Signed-off-by: Masayoshi MIZUMA <m.mizuma@jp.fujitsu.com>
---
 277     |   81 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 277.out |    5 ++++
 group   |    1 +
 3 files changed, 87 insertions(+), 0 deletions(-)
 create mode 100755 277
 create mode 100644 277.out

diff --git a/277 b/277
new file mode 100755
index 0000000..1cfa1b4
--- /dev/null
+++ b/277
@@ -0,0 +1,81 @@
+#! /bin/bash
+# FSQA Test No. 277
+#
+# Run fsstress and freeze/unfreeze in parallel, check freeze/unfreeze
+#
+#-----------------------------------------------------------------------
+# Copyright (c) 2011-2012 Fujitsu, Inc.  All Rights Reserved.
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License as
+# published by the Free Software Foundation.
+#
+# This program is distributed in the hope that it would be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write the Free Software Foundation,
+# Inc.,  51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
+#
+#-----------------------------------------------------------------------
+#
+# creator
+owner=m.mizuma@jp.fujitsu.com
+
+seq=`basename $0`
+echo "QA output created by $seq"
+
+here=`pwd`
+tmp=/tmp/$$
+status=0 # success is the default!
+trap "rm -f $tmp.*; exit \$status" 0 1 2 3 15
+
+# get standard environment, filters and checks
+. ./common.rc
+. ./common.filter
+
+_workout()
+{
+	echo ""
+	echo "Run fsstress"
+	echo ""
+	num_iterations=500
+	out=$SCRATCH_MNT/fsstress.$$
+	args="-p100 -n10000 -d $out"
+	echo "fsstress $args" >> $here/$seq.full
+	$FSSTRESS_PROG $args > /dev/null 2>&1 &
+	pid=$!
+	echo "Run xfs_freeze in parallel"
+	for ((i=0; i < num_iterations; i++))
+	do
+		xfs_freeze -f $SCRATCH_MNT | tee -a $seq.full
+		xfs_freeze -u $SCRATCH_MNT | tee -a $seq.full
+	done
+	kill $pid 2> /dev/null
+	wait $pid
+}
+
+# real QA test starts here
+_supported_fs generic
+_supported_os Linux
+_need_to_be_root
+_require_scratch
+
+_scratch_mkfs >> $seq.full 2>&1
+_scratch_mount
+
+if ! _workout; then
+	umount $SCRATCH_DEV 2>/dev/null
+	exit
+fi
+
+if ! _scratch_unmount; then
+	echo "failed to umount"
+	status=1
+	exit
+fi
+_check_scratch_fs
+status=$?
+exit
diff --git a/277.out b/277.out
new file mode 100644
index 0000000..2cd57ec
--- /dev/null
+++ b/277.out
@@ -0,0 +1,5 @@
+QA output created by 277
+
+Run fsstress
+
+Run xfs_freeze in parallel
diff --git a/group b/group
index dd9f00d..24b8bd1 100644
--- a/group
+++ b/group
@@ -390,3 +390,4 @@ deprecated
 274 auto rw
 275 auto rw
 276 auto rw metadata
+277 other auto
-- 
1.7.1

Thanks,
Masayoshi Mizuma




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

* Re: [PATCH] xfstests: 277 new test to check freeze/unfreeze works well or not under heavy load.
  2011-12-09  5:52 [PATCH] xfstests: 277 new test to check freeze/unfreeze works well or not under heavy load Masayoshi MIZUMA
@ 2011-12-09  7:17 ` Dave Chinner
  2011-12-12  9:31   ` Masayoshi MIZUMA
  0 siblings, 1 reply; 3+ messages in thread
From: Dave Chinner @ 2011-12-09  7:17 UTC (permalink / raw)
  To: Masayoshi MIZUMA; +Cc: Christoph Hellwig, linux-fsdevel, xfs, linux-ext4

On Fri, Dec 09, 2011 at 02:52:31PM +0900, Masayoshi MIZUMA wrote:
> Hi,
> 
> unfreeze function, thaw_super(), sometimes hangs up if flush kernel
> thread does writeback to the same filesystem concurrently.
> (the problem is reported at
>  http://marc.info/?l=linux-ext4&m=132339590004560&w=2)
> 
> This test runs freeze/unfreeze under heavy load. If the problem is
> reproduced, this test will hang up...

This is effectively a duplicate of test 068, which is currently
described as an XFS only test. It is actually generic now that
xfs_freeze works on other filesytsems, so please update 068
appropriately rather that introducing a new test.

Cheers,

Dave

-- 
Dave Chinner
david@fromorbit.com

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

* Re: [PATCH] xfstests: 277 new test to check freeze/unfreeze works well or not under heavy load.
  2011-12-09  7:17 ` Dave Chinner
@ 2011-12-12  9:31   ` Masayoshi MIZUMA
  0 siblings, 0 replies; 3+ messages in thread
From: Masayoshi MIZUMA @ 2011-12-12  9:31 UTC (permalink / raw)
  To: Dave Chinner; +Cc: Christoph Hellwig, linux-fsdevel, xfs, linux-ext4


(2011/12/09 16:17), Dave Chinner wrote:

> On Fri, Dec 09, 2011 at 02:52:31PM +0900, Masayoshi MIZUMA wrote:
> > Hi,
> > 
> > unfreeze function, thaw_super(), sometimes hangs up if flush kernel
> > thread does writeback to the same filesystem concurrently.
> > (the problem is reported at
> >  http://marc.info/?l=linux-ext4&m=132339590004560&w=2)
> > 
> > This test runs freeze/unfreeze under heavy load. If the problem is
> > reproduced, this test will hang up...
> 
> This is effectively a duplicate of test 068, which is currently
> described as an XFS only test. It is actually generic now that
> xfs_freeze works on other filesytsems, so please update 068
> appropriately rather that introducing a new test.

OK, I will try to update 068 to reproduce the problem, thanks!

Masayoshi Mizuma

> 
> Cheers,
> 
> Dave
> 
> -- 
> Dave Chinner
> david@fromorbit.com




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

end of thread, other threads:[~2011-12-12  9:32 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-12-09  5:52 [PATCH] xfstests: 277 new test to check freeze/unfreeze works well or not under heavy load Masayoshi MIZUMA
2011-12-09  7:17 ` Dave Chinner
2011-12-12  9:31   ` Masayoshi MIZUMA

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).