From: Christoph Hellwig <hch@infradead.org>
To: Andi Drebes <lists-receive@programmierforen.de>
Cc: linux-btrfs@vger.kernel.org, Chris Mason <chris.mason@oracle.com>
Subject: Re: [PATCH] Prevent btrfsck to run on mounted filesystems
Date: Fri, 30 Oct 2009 01:02:44 -0400 [thread overview]
Message-ID: <20091030050243.GA17714@infradead.org> (raw)
In-Reply-To: <200910292152.15564.lists-receive@programmierforen.de>
On Thu, Oct 29, 2009 at 09:52:15PM +0100, Andi Drebes wrote:
> As recently discussed on the list, btrfsck should only be run on unmounted filesystems. This patch adds a short check for the mount status at the beginning of btrfsck. If the FS is mounted, the program aborts showing an error message.
Just open the nodes with O_EXCL and you'll get all the checking for
free. Also make sure that for a pure, read-only checks instead of a
repair to allow running on at least a read-only mounted filesystem.
next prev parent reply other threads:[~2009-10-30 5:02 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-10-29 20:52 [PATCH] Prevent btrfsck to run on mounted filesystems Andi Drebes
2009-10-30 5:02 ` Christoph Hellwig [this message]
2009-10-30 13:05 ` Chris Mason
2009-10-31 20:46 ` Andi Drebes
2009-11-09 14:59 ` Andi Drebes
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20091030050243.GA17714@infradead.org \
--to=hch@infradead.org \
--cc=chris.mason@oracle.com \
--cc=linux-btrfs@vger.kernel.org \
--cc=lists-receive@programmierforen.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox