[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#15680: dd: suggest iflag=fullblock ... but only if count > 1
From: |
Eric Blake |
Subject: |
bug#15680: dd: suggest iflag=fullblock ... but only if count > 1 |
Date: |
Tue, 22 Oct 2013 08:05:12 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.0 |
On 10/22/2013 07:47 AM, Bernhard Voelker wrote:
> dd(1) issues a nice warning about short reads ...
>
> src/dd if=/dev/random of=sample bs=1000 count=2
> src/dd: warning: partial read (128 bytes); suggest iflag=fullblock
> 0+2 records in
> 0+2 records out
> 256 bytes (256 B) copied, 0.000423371 s, 605 kB/s
>
> ... but only if count was > 1:
>
> src/dd if=/dev/random of=sample bs=1000 count=1
> 0+1 records in
> 0+1 records out
> 128 bytes (128 B) copied, 0.000270231 s, 474 kB/s
>
> Is this by intension or an off-by-one?
My understanding is that it is intentional.
--
Eric Blake eblake redhat com +1-919-301-3266
Libvirt virtualization library http://libvirt.org
signature.asc
Description: OpenPGP digital signature