Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/806205/?format=api
{ "id": 806205, "url": "http://patchwork.ozlabs.org/api/patches/806205/?format=api", "web_url": "http://patchwork.ozlabs.org/project/linux-ext4/patch/1503829290-10103-1-git-send-email-amir73il@gmail.com/", "project": { "id": 8, "url": "http://patchwork.ozlabs.org/api/projects/8/?format=api", "name": "Linux ext4 filesystem development", "link_name": "linux-ext4", "list_id": "linux-ext4.vger.kernel.org", "list_email": "linux-ext4@vger.kernel.org", "web_url": null, "scm_url": null, "webscm_url": null, "list_archive_url": "", "list_archive_url_format": "", "commit_url_format": "" }, "msgid": "<1503829290-10103-1-git-send-email-amir73il@gmail.com>", "list_archive_url": null, "date": "2017-08-27T10:21:30", "name": "[RFC] fstests: regression test for ext4 crash consistency bug", "commit_ref": null, "pull_url": null, "state": "not-applicable", "archived": true, "hash": "40c921d83615de435706d65bb1a5f20c97a86537", "submitter": { "id": 4703, "url": "http://patchwork.ozlabs.org/api/people/4703/?format=api", "name": "Amir Goldstein", "email": "amir73il@gmail.com" }, "delegate": null, "mbox": "http://patchwork.ozlabs.org/project/linux-ext4/patch/1503829290-10103-1-git-send-email-amir73il@gmail.com/mbox/", "series": [ { "id": 5, "url": "http://patchwork.ozlabs.org/api/series/5/?format=api", "web_url": "http://patchwork.ozlabs.org/project/linux-ext4/list/?series=5", "date": "2017-08-27T10:21:30", "name": "[RFC] fstests: regression test for ext4 crash consistency bug", "version": 1, "mbox": "http://patchwork.ozlabs.org/series/5/mbox/" } ], "comments": "http://patchwork.ozlabs.org/api/patches/806205/comments/", "check": "pending", "checks": "http://patchwork.ozlabs.org/api/patches/806205/checks/", "tags": {}, "related": [], "headers": { "Return-Path": "<linux-ext4-owner@vger.kernel.org>", "X-Original-To": "patchwork-incoming@ozlabs.org", "Delivered-To": "patchwork-incoming@ozlabs.org", "Authentication-Results": [ "ozlabs.org;\n\tspf=none (mailfrom) smtp.mailfrom=vger.kernel.org\n\t(client-ip=209.132.180.67; helo=vger.kernel.org;\n\tenvelope-from=linux-ext4-owner@vger.kernel.org;\n\treceiver=<UNKNOWN>)", "ozlabs.org; dkim=pass (2048-bit key;\n\tunprotected) header.d=gmail.com header.i=@gmail.com\n\theader.b=\"HoLgZFz2\"; dkim-atps=neutral" ], "Received": [ "from vger.kernel.org (vger.kernel.org [209.132.180.67])\n\tby ozlabs.org (Postfix) with ESMTP id 3xg9sh23pFz9sMN\n\tfor <patchwork-incoming@ozlabs.org>;\n\tSun, 27 Aug 2017 20:21:12 +1000 (AEST)", "(majordomo@vger.kernel.org) by vger.kernel.org via listexpand\n\tid S1751215AbdH0KVI (ORCPT <rfc822;patchwork-incoming@ozlabs.org>);\n\tSun, 27 Aug 2017 06:21:08 -0400", "from mail-wm0-f67.google.com ([74.125.82.67]:37620 \"EHLO\n\tmail-wm0-f67.google.com\" rhost-flags-OK-OK-OK-OK) by vger.kernel.org\n\twith ESMTP id S1751181AbdH0KVG (ORCPT\n\t<rfc822; linux-ext4@vger.kernel.org>); Sun, 27 Aug 2017 06:21:06 -0400", "by mail-wm0-f67.google.com with SMTP id m85so535927wma.4;\n\tSun, 27 Aug 2017 03:21:05 -0700 (PDT)", "from localhost.localdomain (bzq-166-168-31-246.red.bezeqint.net.\n\t[31.168.166.246]) by smtp.gmail.com with ESMTPSA id\n\t93sm7683800wro.47.2017.08.27.03.21.03\n\t(version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128);\n\tSun, 27 Aug 2017 03:21:04 -0700 (PDT)" ], "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=gmail.com; s=20161025;\n\th=from:to:cc:subject:date:message-id;\n\tbh=yPXAylMBW3L21+VvGkzpvYvFLGGxTffHHNrrwnTlZw0=;\n\tb=HoLgZFz2vUk8ZIZE4l/RZVdl5BRAfKl1LYwiH4VF55n5YYjw5s0nPtA3/GPaLpR+SD\n\tWWDPQ9+wV7Le8rOSOvbFBbEq3F/0jDe6rNpw9TXGWOPE6Dv8uzZxAaZEmsx1VzYpMxCN\n\tDeC7sWxXXqhKuDvUvzf9aq+7hl2MDRhi5CVCvMjwczCOp2MVfdhRl1D0SXnvWrQ10J7c\n\t2j/G6uaQItDdHm39w2y/daXxRCKPd3C9DGeVaVAM3wuYO0BaJPBC1isqmkCXqTql/gX/\n\thXiIyFr3Hk/iy0ze1jvlTkX4zE4a3AXxYV/oDejdhKd1T2uPqiEISeL4/XRpREX6LXQP\n\tiSMA==", "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20161025;\n\th=x-gm-message-state:from:to:cc:subject:date:message-id;\n\tbh=yPXAylMBW3L21+VvGkzpvYvFLGGxTffHHNrrwnTlZw0=;\n\tb=ZRxrGXtoiKayUqmxFc3SmCxxPTHMOGE90a5YL+cNRNHek0ajTOmYjokqpWVi8FBliA\n\tz3Uh/2KZbD9MEas/b685C6w5HRlJiDY9ChDkfXfiZgK/an8FDCqU55ToA5kUzrK65Hua\n\tJnDkVlTT4vRoU4JoS3FlmzQu38pU18ksjoAytUd25/2870sQr5wbNMat6/Cq7DuK9fNT\n\t3x+Vwy6JrM36p3Pk273CE/MTORhkF/gSwQql3YwQQFIlRyjSYEaiVZAvgLsw250YzgkH\n\tIa6sVZhrgOfWnlf9JMqMyqIn8eCryxU5BAAhqemQTIkhILRdl2AVIvQym2c4My1FrsjU\n\t8ZQA==", "X-Gm-Message-State": "AHYfb5gUEunkZB6MLjqNw33BQkhUhPtg995TBgp34MqnQkYjmBRlq9Oq\n\trggbCGXECF6KWQ==", "X-Received": "by 10.28.93.20 with SMTP id r20mr1741496wmb.71.1503829264990;\n\tSun, 27 Aug 2017 03:21:04 -0700 (PDT)", "From": "Amir Goldstein <amir73il@gmail.com>", "To": "Theodore Ts'o <tytso@mit.edu>", "Cc": "Eryu Guan <eguan@redhat.com>, Josef Bacik <jbacik@fb.com>,\n\tfstests@vger.kernel.org, linux-ext4@vger.kernel.org", "Subject": "[RFC][PATCH] fstests: regression test for ext4 crash consistency bug", "Date": "Sun, 27 Aug 2017 13:21:30 +0300", "Message-Id": "<1503829290-10103-1-git-send-email-amir73il@gmail.com>", "X-Mailer": "git-send-email 2.7.4", "Sender": "linux-ext4-owner@vger.kernel.org", "Precedence": "bulk", "List-ID": "<linux-ext4.vger.kernel.org>", "X-Mailing-List": "linux-ext4@vger.kernel.org" }, "content": "This test is motivated by a bug found in ext4 during random crash\nconsistency tests.\n\nThis test uses device mapper flakey target to demonstrate the bug\nfound using device mapper log-writes target.\n\nSigned-off-by: Amir Goldstein <amir73il@gmail.com>\n---\n\nTed,\n\nWhile working on crash consistency xfstests [1], I stubmled on what\nappeared to be an ext4 crash consistency bug.\n\nThe tests I used rely on the log-writes dm target code written\nby Josef Bacik, which had little exposure to the wide community\nas far as I know. I wanted to prove to myself that the found\ninconsistency was not due to a test bug, so I bisected the failed\ntest to the minimal operations that trigger the failure and wrote\na small independent test to reproduce the issue using dm flakey target.\n\nThe following fsck error is reliably reproduced by replaying 3 fsx ops\n(write, zero_range, mapwrite) on overlapping regions, then\nemulating a crash, followed by mount and umount:\n\n ./ltp/fsx -d --replay-ops /tmp/8995.fsxops /mnt/scratch/testfile\n 1 write 0x3e5ec thru 0x3ffff (0x1a14 bytes)\n 2 zero from 0x20fac to 0x27d48, (0x6d9c bytes)\n 3 mapwrite 0x216ad thru 0x23dfb (0x274f bytes)\n All 4 operations completed A-OK!\n _check_generic_filesystem: filesystem on /dev/mapper/ssd-scratch is inconsistent\n *** fsck.ext4 output ***\n fsck from util-linux 2.27.1\n e2fsck 1.42.13 (17-May-2015)\n Pass 1: Checking inodes, blocks, and sizes\n Inode 12, i_size is 147456, should be 163840. Fix? no\n\nNote that the inconsistency is \"applied\" by journal replay during mount.\nfsck -nf before mount does not report any errors.\n\nI did not intend for this test to be merged as is, but rather to be used\nby ext4 developers to analyze the problem and then re-write the test with\nmore comments and less arbitrary offset/length values.\n\nP.S.: crash consistency tests also reliably reproduce a btrfs fsck error.\n a detailed report with I/O recording was sent to Josef.\nP.S.2: crash consistency tests report file data checksum errors on xfs\n after fsync+crash, but I still need to prove the reliability of\n these reports.\n \n[1] https://github.com/amir73il/xfstests/commits/dm-log-writes\n\n tests/generic/501 | 77 +++++++++++++++++++++++++++++++++++++++++++++++++++\n tests/generic/501.out | 2 ++\n tests/generic/group | 1 +\n 3 files changed, 80 insertions(+)\n create mode 100755 tests/generic/501\n create mode 100644 tests/generic/501.out", "diff": "diff --git a/tests/generic/501 b/tests/generic/501\nnew file mode 100755\nindex 0000000..6e672b9\n--- /dev/null\n+++ b/tests/generic/501\n@@ -0,0 +1,77 @@\n+#! /bin/bash\n+# FS QA Test No. 501\n+#\n+# This test is motivated by a bug found in ext4 during random crash\n+# consistency tests.\n+#\n+#-----------------------------------------------------------------------\n+# Copyright (C) 2017 CTERA Networks. All Rights Reserved.\n+# Author: Amir Goldstein <amir73il@gmail.com>\n+#\n+# This program is free software; you can redistribute it and/or\n+# modify it under the terms of the GNU General Public License as\n+# published by the Free Software Foundation.\n+#\n+# This program is distributed in the hope that it would be useful,\n+# but WITHOUT ANY WARRANTY; without even the implied warranty of\n+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n+# GNU General Public License for more details.\n+#\n+# You should have received a copy of the GNU General Public License\n+# along with this program; if not, write the Free Software Foundation,\n+# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA\n+#-----------------------------------------------------------------------\n+#\n+\n+seq=`basename $0`\n+seqres=$RESULT_DIR/$seq\n+echo \"QA output created by $seq\"\n+\n+here=`pwd`\n+tmp=/tmp/$$\n+status=1\t# failure is the default!\n+\n+_cleanup()\n+{\n+\t_cleanup_flakey\n+\tcd /\n+\trm -f $tmp.*\n+}\n+trap \"_cleanup; exit \\$status\" 0 1 2 3 15\n+\n+# get standard environment, filters and checks\n+. ./common/rc\n+. ./common/filter\n+. ./common/dmflakey\n+\n+# real QA test starts here\n+_supported_fs generic\n+_supported_os Linux\n+_require_scratch\n+_require_dm_target flakey\n+_require_metadata_journaling $SCRATCH_DEV\n+\n+rm -f $seqres.full\n+\n+_scratch_mkfs >> $seqres.full 2>&1\n+\n+_init_flakey\n+_mount_flakey\n+\n+fsxops=$tmp.fsxops\n+cat <<EOF > $fsxops\n+write 0x3e5ec 0x1a14 0x21446\n+zero_range 0x20fac 0x6d9c 0x40000 keep_size\n+mapwrite 0x216ad 0x274f 0x40000\n+EOF\n+run_check $here/ltp/fsx -d --replay-ops $fsxops $SCRATCH_MNT/testfile\n+\n+_flakey_drop_and_remount\n+_unmount_flakey\n+_cleanup_flakey\n+_check_scratch_fs\n+\n+echo \"Silence is golden\"\n+\n+status=0\n+exit\ndiff --git a/tests/generic/501.out b/tests/generic/501.out\nnew file mode 100644\nindex 0000000..00133b6\n--- /dev/null\n+++ b/tests/generic/501.out\n@@ -0,0 +1,2 @@\n+QA output created by 501\n+Silence is golden\ndiff --git a/tests/generic/group b/tests/generic/group\nindex 044ec3f..f22b635 100644\n--- a/tests/generic/group\n+++ b/tests/generic/group\n@@ -453,3 +453,4 @@\n 448 auto quick rw\n 449 auto quick acl enospc\n 450 auto quick rw\n+501 auto quick metadata\n", "prefixes": [ "RFC" ] }