LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   how to use 'apt-get autoremove' to remove unnecessary packages (https://www.linuxquestions.org/questions/linux-newbie-8/how-to-use-apt-get-autoremove-to-remove-unnecessary-packages-4175527274/)

Gregg Bell 12-03-2014 11:25 PM

how to use 'apt-get autoremove' to remove unnecessary packages
 
I was installing something and ran into this (in the terminal). So just how do I remove them? Thanks!

The following packages were automatically installed and are no longer required:
libpostproc52 linux-headers-3.13.0-24 linux-headers-3.13.0-24-generic
linux-image-3.13.0-24-generic linux-image-extra-3.13.0-24-generic
Use 'apt-get autoremove' to remove them.

evo2 12-04-2014 12:42 AM

Hi,

you run exactly that command with root privs. Eg open a terminal an run
Code:

sudo apt-get autoremove
Evo2.

Gregg Bell 12-04-2014 11:59 PM

Quote:

Originally Posted by evo2 (Post 5279203)
Hi,

you run exactly that command with root privs. Eg open a terminal an run
Code:

sudo apt-get autoremove
Evo2.

Thanks Evo2. Is this how it would work out step by step?

So I run:

sudo apt-get autoremove

then I run:

libpostproc52 linux-headers-3.13.0-24 linux-headers-3.13.0-24-generic

then I run:

sudo apt-get autoremove

then I run:

linux-image-3.13.0-24-generic linux-image-extra-3.13.0-24-generic

evo2 12-05-2014 12:03 AM

Hi,

no you just have to run:
Code:

sudo apt-get autoremove
That's all.

Evo2.

Gregg Bell 12-05-2014 12:19 AM

Quote:

Originally Posted by evo2 (Post 5279821)
Hi,

no you just have to run:
Code:

sudo apt-get autoremove
That's all.

Evo2.

Evo, I did it and it wants to remove more than what I mentioned.

gregory@UpstairsComputer:~/Desktop$ sudo apt-get autoremove
[sudo] password for gregory:
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be REMOVED:
libpostproc52 linux-headers-3.13.0-24 linux-headers-3.13.0-24-generic
linux-image-3.13.0-24-generic linux-image-extra-3.13.0-24-generic
wine-gecko2.21 wine-mono0.0.8
0 upgraded, 0 newly installed, 7 to remove and 2 not upgraded.
After this operation, 290 MB disk space will be freed.
Do you want to continue? [Y/n]

I don't know what those other things do, so I said no. Should I go back in run it again and say yes? Which is another way of saying, 'Are those other things important or should I get rid of them?'

And 290MB seems a fair amount of file size. Maybe some of that stuff is imporant? I know I've been trying to do some stuff with WINE lately.

Is there any way to remove just the ones I mentioned?

evo2 12-05-2014 01:15 AM

Hi,

from the apt-get man page:
Code:

      autoremove
          autoremove is used to remove packages that were automatically
          installed to satisfy dependencies for other packages and are now no
          longer needed.

So I think you can just remove them. If you want more information about each package you can use apt-cache. Eg
Code:

apt-cache show <packagename>
If you just want to remove specific packages you can do:
Code:

sudo apt-get remove <packagename>
Or if you want to remove its configuration files too (you usually do).
Code:

sudo apt-get purge <packagename>
I recommend you read some apt tutorials online to learn how to use it.

HTH,

Evo2.

Gregg Bell 12-05-2014 01:44 AM

Quote:

Originally Posted by evo2 (Post 5279851)
Hi,

from the apt-get man page:
Code:

      autoremove
          autoremove is used to remove packages that were automatically
          installed to satisfy dependencies for other packages and are now no
          longer needed.

So I think you can just remove them. If you want more information about each package you can use apt-cache. Eg
Code:

apt-cache show <packagename>
If you just want to remove specific packages you can do:
Code:

sudo apt-get remove <packagename>
Or if you want to remove its configuration files too (you usually do).
Code:

sudo apt-get purge <packagename>
I recommend you read some apt tutorials online to learn how to use it.

HTH,

Evo2.

Thanks, Evo2, for the superb information. I will definitely learn more about removing them too. Really appreciate your effort.


All times are GMT -5. The time now is 11:11 PM.