[Btrfs-devel] Oops

Zach Brown zach.brown at oracle.com
Sat Dec 8 09:01:24 PST 2007


>> $ mount -o loop /usr/portage.img /usr/portage/

>> $ mount -o loop,subvol=. /usr/portage.img /mnt/tmp/

> It's seem you setup two difference loopback devices on the same image
> file. Please try mount the image file this way.

I think btrfs.ko should have a global list of uuids that are mounted.
It could then forbid to mount a superblock with a uuid that is already
mounted somewhere else.  Maybe it could only perform this check for
writable mounts, which I suspect is all mounts today ;).

It wouldn't be perfect but it is a trivial amount of code and it would
have prevented this honest mistake.

- z



More information about the Btrfs-devel mailing list