3

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?

1 Answer 1

2

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.

2
  • 1
    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, 2013 at 10:04
  • dd will send an error to the terminal (STDERR) whenever it encounters a bad block.
    – johnshen64
    Jul 22, 2013 at 14:37

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .