Unable to remove files since there is "No space left on device"

Asked by Eduardo Zelada Lau on 2019-08-27

I was unable to login in my root user. It return to the login session whenever I try to login. Then I realize that I had no space left on the device. I tried to eliminate some unused kernels, however neither "sudo apt-get autoremove" nor "sudo dpkg --purge linux-{image,headers}-3.16.0-{xx,yy,zz}" works. It says that there's no space left on device.

From what I read in other threads, here are the results from the diagnostic command (uname -a; lsb_release -crid; df -h; dpkg -l | grep' linux-image')

Linux Mendel-GRU 3.13.0-168-generic #218-Ubuntu SMP Thu Mar 14 16:56:08 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux

Distributor ID: Ubuntu

Description: Ubuntu 14.04.6 LTS

Release: 14.04

Codename: trusty

Filesystem Size Used Avail Use% Mounted on

udev 7,8G 4,0K 7,8G 1% /dev

tmpfs 1,6G 1,4M 1,6G 1% /run

/dev/sda1 443G 438G 0 100% /

none 4,0K 0 4,0K 0% /sys/fs/cgroup

none 5,0M 0 5,0M 0% /run/lock

none 7,8G 152K 7,8G 1% /run/shm

none 100M 68K 100M 1% /run/user

overflow 1,0M 16K 1008K 2% /tmp

none 7,8G 1,5M 7,8G 1% /tmp/guest-nIFzAb

rc linux-image-3.13.0-141-generic 3.13.0-141.190
     amd64 Linux kernel image for version 3.13.0 on 64 bit x86 SMP

rc linux-image-3.13.0-142-generic 3.13.0-142.191
     amd64 Linux kernel image for version 3.13.0 on 64 bit x86 SMP

rc linux-image-3.13.0-160-generic 3.13.0-160.210
     amd64 Linux kernel image for version 3.13.0 on 64 bit x86 SMP

rc linux-image-3.13.0-161-generic 3.13.0-161.211
     amd64 Linux kernel image for version 3.13.0 on 64 bit x86 SMP
rc linux-image-3.13.0-162-generic 3.13.0-162.212
     amd64 Linux kernel image for version 3.13.0 on 64 bit x86 SMP

rc linux-image-3.13.0-165-generic 3.13.0-165.215
     amd64 Linux kernel image for version 3.13.0 on 64 bit x86 SMP

ii linux-image-3.13.0-168-generic 3.13.0-168.218
     amd64 Signed kernel image generic

rc linux-image-3.13.0-24-generic 3.13.0-24.47
     amd64 Linux kernel image for version 3.13.0 on 64 bit x86 SMP

rc linux-image-3.13.0-29-generic 3.13.0-29.53
     amd64 Linux kernel image for version 3.13.0 on 64 bit x86 SMP

rc linux-image-3.13.0-32-generic 3.13.0-32.57
     amd64 Linux kernel image for version 3.13.0 on 64 bit x86 SMP

rc linux-image-3.13.0-35-generic 3.13.0-35.62
     amd64 Linux kernel image for version 3.13.0 on 64 bit x86 SMP

rc linux-image-3.13.0-36-generic 3.13.0-36.63
     amd64 Linux kernel image for version 3.13.0 on 64 bit x86 SMP

rc linux-image-3.13.0-40-generic 3.13.0-40.69
     amd64 Linux kernel image for version 3.13.0 on 64 bit x86 SMP

rc linux-image-3.13.0-43-generic 3.13.0-43.72
    amd64 Linux kernel image for version 3.13.0 on 64 bit x86 SMP

rc linux-image-3.13.0-45-generic 3.13.0-45.74
    amd64 Linux kernel image for version 3.13.0 on 64 bit x86 SMP

rc linux-image-3.13.0-46-generic 3.13.0-46.79
    amd64 Linux kernel image for version 3.13.0 on 64 bit x86 SMP

rc linux-image-3.13.0-48-generic 3.13.0-48.80
    amd64 Linux kernel image for version 3.13.0 on 64 bit x86 SMP

rc linux-image-3.13.0-49-generic 3.13.0-49.83
    amd64 Linux kernel image for version 3.13.0 on 64 bit x86 SMP

rc linux-image-3.13.0-53-generic 3.13.0-53.89
    amd64 Linux kernel image for version 3.13.0 on 64 bit x86 SMP

pH linux-image-extra-3.13.0-141-generic 3.13.0-141.190
    amd64 Linux kernel extra modules for version 3.13.0 on 64 bit x86 SMP

rH linux-image-extra-3.13.0-142-generic 3.13.0-142.191
    amd64 Linux kernel extra modules for version 3.13.0 on 64 bit x86 SMP

rH linux-image-extra-3.13.0-160-generic 3.13.0-160.210
    amd64 Linux kernel extra modules for version 3.13.0 on 64 bit x86 SMP

rH linux-image-extra-3.13.0-161-generic 3.13.0-161.211
    amd64 Linux kernel extra modules for version 3.13.0 on 64 bit x86 SMP

