On Tue, Apr 07, 2015 at 12:58:28PM +0200, arnaud gaboury wrote:
> On Tue, Apr 7, 2015 at 11:57 AM, arnaud gaboury
> <arnaud.gabo...@gmail.com> wrote:
> >
> > I plan to install my OS on a btrfs partition, with some subvolumes.
> > Once the partition has been btrfs formated, I mounted it somewhere, cd
> > and then run <btrfs subvolume create>.
> >
> > I did these two subvolumes for now:
> > # btrfs subvolume list .
> > ID 256 gen 6 top level 5 path var
> > ID 257 gen 7 top level 5 path home
> >
> > Now I am wondering if I need to create the root filesystem partition
> > (/)? If yes, is this correct:
> > # btrfs subvolume create root
> 
> 
> After more reading, it seems to me creating a top root subvolume is
> the right thing to do:
> # btrfs subvolume create root
> # btrfs subvolume create root/var
> # btrfs subvolume create root/home
> 
> Am I right?

   Not how I'd recommend doing it. I'd say:

# btrfs sub crea root
# btrfs sub crea var
# btrfs sub crea home

   Then fstab:

LABEL=myfs    /      btrfs    subvol=root         0 0
LABEL=myfs    /var   btrfs    subvol=var          0 0
LABEL=myfs    /home  btrfs    subvol=home         0 0

   And finally, add this to your kernel command line in the bootloader
to specify how to mount root:

rootflags=subvol=root

   Hugo.

-- 
Hugo Mills             | The trouble with you, Ibid, is you think you know
hugo@... carfax.org.uk | everything.
http://carfax.org.uk/  |
PGP: E2AB1DE4          |

Attachment: signature.asc
Description: Digital signature

Reply via email to