dd: cryptic error message when bs=<unreasonably large value>
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
coreutils (Ubuntu) |
Triaged
|
Low
|
Unassigned |
Bug Description
Binary package hint: coreutils
imi@most:~$ true|dd bs=1 count=3G
0+0 records in
0+0 records out
0 bytes (0 B) copied, 4.0228e-05 s, 0.0 kB/s
imi@most:~$ true|dd bs=3G count=1
dd: invalid number `3G'
however, according to man DD:
BLOCKS and BYTES may be followed by the following multiplicative suf‐
fixes: c =1, w =2, b =512, kB =1000, K =1024, MB =1000*1000, M
=1024*1024, xM =M GB =1000*1000*1000, G =1024*1024*1024, and so on for
T, P, E, Z, Y.
ProblemType: Bug
DistroRelease: Ubuntu 10.04
Package: coreutils 7.4-2ubuntu2
ProcVersionSign
Uname: Linux 2.6.32-22-generic i686
Architecture: i386
Date: Thu Jun 10 01:37:41 2010
ProcEnviron:
PATH=(custom, user)
LANG=hu_HU.utf8
SHELL=/bin/bash
SourcePackage: coreutils
summary: |
- cryptic error message when bs=<unreasonably large value> + dd: cryptic error message when bs=<unreasonably large value> |
You're on 32bit, on 64bit this seems to work. My guess is that there is a limit to the block size available on 32bit (if that limit was 2G or just under it wouldn't surprise me), on 64bit there is a similar limit somewhere :
dg@major:~$ true | dd bs=3G count=1
0+0 records in
0+0 records out
0 bytes (0 B) copied, 2.1008e-05 s, 0.0 kB/s
dg@major:~$ true | dd bs=3E count=1
dd: memory exhausted
dg@major:~$ true | dd bs=3Z count=1
dd: invalid number `3Z'
I can see an argument that there might want to put a better error message in, or state that the bs is dependent on memory
size.
Dave