btrfs vs lvm?

568 views
Skip to first unread message

Niels Kobschaetzki

unread,
May 29, 2016, 3:36:49 PM5/29/16
to qubes...@googlegroups.com
Hi,

is it just me or is in the documentation no explanation why one should
use over the other? I also couldn't really find anything in the
ML-archive.

Why should I use btrfs or lvm with QubesOS? I have in my head somewhere
looming with real problems when there is not a lot of space available,
up to a system that is not bootable anymore. Do the tools provided by
Qubes use features of btrfs like snapshoting or what else it has up its
sleeves? What problems might arise when one uses btrfs? Is it really
stable enough nowadays?

Niels

Andrew David Wong

unread,
May 29, 2016, 5:06:56 PM5/29/16
to Niels Kobschaetzki, qubes...@googlegroups.com
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512
IMHO, Btrfs vs. LVM is beyond the scope of Qubes. One may be better
than the other for you depending on your needs, but neither is required.

- --
Andrew David Wong (Axon)
Community Manager, Qubes OS
https://www.qubes-os.org
-----BEGIN PGP SIGNATURE-----

iQIcBAEBCgAGBQJXS1noAAoJENtN07w5UDAwTQoP/2OyzvcezJ7Buanpp2TBZP1X
dfCbwh9kZlxpdiQplwuFrcNaENzJLOVYgjR61TeVFL2uZZ2cIwZFiWmFYSZyg7kw
lH7mE3DtfTLflT9D4SRjAVuoRmdufgLfyu2nrjpcF+oSMTNW8k0XB+uANWHmtRL5
Ph+QGMboYlilbtZ/rtNXEP0eSmlclLA96JRw3KbAeUpXfgIMSooygsMrxqYwCIPV
Uc82UwYx0RG6A9uwhS0SN/38xyzMCkztxbPulcOpzW3aDCLLVBV/NHT7Nn6PCHSp
yh4cvjKCsRWKYnnbki6lF+FQvurHYUoJNLUPE7fPCwsBd/ERyvINhXJaQWL2SZ+0
L5q9VsCi9KfVRdpudACxCPA1M/3pgzN5p27Ipe27ClRSTMZ8bYT6xKLTUEJLlv4s
jeBpmaNh4ekU/zztjL3WfuxvYDlVfwyA0wYFl7EfaTQ4tKyId9Xy8AF+8tg+6Wr4
OTlcQEp8LvSlGr79bCfP5C/FCAIVz6Q+Nl5+2Wlf+66nOLEXWu6/X53gJG80ufHL
LOmLoKwZXhFjiuGapQymO3TLP7q6/4tulhonFwa6U2qHZc3C7Sa9COf9melKtsxt
oAAs3HqxuIuoYQVPyAAl3mGLSjHQxFI7lHXE/TfoNU6bvJ2a1OcDbMF6hXwWaMER
BiAwNqNh97j8aRqABiAA
=x7Nv
-----END PGP SIGNATURE-----

Chris Laprise

unread,
May 29, 2016, 7:27:42 PM5/29/16
to Niels Kobschaetzki, qubes...@googlegroups.com
Hi Niels,

There is one case where I would use lvm over btrfs at this point: RAID
configurations. I think they were still trying to get the bugs out of
btrfs RAID as recently as last year.

Otherwise, btrfs has been great with Qubes and I highly recommend it on
a normal PC or laptop. Its been very stable for me and is now faster[1]
and more versatile than other options. For instance, if I want to
experiment with a number of different templates or appvms, Qubes will
reflink the disk images instead of duplicating them. The reflinked
copies occur instantly, and only use extra disk blocks when changes are
made to the original or the copies. AFAIK, this capability is unique to
btrfs and requires only a simple 'cp --reflink' which Qubes does
automatically in the case of vm images.

Btrfs also has differential send/receive backup and restore. Qubes
backup doesn't take advantage of this yet, but its still something you
can configure yourself.

I haven't had any issues with disk space, though I generally keep more
than 20GB free.

Chris

1. https://www.diva-portal.org/smash/get/diva2:822493/FULLTEXT01.pdf

Franz

unread,
May 29, 2016, 9:49:05 PM5/29/16
to Chris Laprise, Niels Kobschaetzki, qubes...@googlegroups.com
Very interesting post! Thanks Chris

 
--
You received this message because you are subscribed to the Google Groups "qubes-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to qubes-users...@googlegroups.com.
To post to this group, send email to qubes...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/qubes-users/574B7AE3.6020006%40openmailbox.org.

For more options, visit https://groups.google.com/d/optout.

ni...@kobschaetzki.net

unread,
May 30, 2016, 5:28:06 AM5/30/16
to Chris Laprise, qubes...@googlegroups.com
Hi Chris,

> On May 30, 2016 at 1:27 AM Chris Laprise <tas...@openmailbox.org> wrote:
>
> On 05/29/2016 03:36 PM, Niels Kobschaetzki wrote:
>
> > Hi,

<snip does btrfs has advantages over lvm on QubesOS?>

> Hi Niels,

<snip yes, but don't use it with a raid>

Thanks a lot, very interesting post. I am really thinking about re-installing Qubes with BtrFS but I probably need a bigger SSD first.

Niels

Bahtiar `kalkin-` Gadimov

unread,
May 30, 2016, 8:09:08 AM5/30/16
to qubes-users
Hi,

Excerpts from Niels Kobschaetzki's message of 2016-05-29 21:36:38 +0200:

> Why should I use btrfs or lvm with QubesOS?

IMHO you should use LVM. Because btrfs is IMHO not mature enough. (Personal
anecdote warning) I used it for backups until the partion become read-only and
throw out of space warnings, for no obvious reason.

> I have in my head somewhere looming with real problems when there is not a lot
> of space available, up to a system that is not bootable anymore. Do the tools
> provided by Qubes use features of btrfs like snapshoting or what else it has
> up its sleeves?

LVM snapshots used to be slow and expensive, but for a few years LVM has thin
pool support. This is very similar to Btrfs and ZFS snapshot functionality,
saves a ton of diskspace through the overcommit functionality, can be chosen
during QubesOS install is fast (at least fast enough).

If you really have disk space issues, you can try my LVM patches
(https://github.com/kalkin/qubes-core-admin/tree/qubes3-lvm), which allow
storing domains on thin volumes. This save a ton of space when using multiple
TemplateVMs based on each other, because of the CoW mechanism.

> What problems might arise when one uses btrfs? Is it really stable enough
> nowadays?

IMHO no. I'm using unix/posix systems for more than a decade and btrfs was the
first fs which has “broken down” for me.

kalkin-
signature.asc

Rusty Bird

unread,
May 30, 2016, 11:36:04 AM5/30/16
to qubes-users, Bahtiar `kalkin-` Gadimov, Niels Kobschaetzki
Bahtiar `kalkin-` Gadimov:
> IMHO you should use LVM. Because btrfs is IMHO not mature enough. (Personal
> anecdote warning) I used it for backups until the partion become read-only and
> throw out of space warnings, for no obvious reason.

On Qubes 3.0, I had the same issue: More than a couple of dozen whole-fs
snapshots made the fs readonly. Booting a newer kernel and removing some
of the snapshots fixed it then.

Rusty

signature.asc

Chris Laprise

unread,
May 30, 2016, 4:28:54 PM5/30/16
to qubes...@googlegroups.com
IIRC, kernel 3.17 and later are considered safe bets for btrfs.

Chris
Reply all
Reply to author
Forward
0 new messages