read/write performance through mount point by guestmount
I create a *4x256GB-SSD RAID0(/dev/md1)* and I test the performance through fio. fio config: ioengine=libaiodirect=1time_basedruntime=120ramp_time=30size=100g The sequential read/write performance is:
*read: 2000MB/swrite: 1800MB/s*
Now I make a ext4 on the RAID0(/dev/md1) and mount on /home/. ANd I create a 100G-disk.qcow2 by guestfish.
$guestfish
<fish>: disk-create disk.qcow2 qcow2 100*1024*1024*1024 <fish>: run <fish>: mkfs ext4 /dev/sda <fish>: shutdown <fish>: quit
No errors showed. I mount the disk.qcow2 on the /home/test/, and create a 50GB file.
$dd if=/dev/zero of=/home/test/file bs=1M count=51280
Test sequential read/write again through fio and config almost the same: ioengine=libaiodirect=1time_basedruntime=120ramp_time=30size=50g and the testing filename is /home/test/file and the performance is :
*read: 86MB/swrite: 43MB/s*
how come the performance is so bad? almost down 95%. My machine is: 4.4.0-83-generic, Ubuntu 16.04, x86_64 GNU/Linux
On Mon, Jul 31, 2017 at 12:20:10PM +0800, lampahome wrote:
I mount the disk.qcow2 on the /home/test/, and create a 50GB file.
Mount the disk how? Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog: http://rwmj.wordpress.com virt-builder quickly builds VMs from scratch http://libguestfs.org/virt-builder.1.html
On Mon, Jul 31, 2017 at 09:49:00AM +0100, Richard W.M. Jones wrote:
On Mon, Jul 31, 2017 at 12:20:10PM +0800, lampahome wrote:
I mount the disk.qcow2 on the /home/test/, and create a 50GB file.
Mount the disk how?
OK, subject says using guestmount. I'm surprised the slowdown isn't more than 95%. It's using FUSE which goes through an insane number of layers, see the "Update" section in this post: https://rwmj.wordpress.com/2009/10/30/fuse-support-for-libguestfs/ Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog: http://rwmj.wordpress.com libguestfs lets you edit virtual machines. Supports shell scripting, bindings from many languages. http://libguestfs.org
if I mount through guestfs library in python or guestfish, the same condition happenes? I mean the insane number of layers and the performance 2017-07-31 16:52 GMT+08:00 Richard W.M. Jones <rjones@redhat.com>:
On Mon, Jul 31, 2017 at 09:49:00AM +0100, Richard W.M. Jones wrote:
On Mon, Jul 31, 2017 at 12:20:10PM +0800, lampahome wrote:
I mount the disk.qcow2 on the /home/test/, and create a 50GB file.
Mount the disk how?
OK, subject says using guestmount.
I'm surprised the slowdown isn't more than 95%. It's using FUSE which goes through an insane number of layers, see the "Update" section in this post:
https://rwmj.wordpress.com/2009/10/30/fuse-support-for-libguestfs/
Rich.
-- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~ rjones Read my programming and virtualization blog: http://rwmj.wordpress.com libguestfs lets you edit virtual machines. Supports shell scripting, bindings from many languages. http://libguestfs.org
On Mon, Jul 31, 2017 at 06:52:28PM +0800, lampahome wrote:
if I mount through guestfs library in python or guestfish, the same condition happenes?
I mean the insane number of layers and the performance
No. The layers are only present because guestmount uses FUSE. libguestfs itself performs very well if you are careful to use it in the correct way. The architecture of libguestfs is described here: http://libguestfs.org/guestfs-internals.1.html#architecture and we have tools for testing the performance of the virtio-serial connection, qemu block layer and overhead of starting the appliance: https://github.com/libguestfs/libguestfs/tree/master/utils and we have a page of tips on getting the best performance: http://libguestfs.org/guestfs-performance.1.html Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog: http://rwmj.wordpress.com virt-top is 'top' for virtual machines. Tiny program with many powerful monitoring features, net stats, disk stats, logging, etc. http://people.redhat.com/~rjones/virt-top
2017-07-31 18:57 GMT+08:00 Richard W.M. Jones <rjones@redhat.com>:
On Mon, Jul 31, 2017 at 06:52:28PM +0800, lampahome wrote:
if I mount through guestfs library in python or guestfish, the same condition happenes?
I mean the insane number of layers and the performance
No. The layers are only present because guestmount uses FUSE.
libguestfs itself performs very well if you are careful to use it in the correct way.
how about guestfish? guestfish follows libguestfs or guestmount?
On Thu, Aug 03, 2017 at 05:37:39PM +0800, lampahome wrote:
2017-07-31 18:57 GMT+08:00 Richard W.M. Jones <rjones@redhat.com>:
On Mon, Jul 31, 2017 at 06:52:28PM +0800, lampahome wrote:
if I mount through guestfs library in python or guestfish, the same condition happenes?
I mean the insane number of layers and the performance
No. The layers are only present because guestmount uses FUSE.
libguestfs itself performs very well if you are careful to use it in the correct way.
how about guestfish? guestfish follows libguestfs or guestmount?
guestfish is a thin wrapper around the libguestfs API. I (again) strongly suggest that you read the documentation which explains all this in great detail: http://libguestfs.org/guestfs-internals.1.html#architecture http://libguestfs.org/guestfish.1.html#description http://libguestfs.org/guestfs-performance.1.html Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog: http://rwmj.wordpress.com Fedora Windows cross-compiler. Compile Windows programs, test, and build Windows installers. Over 100 libraries supported. http://fedoraproject.org/wiki/MinGW
participants (2)
-
lampahome -
Richard W.M. Jones