GNU bug report logs -
#6667
dd ?bug? while making image of hdd with bad sectors
Previous Next
Reported by: Jakub Muszynski <sirkubax <at> gmail.com>
Date: Mon, 19 Jul 2010 13:17:02 UTC
Severity: normal
Tags: notabug
Done: Assaf Gordon <assafgordon <at> gmail.com>
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 6667 in the body.
You can then email your comments to 6667 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
owner <at> debbugs.gnu.org, bug-coreutils <at> gnu.org
:
bug#6667
; Package
coreutils
.
(Mon, 19 Jul 2010 13:17:02 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Jakub Muszynski <sirkubax <at> gmail.com>
:
New bug report received and forwarded. Copy sent to
bug-coreutils <at> gnu.org
.
(Mon, 19 Jul 2010 13:17:02 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
Hello,
It's my first post here, i hope it might be usefull.
My full story can be found here:
http://ubuntuforums.org/showthread.php?p=9607705#post9607705
I will try to summarize it here:
I have broken (fall) hdd, now im sure that's contain ~2GB od broken
sectors, in 1/3 of disc capacity.
I have been trying to make a dd copy :
dd if=/dev/sdb conv=noerror,sync bs=4096k|pv| dd of=usb320.dd
conv=noerror,sync bs=4096k > dd320.LOG
but image took all my free diskspace (406GB), and terminated, eventhough
my hdd is 320GB, (btw, a option to log dd output(errors) would be
usefull, since i use screen terminal)
root <at> gamma:/home/jacek# fdisk -l /dev/sdb
Disk /dev/sdb: 320.1 GB, 320072933376 bytes
255 heads, 63 sectors/track, 38913 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x5517132d
Device Boot Start End Blocks Id System
/dev/sdb1 1 262 2098176 27 Unknown
/dev/sdb2 * 263 5485 41948749 7 HPFS/NTFS
/dev/sdb3 5486 38913 268510410 f W95 Ext'd (LBA)
/dev/sdb5 12037 38913 215889502+ 83 Linux
/dev/sdb6 8696 12036 26836551 b W95 FAT32
/dev/sdb7 5486 6377 7164927 83 Linux
/dev/sdb8 6378 6499 979933+ 82 Linux swap / Solaris
Partition table entries are not in disk order
finally i managed to make image with this command:
dd if=/dev/sdb conv=noerror,sync |pv| dd of=usb320.dd conv=noerror,sync > dd320.LOG
i guess that problem is bs size + sync + badblocks
My disc contain about 2GB bad blocks (around 112Gbyte sector)
thoese 4194304 sectors, exchenged (due to sync flag) for empty sectors
in image file, would be:
with bs=4096k: 4194304 * 4096k = 17592GB (that would definitely not fit
on my disk)
with bs=512: 4194304 * 512 = 2147MB (thats ok)
so i guess, that dd is not considering what is block size while
exchanging broken block in the image file.
I'm not sure if it can be called a bug, but in my opinion is should be
at least mentioned in manual (to care about block size while making dump
of broken disc)
btw - ddrescue also filed to complete backup.
if you want more feedback - i still have the same hardware
configuration, so i can provide more test
Sirkubax
root <at> gamma:/mnt/csda8# dd --version
dd (coreutils) 7.4
Copyright (C) 2009 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later
<http://gnu.org/licenses/gpl.html>.
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Written by Paul Rubin, David MacKenzie, and Stuart Kemp.
root <at> gamma:/mnt/csda8#
Information forwarded
to
owner <at> debbugs.gnu.org, bug-coreutils <at> gnu.org
:
bug#6667
; Package
coreutils
.
(Mon, 19 Jul 2010 14:45:03 GMT)
Full text and
rfc822 format available.
Message #8 received at 6667 <at> debbugs.gnu.org (full text, mbox):
On 19/07/10 10:05, Jakub Muszynski wrote:
> Hello,
>
> It's my first post here, i hope it might be usefull.
> My full story can be found here:
> http://ubuntuforums.org/showthread.php?p=9607705#post9607705
> I will try to summarize it here:
>
> I have broken (fall) hdd, now im sure that's contain ~2GB od broken
> sectors, in 1/3 of disc capacity.
> I have been trying to make a dd copy :
>
> dd if=/dev/sdb conv=noerror,sync bs=4096k|pv| dd of=usb320.dd
> conv=noerror,sync bs=4096k > dd320.LOG
>
> but image took all my free diskspace (406GB), and terminated, eventhough
> my hdd is 320GB
dd doesn't read full blocks by default,
so one has to be careful when reading from pipes.
Is pv showing less than 406GB transferred?
less would suggest the issue is with the second dd.
Does adding "iflag=fullblock" to the second dd fix things?
Since you're not specifying a count, just removing the
"sync" option from the second dd is equivalent.
Note one can can progress from dd by sending `kill -USR1`
to the $pid every so often.
Note also that one could get a proper progress bar from pv with:
pv -s $(blockdev --getsize64 /dev/sdb)
> (btw, a option to log dd output(errors) would be
> usefull, since i use screen terminal)
How about just doing: 2>error.log
> btw - ddrescue also filed to complete backup.
Surprising since this is what it's designed for.
cheers,
Pádraig.
Information forwarded
to
bug-coreutils <at> gnu.org
:
bug#6667
; Package
coreutils
.
(Wed, 10 Oct 2018 17:14:01 GMT)
Full text and
rfc822 format available.
Message #11 received at 6667 <at> debbugs.gnu.org (full text, mbox):
tags 6667 notabug
close 6667
stop
Hello,
On 19/07/10 08:44 AM, Pádraig Brady wrote:
> On 19/07/10 10:05, Jakub Muszynski wrote:
>> I have been trying to make a dd copy :
>>
>> dd if=/dev/sdb conv=noerror,sync bs=4096k|pv| dd of=usb320.dd
>> conv=noerror,sync bs=4096k > dd320.LOG
>>
>> but image took all my free diskspace (406GB), and terminated, eventhough
>> my hdd is 320GB
>
> dd doesn't read full blocks by default,
> so one has to be careful when reading from pipes.
[...]
> Does adding "iflag=fullblock" to the second dd fix things?
> Since you're not specifying a count, just removing the
> "sync" option from the second dd is equivalent.
With no further comments in 8 years, I'm closing this item.
regards,
- assaf
Added tag(s) notabug.
Request was from
Assaf Gordon <assafgordon <at> gmail.com>
to
control <at> debbugs.gnu.org
.
(Wed, 10 Oct 2018 17:14:02 GMT)
Full text and
rfc822 format available.
bug closed, send any further explanations to
6667 <at> debbugs.gnu.org and Jakub Muszynski <sirkubax <at> gmail.com>
Request was from
Assaf Gordon <assafgordon <at> gmail.com>
to
control <at> debbugs.gnu.org
.
(Wed, 10 Oct 2018 17:14:02 GMT)
Full text and
rfc822 format available.
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Thu, 08 Nov 2018 12:24:06 GMT)
Full text and
rfc822 format available.
This bug report was last modified 5 years and 180 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.