rH linux-image-extra-3.13.0-162-generic 3.13.0-162.212
    amd64 Linux kernel extra modules for version 3.13.0 on 64 bit x86 SMP

rH linux-image-extra-3.13.0-165-generic 3.13.0-165.215
    amd64 Linux kernel extra modules for version 3.13.0 on 64 bit x86 SMP

rc linux-image-extra-3.13.0-24-generic 3.13.0-24.47
    amd64 Linux kernel extra modules for version 3.13.0 on 64 bit x86 SMP

rc linux-image-extra-3.13.0-29-generic 3.13.0-29.53
    amd64 Linux kernel extra modules for version 3.13.0 on 64 bit x86 SMP

rc linux-image-extra-3.13.0-32-generic 3.13.0-32.57
    amd64 Linux kernel extra modules for version 3.13.0 on 64 bit x86 SMP

rc linux-image-extra-3.13.0-35-generic 3.13.0-35.62
    amd64 Linux kernel extra modules for version 3.13.0 on 64 bit x86 SMP

rc linux-image-extra-3.13.0-36-generic 3.13.0-36.63
    amd64 Linux kernel extra modules for version 3.13.0 on 64 bit x86 SMP

rH linux-image-extra-3.13.0-40-generic 3.13.0-40.69
    amd64 Linux kernel extra modules for version 3.13.0 on 64 bit x86 SMP

rH linux-image-extra-3.13.0-43-generic 3.13.0-43.72
    amd64 Linux kernel extra modules for version 3.13.0 on 64 bit x86 SMP

rH linux-image-extra-3.13.0-45-generic 3.13.0-45.74
    amd64 Linux kernel extra modules for version 3.13.0 on 64 bit x86 SMP

rH linux-image-extra-3.13.0-46-generic 3.13.0-46.79
    amd64 Linux kernel extra modules for version 3.13.0 on 64 bit x86 SMP

rH linux-image-extra-3.13.0-48-generic 3.13.0-48.80
    amd64 Linux kernel extra modules for version 3.13.0 on 64 bit x86 SMP

rH linux-image-extra-3.13.0-49-generic 3.13.0-49.83
    amd64 Linux kernel extra modules for version 3.13.0 on 64 bit x86 SMP

rH linux-image-extra-3.13.0-53-generic 3.13.0-53.89
    amd64 Linux kernel extra modules for version 3.13.0 on 64 bit x86 SMP

ii linux-image-generic 3.13.0.168.179
    amd64 Generic Linux kernel image

Thanks for help. I'm waiting for a response.

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu Edit question
Assignee:
No assignee Edit question
Solved by:
Manfred Hampl
Solved:
2019-09-03
Last query:
2019-09-03
Last reply:
2019-08-28
Bashing-om (bashing-om) said : #1

Eduardo Zelada Lau; Hello -

I be that harbinger if ill news:
"Ubuntu 14.04 LTS (Trusty Tahr) was the 20th release of Ubuntu. !End-of-life was April 25th, 2019.
               Paid support (ESM) is available."

As 14.04 no longer has support - how much effort to you want to expend to salvage this install as apposed to a fresh clean install of a current release ? And still have to make the release upgrade if you choose to salvage.

-hard row to hoe-

Best Manfred Hampl (m-hampl) said : #2

bashing-om's answer is correct.
Ubuntu 14.04 is no more supported except for paid extended maintenance for server systems.

Your hard disk is full, probably with lots of files from unused versions of the kernel packages.

You should decide what you want to do:
- do a new installation from scratch with a supported Ubuntu version
or
- try removing obsolete files to get your 14.04 version running, and then do an upgrade to a supported release.

An important factor can be, if there are many files stored on the system that you want to keep.

As a first diagnostic command towards repairing the old system what is the output of
ls -l /boot

Eduardo Zelada Lau (ezeta1) said : #3

Thanks for the early response.

Hopefully all the important files have been back up in a cloud. What would be the procedure in order to install a current release?

Manfred Hampl (m-hampl) said : #4

To install a current version of Ubuntu visit https://ubuntu.com/download/desktop

Download the installer iso file, and either burn a DVD with it or create a bootable USB-stick (instructions on the bottom of the page mentioned above).

Of course you have to be aware that you cannot store the installer on your full hard disk!

Eduardo Zelada Lau (ezeta1) said : #5

Ok, so I just setup a USB flash drive (8GB Kingston) containing the ISO file that I made using rufus.

When I connect the USB to my computer with Ubuntu 14.04 LTS for the boot procedure, I'm not able to boot it. I've tried rebooting several times, changing the ports. It just direct me directly to the ubuntu OS.

Manfred Hampl (m-hampl) said : #6

You have temporarily change the boot device priority in your computer BIOS, that it boots the USB stick instead of the operating system on the hard disk.
I assume that very early in the boot process you see some kind of welcome screen (probably with a logo from your computer's manufacturer) and a text somewhat similar to "press ESC for BIOS setup, or F10 for selecting boot device".

You immediately have to press the key that is mentioned there and then select to boot from the USB stick.

Eduardo Zelada Lau (ezeta1) said : #7

Thanks Manfred Hampl, that solved my question.