GNU bug report logs -
#7421
[Feature request]: add option to dd to issue ioctl(BLKFLSBUF) on output descriptior after each write or at the end
Previous Next
Reported by: Марк Коренберг <socketpair <at> gmail.com>
Date: Wed, 17 Nov 2010 11:47:02 UTC
Severity: wishlist
Tags: wontfix
Done: Pádraig Brady <P <at> draigBrady.com>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
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.
This bug report was last modified 10 years and 121 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.