xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
* new knob to tweak caching mode for backends
@ 2014-05-26 17:06 Olaf Hering
  2014-05-27 16:50 ` Jim Fehlig
  0 siblings, 1 reply; 7+ messages in thread
From: Olaf Hering @ 2014-05-26 17:06 UTC (permalink / raw)
  To: Stefano Stabellini, Ian Campbell, Ian Jackson, andrew.cooper3; +Cc: xen-devel


Currently libxl (and xend) has no knob to control cache mode of backend
driver for block devices. libvirt and qemu have:
cache=off|none|directsync|writeback|unsafe|writethrough.

The xen qdisk driver in qemu defaults to "writeback". If the diskspec in
domU…cfg has 'direct-io-safe' then qdisk will default to directsync AIO.

I think these defaults are fine as they provide some sort of data
integrity.


But there is one issue: all the flushing thats going on during guest
triggered writes does slows down the guest. There should be a knob to
skip the regular flushes on the host.  If the given backing file will
contain throw-away data its up the the admin to make this decision.

The use case I have in mind are guest installations, which trigger alot
of disk io. We see a speedup from 22min down to 10min if qemu is forced
to use cache=unsafe. 

I wonder if and how such a knob should be exposed in domU.cfg:disk=[]
To me it looks like a bool similar to direct-io-safe is enough. If the
flag is set in xenstore, xen qdisk sets BDRV_O_NO_FLUSH to skip flushes.


Olaf

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

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

end of thread, other threads:[~2014-06-10 13:34 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-05-26 17:06 new knob to tweak caching mode for backends Olaf Hering
2014-05-27 16:50 ` Jim Fehlig
2014-05-27 17:08   ` Stefano Stabellini
2014-05-27 20:18     ` Jim Fehlig
2014-05-28  8:53     ` Olaf Hering
2014-05-28 11:26       ` Stefano Stabellini
2014-06-10 13:34       ` Ian Jackson

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).