From: Konstantinos Skarlatos <k.skarlatos@gmail.com>
To: Hugo Mills <hugo@carfax.org.uk>,
linux-btrfs@vger.kernel.org, ce3g8jdj@umail.furryterror.org
Subject: Re: Adding a 4TB disk to a 2x4TB btrfs (data:single) filesystem and balancing takes extremely long (over a month). Filesystem has been deduped with bees
Date: Sun, 3 Apr 2022 16:43:26 +0300 [thread overview]
Message-ID: <693e407b-9780-7afb-ad7f-d8d97cf9d65f@gmail.com> (raw)
In-Reply-To: <20220401131715.GL18319@savella.carfax.org.uk>
On 1/4/2022 4:17 μμ, Hugo Mills wrote:
> On Fri, Apr 01, 2022 at 02:13:58PM +0300, Konstantinos Skarlatos wrote:
>> Hello,
>> I am running btrfs on 2x 4TB HDDs (data: single, metadata: raid1) and i
>> added another 4TB disk.
>> According to btrfs wiki i should run balance after adding the new device.
>> My problem is that this balance takes extremely long, it is running for 4
>> days and it still has 91% left.
>> Is this normal, and can i do anything to fix this?
> It's not normal for it to take that long, no. Do you have lots of
> snapshots (like, thousands), and lots of small or heavily fragmented
> files?
Hi, sorry for missing your reply.
I only have 12 subvolumes and no snapshots. There are about 10 million
files in the filesystem.
>
> Is the balance actually progressing, or has it got stuck? Are there
> regular messages in dmesg about it balancing block groups? If not,
> when was the last one?
It is progressing without getting stuck, every few minutes (sometimes
sooner sometimes longer) a new block gets balanced
>
> If your data is single, it's not really necessary to do the balance
> anyway, so you may want to cancel it. The balance in this situation is
> more about ensuring that all the space on the new disk is usable by
> the higher RAID levels. For example, adding a single disk to a
> nearly-full RAID-1 without balancing would leave you in a state where
> you couldn't add more data chunks because there's only space on one
> disk to do so, and RAID-1 needs two disks with space to allocate a
> data chunk in. With single data, that's not a problem.
Thanks for the advice. I think this is something that should be better
documented as the official wiki says that this must be done after adding
a new disk
>
>> kernel is linux-5.17.1, i have also tried with 5.16 kernels.
>> mount options are: rw,relatime,compress-force=zstd:11,space_cache=v2
>> I have been using bees for dedup, but it is disabled for the balance.
>> I am not doing any IO on the disks, they have no smart errors, and none of
>> them are SMR (2x WD40EFRX and 1x ST4000DM000)
>> Autodefrag is disabled, and i also have checked that the disks are in stable
>> drive cages in order to be sure i have no problems with vibration.
>> Benchmarking them gives normal speeds. Quotas have never been enabled.
next prev parent reply other threads:[~2022-04-03 13:42 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-04-01 11:13 Adding a 4TB disk to a 2x4TB btrfs (data:single) filesystem and balancing takes extremely long (over a month). Filesystem has been deduped with bees Konstantinos Skarlatos
2022-04-01 13:17 ` Hugo Mills
2022-04-03 13:43 ` Konstantinos Skarlatos [this message]
2022-04-01 14:11 ` Zygo Blaxell
2022-04-02 18:27 ` Konstantinos Skarlatos
2022-04-02 23:16 ` Zygo Blaxell
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=693e407b-9780-7afb-ad7f-d8d97cf9d65f@gmail.com \
--to=k.skarlatos@gmail.com \
--cc=ce3g8jdj@umail.furryterror.org \
--cc=hugo@carfax.org.uk \
--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