Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am going to be getting rid of a computer and giving it to a friend.

I want to wipe all documents and files, all Ubuntu mods and applications and give it to him with no data or application but the operating system still there. The harddrive is dedicated to Ubuntu.

Please help.

share|improve this question

First, use a command line program called shred to wipe everything from your hard drive. shred will overwrite your personal data with random numbers so that the original data is not recoverable.

To do this, create a Live USB Ubuntu drive that you can use to boot the computer from. If you can make the live USB persistent then installed files like shred will remain there for later use.

Using "Try Ubuntu" option in the live USB, install shred by typing in a Terminal

sudo apt-get install shred

Use man shred to learn about the program.

Finally use shred to wipe the computer's disk(s).

Second, Install Ubuntu. If you use the OEM install option, you can set it up with updates and install other software (like Chrome or Skype) without creating an user-ID for your friend. When your friend boots the computer for the dirst time s/he will be prompted for name language timezone etc. the final setup. See How do I pre-install Ubuntu for someone (OEM install)?.

Hope this helps.

share|improve this answer

Re-installing will cost you 30 mins and probably will be the only way that everything is back to factory. Consider that option, its the easiest path.

Download Ubuntu, burn it to a CD or transfer the install to a USB drive, boot and tell the install setup to remove and re-install the system.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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