I don't want to wipe my hard drive. I just want to get rid of all the extra software I've installed over time, and return to a prisitine, default system.

  • You might not need an actual reinstall at all. If you just remove the things you know you don't want and install xubuntu-desktop, you might find that performance perks up a bit. I'm not saying you shouldn't reinstall, just that you don't necessarily need to.
    – koanhead
    Dec 26, 2010 at 21:28

5 Answers 5


I do this occasionally, using aptitude. Aptitude is a console ("old-skool") tool that's powerful but a little tricky to get to use. It's like vim or emacs, when Ubuntu Software Center is like Gedit or AbiWord :-) Nevertheless, there's a good way to achieve your goal in aptitude, so if you're willing to give it a try, this might work for you.

First install aptitude:

sudo apt-get install aptitude

You might want to read the docs for aptitude. If you don't, you'll be following my directions below blind, and could fly into a mountainside that leaves your system unbootable, in which case you'll need to try one of the "careful reinstall" options where you do a fresh install trying to preserve your personal data along the way. The docs for aptitude are at:

zless /usr/share/doc/aptitude/README

Now, go into aptitude. I'll tell you a series of keys to press. The case (upper or lower) is significant: U is different to u.

sudo aptitude

u (this updates the package database. press enter to clear any warnings that popup afterwards)

arrow down to the section called "Installed packages"

M (this marks every package as automatically installed, so it schedules all of them for removal. don't quit now or you'll be in trouble)

/ (this opens a search dialog)

ubuntu-desktop [ENTER]

+(this tells aptitude you want to install ubuntu-desktop and all dependencies)

[ENTER] (goes into the details for the ubuntu-desktop package)

arrow down to the "Recommends" line

+ (tells aptitude to install all the recommended packages too)

g ("go" - will tell you what it wants to do)

g (confirms that you want to do it, and gets going)

That should leave you fully up to date, with a relatively clean, minimal desktop system.

If you get stuck, hit ? for help in aptitude. You may need to use a or z to scroll up and down in various places. I did say it was old-skool :-) But once you know how to use it, you can get a lot of detailed package management done quickly.


You can reinstall without losing your data if you follow the instructions here.


To simply get a "fresh desktop" the easiest way would be to create a new user that always starts off with a clean and default desktop. If there is still the one or other package in your way it's probably the least time consuming thing to just purge these single packages.

Removing software you installed or performing a reinstall of Ubuntu only makes sense if the amount of harddisk space occupied is significant or if many of the apps are buggy and affect the system performance.

Before you proceed with deleting or reinstalling I recommend you check first if your system performance will really benefit from doing so.

  • That's certainly the simplest way (though getting used to a new username would be unfortunate and all)
    – Kzqai
    Apr 11, 2012 at 16:01
  • 1
    @Tchalvak, You can then remove the older user account, and then create another new user account of the former name. This is actually cool
    – Anwar
    Jul 6, 2012 at 9:42
  • Hah, that is tricky indeed. I may have to try that myself to get that "new computer" smell/speed.
    – Kzqai
    Jul 6, 2012 at 14:55

I see if he installs it and doesn't format the installer will spare his home folder.

In any case the two partition recommendation is still valid (os and data should be separated)


There is an easier and less intricate way of achieving Mark's solution.

sudo apt-get install aptitude
sudo aptitude markauto '~i !~M !ubuntu-desktop'

The former command installs aptitude.

The latter command says "Mark every manually installed package that is not ubuntu-desktop as automatically installed". aptitude will then interpret all packages that are not required or recommended by ubuntu-desktop as unnecessary dependencies, and remove them.

  • it wants to remove everything!! :P
    – jrg
    Dec 4, 2012 at 23:26

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .