Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Hi together, today I wanted to write a CD image to a USB key, using dd. I noticed that the write is relatively slow. When I started the gkrellm monitor I noticed that dd is doing excessive reads from the target (the USB stick). Write operations took place only between these read operations, see attached screenshot (oh, no file attachments here?...) Any idea what's happening here?
You don't say what blocksize (if any) or other options you specified.
I didn't because I did not specify any special blocksize, so the standard is used.
I don't think the drive was mounted (cannot be 100% sure, though)
I remember having this issue with hard disks, too. Sometimes it helped to just cancel and restart the dd process.
The default might be painfully slow for various reasons. Use of an appropriate bs helps speed things up AND reduce the number of reads and writes. I suggested the 4M as the post that suggested it talked about CD to usb so seemed relevant.
Distribution: Debian testing/sid; OpenSuSE; Fedora; Mint
Posts: 5,524
Rep:
I think dd reads three times as much as it writes. It reads into a buffer, then it compares the buffer to the source, then it writes the buffer to the target. And it probably interleaves several of those operations.
It looks like it does what you'd expect - reads sectors, and writes them out. I put perf probes on libc read and write, and ran a small dd - count = 100000. Here's the result, redacted for brevity;
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.