From patchwork Fri Jun 28 22:59:06 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Theodore Ts'o X-Patchwork-Id: 11023547 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 38D731609 for ; Fri, 28 Jun 2019 22:59:20 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 5407C28834 for ; Fri, 28 Jun 2019 22:59:20 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 483D42887D; Fri, 28 Jun 2019 22:59:20 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id AA8A828874 for ; Fri, 28 Jun 2019 22:59:19 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726862AbfF1W7T (ORCPT ); Fri, 28 Jun 2019 18:59:19 -0400 Received: from outgoing-auth-1.mit.edu ([18.9.28.11]:40638 "EHLO outgoing.mit.edu" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726864AbfF1W7T (ORCPT ); Fri, 28 Jun 2019 18:59:19 -0400 Received: from callcc.thunk.org (guestnat-104-133-0-109.corp.google.com [104.133.0.109] (may be forged)) (authenticated bits=0) (User authenticated as tytso@ATHENA.MIT.EDU) by outgoing.mit.edu (8.14.7/8.12.4) with ESMTP id x5SMxEiE020194 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Fri, 28 Jun 2019 18:59:15 -0400 Received: by callcc.thunk.org (Postfix, from userid 15806) id 252F842002E; Fri, 28 Jun 2019 18:59:14 -0400 (EDT) From: "Theodore Ts'o" To: fstests@vger.kernel.org Cc: "Theodore Ts'o" Subject: [PATCH v2 1/5] shared,ext4: move ext4-specific tests out of shared/ Date: Fri, 28 Jun 2019 18:59:06 -0400 Message-Id: <20190628225910.17018-1-tytso@mit.edu> X-Mailer: git-send-email 2.22.0 MIME-Version: 1.0 Sender: fstests-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: fstests@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The tests shared/{001,003,004,272} test behaviour around the ext4's journal. As such, they are pointless to run on ext2, and ext3 no longer is in kernels newer than 4.3. (And most enterprise distributions have been using ext4 to support the ext3 file system; that capability has been around since 2.6.33.) So we can move these tests out of shared and into the ext4 class of tests: shared/001 --> ext4/036 shared/003 --> ext4/037 shared/004 --> ext4/038 shared/272 --> ext4/039 Signed-off-by: Theodore Ts'o --- Changes since v1: - Adjusted _supported_fs lines tests/{shared/001 => ext4/036} | 6 +++--- tests/ext4/036.out | 2 ++ tests/{shared/003 => ext4/037} | 6 ++---- tests/ext4/037.out | 2 ++ tests/{shared/004 => ext4/038} | 4 ++-- tests/ext4/038.out | 2 ++ tests/{shared/272 => ext4/039} | 2 +- tests/{shared/272.out => ext4/039.out} | 2 +- tests/ext4/group | 4 ++++ tests/shared/001.out | 2 -- tests/shared/003.out | 2 -- tests/shared/004.out | 2 -- tests/shared/group | 4 ---- 13 files changed, 19 insertions(+), 21 deletions(-) rename tests/{shared/001 => ext4/036} (90%) create mode 100644 tests/ext4/036.out rename tests/{shared/003 => ext4/037} (93%) create mode 100644 tests/ext4/037.out rename tests/{shared/004 => ext4/038} (94%) create mode 100644 tests/ext4/038.out rename tests/{shared/272 => ext4/039} (97%) rename tests/{shared/272.out => ext4/039.out} (72%) delete mode 100644 tests/shared/001.out delete mode 100644 tests/shared/003.out delete mode 100644 tests/shared/004.out diff --git a/tests/shared/001 b/tests/ext4/036 similarity index 90% rename from tests/shared/001 rename to tests/ext4/036 index bde6e198..08a5e64e 100755 --- a/tests/shared/001 +++ b/tests/ext4/036 @@ -2,9 +2,9 @@ # SPDX-License-Identifier: GPL-2.0 # Copyright (c) 2015 Red Hat Inc. All Rights Reserved. # -# FS QA Test No. 001 +# FS QA Test No. ext4/036 (was shared/001) # -# Test truncate orphan inodes when mounting extN. +# Test truncate orphan inodes when mounting ext4 # ext4 used to hit WARNING, this commit fixed the issue # # 721e3eb ext4: lock i_mutex when truncating orphan inodes @@ -29,7 +29,7 @@ _cleanup() . ./common/filter # real QA test starts here -_supported_fs ext2 ext3 ext4 +_supported_fs ext3 ext4 _supported_os Linux _require_scratch diff --git a/tests/ext4/036.out b/tests/ext4/036.out new file mode 100644 index 00000000..ed460d98 --- /dev/null +++ b/tests/ext4/036.out @@ -0,0 +1,2 @@ +QA output created by 036 +Silence is golden diff --git a/tests/shared/003 b/tests/ext4/037 similarity index 93% rename from tests/shared/003 rename to tests/ext4/037 index 761b9691..33c46e13 100755 --- a/tests/shared/003 +++ b/tests/ext4/037 @@ -2,15 +2,13 @@ # SPDX-License-Identifier: GPL-2.0 # Copyright (c) 2015 Red Hat Inc. All Rights Reserved. # -# FS QA Test 003 +# FS QA Test ext4/037 (was shared/003) # # Test mount a needs_recovery partition with noload option. # ext4 used to Oops until part of this commit: # # 744692d ext4: use ext4_get_block_write in buffer write # -# Also test on ext2/3. -# seq=`basename $0` seqres=$RESULT_DIR/$seq echo "QA output created by $seq" @@ -31,7 +29,7 @@ _cleanup() . ./common/filter # real QA test starts here -_supported_fs ext2 ext3 ext4 +_supported_fs ext3 ext4 _supported_os Linux # nofsck as we modify sb via debugfs diff --git a/tests/ext4/037.out b/tests/ext4/037.out new file mode 100644 index 00000000..5c3a30a4 --- /dev/null +++ b/tests/ext4/037.out @@ -0,0 +1,2 @@ +QA output created by 037 +Silence is golden diff --git a/tests/shared/004 b/tests/ext4/038 similarity index 94% rename from tests/shared/004 rename to tests/ext4/038 index 3021c85d..b8f52b5a 100755 --- a/tests/shared/004 +++ b/tests/ext4/038 @@ -2,7 +2,7 @@ # SPDX-License-Identifier: GPL-2.0 # Copyright (c) 2016 Fujitsu. All Rights Reserved. # -# FS QA Test 004 +# FS QA Test ext4/038 (was shared/004) # # Regression test for commit: # c9eb13a ext4: fix hang when processing corrupted orphaned inode list @@ -25,7 +25,7 @@ _cleanup() . ./common/rc # real QA test starts here -_supported_fs ext2 ext3 ext4 +_supported_fs ext3 ext4 _supported_os Linux _require_scratch _require_command "$DEBUGFS_PROG" debugfs diff --git a/tests/ext4/038.out b/tests/ext4/038.out new file mode 100644 index 00000000..5e0f13ec --- /dev/null +++ b/tests/ext4/038.out @@ -0,0 +1,2 @@ +QA output created by 038 +Silence is golden diff --git a/tests/shared/272 b/tests/ext4/039 similarity index 97% rename from tests/shared/272 rename to tests/ext4/039 index b94dfc3c..28db308d 100755 --- a/tests/shared/272 +++ b/tests/ext4/039 @@ -2,7 +2,7 @@ # SPDX-License-Identifier: GPL-2.0 # Copyright (c) 2006 Silicon Graphics, Inc. All Rights Reserved. # -# FSQA Test No. 272 +# FSQA Test No. ext4/039 (was shared/272) # # Test data journaling flag switch for a single file # diff --git a/tests/shared/272.out b/tests/ext4/039.out similarity index 72% rename from tests/shared/272.out rename to tests/ext4/039.out index a9eaf84c..2c8aabad 100644 --- a/tests/shared/272.out +++ b/tests/ext4/039.out @@ -1,3 +1,3 @@ -QA output created by 272 +QA output created by 039 Switch data journalling mode. Silence is golden. Check filesystem diff --git a/tests/ext4/group b/tests/ext4/group index d27ec893..6418d82d 100644 --- a/tests/ext4/group +++ b/tests/ext4/group @@ -38,6 +38,10 @@ 033 auto ioctl resize 034 auto quick quota 035 auto quick resize +036 auto quick +037 auto quick +038 auto quick +039 auto enospc rw 271 auto rw quick 301 aio auto ioctl rw stress defrag 302 aio auto ioctl rw stress defrag diff --git a/tests/shared/001.out b/tests/shared/001.out deleted file mode 100644 index 88678b8e..00000000 --- a/tests/shared/001.out +++ /dev/null @@ -1,2 +0,0 @@ -QA output created by 001 -Silence is golden diff --git a/tests/shared/003.out b/tests/shared/003.out deleted file mode 100644 index 6895fc80..00000000 --- a/tests/shared/003.out +++ /dev/null @@ -1,2 +0,0 @@ -QA output created by 003 -Silence is golden diff --git a/tests/shared/004.out b/tests/shared/004.out deleted file mode 100644 index af8614ae..00000000 --- a/tests/shared/004.out +++ /dev/null @@ -1,2 +0,0 @@ -QA output created by 004 -Silence is golden diff --git a/tests/shared/group b/tests/shared/group index b091d911..6f184946 100644 --- a/tests/shared/group +++ b/tests/shared/group @@ -3,10 +3,7 @@ # - do not start group names with a digit # - comment line before each group is "new" description # -001 auto quick 002 auto metadata quick log -003 auto quick -004 auto quick 005 dangerous_fuzzers 006 auto enospc 007 dangerous_fuzzers @@ -15,6 +12,5 @@ 010 auto stress dedupe 011 auto quick 032 mkfs auto quick -272 auto enospc rw 289 auto quick 298 auto trim From patchwork Fri Jun 28 22:59:07 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Theodore Ts'o X-Patchwork-Id: 11023541 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 5F2DC746 for ; Fri, 28 Jun 2019 22:59:19 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 7922C2887D for ; Fri, 28 Jun 2019 22:59:19 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 6D57A28880; Fri, 28 Jun 2019 22:59:19 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 1F0C628874 for ; Fri, 28 Jun 2019 22:59:19 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726775AbfF1W7S (ORCPT ); Fri, 28 Jun 2019 18:59:18 -0400 Received: from outgoing-auth-1.mit.edu ([18.9.28.11]:40639 "EHLO outgoing.mit.edu" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726866AbfF1W7S (ORCPT ); Fri, 28 Jun 2019 18:59:18 -0400 Received: from callcc.thunk.org (guestnat-104-133-0-109.corp.google.com [104.133.0.109] (may be forged)) (authenticated bits=0) (User authenticated as tytso@ATHENA.MIT.EDU) by outgoing.mit.edu (8.14.7/8.12.4) with ESMTP id x5SMxEhv020195 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Fri, 28 Jun 2019 18:59:15 -0400 Received: by callcc.thunk.org (Postfix, from userid 15806) id 2A4DD42002D; Fri, 28 Jun 2019 18:59:14 -0400 (EDT) From: "Theodore Ts'o" To: fstests@vger.kernel.org Cc: "Theodore Ts'o" Subject: [PATCH v2 2/5] check: add ext4 group list when testing ext2 and ext3 Date: Fri, 28 Jun 2019 18:59:07 -0400 Message-Id: <20190628225910.17018-2-tytso@mit.edu> X-Mailer: git-send-email 2.22.0 In-Reply-To: <20190628225910.17018-1-tytso@mit.edu> References: <20190628225910.17018-1-tytso@mit.edu> MIME-Version: 1.0 Sender: fstests-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: fstests@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Modern kernels use the ext4 implementation to support ext2 and ext3 mounts, and a number of the ext4 tests are actually suitable for ext2 and ext3. We're trying to move tests out of shared anyway, so instead of moving tests from ext4/NNN to shared, let's just include the ext4 group list when FSTYP is ext2 or ext3. Signed-off-by: Theodore Ts'o --- Changes since v1: - none check | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/check b/check index 7511e1ce..2a5d8ab1 100755 --- a/check +++ b/check @@ -130,6 +130,7 @@ get_group_list() local grp=$1 local grpl="" local sub=$(dirname $grp) + local fsgroup="$FSTYP" if [ -n "$sub" -a "$sub" != "." -a -d "$SRC_DIR/$sub" ]; then # group is given as / (e.g. xfs/quick) @@ -138,7 +139,10 @@ get_group_list() return fi - for d in $SRC_GROUPS $FSTYP; do + if [ "$FSTYP" = ext2 -o "$FSTYP" = ext3 ]; then + fsgroup=ext4 + fi + for d in $SRC_GROUPS $fsgroup; do if ! test -d "$SRC_DIR/$d" ; then continue fi From patchwork Fri Jun 28 22:59:08 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Theodore Ts'o X-Patchwork-Id: 11023545 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id EB007138B for ; Fri, 28 Jun 2019 22:59:19 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 1337628834 for ; Fri, 28 Jun 2019 22:59:20 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 080A928880; Fri, 28 Jun 2019 22:59:20 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 8AA0C28834 for ; Fri, 28 Jun 2019 22:59:19 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726707AbfF1W7T (ORCPT ); Fri, 28 Jun 2019 18:59:19 -0400 Received: from outgoing-auth-1.mit.edu ([18.9.28.11]:40635 "EHLO outgoing.mit.edu" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726862AbfF1W7T (ORCPT ); Fri, 28 Jun 2019 18:59:19 -0400 Received: from callcc.thunk.org (guestnat-104-133-0-109.corp.google.com [104.133.0.109] (may be forged)) (authenticated bits=0) (User authenticated as tytso@ATHENA.MIT.EDU) by outgoing.mit.edu (8.14.7/8.12.4) with ESMTP id x5SMxE07020196 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Fri, 28 Jun 2019 18:59:15 -0400 Received: by callcc.thunk.org (Postfix, from userid 15806) id 311A3420031; Fri, 28 Jun 2019 18:59:14 -0400 (EDT) From: "Theodore Ts'o" To: fstests@vger.kernel.org Cc: "Theodore Ts'o" Subject: [PATCH v2 3/5] shared,ext4: move ext[234]-specific tests out of shared/ Date: Fri, 28 Jun 2019 18:59:08 -0400 Message-Id: <20190628225910.17018-3-tytso@mit.edu> X-Mailer: git-send-email 2.22.0 In-Reply-To: <20190628225910.17018-1-tytso@mit.edu> References: <20190628225910.17018-1-tytso@mit.edu> MIME-Version: 1.0 Sender: fstests-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: fstests@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Move the following tests: shared/005 --> ext4/040 shared/007 --> ext4/041 shared/289 --> ext4/042 Signed-off-by: Theodore Ts'o --- Changes since v1: - none tests/{shared/005 => ext4/040} | 2 +- tests/{shared/007.out => ext4/040.out} | 2 +- tests/{shared/007 => ext4/041} | 2 +- tests/{shared/005.out => ext4/041.out} | 2 +- tests/{shared/289 => ext4/042} | 2 +- tests/{shared/289.out => ext4/042.out} | 2 +- tests/ext4/group | 3 +++ tests/shared/group | 3 --- 8 files changed, 9 insertions(+), 9 deletions(-) rename tests/{shared/005 => ext4/040} (97%) rename tests/{shared/007.out => ext4/040.out} (77%) rename tests/{shared/007 => ext4/041} (97%) rename tests/{shared/005.out => ext4/041.out} (77%) rename tests/{shared/289 => ext4/042} (98%) rename tests/{shared/289.out => ext4/042.out} (67%) diff --git a/tests/shared/005 b/tests/ext4/040 similarity index 97% rename from tests/shared/005 rename to tests/ext4/040 index 67940dd0..3e475f7d 100755 --- a/tests/shared/005 +++ b/tests/ext4/040 @@ -2,7 +2,7 @@ # SPDX-License-Identifier: GPL-2.0 # Copyright (c) 2017 Oracle, Inc. All Rights Reserved. # -# FSQA Test No. 005 +# FSQA Test No. ext4/040 (was shared/005) # # Since loff_t is a signed type, it is invalid for a filesystem to load # an inode with i_size = -1ULL. Unfortunately, nobody checks this, diff --git a/tests/shared/007.out b/tests/ext4/040.out similarity index 77% rename from tests/shared/007.out rename to tests/ext4/040.out index 3afba59a..dbccb495 100644 --- a/tests/shared/007.out +++ b/tests/ext4/040.out @@ -1,4 +1,4 @@ -QA output created by 007 +QA output created by 040 Format and mount Corrupt filesystem Remount, try to append diff --git a/tests/shared/007 b/tests/ext4/041 similarity index 97% rename from tests/shared/007 rename to tests/ext4/041 index 65cb5273..5c9c0713 100755 --- a/tests/shared/007 +++ b/tests/ext4/041 @@ -2,7 +2,7 @@ # SPDX-License-Identifier: GPL-2.0 # Copyright (c) 2017 Oracle, Inc. All Rights Reserved. # -# FSQA Test No. 007 +# FSQA Test No. ext4/041 (was shared/007) # # Since loff_t is a signed type, it is invalid for a filesystem to load # an inode with i_size = -1ULL. Unfortunately, nobody checks this, diff --git a/tests/shared/005.out b/tests/ext4/041.out similarity index 77% rename from tests/shared/005.out rename to tests/ext4/041.out index 06e3fcdc..97480072 100644 --- a/tests/shared/005.out +++ b/tests/ext4/041.out @@ -1,4 +1,4 @@ -QA output created by 005 +QA output created by 041 Format and mount Corrupt filesystem Remount, try to append diff --git a/tests/shared/289 b/tests/ext4/042 similarity index 98% rename from tests/shared/289 rename to tests/ext4/042 index 94b64430..17d482a1 100755 --- a/tests/shared/289 +++ b/tests/ext4/042 @@ -2,7 +2,7 @@ # SPDX-License-Identifier: GPL-2.0 # Copyright (c) 2012 Red Hat, Inc. All Rights Reserved. # -# FS QA Test No. 289 +# FS QA Test No. ext4/042 (was shared/289) # # Test overhead & df output for extN filesystems # diff --git a/tests/shared/289.out b/tests/ext4/042.out similarity index 67% rename from tests/shared/289.out rename to tests/ext4/042.out index a4de760a..1bd6f82a 100644 --- a/tests/shared/289.out +++ b/tests/ext4/042.out @@ -1,3 +1,3 @@ -QA output created by 289 +QA output created by 042 minix f_blocks is in range bsd f_blocks is in range diff --git a/tests/ext4/group b/tests/ext4/group index 6418d82d..9dfc0d35 100644 --- a/tests/ext4/group +++ b/tests/ext4/group @@ -42,6 +42,9 @@ 037 auto quick 038 auto quick 039 auto enospc rw +040 dangerous_fuzzers +041 dangerous_fuzzers +042 auto quick 271 auto rw quick 301 aio auto ioctl rw stress defrag 302 aio auto ioctl rw stress defrag diff --git a/tests/shared/group b/tests/shared/group index 6f184946..3507d7d4 100644 --- a/tests/shared/group +++ b/tests/shared/group @@ -4,13 +4,10 @@ # - comment line before each group is "new" description # 002 auto metadata quick log -005 dangerous_fuzzers 006 auto enospc -007 dangerous_fuzzers 008 auto stress dedupe 009 auto stress dedupe 010 auto stress dedupe 011 auto quick 032 mkfs auto quick -289 auto quick 298 auto trim From patchwork Fri Jun 28 22:59:09 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Theodore Ts'o X-Patchwork-Id: 11023543 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 77E83112C for ; Fri, 28 Jun 2019 22:59:19 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 9449B28874 for ; Fri, 28 Jun 2019 22:59:19 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 85C222888B; Fri, 28 Jun 2019 22:59:19 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id F3A1328834 for ; Fri, 28 Jun 2019 22:59:18 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726867AbfF1W7S (ORCPT ); Fri, 28 Jun 2019 18:59:18 -0400 Received: from outgoing-auth-1.mit.edu ([18.9.28.11]:40636 "EHLO outgoing.mit.edu" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726775AbfF1W7S (ORCPT ); Fri, 28 Jun 2019 18:59:18 -0400 Received: from callcc.thunk.org (guestnat-104-133-0-109.corp.google.com [104.133.0.109] (may be forged)) (authenticated bits=0) (User authenticated as tytso@ATHENA.MIT.EDU) by outgoing.mit.edu (8.14.7/8.12.4) with ESMTP id x5SMxEn8020197 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Fri, 28 Jun 2019 18:59:15 -0400 Received: by callcc.thunk.org (Postfix, from userid 15806) id 361FD420033; Fri, 28 Jun 2019 18:59:14 -0400 (EDT) From: "Theodore Ts'o" To: fstests@vger.kernel.org Cc: "Theodore Ts'o" Subject: [PATCH v2 4/5] shared,generic: move shared/006 to generic/ Date: Fri, 28 Jun 2019 18:59:09 -0400 Message-Id: <20190628225910.17018-4-tytso@mit.edu> X-Mailer: git-send-email 2.22.0 In-Reply-To: <20190628225910.17018-1-tytso@mit.edu> References: <20190628225910.17018-1-tytso@mit.edu> MIME-Version: 1.0 Sender: fstests-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: fstests@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The shared/006 uses _scratch_mkfs_sized to create a limited size file system, and then creates inodes until it gets ENOSPC, and then checks to make sure the file system is consistent. It then remounts the file system, removes all of the files, and makes sure the file system is consistent afterwards. This test was marked as only being supported on ext[234] and xfs, and so it was in shared. However, I've tested and this test works just fine on btrfs, ubifs, tmpfs, and should work on all file systems that support _scratch_mkfs_sized, since even if there isn't a fixed inode table, the file system will eventually run out of disk space. Signed-off-by: Theodore Ts'o --- Changes since v1: - added a new _require_scratch_inode_limits and use it for generic/558 - added missing "_supported_fs generic" line common/rc | 11 +++++++++++ tests/{shared/006 => generic/558} | 7 +++---- tests/generic/558.out | 2 ++ tests/generic/group | 1 + tests/shared/006.out | 2 -- tests/shared/group | 1 - 6 files changed, 17 insertions(+), 7 deletions(-) rename tests/{shared/006 => generic/558} (95%) create mode 100644 tests/generic/558.out delete mode 100644 tests/shared/006.out diff --git a/common/rc b/common/rc index 9165a6f2..8e024f04 100644 --- a/common/rc +++ b/common/rc @@ -4147,6 +4147,17 @@ _require_scratch_btime() _scratch_unmount } +_require_scratch_inode_limits() +{ + _require_scratch + _scratch_mkfs > /dev/null 2>&1 + _scratch_mount + if [ $(_get_free_inode $SCRATCH_MNT) -eq 0 ]; then + _notrun "$FSTYP does not have a fixed number of inodes available" + fi + _scratch_unmount +} + _require_filefrag_options() { _require_command "$FILEFRAG_PROG" filefrag diff --git a/tests/shared/006 b/tests/generic/558 similarity index 95% rename from tests/shared/006 rename to tests/generic/558 index aa65e9a2..5807dba3 100755 --- a/tests/shared/006 +++ b/tests/generic/558 @@ -2,7 +2,7 @@ # SPDX-License-Identifier: GPL-2.0 # Copyright (c) 2014 Red Hat Inc. All Rights Reserved. # -# FS QA Test No. shared/006 +# FS QA Test No. generic/558 # # Stress test fs by using up all inodes and check fs. # @@ -42,10 +42,9 @@ create_file() . ./common/filter # real QA test starts here -_supported_fs ext4 ext3 ext2 xfs +_supported_fs generic _supported_os Linux - -_require_scratch +_require_scratch_inode_limits rm -f $seqres.full echo "Silence is golden" diff --git a/tests/generic/558.out b/tests/generic/558.out new file mode 100644 index 00000000..9a6c4e79 --- /dev/null +++ b/tests/generic/558.out @@ -0,0 +1,2 @@ +QA output created by 558 +Silence is golden diff --git a/tests/generic/group b/tests/generic/group index 543c0627..8fc85b63 100644 --- a/tests/generic/group +++ b/tests/generic/group @@ -560,3 +560,4 @@ 555 auto quick cap 556 auto quick casefold 557 auto quick log +558 auto enospc diff --git a/tests/shared/006.out b/tests/shared/006.out deleted file mode 100644 index 675c1b7c..00000000 --- a/tests/shared/006.out +++ /dev/null @@ -1,2 +0,0 @@ -QA output created by 006 -Silence is golden diff --git a/tests/shared/group b/tests/shared/group index 3507d7d4..2cf910bd 100644 --- a/tests/shared/group +++ b/tests/shared/group @@ -4,7 +4,6 @@ # - comment line before each group is "new" description # 002 auto metadata quick log -006 auto enospc 008 auto stress dedupe 009 auto stress dedupe 010 auto stress dedupe From patchwork Fri Jun 28 22:59:10 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Theodore Ts'o X-Patchwork-Id: 11023549 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id D8930746 for ; Fri, 28 Jun 2019 22:59:20 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 007D328834 for ; Fri, 28 Jun 2019 22:59:21 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id E877728874; Fri, 28 Jun 2019 22:59:20 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 5A32B28880 for ; Fri, 28 Jun 2019 22:59:20 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726864AbfF1W7U (ORCPT ); Fri, 28 Jun 2019 18:59:20 -0400 Received: from outgoing-auth-1.mit.edu ([18.9.28.11]:40637 "EHLO outgoing.mit.edu" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726863AbfF1W7T (ORCPT ); Fri, 28 Jun 2019 18:59:19 -0400 Received: from callcc.thunk.org (guestnat-104-133-0-109.corp.google.com [104.133.0.109] (may be forged)) (authenticated bits=0) (User authenticated as tytso@ATHENA.MIT.EDU) by outgoing.mit.edu (8.14.7/8.12.4) with ESMTP id x5SMxEE7020202 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Fri, 28 Jun 2019 18:59:15 -0400 Received: by callcc.thunk.org (Postfix, from userid 15806) id 3AB13420034; Fri, 28 Jun 2019 18:59:14 -0400 (EDT) From: "Theodore Ts'o" To: fstests@vger.kernel.org Cc: "Theodore Ts'o" Subject: [PATCH v2 5/5] shared,generic: move tests using duperemove to generic/ Date: Fri, 28 Jun 2019 18:59:10 -0400 Message-Id: <20190628225910.17018-5-tytso@mit.edu> X-Mailer: git-send-email 2.22.0 In-Reply-To: <20190628225910.17018-1-tytso@mit.edu> References: <20190628225910.17018-1-tytso@mit.edu> MIME-Version: 1.0 Sender: fstests-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: fstests@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Add _require_scratch_duperemove which validates that the file system supports duperemove. This allows us to move three tests from shared/ to generic/. This means these tests will automatically adapt when duperemove supports other file systems. Tests moved are: shared/008 --> generic/559 shared/009 --> generic/560 shared/010 --> generic/561 Signed-off-by: Theodore Ts'o --- Changes since v1: - added missing "_supported_fs generic" lines common/reflink | 18 ++++++++++++++++++ tests/{shared/008 => generic/559} | 10 ++++------ tests/{shared/008.out => generic/559.out} | 2 +- tests/{shared/009 => generic/560} | 10 +++------- tests/{shared/009.out => generic/560.out} | 2 +- tests/{shared/010 => generic/561} | 10 +++------- tests/generic/561.out | 2 ++ tests/generic/group | 3 +++ tests/shared/010.out | 2 -- tests/shared/group | 3 --- 10 files changed, 35 insertions(+), 27 deletions(-) rename tests/{shared/008 => generic/559} (85%) rename tests/{shared/008.out => generic/559.out} (64%) rename tests/{shared/009 => generic/560} (91%) rename tests/{shared/009.out => generic/560.out} (74%) rename tests/{shared/010 => generic/561} (89%) create mode 100644 tests/generic/561.out delete mode 100644 tests/shared/010.out diff --git a/common/reflink b/common/reflink index 598f0877..ee60398e 100644 --- a/common/reflink +++ b/common/reflink @@ -75,6 +75,24 @@ _require_scratch_reflink() _scratch_unmount } +# this test requires duperemove working for the file system +_require_scratch_duperemove() +{ + _require_scratch + _require_command "$DUPEREMOVE_PROG" duperemove + + _scratch_mkfs > /dev/null + _scratch_mount + dd if=/dev/zero of="$SCRATCH_MNT/file1" bs=128k count=1 >& /dev/null + dd if=/dev/zero of="$SCRATCH_MNT/file2" bs=128k count=1 >& /dev/null + if ! "$DUPEREMOVE_PROG" -d "$SCRATCH_MNT/file1" \ + "$SCRATCH_MNT/file2" >& /dev/null ; then + _scratch_unmount + _notrun "duperemove does not support file system type: $FSTYP" + fi + _scratch_unmount +} + # this test requires scratch fs to report explicit SHARED flag # e.g. # 0 4K 8K diff --git a/tests/shared/008 b/tests/generic/559 similarity index 85% rename from tests/shared/008 rename to tests/generic/559 index a7d76083..b5297b57 100755 --- a/tests/shared/008 +++ b/tests/generic/559 @@ -2,7 +2,7 @@ # SPDX-License-Identifier: GPL-2.0 # Copyright (c) 2018 Red Hat Inc. All Rights Reserved. # -# FS QA Test 008 +# FS QA Test generic/559 (was shared/008) # # Dedupe a single big file and verify integrity # @@ -29,12 +29,10 @@ _cleanup() # remove previous $seqres.full before test rm -f $seqres.full -# duperemove only supports btrfs and xfs (with reflink feature). -# Add other filesystems if it supports more later. -_supported_fs xfs btrfs +# real QA test starts here +_supported_fs generic _supported_os Linux -_require_scratch_dedupe -_require_command "$DUPEREMOVE_PROG" duperemove +_require_scratch_duperemove fssize=$((2 * 1024 * 1024 * 1024)) _scratch_mkfs_sized $fssize > $seqres.full 2>&1 diff --git a/tests/shared/008.out b/tests/generic/559.out similarity index 64% rename from tests/shared/008.out rename to tests/generic/559.out index f29d478f..a558ada3 100644 --- a/tests/shared/008.out +++ b/tests/generic/559.out @@ -1,3 +1,3 @@ -QA output created by 008 +QA output created by 559 = before cycle mount = = after cycle mount = diff --git a/tests/shared/009 b/tests/generic/560 similarity index 91% rename from tests/shared/009 rename to tests/generic/560 index 933d3098..de1fba92 100755 --- a/tests/shared/009 +++ b/tests/generic/560 @@ -2,7 +2,7 @@ # SPDX-License-Identifier: GPL-2.0 # Copyright (c) 2018 Red Hat Inc. All Rights Reserved. # -# FS QA Test 009 +# FS QA Test generic/560 (was shared/009) # # Iterate dedupe integrity test. Copy an original data0 several # times (d0 -> d1, d1 -> d2, ... dn-1 -> dn), dedupe dataN everytime @@ -32,13 +32,9 @@ _cleanup() rm -f $seqres.full # real QA test starts here - -# duperemove only supports btrfs and xfs (with reflink feature). -# Add other filesystems if it supports more later. -_supported_fs xfs btrfs +_supported_fs generic _supported_os Linux -_require_scratch_dedupe -_require_command "$DUPEREMOVE_PROG" duperemove +_require_scratch_duperemove _scratch_mkfs > $seqres.full 2>&1 _scratch_mount >> $seqres.full 2>&1 diff --git a/tests/shared/009.out b/tests/generic/560.out similarity index 74% rename from tests/shared/009.out rename to tests/generic/560.out index 44a78ba3..10ae7edd 100644 --- a/tests/shared/009.out +++ b/tests/generic/560.out @@ -1,4 +1,4 @@ -QA output created by 009 +QA output created by 560 = Do dedup and verify = = Backwords verify = = Verify after cycle mount = diff --git a/tests/shared/010 b/tests/generic/561 similarity index 89% rename from tests/shared/010 rename to tests/generic/561 index 04f55890..3cd0b365 100755 --- a/tests/shared/010 +++ b/tests/generic/561 @@ -2,7 +2,7 @@ # SPDX-License-Identifier: GPL-2.0 # Copyright (c) 2018 Red Hat Inc. All Rights Reserved. # -# FS QA Test 010 +# FS QA Test generic/561 (was shared/010) # # Dedup & random I/O race test, do multi-threads fsstress and dedupe on # same directory/files @@ -32,13 +32,9 @@ _cleanup() rm -f $seqres.full # real QA test starts here - -# duperemove only supports btrfs and xfs (with reflink feature). -# Add other filesystems if it supports more later. -_supported_fs xfs btrfs +_supported_fs generic _supported_os Linux -_require_scratch_dedupe -_require_command "$DUPEREMOVE_PROG" duperemove +_require_scratch_duperemove _require_command "$KILLALL_PROG" killall _scratch_mkfs > $seqres.full 2>&1 diff --git a/tests/generic/561.out b/tests/generic/561.out new file mode 100644 index 00000000..5e46f61f --- /dev/null +++ b/tests/generic/561.out @@ -0,0 +1,2 @@ +QA output created by 561 +Silence is golden diff --git a/tests/generic/group b/tests/generic/group index 8fc85b63..c30d18e0 100644 --- a/tests/generic/group +++ b/tests/generic/group @@ -561,3 +561,6 @@ 556 auto quick casefold 557 auto quick log 558 auto enospc +559 auto stress dedupe +560 auto stress dedupe +561 auto stress dedupe diff --git a/tests/shared/010.out b/tests/shared/010.out deleted file mode 100644 index 1d83a8d6..00000000 --- a/tests/shared/010.out +++ /dev/null @@ -1,2 +0,0 @@ -QA output created by 010 -Silence is golden diff --git a/tests/shared/group b/tests/shared/group index 2cf910bd..6112c8dd 100644 --- a/tests/shared/group +++ b/tests/shared/group @@ -4,9 +4,6 @@ # - comment line before each group is "new" description # 002 auto metadata quick log -008 auto stress dedupe -009 auto stress dedupe -010 auto stress dedupe 011 auto quick 032 mkfs auto quick 298 auto trim