1

I have 3 hard disks 1T each. I want to wipe them out completely. I decided yo use dd like so:

dd if=/dev/zero of=/dev/sdb bs=1M
dd if=/dev/zero of=/dev/sdc bs=1M
dd if=/dev/zero of=/dev/sdd bs=1M

Since it takes a while for the commands to complete, can I assume that it will be faster if I open 3 different consoles and execute the commands simultaneously?

Will it be 3 times faster compared to executing them sequentially?

Pavel Tankov
  • 376
  • 3
  • 16
  • 1
    That is something you could easily test, right? But my guess is that it is the drives themselves and not the controller they are attached to, that would be the limiting factor and you can run all `dd` commands in parallel without one `dd` session negatively impacting the other. – HBruijn Mar 02 '18 at 11:26
  • Secure erase would be faster still. – Michael Hampton Mar 02 '18 at 15:55

1 Answers1

1

OK, I went on and did a small experiment. It seems that running the commands simultaneously isn't exactly 3 times faster, but it's way faster than one-by-one.

I ran them all, then monitored the progress by typing:

watch -n5 'sudo kill -USR1 $(pgrep ^dd)'

When all 3 commands are running, I get about 100 MB/s. If I stop 2 other and leave just 1 instance of dd running, the speed increases to about 120 MB/s.

That is of course just in the beginning while the disk is being written on the outer-most cylinders, where it's fastest. Later speed drops proportionally a little bit, but still the conclusion is this:

Yes, it is a lot faster to do this wiping out simultaneously.

Pavel Tankov
  • 376
  • 3
  • 16