http://bugzilla.opensuse.org/show_bug.cgi?id=1049994
http://bugzilla.opensuse.org/show_bug.cgi?id=1049994#c1
Andrei Borzenkov changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |CONFIRMED
Assignee|jsrain@suse.com |mchang@suse.com
--- Comment #1 from Andrei Borzenkov ---
@Michael: I helped Antoine to triage this on forum. Following situation:
- SUSE grub snapshot handling relies on the fact that /.snapshots directory in
current snapshot always points to /@/.snapshots subvolume.
- this works by accident due to a bug in grub btrfs driver. When grub sees
directory entry of type ROOT_ITEM (0x84) which indicates grafted subvolume it
unconditionally jumps to corresponding subvolume. But this directory entry is
duplicated in snapshots, although it is no more actually connected to
subvolume. As example
directory /mnt/@/ tree 257 inum 256
dir item list hash 1921786525 size 1
dir item location (258 ROOT_ITEM -1) type DIR name utf-8 .snapshots
directory /mnt/@/.snapshots/1/snapshot/ tree 259 inum 256
dir item list hash 1921786525 size 1
dir item location (258 ROOT_ITEM -1) type DIR name utf-8 .snapshots
directory /mnt/@/.snapshots/198/snapshot/ tree 714 inum 256
dir item list hash 1921786525 size 1
dir item location (258 ROOT_ITEM -1) type DIR name utf-8 .snapshots
Note that all three directories have entry (258 ROOT_ITEM); but only the very
first one actually has subvolume, "connected" to it. This can be verified by
searching for ROOT_REF or ROOT_BACKREF with parent and child tree ids:
(257 ROOT_REF 258)
(258 ROOT_BACKREF 257)
- received snapshot no more contains this ROOT_ITEM stub entry (it is not
duplicated across btrfs send/receive), which breaks code assumption, making
/.snapshots/... paths non-existent.
Once this bug is fixed upstream, SUSE snapshot handling will break just as it
breaks now in reported case. It looks like the most obvious fix is to
explicitly mount /@/.snapshots on /.snapshots, just like we already do it for
platform directory.
I took liberty to assign it to you because a) I still do not feel at home with
SUSE btrfs patches and b) I likely won't be able to do anything until September
anyway. Thank you.
--
You are receiving this mail because:
You are on the CC list for the bug.