Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Suppose that

dd if=/dev/sda bs=100M | gzip -c > somefile.img.gz 

is done. If errors occur in dd, do I get to see error messages in terminal, or do they get ignored?

Also, suppose that dd encounters a read error. Will dd just skip the block, or will it print out error messages?

share|improve this question
up vote 2 down vote accepted

You will see the error message if there is any.

There are different types of read errors and dd should always report it. If the error is continuable, dd just outputs nulls for that block. Otherwise dd will stop.

If you want to recover data, ddrescue is more error-tolerant than dd.

share|improve this answer
I realized that my new post may have been a duplicate, so I am commenting here. What I want is if dd encounters bad sectors of hard disk, does it send an error message to terminal, or does it just ignore it? That's my question. Sorry for messing up with questions. – dding Jul 22 '13 at 10:04
dd will send an error to the terminal (STDERR) whenever it encounters a bad block. – johnshen64 Jul 22 '13 at 14:37

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.