How can I delete Ubuntu temp files which are created during software installation or upgrade?

12,773

I would try to clean the repository of downloaded packages. Either of these commands (see man apt-get).

apt-get autoclean
apt-get clean

If you don't have /tmp on tmpfs, you may want to delete all the files and directories under /tmp. A tool like tmpreaper can be used to keep it clean. You can also set edit /etc/defaults/rcS and uncomment the TMPTIME=0 line to have /tmp cleaned on reboot.

If you can't boot fully, you can try booting into recovery mode. If you can boot that far, you will need to mount the disk in read-write mode before cleaning it up. Running the command mount -a should mount all the file systems so you can do cleanup. Once you are done reboot.

Share:
12,773

Related videos on Youtube

Madhav Nikam
Author by

Madhav Nikam

I like to improve new thoughts, Technics, and philosophy. Love to computer, mathematics and nature. Agriculture is my soul, math is my mind, computer is my heart and knowledge is my breath. I think breathing of knowledge is very importance to make us alive.

Updated on September 18, 2022

Comments

  • Madhav Nikam
    Madhav Nikam over 1 year

    I make a very big mistake with my Ubuntu. I was try to install Ubuntu touch but disk disk has no space. My mistake is I not read/ neg-late need of primary requirement of space for installation of Ubuntu touch. Because of full disk space my Ubuntu does not start. I try to free more than 2 GB space by deleting media files. But after start Ubuntu that space also allocated or used by Ubuntu. I use commands

    sudo add-apt-repository ppa:phablet-team/tools
    sudo apt-get update
    sudo apt-get install ubuntu-emulator
    sudo apt-get upgrade
    sudo ubuntu-emulator create UbuntuTouch --arch=i386 --channel=ubuntu-touch/utopic-proposed
    when I use that commands during instalation process my Ubuntu is freeze and hang so I restart it but after restart it does not start. for solving that problem which files should I delete? suggest files or folder for delete which make free space but their delete not make cause of system failure. I don't like format my Ubuntu System.
    Note
    I have dual boot system in EduBOSS Linux I has full root privilege. I can access Ubuntu files by EduBOSS or BOOT repair disk.

    Ubuntu 14

    • Madhav Nikam
      Madhav Nikam almost 9 years
      When I delete anything from drive after restart disk is full and no space left ..