0

I installed pv so I could check progress of a usb installation, and I began the process with sudo dd if= | pv | of=/dev/sdb.

Well, it's supposed to ask me for my sudo password, but when I pressed Enter, it started showing progress before I could enter the password. I went ahead and attempted to type the password, but it was mixed in with the progress text. So, then I decided to do Ctrl+C to stop it.

My question is: Can I just do "sudo dd if=/dev/urandom of=/dev/sdb" to erase any data and start over? I JUST bought this drive today, so this is frustrating. I'm definitely not doing that again.

Thanks.

1
  • if your command was sudo dd if=<data_here> | pv | of=/dev/sdb you probably didn't write anything to /dev/sdb – user448115 Jun 4 '16 at 14:11
0

If you will be writing another image onto it (Using dd or the graphical USB image writer included in Ubuntu, or some other tool), there is no need to erase anything first, just start over and write the new image directly onto it.

If you want to use it to store files, you can format it using the graphical "Disks" utility, again no need to erase anything first.

However, overwriting the contents with sudo dd if=/dev/urandom of=/dev/sdb won't do any harm either, although i'd recommend using if=/dev/zero, since it may be faster.

1
  • Thank you. I got it going. Btw, I was installing a disk image (.iso) in case anyone was wondering. – DevOpsSauce Jun 4 '16 at 15:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.