Am 20.11.2011 11:59, schrieb Pekka Enberg:
> On Sun, 2011-11-20 at 14:14 +0800, Lan, Tianyu wrote:
>>> OK. Thx.
>>> But fsync is too slow. I try to find a way to sync a range of file. 
>>> Are there any solutions to meet my purpose?
> 
> On Sun, 2011-11-20 at 08:23 +0200, Sasha Levin wrote:
>> fdatasync() is as good as it'll get.
>>
>> tbh, maybe we should just consider opening QCOW images with O_SYNC and
>> just get it over with?
> 
> No, lets not do that. It's easier to improve the performance of correct
> code that doesn't use O_SYNC.

Yes, O_SYNC gives you horrible performance. With explicit fsyncs cluster
allocation is somewhat slow (you can try to speed it up by batching
updates like qemu does), but at least rewrites will perform reasonably
close to raw.

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

Reply via email to