DebOrphan and GtkOrphan, remove the packages that your Ubuntu does not use

DebOrphan GtkOrphan name

In the next article we are going to take a look at a couple of tools called DebOrphan and GtkOrphan. Keep our operating system clean it is always a good idea for a correct operation of the same. For this reason, it is always advisable to review unused packages (orphaned packages) that accumulate on our hard drive with the installation and uninstallation of programs.

Orphaned (unused) packages are nothing more than packages that will be installed as dependencies / libraries when we install software on our system. As everyone knows, whenever we install an application, these dependencies will also be installed along with the application. Dependencies can remain on our hard drive even after we have eliminated the application that uses them. This can lead to our hard drive being flooded with unused or orphaned packages, causing space to run out on the drive.

El disc space Low not only affects the performance of the system, but it can also be a problem when we want to install a new large program and we are short of space. Therefore, it is advisable to add this cleaning to the maintenance of our system.

Today there are many maintenance programs for Ubuntu, but in this article we will see how remove unused, unwanted or orphaned packages using Deborphan or GtkOrphan. These two utilities that are still two good options, work perfectly in Ubuntu and its derivatives, such as Linux Mint and elementary OS.

Deborphan, find and remove unused packages

Deborphan is a command line utility. This is used to find and remove unused or orphaned packages on both desktops and servers. Luckily, it is available in the official repositories, even though I think no longer keeps updating. To install it, we will only have to open the terminal (Ctrl + Alt + T) and execute the following command:

sudo apt install deborphan

Once installed, we can run it as shown below to find the orphaned packages.

deborphan

Application it will show us a list of the packages found, in the same way that can be seen in the following capture:

deborphan listed

Once identified, to remove the orphaned packages, we will execute in the same terminal:

sudo orphaner

deborphan cleaning files

Select the files and select "OK" to delete them.

GtkOrphan, find and remove unused packages

This is the graphical tool that allows us to find and remove orphaned packages. Gtkorphan works only on desktop editions. If you are using Ubuntu server without GUI, use Deborphan instead.

Gtkorphan is available in the official repositories, although like the previous utility, I think it has been a long time ago it does not actualize. To install it, run in the terminal (Ctrl + Alt + T):

sudo apt install gtkorphan

Once installed, we will be able to start it by running the following command from the terminal:

sudo gtkorphan

The default interface of Gtkorphan will be the same that can be seen below:

gtkorphan screen

Since I already removed the orphaned packets with the above program, the capture does not show any packets. However, from the main window we can expand the "Options" section. In the options that will be shown, we will have to check the box that says «Show all orphaned packages, not just the ones in the libs section«.

gtkorphan listed important packages

Now Gtkorphan will list all orphaned packages. Here you have to be careful. As seen in the image above, Gtkorphan lists some important packages as unused. We must not remove them. To save the important packages, we will have to right click on the package name. In the drop down menu, we just have to click on the package option Hibernate package.

gtkorphan keep package

This will prevent Gtkorphan from removing packages that are still needed by the system. We will only have to do this the first time. After that, you can remove the orphaned packages if they exist.

Once we have all the important packages selected and saved, we scroll down the list. If we do not need a package, we will click on it and the "Select to remove" option.

How to Live Aligned with alternative, we can always run the following command to remove unused / orphaned packages at the same time.

sudo apt-get autoclean && sudo apt-get autoremove

uninstall

To remove these programs from our Ubuntu system, we will just have to do the usual. To remove Deborphan, we open a terminal (Ctrl + Alt + T) and type:

sudo apt remove deborphan

If we have chosen to install GtkOrphan, in the terminal we will write:

sudo apt remove gtkorphan

Leave a Comment

Your email address will not be published. Required fields are marked with *

*

*

  1. Responsible for the data: Miguel Ángel Gatón
  2. Purpose of the data: Control SPAM, comment management.
  3. Legitimation: Your consent
  4. Communication of the data: The data will not be communicated to third parties except by legal obligation.
  5. Data storage: Database hosted by Occentus Networks (EU)
  6. Rights: At any time you can limit, recover and delete your information.

  1.   Sugi Sandoval said

    Good info, I will be aware of the forum.
    Thanks: 3
    regards