From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.8 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id DAE85C4338F for ; Sun, 8 Aug 2021 00:25:36 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id A8F0361058 for ; Sun, 8 Aug 2021 00:25:36 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229865AbhHHAZx (ORCPT ); Sat, 7 Aug 2021 20:25:53 -0400 Received: from tartarus.angband.pl ([51.83.246.204]:47832 "EHLO tartarus.angband.pl" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229826AbhHHAZx (ORCPT ); Sat, 7 Aug 2021 20:25:53 -0400 X-Greylist: delayed 1500 seconds by postgrey-1.27 at vger.kernel.org; Sat, 07 Aug 2021 20:25:52 EDT Received: from kilobyte by tartarus.angband.pl with local (Exim 4.94.2) (envelope-from ) id 1mCWCt-002MnW-UK; Sun, 08 Aug 2021 01:58:23 +0200 Date: Sun, 8 Aug 2021 01:58:23 +0200 From: Adam Borowski To: Dave T Cc: Btrfs BTRFS , Phillip Susi Subject: Re: why is the same mount point repeatedly mounted in nested manner? Message-ID: References: <87eeb7pysj.fsf@vps.thesusis.net> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: X-Junkbait: aaron@angband.pl, zzyx@angband.pl X-SA-Exim-Connect-IP: X-SA-Exim-Mail-From: kilobyte@angband.pl X-SA-Exim-Scanned: No (on tartarus.angband.pl); SAEximRunCond expanded to false Precedence: bulk List-ID: X-Mailing-List: linux-btrfs@vger.kernel.org On Thu, Aug 05, 2021 at 04:41:03PM -0400, Dave T wrote: > On Thu, Aug 5, 2021 at 1:49 PM Phillip Susi wrote: > > Dave T writes: > > > > > I'm using btrbk via a systemd timer. I have a daily and hourly timer > > > set up. Each timer starts by mounting the btrfs root, performing the > > > btrbk task, and unmounting the btrfs root. > Not exactly... that path should not be unmounted. I do not mount that > location explicitly for the btrbk tasks. It is mounted when the server > boots up with the bind mount line I showed in fstab: > > /var/cache/pacman /srv/nfs/var/cache/pacman none bind 0 0 > > It should not be unmounted (or remounted) just because the top level > btrfs volume is (un)mounted for btrbk tasks. That's the part that is > confusing me. > > There is no command associated with my btrbk tasks that mounts > /srv/nfs/var/cache/pacman (or /var/cache/pacman). There's no other > entry in fstab for it except the bind mount I showed. I've seen systemd randomly mount and/or unmount filesystems listed in fstab when their state somehow differs from what systemd thinks should be (which can happen either by you or a program doing a mount, or due to systemd misreading the state reported by the kernel). So I wonder, can you test with an init/rc other than systemd? Meow! -- ⢀⣴⠾⠻⢶⣦⠀ ⣾⠁⢠⠒⠀⣿⡁ If you ponder doing what Jesus did, remember than flipping tables ⢿⡄⠘⠷⠚⠋⠀ and chasing people with a whip is a prime choice. ⠈⠳⣄⠀⠀⠀⠀