Results 1 to 5 of 5

Thread: sudo apt-get clean / auto clean / autoremove

  1. #1
    Join Date
    Feb 2018
    Location
    Poland
    Beans
    38
    Distro
    Ubuntu Mate

    sudo apt-get clean / auto clean / autoremove

    A couple of simple questions: should I or shouldn't I use the following commands in terminal let's say, once a month? How often do you do it?

    sudo apt-get clean
    sudo apt-get auto clean
    sudo apt-get autoremove

  2. #2
    Join Date
    Aug 2013
    Beans
    4,941

    Re: sudo apt-get clean / auto clean / autoremove

    I do it whenever I am bored. Actually I use bleachbit Too lazy to type.

  3. #3
    Join Date
    Apr 2011
    Location
    Mystletainn Kick!
    Beans
    13,616
    Distro
    Ubuntu

    Re: sudo apt-get clean / auto clean / autoremove

    clean makes autoclean moot.
    Since clean clears everything out.
    (autoclean only clears the older package version archives out.)
    Both clear out the downloaded installer packages that the system archives for you.

    autoremove is something different.
    it actually removes installed software, that the system has deemed old and obsolete.

    So run one of the clean commands and the autoremove command.
    Your choice as to which.

    How often will depend on how liberal or stingy you were when you setup Ubuntu, in regards to the amount of hard drive space.
    If you allocated a large amount of space, then you could go years without running those commands.
    But if you allocated a very small amount, then you might need to run them weekly or biweekly, depending on things like what new updates come.
    (or if you need the space for your own personal files)
    Splat Double Splat Triple Splat
    Earn Your Keep
    Don't mind me, I'm only passing through.
    Once in a blue moon, I'm actually helpful
    .

  4. #4
    Join Date
    Aug 2013
    Beans
    4,941

    Re: sudo apt-get clean / auto clean / autoremove

    Quote Originally Posted by deadflowr View Post
    clean makes autoclean moot.

    autoremove is something different.
    it actually removes installed software, that the system has deemed old and obsolete.

    No, it doesn't. It removes software which are installed as dependencies of others, which you have uninstalled. Say sudo apt install A brings in B as a dependency, now you have uninstalled A (not through autoremove!) then B becomes autoremovable. The only exception I know of is old kernels. Ubuntu keeps two kernels by default, so when it upgrades to a third one, the oldest one becomes autoremovable. Since Ubuntu apparently by default puts all kernels in a tiny /boot partition ( if you install automatically, since I always do manual I can't be sure, just from reading forum threads) and many people have problems when /boot is full, I think one should do autoremove more often.

  5. #5
    Join Date
    Dec 2017
    Location
    RockyMts
    Beans
    1,167

    Re: sudo apt-get clean / auto clean / autoremove


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •