bug-coreutils
[Top][All Lists]
Advanced

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

bug#7421: [Feature request]: add option to dd to issue ioctl(BLKFLSBUF)


From: Pádraig Brady
Subject: bug#7421: [Feature request]: add option to dd to issue ioctl(BLKFLSBUF) on output descriptior after each write or at the end
Date: Sun, 25 Jan 2015 18:41:52 +0000
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.3.0

unarchive 7421
tag 7421 wontfix
close 7421
stop

On 17/11/10 10:41, Марк Коренберг wrote:
> [Feature request]: add option to dd to issue ioctl(BLKFLSBUF) on
> output descriptior after each write or at the end
> 
> I already has sent a message about fsync/fdatasync after each write.
> It seems that ioctl(BLKFLSBUF) need be implemented in same semantics.
> 
> in oflags and conv
> i.e. ioctl after each write oflags=blkflsbuf
> and ioctl at the end, if specified in conv=blkflsbuf

This is already supported with the `blockdev --flushbufs` command.
Given this is a low level linux specific interface, it's more suited
to the blockdev command than a more general tool like dd.
Note ioctl(BLKFLSBUF) only writes out dirty pages to the block device,
it doesn't guarantee to send a flush request to the device.
Also http://lwn.net/Articles/433384/ mentions that BLKFLSBUF also
invalidates the bdev mapping, which isn't generally desirable,
and doesn't work for non-block file systems.

We're considering adding syncfs() support to the sync command
which should cater for much of the use case you describe here:
That's discussed at http://bugs.gnu.org/19681

thanks,
Pádraig.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]