How can Grub2 access files in a btrfs subvolume?

I would like to boot ISO file stored as /home/myuser/file.iso.
/home is a btrfs subvol of /.

Background
I would like to collect several Install/Rescue ISOs in my home directory.
Then for every interesting ISO I would add an entry in /etc/grub.d/40_custom.
How must the entry look like?

I was inspired by https://forums.opensuse.org/t/how-to-boot-a-opensuse-dvd-from-hard-disk-with-grub2/87949

I do not want to put the ISOs into the root-fs as it is not worth having a recovery option.
Also it would fill the root-fs.

thanks

No, /home is a mount point, not a subvolume.

Upstream grub always resolves paths on btrfs starting from the top of the filesystem. SUSE grub has patches to change it when snapshots are enabled - it only works with the default subvolume. To access other subvolumes in this case you can use btrfs-mount-subvol command. Something like (untested)

btrfs-mount-subvol ($root) /home @/home

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.