All of lore.kernel.org
 help / color / mirror / Atom feed
* Bug / Suspected regression. Multiple block group profiles detected on newly created raid1.
@ 2021-10-09 11:44 FireFish5000
  2021-10-09 12:19 ` Qu Wenruo
  0 siblings, 1 reply; 5+ messages in thread
From: FireFish5000 @ 2021-10-09 11:44 UTC (permalink / raw)
  To: linux-btrfs

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

After creating a new btrfs raid1 and was surprised to be greeted with
the warning

WARNING: Multiple block group profiles detected, see 'man btrfs(5)'.
WARNING:   Metadata: single, raid1

I asked on the IRC, and darkling directed me to the mailing list
suspecting this was a regression.
I am on 5.14.8-gentoo-dist with btrfs-progs v5.14.1

I have attached a script to reproduce this with temporary images/loop devices,
Along with the full output I received when running the script.

A shortened version of the commands that I ran on my *real drives* and
the relevant output is also provided below for convenience. P at the
end of the device path was inserted incase sleepy joe copies it
thinking its the reproduction script:

# mkfs.btrfs --force -R free-space-tree -L BtrfsRaid1Test -d raid1 -m
raid1 /dev/sdaP /dev/sdbP; mount /dev/sda /mnt/tmp; btrfs filesystem
df /mnt/tmp
btrfs-progs v5.14.1
....truncated....
....truncated....
Data, RAID1: total=1.00GiB, used=0.00B
System, RAID1: total=8.00MiB, used=16.00KiB
Metadata, RAID1: total=1.00GiB, used=176.00KiB
Metadata, single: total=8.00MiB, used=0.00B
GlobalReserve, single: total=3.25MiB, used=0.00B
WARNING: Multiple block group profiles detected, see 'man btrfs(5)'.
WARNING:   Metadata: single, raid1

[-- Attachment #2: btrfsRaid1Test.sh - output.txt --]
[-- Type: text/plain, Size: 2367 bytes --]

# Get System Info
uname -r
+ uname -r
5.14.8-gentoo-dist
btrfs version
+ btrfs version
btrfs-progs v5.14.1 

##########
# Create blank images
fallocate -l 2G /tmp/tmpImgA
+ fallocate -l 2G /tmp/tmpImgA
fallocate -l 2G /tmp/tmpImgB
+ fallocate -l 2G /tmp/tmpImgB

##########
# Prepare loopback devices
modprobe loop
+ modprobe loop
LOOP_A="$(losetup --show -fP /tmp/tmpImgA)"
++ losetup --show -fP /tmp/tmpImgA
+ LOOP_A=/dev/loop0
LOOP_B="$(losetup --show -fP /tmp/tmpImgB)"
++ losetup --show -fP /tmp/tmpImgB
+ LOOP_B=/dev/loop1

##########
# Create raid1
mkfs.btrfs --force -R free-space-tree -L TmpRaid1 -d raid1 -m raid1 "$LOOP_A" "$LOOP_B"
+ mkfs.btrfs --force -R free-space-tree -L TmpRaid1 -d raid1 -m raid1 /dev/loop0 /dev/loop1
btrfs-progs v5.14.1 
See http://btrfs.wiki.kernel.org for more information.

Label:              TmpRaid1
UUID:               96f6a82c-e80f-4560-9045-0229e63f5d66
Node size:          16384
Sector size:        4096
Filesystem size:    4.00GiB
Block group profiles:
  Data:             RAID1           204.75MiB
  Metadata:         RAID1           264.00MiB
  System:           RAID1             8.00MiB
SSD detected:       yes
Zoned device:       no
Incompat features:  extref, skinny-metadata
Runtime features:   free-space-tree
Checksum:           crc32c
Number of devices:  2
Devices:
   ID        SIZE  PATH
    1     2.00GiB  /dev/loop0
    2     2.00GiB  /dev/loop1


##########
# Mount temp raid1
mkdir /tmp/tmpRaid1
+ mkdir /tmp/tmpRaid1
mount "$LOOP_A" /tmp/tmpRaid1
+ mount /dev/loop0 /tmp/tmpRaid1

##########
# Run btrfs df
btrfs filesystem df /tmp/tmpRaid1
+ btrfs filesystem df /tmp/tmpRaid1
Data, RAID1: total=204.75MiB, used=0.00B
System, RAID1: total=8.00MiB, used=16.00KiB
Metadata, RAID1: total=256.00MiB, used=128.00KiB
Metadata, single: total=8.00MiB, used=0.00B
GlobalReserve, single: total=3.25MiB, used=0.00B
WARNING: Multiple block group profiles detected, see 'man btrfs(5)'.
WARNING:   Metadata: single, raid1

##########
# cleanup
umount /tmp/tmpRaid1
+ umount /tmp/tmpRaid1

losetup --detach "$LOOP_A"
+ losetup --detach /dev/loop0
losetup --detach "$LOOP_B"
+ losetup --detach /dev/loop1

sync
+ sync
rmdir /tmp/tmpRaid1/
+ rmdir /tmp/tmpRaid1/
rm /tmp/tmpImgA
+ rm /tmp/tmpImgA
rm /tmp/tmpImgB
+ rm /tmp/tmpImgB

[-- Attachment #3: btrfsRaid1Test.sh --]
[-- Type: application/x-sh, Size: 847 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2021-10-10  9:21 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-10-09 11:44 Bug / Suspected regression. Multiple block group profiles detected on newly created raid1 FireFish5000
2021-10-09 12:19 ` Qu Wenruo
2021-10-09 13:24   ` FireFish5000
2021-10-09 13:42     ` Hugo Mills
2021-10-10  9:21   ` Qu Wenruo

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.