linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Large files, nodatacow and fragmentation
@ 2014-08-11 18:36 G. Richard Bellamy
  2014-08-11 19:14 ` Roman Mamedov
  0 siblings, 1 reply; 20+ messages in thread
From: G. Richard Bellamy @ 2014-08-11 18:36 UTC (permalink / raw)
  To: linux-btrfs

I've been playing with btrfs as a backing store for my KVM images.

I've used 'chattr +C' on the directory where those images are stored.

You can see my recipe below [1]. I've read the gotchas found here [2]

I'm having continuing performance issues inside the Guest VM that is
created inside the btrfs subvolume, using a qcow2 format. I'm having a
hard time determining whether the issues are related to KVM or btrfs,
or if this is even a reasonable topic of discussion.

I've seen the comments on this list saying that if I want a COW
filesystem with sparse files, that I'd be better off with ZFS. I'd
like to use an in-tree COW filesystem, but if it's just not gonna
happen yet with btrfs, I guess that's just the way it is.

That being said, how would I determine what the root issue is?
Specifically, the qcow2 file in question seems to have increasing
fragmentation, even with the No_COW attr.

[1]
$ mkfs.btrfs -m raid10 -d raid10 /dev/sda /dev/sdb /dev/sdc /dev/sdd
$ mount /dev/sda /mnt
$ cd /mnt
$ btrfs create subvolume __data
$ btrfs create subvolume __data/libvirt
$ cd /
$ umount /mnt
$ mount /dev/sda /var/lib/libvirt
$ chattr +C /var/lib/libvirt/images
$ cp /run/media/rbellamy/433acf1d-a1a4-4596-a6a7-005e643b24e0/libvirt/images/atlas.qcow2
/var/lib/libvirt/images/
$ filefrag /var/lib/libvirt/images/atlas.qcow2
/var/lib/libvirt/images/atlas.qcow2: 0 extents found
[START UP THE VM - DO SOME THINGS]
$ filefrag /var/lib/libvirt/images/atlas.qcow2
/var/lib/libvirt/images/atlas.qcow2: 12236 extents found
[START UP THE VM - DO SOME THINGS]
$ filefrag /var/lib/libvirt/images/atlas.qcow2
/var/lib/libvirt/images/atlas.qcow2: 34988 extents found

[2]
https://btrfs.wiki.kernel.org/index.php/Gotchas

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

end of thread, other threads:[~2014-09-03 18:53 UTC | newest]

Thread overview: 20+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-08-11 18:36 Large files, nodatacow and fragmentation G. Richard Bellamy
2014-08-11 19:14 ` Roman Mamedov
2014-08-11 21:37   ` G. Richard Bellamy
2014-08-11 23:31   ` Chris Murphy
2014-08-14  3:57     ` G. Richard Bellamy
2014-08-14  4:23       ` Chris Murphy
2014-08-14 14:30         ` G. Richard Bellamy
2014-08-14 15:05           ` Austin S Hemmelgarn
2014-08-14 18:15             ` G. Richard Bellamy
2014-08-14 18:40           ` Chris Murphy
2014-08-14 23:16             ` G. Richard Bellamy
2014-08-15  1:05               ` Chris Murphy
2014-09-02 18:31                 ` G. Richard Bellamy
2014-09-02 19:17                   ` Chris Murphy
2014-09-02 19:17                   ` Austin S Hemmelgarn
2014-09-02 23:30                     ` G. Richard Bellamy
2014-09-03  6:01                       ` Chris Murphy
2014-09-03  6:26                         ` Chris Murphy
2014-09-03 15:45                           ` G. Richard Bellamy
2014-09-03 18:53                             ` Clemens Eisserer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).