Linux Btrfs filesystem development
 help / color / mirror / Atom feed
From: Andrei Borzenkov <arvidjaar@gmail.com>
To: Leszek Dubiel <leszek@dubiel.pl>,
	Btrfs BTRFS <linux-btrfs@vger.kernel.org>
Subject: Re: 97% full system, dusage didn't help, musage strange
Date: Sat, 4 Jan 2025 08:32:22 +0300	[thread overview]
Message-ID: <5d045808-1f34-4dd3-bb82-71da628ccaf6@gmail.com> (raw)
In-Reply-To: <000bcef0-a86e-4832-90bb-9a4a47afad6d@dubiel.pl>

04.01.2025 01:52, Leszek Dubiel wrote:
> 
> 
> 
> 
> 
> 
> 
> 
> 
> W dniu 16.12.2024 o 22:01, Qu Wenruo pisze:
> 
> 
> 
>   > If you want to be extra safe, the best solution is to use tools that
> can report the usage percentage of each block group.
>   >
>   > You need something procedure like this:
>   >
>   > start:
>   >     if (unallocated space >= 8GiB)
>   >         return;
>   > check_usage_percentage:
>   >     if (no block group has usage percentage < 30%) {
>   >         delete_files;
>   >         goto check_usage_percentage;
>   >     }
>   >     balance dusage=30
>   >     goto start;
>   >
>   > Although there are some concerns, firstly the tool, sorry I didn't
> remember the name but there is an out-of-btrfs-progs tool can do exactly
> that.
> 
> In btrfs-progs package I didn't find any such tool.
> 
> There is "btrfs maintenance" by kdave:
> 
>                        https://github.com/kdave/btrfsmaintenance
> 
> but it starts normal balance, it doesn't analize "block usage percentage".
> 

https://github.com/knorrie/btrfs-heatmap

https://github.com/knorrie/python-btrfs

The latter is general Python library to work with btrfs and various 
(sample) tools, like btrfs-balance-least-used or btrfs-usage-report.


  reply	other threads:[~2025-01-04  5:32 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-12-14 17:55 97% full system, dusage didn't help, musage strange Leszek Dubiel
2024-12-14 18:35 ` Roman Mamedov
2024-12-14 18:47 ` Andrei Borzenkov
2024-12-14 20:13   ` Leszek Dubiel
2024-12-14 21:14     ` Qu Wenruo
2024-12-16 17:12       ` Leszek Dubiel
2024-12-16 21:01         ` Qu Wenruo
2024-12-17 21:44           ` Leszek Dubiel
2025-01-03 22:52           ` Leszek Dubiel
2025-01-04  5:32             ` Andrei Borzenkov [this message]
2025-01-04  7:11               ` Leszek Dubiel

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=5d045808-1f34-4dd3-bb82-71da628ccaf6@gmail.com \
    --to=arvidjaar@gmail.com \
    --cc=leszek@dubiel.pl \
    --cc=linux-btrfs@vger.kernel.org \
    /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