From: Chris Mason <chris.mason@oracle.com>
To: Roland Dreier <rdreier@cisco.com>
Cc: jim owens <jowens@hp.com>, Josef Bacik <josef@redhat.com>,
linux-btrfs@vger.kernel.org
Subject: Re: UI issues around RAID1
Date: Thu, 19 Nov 2009 09:56:27 -0500 [thread overview]
Message-ID: <20091119145627.GK3110@think> (raw)
In-Reply-To: <adamy2jaf43.fsf@roland-alpha.cisco.com>
On Wed, Nov 18, 2009 at 09:59:24AM -0800, Roland Dreier wrote:
>
> > > Yeah df is just a fun ball of wax in many respects. We don't take into account
> > > RAID and we don't subtrace space thats strictly for metadata, so there are
> > > several things that need to be fixed for df. Thanks,
>
> > But as we have said many times... if we have different
> > raid types active on different files, any attempt to make
> > df report "raid adjusted numbers" instead of the current raw
> > total storage numbers is going to sometimes give wrong answers.
> >
> > So I think it is dangerous to try. The current output
> > may be ugly, but it is always consistent and explainable.
>
> It does seem like a big problem, especially as we add in other RAID
> levels etc. However on the flip side, the accounting of the "used"
> space does seem off and maybe fixable?
>
> In other words if I create a btrfs filesystem out of two 1GB devices
> with RAID1 for data and metadata, then df shows a total size of 2GB for
> the filesystem. But if I then create a .5 GB file on that filesystem,
> the used space is shown as .5 GB only -- ie the accounting of total size
> is at the device/block level, but the accounting of used space is at the
> logical/filesystem level. Which leads to very confusing df output.
>
> I wonder if it's possible to come up with a way to make things
> consistent at least, or figure out a way to define more useful
> information about space left on the filesystem.
That part we can at least do. Since we know the amount of space used in
each block group and the raid level of each block group, we can figure
it out. It won't be cheap overall but it is at least possible.
-chris
next prev parent reply other threads:[~2009-11-19 14:56 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-11-16 18:45 UI issues around RAID1 Roland Dreier
2009-11-16 20:20 ` Josef Bacik
2009-11-16 21:48 ` jim owens
[not found] ` <2a31deca0911170244m74478cefy2a3f5f7bc1daf476@mail.gmail.com>
2009-11-17 15:25 ` jim owens
2009-11-17 20:23 ` Andrey Kuzmin
2009-11-18 17:59 ` Roland Dreier
2009-11-19 14:56 ` Chris Mason [this message]
2009-11-18 17:54 ` Roland Dreier
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=20091119145627.GK3110@think \
--to=chris.mason@oracle.com \
--cc=josef@redhat.com \
--cc=jowens@hp.com \
--cc=linux-btrfs@vger.kernel.org \
--cc=rdreier@cisco.com \
/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