From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-pl1-f173.google.com (mail-pl1-f173.google.com [209.85.214.173]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 0893A2E62A9 for ; Wed, 19 Nov 2025 05:28:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.214.173 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1763530098; cv=none; b=SAAyhUM6Ada3wOU+PWhy54UcvkHq3eS7Zbcp6WKEX29DSBg7tVcPExH1bKGS6TGCLYNbhy1AKsVAI09lYhnu0CNZ4arswAgp/GAGEyOsO7CVKEj4J2NFO6ihL1Yk0Bd5bskWKglJUu0NWawu1B0745aW0C2I2fcxT4paQaHTie4= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1763530098; c=relaxed/simple; bh=hJO6m9RjbVYHsCF61QaRvX1qqaaK0NRgDI2oFuZmaag=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=HpzxWUNMCqQbW/meHaGgtTVD6gFU1klMo/qOzqB+g0234FwKqVPPpVIJlJ0jnXrRrwH1lOp18CeQ+YyXiIsDWcpTtuvq9XrirOD//1yE2yEjZiaWhcAb9DrqC7xhwS6FeGaZ53QhH5oTmZZ6c5Bbg9JnfetVTPOnLtqvSEX2Vqg= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=iBK4qS2f; arc=none smtp.client-ip=209.85.214.173 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="iBK4qS2f" Received: by mail-pl1-f173.google.com with SMTP id d9443c01a7336-2984dfae0acso86110915ad.0 for ; Tue, 18 Nov 2025 21:28:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1763530096; x=1764134896; darn=vger.kernel.org; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date:from:to :cc:subject:date:message-id:reply-to; bh=Q/moTquEdLk1bVa6y386cGDn3Tz+QN3S+IIzvr7irM4=; b=iBK4qS2fm6DblOHt7hJ/a1FEEYH3CGQbOFxzjcAdonWJVofMuraNid0TiRr78lMqCE wLPPOSylQnEJQmCBvks8ssxtv69Bboi0FEW0znyx/IusMYabAs74jSCIc43l5Xgjffz7 XsDiD4MGIcUrNUiZjYv/zYTuXmjoY0ppbP1cEDdNzU2yHTbZYegtjshQq4vn0ArZGKba NH9VQdxym1EDJOOKIN6NWxRPuJZlmDVjfo9BfSeLCmN7vYUD0qAJ2+/VdPPiGHnYehlM ltpWDnXRjchlMwvZkGrB0fsn4N3bh2WYpgfCTjVLExCyigFZavtHh1tsfx8axlBFT0Kt LvZg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763530096; x=1764134896; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=Q/moTquEdLk1bVa6y386cGDn3Tz+QN3S+IIzvr7irM4=; b=TDHConZXRaxDifLF0uU6ywDAdmnIuYIbieAeFH5I2cC/qwgAsXOREJHgo2MpK/EwpL I+hGdcfCEnFiGp0p6CS+fqXu7KE22ceoAfEKfx0emIcfO+V6iMs3kmr6PMP6qHnS2M7i ypbVIBaFlJQlSN2wx0KkznFmdu5gGt0OfiVY/NU8kK2wgugBlspl/Dd+/bGPDoKsmx60 SDBp1CvlC5xFd27eQKQBxnvneJy0mcrgkRMbysQogBAsmFKxgTWWxPifaUf3FuWt0soo QR6uXEjuv/yXGK7WrwlUCQIJF5gispvQlbMbFRm7d3A5SSVtzjf2wR3tY22ew54J0Txl z5xw== X-Gm-Message-State: AOJu0YzKaI/XvpxdWaMddxXTm/CdhBIp/Faxwnwz4rvgH3WMVS8NXVMy uF9d8SOQu2yVV1XklVkRuqdlPNck6nd3t/65NVzUmwmCpbUNVIPg61mC X-Gm-Gg: ASbGncsP+EbtCxgg2uTfLRdoUoUohOwsUikUY6C9etIxwt6r2ILdwhVAHL5cgqIdl3v GnSSebt0Bz+80uUV1lKxypxPIhSPWX1FvalABxDZk+T7YVZ/wlwVMhHIoXtqHGUz/y7fmpVhSly REhs3+bMts8mPgpZ7rMJ5u+pY52fktR7INKD7ZaAe6xtcCdft9nXqgb6Sey+flLeQhaUw0kOkW/ wYsAPJwYjH7LdM7rqa2ATRrujuIBkZmocaii8OdhZbviKZegd2VZ4meukjN9DL2ueEcYQykztKt GnpHnnLt2r0BMTPsnjiEf7qx0rhpyTkQi2bbl/gF61ykmWrrG9yPWpnE+IWU07l4zgYMhP6aSdD 927zvjTN3nwlNF5JJb9U1HQv8FK8DFQY4fn+Wo5cYZS4bSRvQIB9XDaijcP3izZMzrtHxjKNYcl +G76pZ X-Google-Smtp-Source: AGHT+IGn6aUPitlZ+ZQfy3JAGpYrp4d9qXro/j7LocAsUSdmXLEukjfCy/tH2vvyTAILz1OIzJbcIQ== X-Received: by 2002:a17:902:ccc7:b0:295:888e:d204 with SMTP id d9443c01a7336-2986a76b5dbmr227495715ad.57.1763530096234; Tue, 18 Nov 2025 21:28:16 -0800 (PST) Received: from sidong ([175.195.128.78]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-2985c2c16a1sm192519875ad.95.2025.11.18.21.28.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 18 Nov 2025 21:28:15 -0800 (PST) Date: Wed, 19 Nov 2025 05:28:04 +0000 From: Sidong Yang To: Qu Wenruo Cc: fstests@vger.kernel.org, linux-btrfs@vger.kernel.org Subject: Re: [PATCH 1/1] btrfs/339: test receive dump stream for different user Message-ID: References: <20251119024034.23861-1-realwakka@gmail.com> Precedence: bulk X-Mailing-List: fstests@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: On Wed, Nov 19, 2025 at 02:05:57PM +1030, Qu Wenruo wrote: > > > 在 2025/11/19 13:10, Sidong Yang 写道: > > Test receive to dump stream file from different user. > > > > This is a regression test for the btrfs-progs commit cd933616d485 > > ("btrfs-progs: receive: don't use O_NOATIME to open stream for > > dumping"). > > > > Signed-off-by: Sidong Yang > > --- > > tests/btrfs/339 | 32 ++++++++++++++++++++++++++++++++ > > tests/btrfs/339.out | 2 ++ > > 2 files changed, 34 insertions(+) > > create mode 100755 tests/btrfs/339 > > create mode 100644 tests/btrfs/339.out > > > > diff --git a/tests/btrfs/339 b/tests/btrfs/339 > > new file mode 100755 > > index 00000000..728f3d9d > > --- /dev/null > > +++ b/tests/btrfs/339 > > @@ -0,0 +1,32 @@ > > +#! /bin/bash > > +# SPDX-License-Identifier: GPL-2.0 > > +# Copyright (c) 2025 Sidong Yang. All Rights Reserved. > > +# > > +# FS QA Test 339 > > +# > > +# Test btrfs receive dump stream from different user > > +# > > +. ./common/preamble > > +_begin_fstest auto quick send snapshot > > + > > +. ./common/filter > > +. ./common/quota > > + > > +_require_scratch > > +_require_user > > + > > +_fixed_by_git_commit btrfs-progs cd933616d485 \ > > + "btrfs-progs: receive: don't use O_NOATIME to open stream for dumping" > > + > > +_scratch_mkfs >> $seqres.full 2>&1 || _fail "mkfs failed" > > +_scratch_mount > > + > > +$BTRFS_UTIL_PROG -q subvolume snapshot -r $SCRATCH_MNT $SCRATCH_MNT/snap | _filter_scratch > > If you are using "-q" to suppress non-critical messages, you don't need to > do the _filter_scratch call. > > It's better just to redirect all output to seqres.full without "-q". Thanks, I'll use it. > > > +$BTRFS_UTIL_PROG -q send -f stream $SCRATCH_MNT/snap > > Furthermore, the stream file is at the current working directory, and if the > test case is interrupted before "rm stream" call, the file will be left > uncleaned. > > Please use $tmp or some location inside $TEST_DIR to store the send stream, > and have a proper cleanup function. $tmp would be good to use. Thanks, Sidong > > Thanks, > Qu > > > +chmod a+r stream > > +_su $qa_user -c "$BTRFS_UTIL_PROG receive --dump -f stream" >> $seqres.full > > +rm stream > > + > > +# success, all done > > +echo "Silence is golden" > > +_exit 0 > > diff --git a/tests/btrfs/339.out b/tests/btrfs/339.out > > new file mode 100644 > > index 00000000..293ea808 > > --- /dev/null > > +++ b/tests/btrfs/339.out > > @@ -0,0 +1,2 @@ > > +QA output created by 339 > > +Silence is golden >