[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Xen-devel] Benchmark Xen writes with sync - Xen ignores fsync, O_SYNC?
- To: xen-devel@xxxxxxxxxxxxx
- From: Pablo Llopis <pllopis@xxxxxxxxxxxxxxxxx>
- Date: Fri, 6 Apr 2012 00:30:05 +0200
- Delivery-date: Thu, 05 Apr 2012 22:30:43 +0000
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:date:x-google-sender-auth:message-id:subject :from:to:content-type; bh=vQY+VhOHXsM26KR90fTr/EBmsu66EGWTkMouS9YpF3M=; b=DBN+494v4XFFzNjXpiM8kXzXIwRpx+YmEUMeN95tShoJkrI8tayCPXNrXAkW9qxdKK ppvtAP+jyC5+VXRo/9U6m869ewo+veBHXLOXaTeSXixvxkVlJMEdthKRXpggyiq5VPDX nmTbi9HRxcByGVOPJpSNXVrt+wXxb3Uva/hCYi4oFmUM/grUPK7eHGOCpvEtlcLBjaCF qUa0dz7Zz+K3d32hm08g8+lD/f12lY8zAv+6WWDgwH+XYYRL4mIybpQ/m3IL0FAu3xFX 1FqNMePTnp5vn3crIWP4Tk2fPY3xpy6+CiQuP1jUjjCWO98z0V2s6R7jWXE99fPxRuzz EVow==
- List-id: Xen developer discussion <xen-devel.lists.xen.org>
Hi there Xen community,
I am trying to benchmark and compare I/O in Xen/domU to native performance.
In order to do this I started trying to benchmark writes so as to avoid caching effects that surely turn up when performing reads due to the page cache et al.
However, I have quickly run into a problem: Xen domU reports that a 128MB file is written at close to 300MB/s, while the disk's performance peaks at about 80MB/s (I observed this on a dom0 and on a bare-metal kernel with no hypervisor).
Please note that I fsync() after all writes in hopes to avoid the effect of write buffers. I have tried with O_SYNC as well, observing a similar outcome.
I can confirm this writing a simple program, and verified exactly same results running bonnie++ with the fsync() option turned on.
I am surprised to see writes reaching a throughput as high as 300MB/s, as the disk surely isn't physically capable of reaching that bandwidth, meaning that writes are not being really synced to disk.
Is this a bug in Xen, or is there a way to make Xen not ignore fsync, fdatasync, O_SYNC, etc..?
How would I proceed to measure and compare real read/write speeds on a Xen domU ?
My disk drivers are specified with "file:/path/to/image.img,xvda,1,w" (I could not get the tapdisk driver to work properly, I tried with vanilla 3.2 and 3.0.0 ubuntu kernels)
Xen is version 4.1.1 and is running Oneiric domUs (kernel 3.0.0)
For the dom0 I have a 3.2 vanilla kernel and a ubuntu (oneiric) 3.0.0 kernel
Thank you in advance,
Pablo
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel