Testing and erasing disks in bulk

mdownes

Active Member
Reaction score
120
Location
Dublin, Ireland
Does anyone know of an app that would test a bunch of disks sequentially without intervention? HGST's DFT for Windows almost does it, but you must acknowledge the results for one disk before it moves onto the next.

Similarly, I'm looking for something like DBAN that would securely erase (or even just encrypt) disks in the same fashion, in bulk, without intervention.

Any suggestions?
 
For your windows method you could always use autohotkey or sikuli to automate the process with image recognition as for a dban replacement eraser from heidi https://eraser.heidi.ie/ will let you do batches if you want something that writes multi passes.

There is also a tool I've been trying to use on the Redo Backup project that nukes drives but requires a hot swap
 
If you're looking to recycle/reuse drives there is no magic wand. Meaning you won't be able to knock 15-20 drives in a few hours.

A number of members here, myself included, use https://www.cru-inc.com/products/wiebetech/wiebetech_drive_erazer_ultra/.

But before I broke down and bought one this is what I did using Linux. Works well, but as I mentioned above, it'll take time. After all you have to write to the entire drive surface. One pass is all that needed. That whole 3 pass thing came about from comments made over 20 years ago about technology that hasn't been used in many years. It's all cli.

Using a tower, with an extra PCI SATA if needed, I'll boot to a Linux distro as root, any one will do as they all have the basic commands, and run fdisk -l > ~/before.txt. That put a file at the root of you home directory that lists all attached drives. They should all begin with sd (s for SATA/SCSI, IDE shows up as hd), followed by an a, b, c, etc. Shutdown and cable up all of the drives. You can actually use USB2SATA bridges as well if needed but they'll be slower. Power up and run fdisk -l > after.txt to get the list of newly attached drives, the ones you want erased. Again they'll be sd something again, but ending in different last letter. In this case ignore any number, like sdd2, as that represents a partition on a drive. Then start opening up terminal windows, one for each drive you want wiped. It's very important to keep track of what's what. You can actually run dd against your boot drive if it's writeable.

Say your doing sdb. In a window enter the command dd if=/dev/zero of=/dev/sdb bs=1m > ~sdb.txt. You'll have the file with a small amount of information output by dd. The drive will be over written with zero's. You can swap if for /dev/urandom but that'll be slower.

You'll do this in each different window for each hd, meaning another one would be sdc, etc. But it'll take some time. Several hours. So I just walk off and check on it that night/next morning.
 
I wish I could knock 15-20 drives in an hour :rolleyes: only way I can do that is with redo's function but a real pain to unlock the drives , humm maybe hook the HDD to the live power cable on the outside pole ...:eek: but ya @Markverhyden your method is way faster than using eraser I know parted magic iso has a wipe tool but I haven't had the chance to test it yet and attempt a recovery has anyone played with that function?
 
Hmm... hdparm? I remember ddrescue also having this capability I thought.
You can use ddrescue to fill a drive with zeros:

>ddrescue --force /dev/zero /dev/sd[x]

That is fine for erasing, but doesn't do a test read. I also don't recommend it for SSDs because it is harder on them.

So, using hdparm to set a password, then send a secure erase command it likely best. I haven't tried, but the startech satdupe11 has a secure erase function built in automatically doing it all for you.
 
Thanks @lcoughey for the badblock command, wasn't aware of it. On the secure erase for SSDs. I understand the part where it clears the crypto key on drives with built in crypto. But what happens on SSD drives without that?
 
Gravedigging an old thread that I still had open in a window because I've been doing some disk wipes and certification back to clients recently:

Most drives should support the ATA SECURE ERASE command, usable from within Parted Magic's disk erase software. The advantage of that is that you're telling the drive to do a wipe, not writing to the drive over the SATA connection. That should let the erase happen at the full potential speed of the drive. The included hex editor software is also capable of opening devices instead of files, so post-erasure you can go in, open the device and bounce to some random spots on the drive to confirm all zeros.

On SSDs the same command should just trigger the built-in erase, there's a separate option for NVME SSDs but I haven't used it.

One caveat: most drives will show as "Frozen" after boot which prevents running the drive erase, but all it takes to clear that state is power cycling the drive by putting the PC to sleep and waking it back up. There's a convenient button on the UI to do just that.
 
Back
Top