[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Fw: How long will this take?



I ran a read test first to look for bad sectors on the new hard drive to see if it was damaged by the shipping process. Now I am writing to each sector, after looking around on the drive to inspect any data written by the manufacturer, to clear everything for the aforementioned reasons. Two files had been placed on the second partition by the manufacturer. The first partition did not have a file system. The manufacturer really screwed up the partitioning process. They started the first partition inside a physical 4096 byte sector. fdisk pointed this out in red text. The drive uses a logical sector size of 512 bytes, but uses a physical sector size of 4096 bytes. I still don't know the rest of the disk geometry.

name=Matthew%20Campbell&email=trenix25%40pm.me





-------- Original Message --------
On Jun 10, 2020, 10:02 AM, David Wright < deblis@lionunicorn.co.uk> wrote:

On Wed 10 Jun 2020 at 10:14:02 (-0400), Michael Stone wrote:
> On Mon, Jun 08, 2020 at 10:01:13PM -0500, David Wright wrote:
> > On Mon 08 Jun 2020 at 20:22:39 (+0000), Matthew Campbell wrote:
> > > I bought a new 4 terrabyte hard drive that is connected with a
> > > USB cable using USB2. It took about 32 hours to read every
> > > sector on the drive to look for bad sectors.
> >
> > I recently ran
> >
> > # badblocks -c 1024 -s -w -t random -v /dev/sdz
> >
> > on a 2TB disk with a USB2 connection. The whole process, writing and
> > checking, took 33⅓ hours. (The disk now holds an encrypted ext4 filesystem.)
>
> Yes, it's a slower process than just writing zeros. A modern drive
> will verify writes as they're made. badblocks is basically a relic of
> another age primarily intended to give a list of bad sectors to avoid
> when making a filesystem. Once upon a time, hard drives actually had a
> handwritten label on the top listing any bad sectors identified at the
> factory so you could avoid them. They don't have that anymore. If any
> modern hard drive has consistent bad (not remappable) sectors it
> should just be thrown away, because that means it is so far gone that
> it no longer has the ability to internally map bad sectors to reserved
> good sectors.
>
> > > I started blanking the sectors using /dev/zero last Friday
> > > night. It still isn't done. Is there a way I can find out how
> > > much data a particular process has written to the disk? I'm
> > > using Debian 10.4.
>
> > I'm not sure why you'd do that. I've only zeroed disks to erase them
> > before I return them to the owner. (They're inside loaned computers.)
>
> Because it accomplishes what your badblocks run does, in less than
> half the time. :)

I tried to make clear that my use case differed from that of the OP,
in case you missed that. Just before lockdown (=lockout). I borrowed
an AIO computer and, to make room, returned a 2006 vintage tower that
would no longer pass its POST. I used /dev/zero to erase all the
information from the disk as there was little point in trying to put
Windows XP (licensed to a dead computer) back onto it. Quick, easy,
and quick to check with od. Both l0f4r0 and I have asked why the OP
is zeroing the drive, but no reply yet. Perhaps you can suggest an
answer.

My use case for badblocks was closer to that of the OP, but still
different. Firstly, the disk contained personal data from unencrypted
use in the past. Secondly, I was intending to use it encrypted (as
mentioned) and prefer no high-watermark. Thirdly, because of its
age (2011), I was interested in seeing how well it performed. I have
no idea whether the disk is "modern" in the sense you used, as I don't
follow the technology like some people on this list evidently do.
Fourthly, I don't make a habit of throwing away 2TB disks.

But, as you know about these things, a few questions:

. How does badblocks do its job in readonly mode, given that it
doesn't know what any block's content ought to be.

. Why might the OP run badblocks, particularly non-destructively
(as if to preserve something), and *then* zero the drive.

. What's the easiest way of finding out about "consistent bad
(not remappable) sectors" on a drive, as I soon will have to
repeat this result (if not by this exact process) with a 3TB
disk of 2013 vintage. (The good news: it has a USB3 connection.)

Cheers,
David.


Reply to: