bin/130857: /bin/dd if=/dev/acd0 returned error "invalid
parameter"
Giorgos Keramidas
keramida at freebsd.org
Thu Jan 22 19:30:03 PST 2009
The following reply was made to PR bin/130857; it has been noted by GNATS.
From: Giorgos Keramidas <keramida at freebsd.org>
To: Tri Brotoharsono <mail at tribrotoharsono.net>
Cc: bug-followup at freebsd.org
Subject: Re: bin/130857: /bin/dd if=/dev/acd0 returned error "invalid parameter"
Date: Fri, 23 Jan 2009 05:24:45 +0200
On Fri, 23 Jan 2009 09:45:46 +0700, Tri Brotoharsono <mail at tribrotoharsono.net> wrote:
> Giorgos Keramidas wrote:
> : So, if you use the patched dd version with open(in.name, O_RDONLY, 0)
> : then the bs=2048 is not needed, and dd works with your CD-ROM disk?
>
> No
>
> : That would be a bit odd.
> :
> : Note: Sorry replying with this address, but my original address denied
> : by mx1.freebsd.org due misconfiguration at my mail server.
> :
> : That's fine, don't worry about it. As long as the subject is there and
> : we can correlate the message with the original bug, all is well.
> :
> : * If you still think we should patch dd with the change, let me know.
> :
> : * If you think it's ok to leave it unmodified, and use bs=2048 should
> : be recommended, we can document this in the manpage and close the
> : problem report.
> :
> : How should we proceed with this?
>
> leave unmodified, recommend bs=2048 in the manpage
Does the following patch to the EXAMPLES section look ok?
I can commit it to the manpage when we shape it to look acceptable.
After the patch is applied, the example looks like this:
EXAMPLES
Check that a disk drive contains no bad blocks:
[...]
To create an image of a Mode-1 CD-ROM, which is commonly
used for data CD-ROM disks, use a block size of 2048 bytes:
dd if=/dev/acd0 of=filename.iso bs=2048
SEE ALSO
[...]
Here's the patch and the proposed commit log...
----- 20090123T031913+0000-dd-cdrom.diff patch starts here -----
Add an example of using bs=2048 to duplicate data CD-ROMs.
This should be a bit useful for users who look at the manpage and
then try to copy data CD-ROM disks using dd. A lot of us know
that bs=2048 is required, but it still manages to cause a bit of
grief to those who haven't heard about it.
PR: bin/130857
Submitted by: Tri Brotoharsono < mail at tribrotoharsono.net >
diff -r ce5936bddb83 -r dfbd83a06fcf bin/dd/dd.1
--- a/bin/dd/dd.1 Fri Jan 23 01:34:58 2009 +0200
+++ b/bin/dd/dd.1 Fri Jan 23 05:18:11 2009 +0200
@@ -392,6 +392,11 @@
Check for (even) parity errors on a file:
.Pp
.Dl "dd if=file conv=pareven | cmp -x - file"
+.Pp
+To create an image of a Mode-1 CD-ROM, which is a commonly used format
+for data CD-ROM disks, use a block size of 2048 bytes:
+.Pp
+.Dl "dd if=/dev/acd0 of=filename.iso bs=2048"
.Sh SEE ALSO
.Xr cp 1 ,
.Xr mt 1 ,
----- 20090123T031913+0000-dd-cdrom.diff patch ends here -----
More information about the freebsd-bugs
mailing list