I am using dd to copy iso images to a thumb drive. Is there a way to output the status of dd during the copy process?
2 Answers
If you're using OS X, you can press CTRL-T and it will give you a progress update.
2You can use any command line technique genially available to any *nix user. There are loads of examples:
They all basically lump into one of two categories: send a kill signal (like CTRL-T) or pipe the output through a viewer like pv. I would only recommend pv only if you already use MacPorts or HomeBrew. Simplest example:
dd if=file.iso | pv | dd of=/dev/sda3If you have more than 1 file to transfer & also want % complete and and ETA, then you have to provide pv the size of the stream it's watching. You can provide the size of a directory tree as
`SIZE=$(du -sb . | awk '{print $1}')` or an entire file system as
`SIZE=$(df -B1 /dev/sda1 | tail -n1 | tr -s ' ' | cut -d' ' -f2)` and then pass the size in to pv as:
dd if=file.iso | pv -s $SIZE | dd of=/dev/sda3