How can I remove all software installed on my Linux distribution? I'm using Debian:
$ uname -a
Linux debian 3.2.0-4-amd64 #1 SMP Debian 3.2.51-1 x86_64 GNU/Linux
I want to go back to the original installed software.
Is there any built-in way to do it in a single command?
Best Answer
You can get a list of all the packages you ever installed from the
apt
history files. These live under/var/log/apt/
:The final step will print a list of all the packages you installed manually, all on one line so you can easily pass them to
apt-get
. That said, removing all these packages in one shot is quite risky and will probably result in unrecoverable system breakage. Proceed with caution and make sure you know exactly what you're doing!