All of lore.kernel.org
 help / color / mirror / Atom feed
* Accessing Parent Subvolume
@ 2015-05-03  6:19 Imran Geriskovan
  2015-05-03  7:09 ` Goffredo Baroncelli
  0 siblings, 1 reply; 2+ messages in thread
From: Imran Geriskovan @ 2015-05-03  6:19 UTC (permalink / raw)
  To: linux-btrfs

It's a common case for installing new operating system on
subvolumes on an existing btrfs. So I'll base my example on it:

** SETUP **
We have the following subvolumes:

- OS1 (say Debian) on default subvolume /
- OS2 (say Arch) on subvolume /@arch

Now, boot into Arch and mount its parent
subvolume on /mnt/debian.


** QUESTIONS **
1- Is it safe to access /mnt/debian ?
2- Is it safe to access /mnt/debian/@arch ?
(Yeah, I'm pushing my chances recursively)


** POSSIBLE ANSWERS **
X- Sure.. Accessing parent subvolumes recursively is a
non issue. Even /arch/debian/arch/debian... is no problem.
(Then, add this to features/decumentation to show how
generic btrfs subvolume mount machinery is)

Y- Btrfs is designed to do that. However, expect some
corner cases/bugs. (It's okay)

Z- Don't even do that. Btrfs is never designed for it and
will never be. (Then, prevent user doing it)


I wonder where btrfs is on XYZ scale.

Thanks for your comments,
Imran

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

* Re: Accessing Parent Subvolume
  2015-05-03  6:19 Accessing Parent Subvolume Imran Geriskovan
@ 2015-05-03  7:09 ` Goffredo Baroncelli
  0 siblings, 0 replies; 2+ messages in thread
From: Goffredo Baroncelli @ 2015-05-03  7:09 UTC (permalink / raw)
  To: Imran Geriskovan, linux-btrfs

On 2015-05-03 08:19, Imran Geriskovan wrote:
> ** QUESTIONS **
> 1- Is it safe to access /mnt/debian ?
> 2- Is it safe to access /mnt/debian/@arch ?
> (Yeah, I'm pushing my chances recursively)
> 
> 
> ** POSSIBLE ANSWERS **
> X- Sure.. Accessing parent subvolumes recursively is a
> non issue. Even /arch/debian/arch/debian... is no problem.
> (Then, add this to features/decumentation to show how
> generic btrfs subvolume mount machinery is)

It is safe. However I suggest to use the root subvolume only to host other subvolumes.

In your case the layout should be:

/@debian
/@arch

The biggest advantage is that all subvolume are equal, so it could be
manage in the same way when you do a snapshot/rollback...

BR
G.Baroncelli

-- 
gpg @keyserver.linux.it: Goffredo Baroncelli <kreijackATinwind.it>
Key fingerprint BBF5 1610 0B64 DAC6 5F7D  17B2 0EDA 9B37 8B82 E0B5

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

end of thread, other threads:[~2015-05-03  7:18 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-05-03  6:19 Accessing Parent Subvolume Imran Geriskovan
2015-05-03  7:09 ` Goffredo Baroncelli

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.