Re: [PATCH] virtio-blk: set QUEUE_ORDERED_DRAIN by default

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, 26 Aug 2009 09:58:13 pm Avi Kivity wrote:
> On 08/26/2009 03:06 PM, Rusty Russell wrote:
> > On Tue, 25 Aug 2009 11:46:08 pm Christoph Hellwig wrote:
> >    
> >> On Tue, Aug 25, 2009 at 11:41:37PM +0930, Rusty Russell wrote:
> >>      
> >>> On Fri, 21 Aug 2009 06:26:16 am Christoph Hellwig wrote:
> >>>        
> >>>> Currently virtio-blk doesn't set any QUEUE_ORDERED_ flag by default, which
> >>>> means it does not allow filesystems to use barriers.  But the typical use
> >>>> case for virtio-blk is to use a backed that uses synchronous I/O
> >>>>          
> >>> Really?  Does qemu open with O_SYNC?
> >>>
> >>> I'm definitely no block expert, but this seems strange...
> >>> Rusty.
> >>>        
> >> Qemu can open it various ways, but the only one that is fully safe
> >> is O_SYNC (cache=writethrough).
> >>      
> > (Rusty goes away and reads the qemu man page).
> >
> > 	By default, if no explicit caching is specified for a qcow2 disk image,
> > 	cache=writeback will be used.
> >    
> 
> It's now switched to writethrough.  In any case, cache=writeback means 
> "lie to the guest, we don't care about integrity".

Well, that was the intent of the virtio barrier feature; *don't* lie to the
guest, make it aware of the limitations.

Of course, having read Christoph's excellent summary of the situation, it's
clear I failed.

> > Are you claiming qcow2 is unusual?  I can believe snapshot is less common,
> > though I use it all the time.
> >
> > You'd normally have to add a feature for something like this.  I don't
> > think this is different.
> 
> Why do we need to add a feature for this?

Because cache=writeback should *not* lie to the guest?

Rusty.
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux