From: Anand Jain <anand.jain@oracle.com>
To: Graham Cobb <g.btrfs@cobb.uk.net>, linux-btrfs@vger.kernel.org
Subject: Re: "btrfs: harden agaist duplicate fsid" spams syslog
Date: Thu, 11 Jul 2019 10:46:31 +0800 [thread overview]
Message-ID: <c01ab9f6-c553-3625-5656-a8f61659de7d@oracle.com> (raw)
In-Reply-To: <5d8baf80-4fb3-221f-5ab4-e98a838f63e1@cobb.uk.net>
Right. It happened even without this patch but we just know it now.
In the original investigations of the patch, the moment you copy a
device image into another device, the autoscan would scan the new
device into the btrfs kernel and created a mess. Now with this patch
we won't replace the device path unless it's the same device (and we
have to let that happen).
Now the question I am trying to understand, why same device is being
scanned every 2 mins, even though its already mount-ed. I am guessing
its toggling the same device paths trying to mount the device-path
which is not mounted. So autofs's check for the device mount seems to
be path based.
Would you please provide your LVM configs and I believe you are using
dm-mapping too. What are the device paths used in the fstab and in grub.
And do you see these messages for all devices of
4d1ba5af-8b89-4cb5-96c6-55d1f028a202 or just devid 4? Would you please
provide more logs at least a complete cycle of the repeating logs.
-Anand
On 11/7/19 2:49 AM, Graham Cobb wrote:
> Anand's Nov 2018 patch "btrfs: harden agaist duplicate fsid" has
> recently percolated through to my Debian buster server system.
>
> And it is spamming my log files.
>
> Each of my btrfs filesystem devices logs 4 messages every 2 minutes.
> Here is an example of the 4 messages related to one device:
>
> Jul 10 19:32:27 black kernel: [33017.407252] BTRFS info (device sdc3):
> device fsid 4d1ba5af-8b89-4cb5-96c6-55d1f028a202 devid 4 moved
> old:/dev/mapper/cryptdata4tb--vg-backup new:/dev/dm-13
> Jul 10 19:32:27 black kernel: [33017.522242] BTRFS info (device sdc3):
> device fsid 4d1ba5af-8b89-4cb5-96c6-55d1f028a202 devid 4 moved
> old:/dev/dm-13 new:/dev/mapper/cryptdata4tb--vg-backup
> Jul 10 19:32:29 black kernel: [33018.797161] BTRFS info (device sdc3):
> device fsid 4d1ba5af-8b89-4cb5-96c6-55d1f028a202 devid 4 moved
> old:/dev/mapper/cryptdata4tb--vg-backup new:/dev/dm-13
> Jul 10 19:32:29 black kernel: [33019.061631] BTRFS info (device sdc3):
> device fsid 4d1ba5af-8b89-4cb5-96c6-55d1f028a202 devid 4 moved
> old:/dev/dm-13 new:/dev/mapper/cryptdata4tb--vg-backup
>
> What is happening here is that each device is actually an LVM logical
> volume, and it is known by a /dev/mapper name and a /dev/dm name. And
> every 2 minutes something cause btrfs to notice that there are two names
> for the same device and it swaps them around. Logging a message to say
> it has done so. And doing it 4 times.
>
> I presume that the swapping doesn't cause any problem. I wonder slightly
> whether ordering guarantees and barriers all work correctly but I
> haven't noticed any problems.
>
> I also assume it has been doing this for a while -- just silently before
> this patch came along.
>
> Is btrfs noticing this itself or is something else (udev or systemd, for
> example) triggering it?
>
> Should I worry about it?
>
> Is there any way to not have my log files full of this?
>
> Graham
>
> [This started with a Debian testing kernel a couple of months ago.
> Current uname -a gives: Linux black 4.19.0-5-amd64 #1 SMP Debian
> 4.19.37-5 (2019-06-19) x86_64 GNU/Linux]
>
next prev parent reply other threads:[~2019-07-11 2:46 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-07-10 18:49 "btrfs: harden agaist duplicate fsid" spams syslog Graham Cobb
2019-07-11 2:46 ` Anand Jain [this message]
2019-07-11 18:00 ` Graham Cobb
2019-07-12 12:46 ` Anand Jain
2019-07-12 13:32 ` Graham Cobb
2019-07-19 15:38 ` David Sterba
2019-07-12 13:35 ` Patrik Lundquist
2019-07-12 13:41 ` Graham Cobb
2019-07-11 23:06 ` Christoph Anton Mitterer
2019-07-12 12:49 ` Anand Jain
2019-07-16 13:59 ` [PATCH] btrfs: ratelimit device path change info on mounted device Anand Jain
2019-07-16 14:08 ` Anand Jain
2019-07-19 14:58 ` 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=c01ab9f6-c553-3625-5656-a8f61659de7d@oracle.com \
--to=anand.jain@oracle.com \
--cc=g.btrfs@cobb.uk.net \
--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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.