linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Hugo Mills <hugo@carfax.org.uk>
To: "Austin S. Hemmelgarn" <ahferroin7@gmail.com>
Cc: waxhead <waxhead@dirtcellar.net>,
	"Hérikz Nawarro" <herikz.nawarro@gmail.com>,
	linux-btrfs@vger.kernel.org
Subject: Re: btrfs raid assurance
Date: Wed, 26 Jul 2017 23:07:51 +0000	[thread overview]
Message-ID: <20170726230751.GS7140@carfax.org.uk> (raw)
In-Reply-To: <c9ec498e-05b3-7120-8042-f423fca0de92@gmail.com>

[-- Attachment #1: Type: text/plain, Size: 3384 bytes --]

On Wed, Jul 26, 2017 at 08:36:54AM -0400, Austin S. Hemmelgarn wrote:
> On 2017-07-26 08:27, Hugo Mills wrote:
> >On Wed, Jul 26, 2017 at 08:12:19AM -0400, Austin S. Hemmelgarn wrote:
> >>On 2017-07-25 17:45, Hugo Mills wrote:
> >>>On Tue, Jul 25, 2017 at 11:29:13PM +0200, waxhead wrote:
> >>>>
> >>>>
> >>>>Hugo Mills wrote:
> >>>>>
> >>>>>>>    You can see about the disk usage in different scenarios with the
> >>>>>>>online tool at:
> >>>>>>>
> >>>>>>>http://carfax.org.uk/btrfs-usage/
> >>>>>>>
> >>>>>>>    Hugo.
> >>>>>>>
> >>>>As a side note, have you ever considered making this online tool
> >>>>(that should never go away just for the record) part of btrfs-progs
> >>>>e.g. a proper tool? I use it quite often (at least several timers
> >>>>per. month) and I would love for this to be a visual tool
> >>>>'btrfs-space-calculator' would be a great name for it I think.
> >>>>
> >>>>Imagine how nice it would be to run....
> >>>>
> >>>>btrfs-space-calculator -mraid1 -draid10 /dev/sda1 /dev/sdb1
> >>>>/dev/sdc2 /dev/sdd2 /dev/sde3 for example and instantly get
> >>>>something similar to my example below (no accuracy intended)
> >>>
> >>>    It's certainly a thought. I've already got the algorithm written
> >>>up. I'd have to resurrect my C skills, though, and it's a long way
> >>>down my list of things to do. :/
> >>>
> >>>    Also on the subject of this tool, I'd like to make it so that the
> >>>parameters get set in the URL, so that people can copy-paste the URL
> >>>of the settings they've got into IRC for discussion. However, that
> >>>would involve doing more JavaScript, which is possibly even lower down
> >>>my list of things to do than starting doing C again...
> >
> >>Is the core logic posted somewhere?  Because if I have some time, I
> >>might write up a quick Python script to do this locally (it may not
> >>be as tightly integrated with the regular tools, but I can count on
> >>half a hand how many distros don't include Python by default).
> >
> >    If it's going to be done in python, I might as well do it myself --
> >I can do python with my eyes closed. It's just C and JS I'm rusty with.
> Same here ironically :)
> >
> >    There is a write-up of the usable-space algorithm somewhere. I
> >wrote it up in detail (with pseudocode) in a mail on this list. I've
> >also got several pages of LaTeX somewhere where I tried and failed to
> >prove the correctness of the formula. I'll see if I can dig them out
> >this evening.
> It looks like the Message-ID for the one on the mailing list is
> <20160311221703.GJ17196@carfax.org.uk>
> I had forgotten that I'd archived that with the intent of actually
> doing something with it eventually...

   Here's the write-up of my attempted proof of the optimality of the
current allocator algorithm:

http://carfax.org.uk/files/temp/btrfs-allocator-draft.pdf

   Section 1 is a general (allocator-agnostic) description of the
process. Section 2 finds a bound on how well _any_ allocator can
do. That's the formula (eq 9) used in the online btrfs-usage
tool. Section 3 described the current allocator. Section 4 is a failed
attempt at proving that the algorithm achieves the bound from section
2. I wasn't able to complete the proof.

   Hugo.

-- 
Hugo Mills             | Great films about cricket: Interview with the Umpire
hugo@... carfax.org.uk |
http://carfax.org.uk/  |
PGP: E2AB1DE4          |

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

      reply	other threads:[~2017-07-26 23:08 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-07-25 12:55 btrfs raid assurance Hérikz Nawarro
2017-07-25 13:16 ` Austin S. Hemmelgarn
2017-07-25 13:46 ` Hugo Mills
2017-07-25 13:50   ` Hérikz Nawarro
2017-07-25 13:51   ` Hugo Mills
2017-07-25 13:55     ` Hérikz Nawarro
2017-07-25 13:58       ` Hugo Mills
2017-07-25 21:29         ` waxhead
2017-07-25 21:45           ` Hugo Mills
2017-07-26 12:12             ` Austin S. Hemmelgarn
2017-07-26 12:27               ` Hugo Mills
2017-07-26 12:28                 ` Hugo Mills
2017-07-26 12:36                 ` Austin S. Hemmelgarn
2017-07-26 23:07                   ` Hugo Mills [this message]

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=20170726230751.GS7140@carfax.org.uk \
    --to=hugo@carfax.org.uk \
    --cc=ahferroin7@gmail.com \
    --cc=herikz.nawarro@gmail.com \
    --cc=linux-btrfs@vger.kernel.org \
    --cc=waxhead@dirtcellar.net \
    /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;
as well as URLs for NNTP newsgroup(s).