From: Craig Andrews <candrews@integralblue.com>
To: Craig Andrews <candrews@integralblue.com>
Cc: linux-btrfs@vger.kernel.org
Subject: Re: Regression in Linux 5.5.0-rc[1-5]: btrfs send/receive out of memory
Date: Mon, 20 Jan 2020 21:18:50 -0500 [thread overview]
Message-ID: <7e7e4f63a89b6bb8a270d4c4ec676835@integralblue.com> (raw)
In-Reply-To: <20200113133741.GU3929@twin.jikos.cz>
[-- Attachment #1: Type: text/plain, Size: 1821 bytes --]
On 2020-01-13 08:37, David Sterba wrote:
> On Mon, Jan 13, 2020 at 07:41:13AM -0500, Craig Andrews wrote:
>> If I perform a btrfs send receive like so:
>>
>> sh -c btrfs send -p /mnt/everything/.snapshots/root.20191230
>> /mnt/everything/.snapshots/root.20191231 | btrfs receive
>> /mnt/backup/.snapshots/
>>
>> On Linux 5.4.0, the process completes successfully.
>>
>> Starting with Linux 5.5.0-rc1 up to the current 5.5 rc, 5.5.0-rc5, the
>> result is the OOM killer being invoked which (among other process
>> carnage) kills the btrfs processes stopping the backup.
>
> As this is on the -rc1, it's possible that changes done in the MM
> subsystem could change the logic of OOM and that send now is able to
> trigger the OOM.
>
> There are 2 btrfs patches in send.c but they reduce amount of work,
> namely for heavily reflinked extents so the effects should be opposite.
>
> To find out where's the cause, is it possible that you build a kernel
> from the 5.4-based branch and run the send again? It's the same set of
> btrfs patches that gets merged to 5.5.
>
> From repository:
> git://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux.git
> branch: for-5.5-rc4
>
> If this can't be done we'll find another way to debug it.
I finally was able to test with this kernel.
With the kernel compiled from the branch "for-5.5-rc4" I do not get the
out of memory error. However, I do this error:
btrfs send -p /mnt/everything/.snapshots/root.20200119
/mnt/everything/.snapshots/root.20200120 | mbuffer -v 1 | btrfs receive
/mnt/backup/.snapshots/
ERROR: failed to clone extents to var/amavis/db/__db.001: Invalid
argument
I rebooted then immediately ran the same command with the 5.4 kernel and
it completed successfully.
So I guess it's nice that I didn't get an out of memory error...
Thanks,
~Craig
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 195 bytes --]
next prev parent reply other threads:[~2020-01-21 2:18 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-01-13 12:41 Regression in Linux 5.5.0-rc[1-5]: btrfs send/receive out of memory Craig Andrews
2020-01-13 13:37 ` David Sterba
2020-01-13 14:48 ` Craig Andrews
2020-01-15 18:44 ` Craig Andrews
2020-01-21 2:18 ` Craig Andrews [this message]
2020-01-25 11:08 ` Stéphane Lesimple
2020-01-27 13:44 ` Filipe Manana
2020-01-27 20:08 ` Stéphane Lesimple
2020-01-28 14:46 ` Craig Andrews
2020-01-28 15:02 ` Filipe Manana
2020-01-28 15:05 ` Craig Andrews
2020-01-28 15:08 ` Filipe Manana
2020-01-28 17:33 ` Filipe Manana
2020-01-28 17:31 ` David Sterba
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=7e7e4f63a89b6bb8a270d4c4ec676835@integralblue.com \
--to=candrews@integralblue.com \
--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