Re: [PATCH V2] kvm tools: Enable O_DIRECT support

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

 



On Fri, Jul 13, 2012 at 12:05 AM, Pekka Enberg <penberg@xxxxxxxxxx> wrote:
> On Thu, Jul 12, 2012 at 6:18 PM, Asias He <asias.hejun@xxxxxxxxx> wrote:
>> With Direct I/O, file reads and writes go directly from the applications
>> to the storage device, bypassing the operating system read and write
>> caches. This is useful for applications that manage their own caches.
>>
>> Open a disk image with O_DIRECT:
>>    $ lkvm run -d ~/img/test.img,direct
>>
>> The original readonly flag is still supported.
>> Open a disk image with O_DIRECT and readonly:
>>    $ lkvm run -d ~/img/test.img,direct,ro
>>
>> Signed-off-by: Asias He <asias.hejun@xxxxxxxxx>
>
> Well, what's the use case for this?

With O_DIRECT, host page cache will be skipped. It saves the copying
of data between page cache and user space, thus reduces cpu
utilization and memory usage. This might be useful for users with
high-end storage.

It's also useful when we benchmark the performance of the storage
stack in kvm tool side because it excludes one factor we are not
interested in.

-- 
Asias He
--
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