From patchwork Wed Dec 6 10:56:13 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Johannes Thumshirn X-Patchwork-Id: 13481505 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=wdc.com header.i=@wdc.com header.b="NENjOBEf" Received: from esa3.hgst.iphmx.com (esa3.hgst.iphmx.com [216.71.153.141]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A45CA12B; Wed, 6 Dec 2023 02:56:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=wdc.com; i=@wdc.com; q=dns/txt; s=dkim.wdc.com; t=1701860183; x=1733396183; h=from:date:subject:mime-version:content-transfer-encoding: message-id:references:in-reply-to:to:cc; bh=vH5ll84B3/EfTeO+vugCYebs+7bGkX44oA4L317bX/A=; b=NENjOBEfAExfVyQlmrHj7PFLOBg0oajd7sNS1ObSI5pdmXFQ9hVevJ0q w7Q3y4mRoEyQ7z8BbzP6aC0YMlA33FGH9fIZKIVW9a0lJtqbOQIieb/ya 0ZW/2V3T75etkz7ALBgnZiZ8D69o2xvUYSSEhrl5sHzTiB3x5Sb+GPHAZ 9b0+DEAleedjVhH+1NC/6X4VngpY0zlh4iLWsDg1+i4rVAwlTxZcVzxax Gj7tMAPHu8MFx/WVQSKS9ymYW3voJv5PzbmjYYN64aCBd/nvQZeOBqlI3 yPtsxdfOf+NxzfJKdfUERIZqm8hAu1ozTgu0ORcm1I7rcl17FfPwCMWea Q==; X-CSE-ConnectionGUID: x6LAKF08R4mK/QoD9yyVBA== X-CSE-MsgGUID: dp+SSm4jT/S8yN1pU7kdFg== X-IronPort-AV: E=Sophos;i="6.04,255,1695657600"; d="scan'208";a="4119708" Received: from h199-255-45-14.hgst.com (HELO uls-op-cesaep01.wdc.com) ([199.255.45.14]) by ob1.hgst.iphmx.com with ESMTP; 06 Dec 2023 18:56:21 +0800 IronPort-SDR: /ABX/qDFVxlCMni84KRElqmr1k4epKUZEBNducG/8vVIMmQK7OtrgWcYs7/aYyE04OAHb1WsOC HOHaIbYnu8Kg== Received: from uls-op-cesaip02.wdc.com ([10.248.3.37]) by uls-op-cesaep01.wdc.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 06 Dec 2023 02:07:22 -0800 IronPort-SDR: Yyz3ciS5HtupcSue501eCq/N1Cjm0ADI7qzpDnEYjjtfrq3OOQGmfEQCJ4SD9Ckm+8ncNwdzd9 WeDs4Fl5ycMw== WDCIronportException: Internal Received: from unknown (HELO redsun91.ssa.fujisawa.hgst.com) ([10.149.66.6]) by uls-op-cesaip02.wdc.com with ESMTP; 06 Dec 2023 02:56:20 -0800 From: Johannes Thumshirn Date: Wed, 06 Dec 2023 02:56:13 -0800 Subject: [PATCH v4 1/8] fstests: doc: add new raid-stripe-tree group Precedence: bulk X-Mailing-List: linux-btrfs@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20231206-btrfs-raid-v4-1-578284dd3a70@wdc.com> References: <20231206-btrfs-raid-v4-0-578284dd3a70@wdc.com> In-Reply-To: <20231206-btrfs-raid-v4-0-578284dd3a70@wdc.com> To: Anand Jain , Zorro Lang Cc: Filipe Manana , fstests@vger.kernel.org, linux-btrfs@vger.kernel.org, Johannes Thumshirn X-Mailer: b4 0.12.3 X-Developer-Signature: v=1; a=ed25519-sha256; t=1701860179; l=705; i=johannes.thumshirn@wdc.com; s=20230613; h=from:subject:message-id; bh=vH5ll84B3/EfTeO+vugCYebs+7bGkX44oA4L317bX/A=; b=ShBBp7q1wx6Yv3TSVvXuYuqSsFe2aCIvsBOZm9OCHJmyuDWek2P9m4X94fDRxgxPeQ+mA/ty3 pHTqjJ5hzudBCPheQ+ACsU4NkTNMmtxbj7tdX3lxuMpW0jPC21hC1Mk X-Developer-Key: i=johannes.thumshirn@wdc.com; a=ed25519; pk=TGmHKs78FdPi+QhrViEvjKIGwReUGCfa+3LEnGoR2KM= Add a new test group for testing the raid-stripe-tree feature of btrfs with fstests. Signed-off-by: Johannes Thumshirn --- doc/group-names.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/doc/group-names.txt b/doc/group-names.txt index c3dcca375537..9c1624868518 100644 --- a/doc/group-names.txt +++ b/doc/group-names.txt @@ -94,6 +94,7 @@ punch fallocate FALLOC_FL_PUNCH_HOLE qgroup btrfs qgroup feature quota filesystem usage quotas raid btrfs RAID +raid-stripe-tree btrfs raid-stripe-tree feature read_repair btrfs error correction on read failure realtime XFS realtime volumes recoveryloop crash recovery loops From patchwork Wed Dec 6 10:56:14 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Johannes Thumshirn X-Patchwork-Id: 13481504 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=wdc.com header.i=@wdc.com header.b="IRclsvao" Received: from esa3.hgst.iphmx.com (esa3.hgst.iphmx.com [216.71.153.141]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 85ED112F; Wed, 6 Dec 2023 02:56:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=wdc.com; i=@wdc.com; q=dns/txt; s=dkim.wdc.com; t=1701860184; x=1733396184; h=from:date:subject:mime-version:content-transfer-encoding: message-id:references:in-reply-to:to:cc; bh=0vFVxyKpqAp7DKayL6Ik1UXOmUX6REN6nOAs9orTBSo=; b=IRclsvaoX4JdbAoybz/tmEkDqDsYhucp38aqMaiBAt16+w7nujSeIKy8 OXA2F6G5Psi83/pkNRb30GpzAGfXjeDY25fW3GIxg40QudYxLY+b0ILIJ 363C68DF7zwO+juVqUpqOpQ6IOrzgtPy2Q2EdCG/PorEtEVomYM5JG619 Nti7tfG2mXtjsCl9ikdqibXA88e8hufkEoWWfJ7MxkFYvot6hieUzkuW/ rtnnhWFoI5a1WeWigoMmmLLPkQTt2sZI3NvRgBZMdp+i8ikKGBc4NhIbA k7c0pss8M3sCAq/ZQFNoLTLGFWQV7uN5wjuN0D9wV9ViTTwLDLXNppnmS Q==; X-CSE-ConnectionGUID: UGNI61dSQoyPSzWaeTcbUg== X-CSE-MsgGUID: c37RQ+fBQVu9Uc8imsj7kw== X-IronPort-AV: E=Sophos;i="6.04,255,1695657600"; d="scan'208";a="4119710" Received: from h199-255-45-14.hgst.com (HELO uls-op-cesaep01.wdc.com) ([199.255.45.14]) by ob1.hgst.iphmx.com with ESMTP; 06 Dec 2023 18:56:22 +0800 IronPort-SDR: CohK/yZiTC8wnkMRgJ6USM20JiOoraS1ssYffdFXYRHF5biD0NTtyKyeaoGOI0YYd6oY5EGjMg fL3nr/2PZ5JA== Received: from uls-op-cesaip02.wdc.com ([10.248.3.37]) by uls-op-cesaep01.wdc.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 06 Dec 2023 02:07:23 -0800 IronPort-SDR: LLeAVrIwfnLF/J57iS0/ZjwUxgMS7dZ7Ic7RxEtSHCSfR2/kfGeS7dOJjvOT0IsBcbPoKxobQc lDb8fmKXGF0A== WDCIronportException: Internal Received: from unknown (HELO redsun91.ssa.fujisawa.hgst.com) ([10.149.66.6]) by uls-op-cesaip02.wdc.com with ESMTP; 06 Dec 2023 02:56:21 -0800 From: Johannes Thumshirn Date: Wed, 06 Dec 2023 02:56:14 -0800 Subject: [PATCH v4 2/8] common: add filter for btrfs raid-stripe dump Precedence: bulk X-Mailing-List: linux-btrfs@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20231206-btrfs-raid-v4-2-578284dd3a70@wdc.com> References: <20231206-btrfs-raid-v4-0-578284dd3a70@wdc.com> In-Reply-To: <20231206-btrfs-raid-v4-0-578284dd3a70@wdc.com> To: Anand Jain , Zorro Lang Cc: Filipe Manana , fstests@vger.kernel.org, linux-btrfs@vger.kernel.org, Johannes Thumshirn X-Mailer: b4 0.12.3 X-Developer-Signature: v=1; a=ed25519-sha256; t=1701860179; l=1491; i=johannes.thumshirn@wdc.com; s=20230613; h=from:subject:message-id; bh=0vFVxyKpqAp7DKayL6Ik1UXOmUX6REN6nOAs9orTBSo=; b=RfMt0ZfSDNgfKfmKjgbvjBfiiT1oguUJps40zXZIOcihp25eRzJK+KNAxBP7YJf2zOLgrQMrP 9ofmHbDQ1J1A1gMpO6rvy2kBNlN+7/9YXRYHeDJjk/A9NYe7ZfwTMoF X-Developer-Key: i=johannes.thumshirn@wdc.com; a=ed25519; pk=TGmHKs78FdPi+QhrViEvjKIGwReUGCfa+3LEnGoR2KM= Signed-off-by: Johannes Thumshirn --- common/filter.btrfs | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/common/filter.btrfs b/common/filter.btrfs index 02c6b92dfa94..2003ba7b7015 100644 --- a/common/filter.btrfs +++ b/common/filter.btrfs @@ -125,5 +125,19 @@ _filter_btrfs_cloner_error() sed -e "s/\(clone failed:\) Operation not supported/\1 Invalid argument/g" } +# filter output of "btrfs inspect-internal dump-tree -t raid-stripe" +_filter_stripe_tree() +{ + sed -E -e "s/leaf [0-9]+ items [0-9]+ free space [0-9]+ generation [0-9]+ owner RAID_STRIPE_TREE/leaf XXXXXXXXX items X free space XXXXX generation X owner RAID_STRIPE_TREE/" \ + -e "s/leaf [0-9]+ flags 0x1\(WRITTEN\) backref revision 1/leaf XXXXXXXXX flags 0x1\(WRITTEN\) backref revision 1/" \ + -e "s/checksum stored [0-9a-f]+/checksum stored /" \ + -e "s/checksum calced [0-9a-f]+/checksum calced /" \ + -e "s/[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}//" \ + -e "s/item ([0-9]+) key \([0-9]+ RAID_STRIPE ([0-9]+)\) itemoff [0-9]+ itemsize ([0-9]+)/item \1 key \(XXXXXX RAID_STRIPE \2\) itemoff XXXXX itemsize \3/" \ + -e "s/stripe ([0-9]+) devid ([0-9]+) physical [0-9]+/stripe \1 devid \2 physical XXXXXXXXX/" \ + -e "s/total bytes [0-9]+/total bytes XXXXXXXX/" \ + -e "s/bytes used [0-9]+/bytes used XXXXXX/" +} + # make sure this script returns success /bin/true From patchwork Wed Dec 6 10:56:15 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Johannes Thumshirn X-Patchwork-Id: 13481506 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=wdc.com header.i=@wdc.com header.b="eOUXRY9Y" Received: from esa3.hgst.iphmx.com (esa3.hgst.iphmx.com [216.71.153.141]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AA16818F; Wed, 6 Dec 2023 02:56:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=wdc.com; i=@wdc.com; q=dns/txt; s=dkim.wdc.com; t=1701860184; x=1733396184; h=from:date:subject:mime-version:content-transfer-encoding: message-id:references:in-reply-to:to:cc; bh=/PZsmw0zyU4nAM+H32DiGBfJFTVkJfKctQwr8KH9gZg=; b=eOUXRY9Y6PAlPzldFW33p1870AVb8RtexnNd6WdFweuTqQwwJ4ZoVIOV 9j87t9OT4MpNncwA/H3QvP5Xu2rSvvVKcgPrFY32GDvyrhJpve+I+bsI6 UxJ7y6NLmIjdhQDsL35WhvWYyabD77JCcp04nbyBx8Vkd+dRkKiHZNkOw wsKneIng3to80PXF1QMfHnnu9VO0sXU4hVYuYVJtRepj62ShD9yaZQN15 uUYFouBV5KFy7lbqBdWzS9VauPRCO33xb1Q3/5feIp5apCNh7+qSE4jFj qLirORwNKx8N4UAQ39Rf+OdrMHFWBqnJJwNL5plMN/fACG97Bl6PzC954 A==; X-CSE-ConnectionGUID: r0CTVtJGTTWM/007/R5R3Q== X-CSE-MsgGUID: PAveaZ1KRzWM4zIqlrs23w== X-IronPort-AV: E=Sophos;i="6.04,255,1695657600"; d="scan'208";a="4119711" Received: from h199-255-45-14.hgst.com (HELO uls-op-cesaep01.wdc.com) ([199.255.45.14]) by ob1.hgst.iphmx.com with ESMTP; 06 Dec 2023 18:56:23 +0800 IronPort-SDR: XTWe2I8MstbtIH0QwVmee2I1jkUhaw1pUTRIS4w5LS/d2OCj4ACHCVkehHBx9QASjd7NRp9YLk PiRt866JMB5g== Received: from uls-op-cesaip02.wdc.com ([10.248.3.37]) by uls-op-cesaep01.wdc.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 06 Dec 2023 02:07:24 -0800 IronPort-SDR: ZMVgIjkgKgXeuZbt5lblUsVOADM4K5LhvhAo/1uXOraco4vLygK+fbYggIWFLIdNLklyOrhHs+ AaAh6BZ1gtAw== WDCIronportException: Internal Received: from unknown (HELO redsun91.ssa.fujisawa.hgst.com) ([10.149.66.6]) by uls-op-cesaip02.wdc.com with ESMTP; 06 Dec 2023 02:56:22 -0800 From: Johannes Thumshirn Date: Wed, 06 Dec 2023 02:56:15 -0800 Subject: [PATCH v4 3/8] common: add _require_btrfs_no_nodatacow helper Precedence: bulk X-Mailing-List: linux-btrfs@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20231206-btrfs-raid-v4-3-578284dd3a70@wdc.com> References: <20231206-btrfs-raid-v4-0-578284dd3a70@wdc.com> In-Reply-To: <20231206-btrfs-raid-v4-0-578284dd3a70@wdc.com> To: Anand Jain , Zorro Lang Cc: Filipe Manana , fstests@vger.kernel.org, linux-btrfs@vger.kernel.org, Johannes Thumshirn X-Mailer: b4 0.12.3 X-Developer-Signature: v=1; a=ed25519-sha256; t=1701860179; l=590; i=johannes.thumshirn@wdc.com; s=20230613; h=from:subject:message-id; bh=/PZsmw0zyU4nAM+H32DiGBfJFTVkJfKctQwr8KH9gZg=; b=Eazl5y3ZqdmL1ATy1WU6JziLhfV0R7gxSN2Ix9jzs2h+Zb9hUk/xEa6zEds8pW5/yjIr4Ua/v Y5utBjhVBQwAJxXWzYvdodN8g53vWpld3QjbtKbKIObjCwogsRCUZbh X-Developer-Key: i=johannes.thumshirn@wdc.com; a=ed25519; pk=TGmHKs78FdPi+QhrViEvjKIGwReUGCfa+3LEnGoR2KM= Signed-off-by: Johannes Thumshirn --- common/btrfs | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/common/btrfs b/common/btrfs index e3ccb4fa07d4..bf69bcee158b 100644 --- a/common/btrfs +++ b/common/btrfs @@ -120,6 +120,13 @@ _require_btrfs_no_compress() fi } +_require_btrfs_no_nodatacow() +{ + if _normalize_mount_options "$MOUNT_OPTIONS" | grep -q "nodatacow"; then + _notrun "This test requires no nodatacow enabled" + fi +} + _require_btrfs_no_block_group_tree() { _scratch_mkfs > /dev/null 2>&1 From patchwork Wed Dec 6 10:56:16 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Johannes Thumshirn X-Patchwork-Id: 13481507 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=wdc.com header.i=@wdc.com header.b="Gl5HhObb" Received: from esa3.hgst.iphmx.com (esa3.hgst.iphmx.com [216.71.153.141]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 93635137; Wed, 6 Dec 2023 02:56:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=wdc.com; i=@wdc.com; q=dns/txt; s=dkim.wdc.com; t=1701860185; x=1733396185; h=from:date:subject:mime-version:content-transfer-encoding: message-id:references:in-reply-to:to:cc; bh=+XK6wnCNqvL23iP8tFvI+SJ8TZWBf8by/kcn6E9LUBo=; b=Gl5HhObboBPzO07FU0idNlagH8i2ZvzX756nEpO0GwFtOJJnaA0yS7Rn eKN+6RMgJGqytbkS7jPOewUjVdID6xsxzvAPh/Vm0CelGMsQXbNALyldH SyKpYW9+BklSqOmMZjK56HIddz4qqViVhwa18z81cMA6MZiNZJ6wwawhv 1LqmcdXxKvhTqJRmUDbXBZXqz18n/8ZH4r7zG9nUMvATK5y3t6gdU7iJo 5Fp0YstpF1AQQ/wAFe+Pap1eEaETNFvbCy0cql/3EjZfVgP5zNluPMbD5 v3mzC+FEQhRQLJKoPwqKvvQwcjRbEb1jhD2DJDNmd8odmHYuZXs8bEArj A==; X-CSE-ConnectionGUID: PmwOGnuXT7mQQB9Fqs19oQ== X-CSE-MsgGUID: TgWoyl4cTkiMpIEu5vVzag== X-IronPort-AV: E=Sophos;i="6.04,255,1695657600"; d="scan'208";a="4119712" Received: from h199-255-45-14.hgst.com (HELO uls-op-cesaep01.wdc.com) ([199.255.45.14]) by ob1.hgst.iphmx.com with ESMTP; 06 Dec 2023 18:56:24 +0800 IronPort-SDR: bprd19nBRfqtt/CALjjVk5TCDgE0AWlParGb8MriCDR6Nzq7TSs7T+pvaah7Up1QowO+Nw1arC IzXGxrTBTYkQ== Received: from uls-op-cesaip02.wdc.com ([10.248.3.37]) by uls-op-cesaep01.wdc.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 06 Dec 2023 02:07:25 -0800 IronPort-SDR: 3fplcOb5N6YCeytgNVW1bzI7yCfQCXbNylt+lAQjZtqNvKsm/k/VvNz/h452OB4bUvUAlOjWmL Rhngly+rGveQ== WDCIronportException: Internal Received: from unknown (HELO redsun91.ssa.fujisawa.hgst.com) ([10.149.66.6]) by uls-op-cesaip02.wdc.com with ESMTP; 06 Dec 2023 02:56:23 -0800 From: Johannes Thumshirn Date: Wed, 06 Dec 2023 02:56:16 -0800 Subject: [PATCH v4 4/8] btrfs: add fstest for stripe-tree metadata with 4k write Precedence: bulk X-Mailing-List: linux-btrfs@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20231206-btrfs-raid-v4-4-578284dd3a70@wdc.com> References: <20231206-btrfs-raid-v4-0-578284dd3a70@wdc.com> In-Reply-To: <20231206-btrfs-raid-v4-0-578284dd3a70@wdc.com> To: Anand Jain , Zorro Lang Cc: Filipe Manana , fstests@vger.kernel.org, linux-btrfs@vger.kernel.org, Johannes Thumshirn X-Mailer: b4 0.12.3 X-Developer-Signature: v=1; a=ed25519-sha256; t=1701860179; l=4174; i=johannes.thumshirn@wdc.com; s=20230613; h=from:subject:message-id; bh=+XK6wnCNqvL23iP8tFvI+SJ8TZWBf8by/kcn6E9LUBo=; b=KDVbvNwkTGUlb/11Ae2YeWFa/lDMKDJueIn5g3wpwmyTseefdKXH5VKGWT3UNGlx4QuEEOqF8 /inv4uJHcWCAJRqPa87MS2NRUPianSTz8408Ssip0EQWDW+qMNVHBql X-Developer-Key: i=johannes.thumshirn@wdc.com; a=ed25519; pk=TGmHKs78FdPi+QhrViEvjKIGwReUGCfa+3LEnGoR2KM= Test a simple 4k write on all RAID profiles currently supported with the raid-stripe-tree. Signed-off-by: Johannes Thumshirn --- tests/btrfs/304 | 55 ++++++++++++++++++++++++++++++++++++++++++++++++++ tests/btrfs/304.out | 58 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 113 insertions(+) diff --git a/tests/btrfs/304 b/tests/btrfs/304 new file mode 100755 index 000000000000..897b35ae21fb --- /dev/null +++ b/tests/btrfs/304 @@ -0,0 +1,55 @@ +#! /bin/bash +# SPDX-License-Identifier: GPL-2.0 +# Copyright (c) 2023 Western Digital Cooperation. All Rights Reserved. +# +# FS QA Test 304 +# +# Test on-disk layout of RAID Stripe Tree Metadata writing 4k to a new file on +# a pristine file system. +# +. ./common/preamble +_begin_fstest auto quick raid remount volume raid-stripe-tree + +. ./common/filter +. ./common/filter.btrfs + +_supported_fs btrfs +_require_btrfs_command inspect-internal dump-tree +_require_btrfs_mkfs_feature "raid-stripe-tree" +_require_scratch_dev_pool 4 +_require_btrfs_fs_feature "raid_stripe_tree" +_require_btrfs_fs_feature "free_space_tree" +_require_btrfs_no_compress + +test_4k_write() +{ + local profile=$1 + local ndevs=$2 + + _scratch_dev_pool_get $ndevs + + echo "==== Testing $profile ====" + _scratch_pool_mkfs -d $profile -m $profile -O raid-stripe-tree + _scratch_mount + + $XFS_IO_PROG -fc "pwrite 0 4k" "$SCRATCH_MNT/foo" | _filter_xfs_io + + _scratch_cycle_mount + md5sum "$SCRATCH_MNT/foo" | _filter_scratch + + _scratch_unmount + + $BTRFS_UTIL_PROG inspect-internal dump-tree -t raid_stripe $SCRATCH_DEV_POOL |\ + _filter_btrfs_version | _filter_stripe_tree + + _scratch_dev_pool_put +} + +echo "= Test basic 4k write =" +test_4k_write raid0 2 +test_4k_write raid1 2 +test_4k_write raid10 4 + +# success, all done +status=0 +exit diff --git a/tests/btrfs/304.out b/tests/btrfs/304.out new file mode 100644 index 000000000000..48036efbf0cf --- /dev/null +++ b/tests/btrfs/304.out @@ -0,0 +1,58 @@ +QA output created by 304 += Test basic 4k write = +==== Testing raid0 ==== +wrote 4096/4096 bytes at offset 0 +XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +5fed275e7617a806f94c173746a2a723 SCRATCH_MNT/foo + +raid stripe tree key (RAID_STRIPE_TREE ROOT_ITEM 0) +leaf XXXXXXXXX items X free space XXXXX generation X owner RAID_STRIPE_TREE +leaf XXXXXXXXX flags 0x1(WRITTEN) backref revision 1 +checksum stored +checksum calced +fs uuid +chunk uuid + item 0 key (XXXXXX RAID_STRIPE 4096) itemoff XXXXX itemsize 24 + encoding: RAID0 + stripe 0 devid 1 physical XXXXXXXXX +total bytes XXXXXXXX +bytes used XXXXXX +uuid +==== Testing raid1 ==== +wrote 4096/4096 bytes at offset 0 +XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +5fed275e7617a806f94c173746a2a723 SCRATCH_MNT/foo + +raid stripe tree key (RAID_STRIPE_TREE ROOT_ITEM 0) +leaf XXXXXXXXX items X free space XXXXX generation X owner RAID_STRIPE_TREE +leaf XXXXXXXXX flags 0x1(WRITTEN) backref revision 1 +checksum stored +checksum calced +fs uuid +chunk uuid + item 0 key (XXXXXX RAID_STRIPE 4096) itemoff XXXXX itemsize 40 + encoding: RAID1 + stripe 0 devid 1 physical XXXXXXXXX + stripe 1 devid 2 physical XXXXXXXXX +total bytes XXXXXXXX +bytes used XXXXXX +uuid +==== Testing raid10 ==== +wrote 4096/4096 bytes at offset 0 +XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +5fed275e7617a806f94c173746a2a723 SCRATCH_MNT/foo + +raid stripe tree key (RAID_STRIPE_TREE ROOT_ITEM 0) +leaf XXXXXXXXX items X free space XXXXX generation X owner RAID_STRIPE_TREE +leaf XXXXXXXXX flags 0x1(WRITTEN) backref revision 1 +checksum stored +checksum calced +fs uuid +chunk uuid + item 0 key (XXXXXX RAID_STRIPE 4096) itemoff XXXXX itemsize 40 + encoding: RAID10 + stripe 0 devid 1 physical XXXXXXXXX + stripe 1 devid 2 physical XXXXXXXXX +total bytes XXXXXXXX +bytes used XXXXXX +uuid From patchwork Wed Dec 6 10:56:17 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Johannes Thumshirn X-Patchwork-Id: 13481508 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=wdc.com header.i=@wdc.com header.b="N7yp8jH3" Received: from esa3.hgst.iphmx.com (esa3.hgst.iphmx.com [216.71.153.141]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A73D71A5; Wed, 6 Dec 2023 02:56:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=wdc.com; i=@wdc.com; q=dns/txt; s=dkim.wdc.com; t=1701860185; x=1733396185; h=from:date:subject:mime-version:content-transfer-encoding: message-id:references:in-reply-to:to:cc; bh=qOpZ6evbWma+7A5uCwQYALxvEPrBOPgb6Lh8f8i6neI=; b=N7yp8jH3I+6YzUnFNfayKbANEm2IjS+6Ugq9ILfSqy1fPDp71aMtSF37 ABklAKf2yqstG/bxqYS4wohdAxbTOwgWssHKUHYU5byfKT/U1qSStoso/ O2/OFzz5jstQoOAkLXc6QJ0As0EOZF4GFEvlGixM+X58Ee4uZJsHDqvZp E/+amCjcWJbfwG/NKg8kRjVAh9XKJLCVU2gkBZ+A++Xouy7LW0CpwBCci SNpDHu+c/QsMfxgOaI73q/oxRMfgiFbTMNqOwbDNwM9KZ9sMCME2sTviH d2UcTnb+cfg9ceVIGFklMTT2c3bppteUYkB/vXSLRbMNZ1RR6iZe/8Rwy Q==; X-CSE-ConnectionGUID: hk9w5WV7Ra+728Wyk99uHQ== X-CSE-MsgGUID: 2V185PA2SUm1GJ+m3mBUfQ== X-IronPort-AV: E=Sophos;i="6.04,255,1695657600"; d="scan'208";a="4119715" Received: from h199-255-45-14.hgst.com (HELO uls-op-cesaep01.wdc.com) ([199.255.45.14]) by ob1.hgst.iphmx.com with ESMTP; 06 Dec 2023 18:56:25 +0800 IronPort-SDR: 9re4+0vqwZnNd610wECFrVhvYj8f+vRwMlI5ORhjRZdbTBVI9MddM+tKqVyG/JzKmT/jSrLDc7 XhLu/fETavYw== Received: from uls-op-cesaip02.wdc.com ([10.248.3.37]) by uls-op-cesaep01.wdc.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 06 Dec 2023 02:07:26 -0800 IronPort-SDR: mgoUqqRicdAwXyEkQiJEfeo1GSc9HhtgE422hga9WTzORab+SCn3KJzRvcItM7WQZbu90ZEBjc moYkwELhGgIQ== WDCIronportException: Internal Received: from unknown (HELO redsun91.ssa.fujisawa.hgst.com) ([10.149.66.6]) by uls-op-cesaip02.wdc.com with ESMTP; 06 Dec 2023 02:56:24 -0800 From: Johannes Thumshirn Date: Wed, 06 Dec 2023 02:56:17 -0800 Subject: [PATCH v4 5/8] btrfs: add fstest for 8k write spanning two stripes on raid-stripe-tree Precedence: bulk X-Mailing-List: linux-btrfs@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20231206-btrfs-raid-v4-5-578284dd3a70@wdc.com> References: <20231206-btrfs-raid-v4-0-578284dd3a70@wdc.com> In-Reply-To: <20231206-btrfs-raid-v4-0-578284dd3a70@wdc.com> To: Anand Jain , Zorro Lang Cc: Filipe Manana , fstests@vger.kernel.org, linux-btrfs@vger.kernel.org, Johannes Thumshirn X-Mailer: b4 0.12.3 X-Developer-Signature: v=1; a=ed25519-sha256; t=1701860179; l=5677; i=johannes.thumshirn@wdc.com; s=20230613; h=from:subject:message-id; bh=qOpZ6evbWma+7A5uCwQYALxvEPrBOPgb6Lh8f8i6neI=; b=UADLXJKawC7IdQyjspHlXOnxjgf6HVBkavTII0Ku5maYzzlSyKuT37EnEYU1UQU2WyfT9xKC/ okKWx7acoeMCzRlD6u9ZqpVre0uh0fBsP3roOoSwf6MLM/L0MmMMQrD X-Developer-Key: i=johannes.thumshirn@wdc.com; a=ed25519; pk=TGmHKs78FdPi+QhrViEvjKIGwReUGCfa+3LEnGoR2KM= Add a test-case writing 8k to a raid-stripe-tree formatted filesystem with one stripe pre-filled to 60k so the 8k are split into a 4k write finishing stripe 1 and a 4k write starting the next stripe. Signed-off-by: Johannes Thumshirn --- tests/btrfs/305 | 60 +++++++++++++++++++++++++++++++++++++++ tests/btrfs/305.out | 82 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 142 insertions(+) diff --git a/tests/btrfs/305 b/tests/btrfs/305 new file mode 100755 index 000000000000..1b2f84884f55 --- /dev/null +++ b/tests/btrfs/305 @@ -0,0 +1,60 @@ +#! /bin/bash +# SPDX-License-Identifier: GPL-2.0 +# Copyright (c) 2023 Western Digital Cooperation. All Rights Reserved. +# +# FS QA Test 305 +# +# Test on-disk layout of RAID Stripe Tree Metadata by writing 8k to a new file +# with a filesystem prepropulated, so that 4k of the write are written to the +# 1st stripe and 4k start a new stripe. +# +. ./common/preamble +_begin_fstest auto quick raid remount volume raid-stripe-tree + +. ./common/filter +. ./common/filter.btrfs + +_supported_fs btrfs +_require_btrfs_command inspect-internal dump-tree +_require_btrfs_mkfs_feature "raid-stripe-tree" +_require_scratch_dev_pool 4 +_require_btrfs_fs_feature "raid_stripe_tree" +_require_btrfs_fs_feature "free_space_tree" +_require_btrfs_no_compress + +test_8k_new_stripe() +{ + local profile=$1 + local ndevs=$2 + + _scratch_dev_pool_get $ndevs + + echo "==== Testing $profile ====" + _scratch_pool_mkfs -d $profile -m $profile -O raid-stripe-tree + _scratch_mount + + # Fill the first stripe up to 64k - 4k + $XFS_IO_PROG -fc "pwrite 0 60k" -c fsync "$SCRATCH_MNT/bar" | _filter_xfs_io + + # The actual 8k write + $XFS_IO_PROG -fc "pwrite 0 8k" "$SCRATCH_MNT/foo" | _filter_xfs_io + + _scratch_cycle_mount + md5sum "$SCRATCH_MNT/foo" | _filter_scratch + + _scratch_unmount + + $BTRFS_UTIL_PROG inspect-internal dump-tree -t raid_stripe $SCRATCH_DEV_POOL |\ + _filter_btrfs_version | _filter_stripe_tree + + _scratch_dev_pool_put +} + +echo "= Test 8k write to a new file so that 4k start a new stripe =" +test_8k_new_stripe raid0 2 +test_8k_new_stripe raid1 2 +test_8k_new_stripe raid10 4 + +# success, all done +status=0 +exit diff --git a/tests/btrfs/305.out b/tests/btrfs/305.out new file mode 100644 index 000000000000..7460501ef40b --- /dev/null +++ b/tests/btrfs/305.out @@ -0,0 +1,82 @@ +QA output created by 305 += Test 8k write to a new file so that 4k start a new stripe = +==== Testing raid0 ==== +wrote 61440/61440 bytes at offset 0 +XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +wrote 8192/8192 bytes at offset 0 +XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +9d3940adb41dd525e008a847e01b15f4 SCRATCH_MNT/foo + +raid stripe tree key (RAID_STRIPE_TREE ROOT_ITEM 0) +leaf XXXXXXXXX items X free space XXXXX generation X owner RAID_STRIPE_TREE +leaf XXXXXXXXX flags 0x1(WRITTEN) backref revision 1 +checksum stored +checksum calced +fs uuid +chunk uuid + item 0 key (XXXXXX RAID_STRIPE 61440) itemoff XXXXX itemsize 24 + encoding: RAID0 + stripe 0 devid 1 physical XXXXXXXXX + item 1 key (XXXXXX RAID_STRIPE 4096) itemoff XXXXX itemsize 24 + encoding: RAID0 + stripe 0 devid 1 physical XXXXXXXXX + item 2 key (XXXXXX RAID_STRIPE 4096) itemoff XXXXX itemsize 24 + encoding: RAID0 + stripe 0 devid 2 physical XXXXXXXXX +total bytes XXXXXXXX +bytes used XXXXXX +uuid +==== Testing raid1 ==== +wrote 61440/61440 bytes at offset 0 +XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +wrote 8192/8192 bytes at offset 0 +XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +9d3940adb41dd525e008a847e01b15f4 SCRATCH_MNT/foo + +raid stripe tree key (RAID_STRIPE_TREE ROOT_ITEM 0) +leaf XXXXXXXXX items X free space XXXXX generation X owner RAID_STRIPE_TREE +leaf XXXXXXXXX flags 0x1(WRITTEN) backref revision 1 +checksum stored +checksum calced +fs uuid +chunk uuid + item 0 key (XXXXXX RAID_STRIPE 61440) itemoff XXXXX itemsize 40 + encoding: RAID1 + stripe 0 devid 1 physical XXXXXXXXX + stripe 1 devid 2 physical XXXXXXXXX + item 1 key (XXXXXX RAID_STRIPE 8192) itemoff XXXXX itemsize 40 + encoding: RAID1 + stripe 0 devid 1 physical XXXXXXXXX + stripe 1 devid 2 physical XXXXXXXXX +total bytes XXXXXXXX +bytes used XXXXXX +uuid +==== Testing raid10 ==== +wrote 61440/61440 bytes at offset 0 +XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +wrote 8192/8192 bytes at offset 0 +XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +9d3940adb41dd525e008a847e01b15f4 SCRATCH_MNT/foo + +raid stripe tree key (RAID_STRIPE_TREE ROOT_ITEM 0) +leaf XXXXXXXXX items X free space XXXXX generation X owner RAID_STRIPE_TREE +leaf XXXXXXXXX flags 0x1(WRITTEN) backref revision 1 +checksum stored +checksum calced +fs uuid +chunk uuid + item 0 key (XXXXXX RAID_STRIPE 61440) itemoff XXXXX itemsize 40 + encoding: RAID10 + stripe 0 devid 1 physical XXXXXXXXX + stripe 1 devid 2 physical XXXXXXXXX + item 1 key (XXXXXX RAID_STRIPE 4096) itemoff XXXXX itemsize 40 + encoding: RAID10 + stripe 0 devid 1 physical XXXXXXXXX + stripe 1 devid 2 physical XXXXXXXXX + item 2 key (XXXXXX RAID_STRIPE 4096) itemoff XXXXX itemsize 40 + encoding: RAID10 + stripe 0 devid 3 physical XXXXXXXXX + stripe 1 devid 4 physical XXXXXXXXX +total bytes XXXXXXXX +bytes used XXXXXX +uuid From patchwork Wed Dec 6 10:56:18 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Johannes Thumshirn X-Patchwork-Id: 13481509 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=wdc.com header.i=@wdc.com header.b="ZNRgky0F" Received: from esa3.hgst.iphmx.com (esa3.hgst.iphmx.com [216.71.153.141]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9EF779C; Wed, 6 Dec 2023 02:56:26 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=wdc.com; i=@wdc.com; q=dns/txt; s=dkim.wdc.com; t=1701860186; x=1733396186; h=from:date:subject:mime-version:content-transfer-encoding: message-id:references:in-reply-to:to:cc; bh=2x2wGtgWmS/xJUHNe4QuZYwvNXtZNE3K89rAEDi8uCQ=; b=ZNRgky0FlwFjWjgv1+NDF7Ry4DzzeS7jrFNgxt4PuOsBbLOAFZ1HKyEk atQWhSBhLzU8ms3cnbMGNisgFHAzKTbY6JSSrEyuxfMtQR3X6T+8MMo2D UTUJ+MO016koQEa3va9JzWpB9ONiFi38PkKpCLXww4085AvE/4B2qzrvT SijVNnd2BUjfKO/E28zA0Q3zoD0k7UYk9QyDK1plYj8nStuyR81RN+bmb NWylRlZTsjp0I810AI6PZ7knmnGAemTbKT5FIMjS/mIaYIgy2YhdmdVym nq6iDuDlMZPLRk/+Y1yfnqHN9Ej5n1q+CyyRiqi5TwCYOlhZISBCWcfH7 A==; X-CSE-ConnectionGUID: ev5Wc07YSF2qrLHX6ER1sQ== X-CSE-MsgGUID: 6av8uyPJQaOzRYQNBE13qw== X-IronPort-AV: E=Sophos;i="6.04,255,1695657600"; d="scan'208";a="4119718" Received: from h199-255-45-14.hgst.com (HELO uls-op-cesaep01.wdc.com) ([199.255.45.14]) by ob1.hgst.iphmx.com with ESMTP; 06 Dec 2023 18:56:26 +0800 IronPort-SDR: iAbXdGwhaIvqRAwphro0lL+rovCEQwk9zj1kleK57W+reT9aS8aYxrGkI7TS+gOdyX7KY7ykLm ZjuyiDpGEvPw== Received: from uls-op-cesaip02.wdc.com ([10.248.3.37]) by uls-op-cesaep01.wdc.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 06 Dec 2023 02:07:27 -0800 IronPort-SDR: uwK6VOmetSVvPUX17v0hl8j4RilBgZJ1oU3rj8FEfHjuWAsCkXl6CQ8raAFmjZsu1UWKMScgzm 8QaAw6f45TzQ== WDCIronportException: Internal Received: from unknown (HELO redsun91.ssa.fujisawa.hgst.com) ([10.149.66.6]) by uls-op-cesaip02.wdc.com with ESMTP; 06 Dec 2023 02:56:25 -0800 From: Johannes Thumshirn Date: Wed, 06 Dec 2023 02:56:18 -0800 Subject: [PATCH v4 6/8] btrfs: add fstest for writing to a file at an offset with RST Precedence: bulk X-Mailing-List: linux-btrfs@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20231206-btrfs-raid-v4-6-578284dd3a70@wdc.com> References: <20231206-btrfs-raid-v4-0-578284dd3a70@wdc.com> In-Reply-To: <20231206-btrfs-raid-v4-0-578284dd3a70@wdc.com> To: Anand Jain , Zorro Lang Cc: Filipe Manana , fstests@vger.kernel.org, linux-btrfs@vger.kernel.org, Johannes Thumshirn X-Mailer: b4 0.12.3 X-Developer-Signature: v=1; a=ed25519-sha256; t=1701860179; l=5279; i=johannes.thumshirn@wdc.com; s=20230613; h=from:subject:message-id; bh=2x2wGtgWmS/xJUHNe4QuZYwvNXtZNE3K89rAEDi8uCQ=; b=RvN2ejfDIODQmTYkJNzlfp/a0c0pEYr8vveVlb6JF1EepEyofOZ9c9IHfVZF6y4HeycuLQruS nGVRY17DhMDBSws7c6moOvqIaOMDo1olWkX+Mmd7SlKb9WUH5o9vqtU X-Developer-Key: i=johannes.thumshirn@wdc.com; a=ed25519; pk=TGmHKs78FdPi+QhrViEvjKIGwReUGCfa+3LEnGoR2KM= Add a fstest writing 4k at offset 64k to a file with one RAID tripe already pre-filled for a raid-stripe-tree formatted file system. Signed-off-by: Johannes Thumshirn --- tests/btrfs/306 | 58 +++++++++++++++++++++++++++++++++++++++++ tests/btrfs/306.out | 75 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 133 insertions(+) diff --git a/tests/btrfs/306 b/tests/btrfs/306 new file mode 100755 index 000000000000..9bbc1170f7ed --- /dev/null +++ b/tests/btrfs/306 @@ -0,0 +1,58 @@ +#! /bin/bash +# SPDX-License-Identifier: GPL-2.0 +# Copyright (c) 2023 Western Digital Cooperation. All Rights Reserved. +# +# FS QA Test 306 +# +# Test on-disk layout of RAID Stripe Tree Metadata by writing 4k to an emppty +# file at offset 64k with one stripe pre-filled on an otherwise pristine +# filesystem. +# +. ./common/preamble +_begin_fstest auto quick raid remount volume raid-stripe-tree + +. ./common/filter +. ./common/filter.btrfs + +_supported_fs btrfs +_require_btrfs_command inspect-internal dump-tree +_require_btrfs_mkfs_feature "raid-stripe-tree" +_require_scratch_dev_pool 4 +_require_btrfs_fs_feature "raid_stripe_tree" +_require_btrfs_fs_feature "free_space_tree" +_require_btrfs_no_compress + +test_4k_write_64koff() +{ + local profile=$1 + local ndevs=$2 + + _scratch_dev_pool_get $ndevs + + echo "==== Testing $profile ====" + _scratch_pool_mkfs -d $profile -m $profile -O raid-stripe-tree + _scratch_mount + + # precondition one stripe + $XFS_IO_PROG -fc "pwrite 0 64k" "$SCRATCH_MNT/bar" | _filter_xfs_io + + $XFS_IO_PROG -fc "pwrite 64k 4k" "$SCRATCH_MNT/foo" | _filter_xfs_io + + _scratch_cycle_mount + md5sum "$SCRATCH_MNT/foo" | _filter_scratch + + _scratch_unmount + + $BTRFS_UTIL_PROG inspect-internal dump-tree -t raid_stripe $SCRATCH_DEV_POOL |\ + _filter_btrfs_version | _filter_stripe_tree + + _scratch_dev_pool_put +} +echo "= Test 4k write to an empty file at offset 64k with one stripe prefilled =" +test_4k_write_64koff raid0 2 +test_4k_write_64koff raid1 2 +test_4k_write_64koff raid10 4 + +# success, all done +status=0 +exit diff --git a/tests/btrfs/306.out b/tests/btrfs/306.out new file mode 100644 index 000000000000..8031cddb79f7 --- /dev/null +++ b/tests/btrfs/306.out @@ -0,0 +1,75 @@ +QA output created by 306 += Test 4k write to an empty file at offset 64k with one stripe prefilled = +==== Testing raid0 ==== +wrote 65536/65536 bytes at offset 0 +XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +wrote 4096/4096 bytes at offset 65536 +XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +381b0e7d72cb4f75286fe2b445e8d92a SCRATCH_MNT/foo + +raid stripe tree key (RAID_STRIPE_TREE ROOT_ITEM 0) +leaf XXXXXXXXX items X free space XXXXX generation X owner RAID_STRIPE_TREE +leaf XXXXXXXXX flags 0x1(WRITTEN) backref revision 1 +checksum stored +checksum calced +fs uuid +chunk uuid + item 0 key (XXXXXX RAID_STRIPE 65536) itemoff XXXXX itemsize 24 + encoding: RAID0 + stripe 0 devid 1 physical XXXXXXXXX + item 1 key (XXXXXX RAID_STRIPE 4096) itemoff XXXXX itemsize 24 + encoding: RAID0 + stripe 0 devid 2 physical XXXXXXXXX +total bytes XXXXXXXX +bytes used XXXXXX +uuid +==== Testing raid1 ==== +wrote 65536/65536 bytes at offset 0 +XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +wrote 4096/4096 bytes at offset 65536 +XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +381b0e7d72cb4f75286fe2b445e8d92a SCRATCH_MNT/foo + +raid stripe tree key (RAID_STRIPE_TREE ROOT_ITEM 0) +leaf XXXXXXXXX items X free space XXXXX generation X owner RAID_STRIPE_TREE +leaf XXXXXXXXX flags 0x1(WRITTEN) backref revision 1 +checksum stored +checksum calced +fs uuid +chunk uuid + item 0 key (XXXXXX RAID_STRIPE 65536) itemoff XXXXX itemsize 40 + encoding: RAID1 + stripe 0 devid 1 physical XXXXXXXXX + stripe 1 devid 2 physical XXXXXXXXX + item 1 key (XXXXXX RAID_STRIPE 4096) itemoff XXXXX itemsize 40 + encoding: RAID1 + stripe 0 devid 1 physical XXXXXXXXX + stripe 1 devid 2 physical XXXXXXXXX +total bytes XXXXXXXX +bytes used XXXXXX +uuid +==== Testing raid10 ==== +wrote 65536/65536 bytes at offset 0 +XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +wrote 4096/4096 bytes at offset 65536 +XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +381b0e7d72cb4f75286fe2b445e8d92a SCRATCH_MNT/foo + +raid stripe tree key (RAID_STRIPE_TREE ROOT_ITEM 0) +leaf XXXXXXXXX items X free space XXXXX generation X owner RAID_STRIPE_TREE +leaf XXXXXXXXX flags 0x1(WRITTEN) backref revision 1 +checksum stored +checksum calced +fs uuid +chunk uuid + item 0 key (XXXXXX RAID_STRIPE 65536) itemoff XXXXX itemsize 40 + encoding: RAID10 + stripe 0 devid 1 physical XXXXXXXXX + stripe 1 devid 2 physical XXXXXXXXX + item 1 key (XXXXXX RAID_STRIPE 4096) itemoff XXXXX itemsize 40 + encoding: RAID10 + stripe 0 devid 3 physical XXXXXXXXX + stripe 1 devid 4 physical XXXXXXXXX +total bytes XXXXXXXX +bytes used XXXXXX +uuid From patchwork Wed Dec 6 10:56:19 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Johannes Thumshirn X-Patchwork-Id: 13481510 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=wdc.com header.i=@wdc.com header.b="Munk1oUv" Received: from esa3.hgst.iphmx.com (esa3.hgst.iphmx.com [216.71.153.141]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B74CD12F; Wed, 6 Dec 2023 02:56:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=wdc.com; i=@wdc.com; q=dns/txt; s=dkim.wdc.com; t=1701860187; x=1733396187; h=from:date:subject:mime-version:content-transfer-encoding: message-id:references:in-reply-to:to:cc; bh=9wWvYkB/5YHkv9U4ir8NMxm7Z2FqMmh8mmA7ZwQF7x0=; b=Munk1oUvIMHoepFYASAFyEkL05hCDfwXjaV8IBJhxGsxtZq3seoG9cLm I1Xz48Y38rtIyOxuGuF9Lnsp0WFmyb+9sPr+AV4eE1aKDTLVEjMt0/lPa NhGRuj/Jff33t5x0A+HnFnymo2f3xRIreN4NWY/hVlMQk1Mlen9YlyzY3 hWbkqBFmbMf11K710S4SL2/Yk4a57ZntxUZUb1W2el+bN787wCeXsrwOa 1KJ6NmKZlqZGE3Qmk7Fmk1vsuD1G7jivLDvCf5phulsMHO2TeJUdWHo1F DjKKudu39nu+nOnOtw7cEf9B3p65vhvo74mZP1JOMIdL/NaUC3uVsvY1b w==; X-CSE-ConnectionGUID: +EYAZaAlSkmS3ddctMK6MA== X-CSE-MsgGUID: K7CTCo0zQJOXwEI4mBvAmA== X-IronPort-AV: E=Sophos;i="6.04,255,1695657600"; d="scan'208";a="4119720" Received: from h199-255-45-14.hgst.com (HELO uls-op-cesaep01.wdc.com) ([199.255.45.14]) by ob1.hgst.iphmx.com with ESMTP; 06 Dec 2023 18:56:27 +0800 IronPort-SDR: FpyHsk3axlLi18pa2F7swZOiitsDdGXcIbBujZbYu3JKMNpCltUN/+U7+FYO5sO9irFye7bYIO XWLs7b5dYdQw== Received: from uls-op-cesaip02.wdc.com ([10.248.3.37]) by uls-op-cesaep01.wdc.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 06 Dec 2023 02:07:28 -0800 IronPort-SDR: v8pXWiP2ycyemhTTwqKxAZ9oLxzgCr47xuqNuLkmDalJt6ZeYb48Lm/pTH8QmnS9GDMi84SQQI Mnr6oaK5HNfw== WDCIronportException: Internal Received: from unknown (HELO redsun91.ssa.fujisawa.hgst.com) ([10.149.66.6]) by uls-op-cesaip02.wdc.com with ESMTP; 06 Dec 2023 02:56:26 -0800 From: Johannes Thumshirn Date: Wed, 06 Dec 2023 02:56:19 -0800 Subject: [PATCH v4 7/8] btrfs: add fstests to write 128k to a RST filesystem Precedence: bulk X-Mailing-List: linux-btrfs@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20231206-btrfs-raid-v4-7-578284dd3a70@wdc.com> References: <20231206-btrfs-raid-v4-0-578284dd3a70@wdc.com> In-Reply-To: <20231206-btrfs-raid-v4-0-578284dd3a70@wdc.com> To: Anand Jain , Zorro Lang Cc: Filipe Manana , fstests@vger.kernel.org, linux-btrfs@vger.kernel.org, Johannes Thumshirn X-Mailer: b4 0.12.3 X-Developer-Signature: v=1; a=ed25519-sha256; t=1701860179; l=4520; i=johannes.thumshirn@wdc.com; s=20230613; h=from:subject:message-id; bh=9wWvYkB/5YHkv9U4ir8NMxm7Z2FqMmh8mmA7ZwQF7x0=; b=YcbH6Tg9yIqFg1/0EqpJZKGexdoGmr6IwQOQF2ZoC9d/z4vR0omZ/V7dhXCm28mu30JddupHK UjsolomYK2FAr+GQJIYIbu/f3vtaS490fVuyuwBugVHMbH+P+ABZSnU X-Developer-Key: i=johannes.thumshirn@wdc.com; a=ed25519; pk=TGmHKs78FdPi+QhrViEvjKIGwReUGCfa+3LEnGoR2KM= Add a test writing 128k to a file on an empty filesystem formatted with a raid-stripe-tree. Signed-off-by: Johannes Thumshirn --- tests/btrfs/307 | 55 +++++++++++++++++++++++++++++++++++++++++++++ tests/btrfs/307.out | 65 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 120 insertions(+) diff --git a/tests/btrfs/307 b/tests/btrfs/307 new file mode 100755 index 000000000000..fcca446f0ff7 --- /dev/null +++ b/tests/btrfs/307 @@ -0,0 +1,55 @@ +#! /bin/bash +# SPDX-License-Identifier: GPL-2.0 +# Copyright (c) 2023 Western Digital Cooperation. All Rights Reserved. +# +# FS QA Test 307 +# +# Test on-disk layout of RAID Stripe Tree Metadata by writing 128k to a new +# file on a pristine filesystem +# +. ./common/preamble +_begin_fstest auto quick raid remount volume raid-stripe-tree + +. ./common/filter +. ./common/filter.btrfs + +_supported_fs btrfs +_require_btrfs_command inspect-internal dump-tree +_require_btrfs_mkfs_feature "raid-stripe-tree" +_require_scratch_dev_pool 4 +_require_btrfs_fs_feature "raid_stripe_tree" +_require_btrfs_fs_feature "free_space_tree" +_require_btrfs_no_compress + +test_128k_write() +{ + local profile=$1 + local ndevs=$2 + + _scratch_dev_pool_get $ndevs + + echo "==== Testing $profile ====" + _scratch_pool_mkfs -d $profile -m $profile -O raid-stripe-tree + _scratch_mount + + $XFS_IO_PROG -fc "pwrite 0 128k" "$SCRATCH_MNT/foo" | _filter_xfs_io + + _scratch_cycle_mount + md5sum "$SCRATCH_MNT/foo" | _filter_scratch + + _scratch_unmount + + $BTRFS_UTIL_PROG inspect-internal dump-tree -t raid_stripe $SCRATCH_DEV_POOL |\ + _filter_btrfs_version | _filter_stripe_tree + + _scratch_dev_pool_put +} + +echo "= Test 128k write to empty file =" +test_128k_write raid0 2 +test_128k_write raid1 2 +test_128k_write raid10 4 + +# success, all done +status=0 +exit diff --git a/tests/btrfs/307.out b/tests/btrfs/307.out new file mode 100644 index 000000000000..b39f3162bff6 --- /dev/null +++ b/tests/btrfs/307.out @@ -0,0 +1,65 @@ +QA output created by 307 += Test 128k write to empty file = +==== Testing raid0 ==== +wrote 131072/131072 bytes at offset 0 +XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +d48858312a922db7eb86377f638dbc9f SCRATCH_MNT/foo + +raid stripe tree key (RAID_STRIPE_TREE ROOT_ITEM 0) +leaf XXXXXXXXX items X free space XXXXX generation X owner RAID_STRIPE_TREE +leaf XXXXXXXXX flags 0x1(WRITTEN) backref revision 1 +checksum stored +checksum calced +fs uuid +chunk uuid + item 0 key (XXXXXX RAID_STRIPE 65536) itemoff XXXXX itemsize 24 + encoding: RAID0 + stripe 0 devid 1 physical XXXXXXXXX + item 1 key (XXXXXX RAID_STRIPE 65536) itemoff XXXXX itemsize 24 + encoding: RAID0 + stripe 0 devid 2 physical XXXXXXXXX +total bytes XXXXXXXX +bytes used XXXXXX +uuid +==== Testing raid1 ==== +wrote 131072/131072 bytes at offset 0 +XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +d48858312a922db7eb86377f638dbc9f SCRATCH_MNT/foo + +raid stripe tree key (RAID_STRIPE_TREE ROOT_ITEM 0) +leaf XXXXXXXXX items X free space XXXXX generation X owner RAID_STRIPE_TREE +leaf XXXXXXXXX flags 0x1(WRITTEN) backref revision 1 +checksum stored +checksum calced +fs uuid +chunk uuid + item 0 key (XXXXXX RAID_STRIPE 131072) itemoff XXXXX itemsize 40 + encoding: RAID1 + stripe 0 devid 1 physical XXXXXXXXX + stripe 1 devid 2 physical XXXXXXXXX +total bytes XXXXXXXX +bytes used XXXXXX +uuid +==== Testing raid10 ==== +wrote 131072/131072 bytes at offset 0 +XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +d48858312a922db7eb86377f638dbc9f SCRATCH_MNT/foo + +raid stripe tree key (RAID_STRIPE_TREE ROOT_ITEM 0) +leaf XXXXXXXXX items X free space XXXXX generation X owner RAID_STRIPE_TREE +leaf XXXXXXXXX flags 0x1(WRITTEN) backref revision 1 +checksum stored +checksum calced +fs uuid +chunk uuid + item 0 key (XXXXXX RAID_STRIPE 65536) itemoff XXXXX itemsize 40 + encoding: RAID10 + stripe 0 devid 1 physical XXXXXXXXX + stripe 1 devid 2 physical XXXXXXXXX + item 1 key (XXXXXX RAID_STRIPE 65536) itemoff XXXXX itemsize 40 + encoding: RAID10 + stripe 0 devid 3 physical XXXXXXXXX + stripe 1 devid 4 physical XXXXXXXXX +total bytes XXXXXXXX +bytes used XXXXXX +uuid From patchwork Wed Dec 6 10:56:20 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Johannes Thumshirn X-Patchwork-Id: 13481511 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=wdc.com header.i=@wdc.com header.b="CFAP7ONl" Received: from esa3.hgst.iphmx.com (esa3.hgst.iphmx.com [216.71.153.141]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A2D9812B; Wed, 6 Dec 2023 02:56:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=wdc.com; i=@wdc.com; q=dns/txt; s=dkim.wdc.com; t=1701860188; x=1733396188; h=from:date:subject:mime-version:content-transfer-encoding: message-id:references:in-reply-to:to:cc; bh=MJZC83rDWYcbfUlPKVg8Wc0vqsaklNBLXvL1F+kDsIs=; b=CFAP7ONloMqydYSDctTUU/bJQsMvVbDxW2SeHTQtuoXe/LwiQp3o2qOq C48GVLmLW+OA1rXfn7CvqBI2808KZl9mU1kG7S3W4DvYB/+WOhjOkutF8 hAkw4KBK7I6ENLHFzHcVIuDHn98nP5P7fpVMCG+LbKBjQgN+d3B7uTF85 0dTc0L8y7aKXW+aUYjMvv3XZCZWsD6AihWN69EevvetcRG2td8DREVQif TeXVgG6dMeCin3l6QewoCGHuGKc+gSJStgQgCs08nreY1Nbg8Y+YUQxHs JQIqjCuyItOipdx+ES32yLm47eAGbxTLAVMy9L4HUX7Q+/1dOgzjD9aMO w==; X-CSE-ConnectionGUID: 903NSeM6SueSJiMRDOMG+g== X-CSE-MsgGUID: rUH+h8C5QFiShHShFZ0LRw== X-IronPort-AV: E=Sophos;i="6.04,255,1695657600"; d="scan'208";a="4119721" Received: from h199-255-45-14.hgst.com (HELO uls-op-cesaep01.wdc.com) ([199.255.45.14]) by ob1.hgst.iphmx.com with ESMTP; 06 Dec 2023 18:56:28 +0800 IronPort-SDR: y9WRCkjOMJ2P3vGj5spGskUzqr7mIsU7CTQkW7cCjuyjcGRtJsDPtLRvr/OMoYympLIted4NeZ unUcd3AQTToQ== Received: from uls-op-cesaip02.wdc.com ([10.248.3.37]) by uls-op-cesaep01.wdc.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 06 Dec 2023 02:07:29 -0800 IronPort-SDR: EVun0atj9iUgXPMPfl9ObG5qXG3Xh3B5+6bl7OcnYQVCeehV54Vx4ZZlKiV2wR2LaiROOnTQDw IhyMOSLQiyGg== WDCIronportException: Internal Received: from unknown (HELO redsun91.ssa.fujisawa.hgst.com) ([10.149.66.6]) by uls-op-cesaip02.wdc.com with ESMTP; 06 Dec 2023 02:56:27 -0800 From: Johannes Thumshirn Date: Wed, 06 Dec 2023 02:56:20 -0800 Subject: [PATCH v4 8/8] btrfs: add fstest for overwriting a file partially with RST Precedence: bulk X-Mailing-List: linux-btrfs@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20231206-btrfs-raid-v4-8-578284dd3a70@wdc.com> References: <20231206-btrfs-raid-v4-0-578284dd3a70@wdc.com> In-Reply-To: <20231206-btrfs-raid-v4-0-578284dd3a70@wdc.com> To: Anand Jain , Zorro Lang Cc: Filipe Manana , fstests@vger.kernel.org, linux-btrfs@vger.kernel.org, Johannes Thumshirn X-Mailer: b4 0.12.3 X-Developer-Signature: v=1; a=ed25519-sha256; t=1701860179; l=6792; i=johannes.thumshirn@wdc.com; s=20230613; h=from:subject:message-id; bh=MJZC83rDWYcbfUlPKVg8Wc0vqsaklNBLXvL1F+kDsIs=; b=GuVSXJKMO5bN+hVMYj0/FdcQZyz4XmtzPp8j2kuuB4doRe2lBv7AnLfqaTmP1K94IWOnZUiQD YFY3Gyhu6EUAVQ7WUKTU1L8CIV/HLlyvWg8/fKLzfT7+jrxxucFJuwO X-Developer-Key: i=johannes.thumshirn@wdc.com; a=ed25519; pk=TGmHKs78FdPi+QhrViEvjKIGwReUGCfa+3LEnGoR2KM= Add a test writing 128k to an empty file with one stripe already pre-filled on-disk. Then overwrite a portion of the file in the middle. Signed-off-by: Johannes Thumshirn --- tests/btrfs/308 | 59 +++++++++++++++++++++++++++++ tests/btrfs/308.out | 106 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 165 insertions(+) diff --git a/tests/btrfs/308 b/tests/btrfs/308 new file mode 100755 index 000000000000..5f9cc183c5ec --- /dev/null +++ b/tests/btrfs/308 @@ -0,0 +1,59 @@ +#! /bin/bash +# SPDX-License-Identifier: GPL-2.0 +# Copyright (c) 2023 Western Digital Cooperation. All Rights Reserved. +# +# FS QA Test 308 +# +# Test on-disk layout of RAID Stripe Tree Metadata by writing 128k to an empty +# file on a filesystem that has one stripe already pre-filled. Afterwards +# overwrite a portion of the file. +# +. ./common/preamble +_begin_fstest auto quick raid remount volume raid-stripe-tree + +. ./common/filter +. ./common/filter.btrfs + +_supported_fs btrfs +_require_btrfs_command inspect-internal dump-tree +_require_btrfs_mkfs_feature "raid-stripe-tree" +_require_scratch_dev_pool 4 +_require_btrfs_fs_feature "raid_stripe_tree" +_require_btrfs_fs_feature "free_space_tree" +_require_btrfs_no_compress +_require_btrfs_no_nodatacow + +test_128k_write_overwrite() +{ + local profile=$1 + local ndevs=$2 + + _scratch_dev_pool_get $ndevs + + echo "==== Testing $profile ====" + _scratch_pool_mkfs -d $profile -m $profile -O raid-stripe-tree + _scratch_mount + + $XFS_IO_PROG -fc "pwrite -W 0 32k" "$SCRATCH_MNT/bar" | _filter_xfs_io + $XFS_IO_PROG -fc "pwrite -W 0 128k" "$SCRATCH_MNT/foo" | _filter_xfs_io + $XFS_IO_PROG -fc "pwrite -W 64k 8k" "$SCRATCH_MNT/foo" | _filter_xfs_io + + _scratch_cycle_mount + md5sum "$SCRATCH_MNT/foo" | _filter_scratch + + _scratch_unmount + + $BTRFS_UTIL_PROG inspect-internal dump-tree -t raid_stripe $SCRATCH_DEV_POOL |\ + _filter_btrfs_version | _filter_stripe_tree + + _scratch_dev_pool_put +} + +echo "= Test 128k write to empty file with 1st stripe partially prefilled then overwrite =" +test_128k_write_overwrite raid0 2 +test_128k_write_overwrite raid1 2 +test_128k_write_overwrite raid10 4 + +# success, all done +status=0 +exit diff --git a/tests/btrfs/308.out b/tests/btrfs/308.out new file mode 100644 index 000000000000..c93a3a43b248 --- /dev/null +++ b/tests/btrfs/308.out @@ -0,0 +1,106 @@ +QA output created by 308 += Test 128k write to empty file with 1st stripe partially prefilled then overwrite = +==== Testing raid0 ==== +wrote 32768/32768 bytes at offset 0 +XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +wrote 131072/131072 bytes at offset 0 +XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +wrote 8192/8192 bytes at offset 65536 +XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +d48858312a922db7eb86377f638dbc9f SCRATCH_MNT/foo + +raid stripe tree key (RAID_STRIPE_TREE ROOT_ITEM 0) +leaf XXXXXXXXX items X free space XXXXX generation X owner RAID_STRIPE_TREE +leaf XXXXXXXXX flags 0x1(WRITTEN) backref revision 1 +checksum stored +checksum calced +fs uuid +chunk uuid + item 0 key (XXXXXX RAID_STRIPE 32768) itemoff XXXXX itemsize 24 + encoding: RAID0 + stripe 0 devid 1 physical XXXXXXXXX + item 1 key (XXXXXX RAID_STRIPE 32768) itemoff XXXXX itemsize 24 + encoding: RAID0 + stripe 0 devid 1 physical XXXXXXXXX + item 2 key (XXXXXX RAID_STRIPE 65536) itemoff XXXXX itemsize 24 + encoding: RAID0 + stripe 0 devid 2 physical XXXXXXXXX + item 3 key (XXXXXX RAID_STRIPE 32768) itemoff XXXXX itemsize 24 + encoding: RAID0 + stripe 0 devid 1 physical XXXXXXXXX + item 4 key (XXXXXX RAID_STRIPE 8192) itemoff XXXXX itemsize 24 + encoding: RAID0 + stripe 0 devid 1 physical XXXXXXXXX +total bytes XXXXXXXX +bytes used XXXXXX +uuid +==== Testing raid1 ==== +wrote 32768/32768 bytes at offset 0 +XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +wrote 131072/131072 bytes at offset 0 +XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +wrote 8192/8192 bytes at offset 65536 +XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +d48858312a922db7eb86377f638dbc9f SCRATCH_MNT/foo + +raid stripe tree key (RAID_STRIPE_TREE ROOT_ITEM 0) +leaf XXXXXXXXX items X free space XXXXX generation X owner RAID_STRIPE_TREE +leaf XXXXXXXXX flags 0x1(WRITTEN) backref revision 1 +checksum stored +checksum calced +fs uuid +chunk uuid + item 0 key (XXXXXX RAID_STRIPE 32768) itemoff XXXXX itemsize 40 + encoding: RAID1 + stripe 0 devid 1 physical XXXXXXXXX + stripe 1 devid 2 physical XXXXXXXXX + item 1 key (XXXXXX RAID_STRIPE 131072) itemoff XXXXX itemsize 40 + encoding: RAID1 + stripe 0 devid 1 physical XXXXXXXXX + stripe 1 devid 2 physical XXXXXXXXX + item 2 key (XXXXXX RAID_STRIPE 8192) itemoff XXXXX itemsize 40 + encoding: RAID1 + stripe 0 devid 1 physical XXXXXXXXX + stripe 1 devid 2 physical XXXXXXXXX +total bytes XXXXXXXX +bytes used XXXXXX +uuid +==== Testing raid10 ==== +wrote 32768/32768 bytes at offset 0 +XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +wrote 131072/131072 bytes at offset 0 +XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +wrote 8192/8192 bytes at offset 65536 +XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec) +d48858312a922db7eb86377f638dbc9f SCRATCH_MNT/foo + +raid stripe tree key (RAID_STRIPE_TREE ROOT_ITEM 0) +leaf XXXXXXXXX items X free space XXXXX generation X owner RAID_STRIPE_TREE +leaf XXXXXXXXX flags 0x1(WRITTEN) backref revision 1 +checksum stored +checksum calced +fs uuid +chunk uuid + item 0 key (XXXXXX RAID_STRIPE 32768) itemoff XXXXX itemsize 40 + encoding: RAID10 + stripe 0 devid 1 physical XXXXXXXXX + stripe 1 devid 2 physical XXXXXXXXX + item 1 key (XXXXXX RAID_STRIPE 32768) itemoff XXXXX itemsize 40 + encoding: RAID10 + stripe 0 devid 1 physical XXXXXXXXX + stripe 1 devid 2 physical XXXXXXXXX + item 2 key (XXXXXX RAID_STRIPE 65536) itemoff XXXXX itemsize 40 + encoding: RAID10 + stripe 0 devid 3 physical XXXXXXXXX + stripe 1 devid 4 physical XXXXXXXXX + item 3 key (XXXXXX RAID_STRIPE 32768) itemoff XXXXX itemsize 40 + encoding: RAID10 + stripe 0 devid 1 physical XXXXXXXXX + stripe 1 devid 2 physical XXXXXXXXX + item 4 key (XXXXXX RAID_STRIPE 8192) itemoff XXXXX itemsize 40 + encoding: RAID10 + stripe 0 devid 1 physical XXXXXXXXX + stripe 1 devid 2 physical XXXXXXXXX +total bytes XXXXXXXX +bytes used XXXXXX +uuid