1

How do you get the top level subvolid of a mounted btrfs? I want the actual subvolid that is mounted at this moment and not the default subvolid (which could be different.)

0

Look at /proc/mounts or the output of mount, the subvolid is always listed in the mount options.

/dev/loop0 /mnt/btrfs btrfs rw,relatime,space_cache,subvolid=5,subvol=/ 0 0
                                                    ^^^^^^^^^^
| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.