Page 3 of 3 FirstFirst 123
Results 21 to 26 of 26

Thread: Unable to clean/clear old kernels from /boot...

  1. #21
    Join Date
    Oct 2010
    Beans
    19

    Re: Unable to clean/clear old kernels from /boot...

    Quote Originally Posted by Impavidus View Post
    Exactly, that's the plan. And as dpkg does less checking, we have to do that ourselves. That's why I first want a list of all installed and partially installed kernels and the currently running version. The list of files in /boot may give false information in case of partially installed packages and I don't want to create even more inconsistencies by manually removing files, which could confuse dpkg when it tries to remove a package that's not properly installed, when package management says it's fully installed. The removal script may return an error, which can only be solved by reinstalling the package, then removing it again, when there's no room for that.

    So let's wait until OP reports back.
    I sincerely apologize to all for the delay. I travel for work and finally have some downtime to resume this, and wow has there been some discussion. To be honest I'm not quite sure who/where to follow, so I'll try to start answering some questions on output:


    Code:
    usr@sys:~$ dpkg --list | grep linux-
    ii  linux-base                            4.5ubuntu1~16.04.1                         all          Linux image base package
    ii  linux-firmware                        1.157.21                                   all          Firmware for Linux kernel drivers
    iU  linux-generic                         4.4.0.164.172                              amd64        Complete Generic Linux kernel and headers
    ii  linux-headers-4.4.0-148               4.4.0-148.174                              all          Header files related to Linux kernel version 4.4.0
    ii  linux-headers-4.4.0-148-generic       4.4.0-148.174                              amd64        Linux kernel headers for version 4.4.0 on 64 bit x86 SMP
    iU  linux-headers-4.4.0-150               4.4.0-150.176                              all          Header files related to Linux kernel version 4.4.0
    iU  linux-headers-4.4.0-150-generic       4.4.0-150.176                              amd64        Linux kernel headers for version 4.4.0 on 64 bit x86 SMP
    iU  linux-headers-4.4.0-151               4.4.0-151.178                              all          Header files related to Linux kernel version 4.4.0
    iU  linux-headers-4.4.0-151-generic       4.4.0-151.178                              amd64        Linux kernel headers for version 4.4.0 on 64 bit x86 SMP
    iU  linux-headers-4.4.0-164               4.4.0-164.192                              all          Header files related to Linux kernel version 4.4.0
    iU  linux-headers-4.4.0-164-generic       4.4.0-164.192                              amd64        Linux kernel headers for version 4.4.0 on 64 bit x86 SMP
    iU  linux-headers-generic                 4.4.0.164.172                              amd64        Generic Linux kernel headers
    rc  linux-image-4.4.0-101-generic         4.4.0-101.124                              amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-4.4.0-103-generic         4.4.0-103.126                              amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-4.4.0-104-generic         4.4.0-104.127                              amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-4.4.0-108-generic         4.4.0-108.131                              amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-4.4.0-109-generic         4.4.0-109.132                              amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-4.4.0-112-generic         4.4.0-112.135                              amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-4.4.0-116-generic         4.4.0-116.140                              amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-4.4.0-119-generic         4.4.0-119.143                              amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-4.4.0-121-generic         4.4.0-121.145                              amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-4.4.0-124-generic         4.4.0-124.148                              amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-4.4.0-127-generic         4.4.0-127.153                              amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-4.4.0-128-generic         4.4.0-128.154                              amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-4.4.0-130-generic         4.4.0-130.156                              amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-4.4.0-133-generic         4.4.0-133.159                              amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-4.4.0-134-generic         4.4.0-134.160                              amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-4.4.0-137-generic         4.4.0-137.163                              amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-4.4.0-138-generic         4.4.0-138.164                              amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-4.4.0-139-generic         4.4.0-139.165                              amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-4.4.0-141-generic         4.4.0-141.167                              amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-4.4.0-142-generic         4.4.0-142.168                              amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-4.4.0-143-generic         4.4.0-143.169                              amd64        Signed kernel image generic
    ii  linux-image-4.4.0-145-generic         4.4.0-145.171                              amd64        Signed kernel image generic
    iF  linux-image-4.4.0-148-generic         4.4.0-148.174                              amd64        Signed kernel image generic
    rc  linux-image-4.4.0-62-generic          4.4.0-62.83                                amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-4.4.0-72-generic          4.4.0-72.93                                amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-4.4.0-75-generic          4.4.0-75.96                                amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-4.4.0-77-generic          4.4.0-77.98                                amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-4.4.0-78-generic          4.4.0-78.99                                amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-4.4.0-79-generic          4.4.0-79.100                               amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-4.4.0-81-generic          4.4.0-81.104                               amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-4.4.0-83-generic          4.4.0-83.106                               amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-4.4.0-87-generic          4.4.0-87.110                               amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-4.4.0-89-generic          4.4.0-89.112                               amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-4.4.0-91-generic          4.4.0-91.114                               amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-4.4.0-92-generic          4.4.0-92.115                               amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-4.4.0-93-generic          4.4.0-93.116                               amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-4.4.0-96-generic          4.4.0-96.119                               amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-4.4.0-97-generic          4.4.0-97.120                               amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-4.4.0-98-generic          4.4.0-98.121                               amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-101-generic   4.4.0-101.124                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-103-generic   4.4.0-103.126                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-104-generic   4.4.0-104.127                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-108-generic   4.4.0-108.131                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-109-generic   4.4.0-109.132                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-112-generic   4.4.0-112.135                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-116-generic   4.4.0-116.140                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-119-generic   4.4.0-119.143                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-121-generic   4.4.0-121.145                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-124-generic   4.4.0-124.148                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-127-generic   4.4.0-127.153                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-128-generic   4.4.0-128.154                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-extra-4.4.0-130-generic   4.4.0-130.156                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-133-generic   4.4.0-133.159                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-extra-4.4.0-134-generic   4.4.0-134.160                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-extra-4.4.0-137-generic   4.4.0-137.163                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-extra-4.4.0-138-generic   4.4.0-138.164                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-extra-4.4.0-139-generic   4.4.0-139.165                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-extra-4.4.0-141-generic   4.4.0-141.167                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-extra-4.4.0-142-generic   4.4.0-142.168                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-62-generic    4.4.0-62.83                                amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-72-generic    4.4.0-72.93                                amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-75-generic    4.4.0-75.96                                amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-77-generic    4.4.0-77.98                                amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-78-generic    4.4.0-78.99                                amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-79-generic    4.4.0-79.100                               amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-81-generic    4.4.0-81.104                               amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-83-generic    4.4.0-83.106                               amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-87-generic    4.4.0-87.110                               amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-89-generic    4.4.0-89.112                               amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-91-generic    4.4.0-91.114                               amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-92-generic    4.4.0-92.115                               amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-93-generic    4.4.0-93.116                               amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-96-generic    4.4.0-96.119                               amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-97-generic    4.4.0-97.120                               amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    rc  linux-image-extra-4.4.0-98-generic    4.4.0-98.121                               amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    iU  linux-image-generic                   4.4.0.164.172                              amd64        Generic Linux kernel image
    ii  linux-modules-4.4.0-143-generic       4.4.0-143.169                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    ii  linux-modules-4.4.0-145-generic       4.4.0-145.171                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    ii  linux-modules-4.4.0-148-generic       4.4.0-148.174                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    ii  linux-modules-extra-4.4.0-143-generic 4.4.0-143.169                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    ii  linux-modules-extra-4.4.0-145-generic 4.4.0-145.171                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    ii  linux-modules-extra-4.4.0-148-generic 4.4.0-148.174                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    iU  linux-modules-extra-4.4.0-150-generic 4.4.0-150.176                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    iU  linux-modules-extra-4.4.0-151-generic 4.4.0-151.178                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    iU  linux-modules-extra-4.4.0-164-generic 4.4.0-164.192                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    And:

    Code:
    usr@sys:~$ uname -r
    4.4.0-145-generic
    And:

    Code:
    usr@sys:~$ df -h /boot
    Filesystem      Size  Used Avail Use% Mounted on
    /dev/sda1       472M  469M     0 100% /boot
    And:
    Code:
    usr@sys:~$ dpkg -l |egrep linux-image | grep '^ii'
    ii  linux-image-4.4.0-130-generic         4.4.0-130.156                              amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-4.4.0-134-generic         4.4.0-134.160                              amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-4.4.0-137-generic         4.4.0-137.163                              amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-4.4.0-138-generic         4.4.0-138.164                              amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-4.4.0-139-generic         4.4.0-139.165                              amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-4.4.0-141-generic         4.4.0-141.167                              amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-4.4.0-142-generic         4.4.0-142.168                              amd64        Linux kernel image for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-4.4.0-143-generic         4.4.0-143.169                              amd64        Signed kernel image generic
    ii  linux-image-4.4.0-145-generic         4.4.0-145.171                              amd64        Signed kernel image generic
    ii  linux-image-extra-4.4.0-130-generic   4.4.0-130.156                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-extra-4.4.0-134-generic   4.4.0-134.160                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-extra-4.4.0-137-generic   4.4.0-137.163                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-extra-4.4.0-138-generic   4.4.0-138.164                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-extra-4.4.0-139-generic   4.4.0-139.165                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-extra-4.4.0-141-generic   4.4.0-141.167                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    ii  linux-image-extra-4.4.0-142-generic   4.4.0-142.168                              amd64        Linux kernel extra modules for version 4.4.0 on 64 bit x86 SMP
    Did I miss any requests for output?

    Should I start following rsteinmetz70112's instructions?

    Thank you all so much for any time you've given. This is turning out to be a mess!

  2. #22
    Join Date
    Aug 2011
    Location
    51.8° N 5.8° E
    Beans
    4,720
    Distro
    Xubuntu 19.04 Disco Dingo

    Re: Unable to clean/clear old kernels from /boot...

    Now try to remove some old kernels:
    Code:
    sudo dpkg --purge linux-image-4.4.0-130-generic linux-image-extra-4.4.0-130-generic
    sudo dpkg --purge linux-image-4.4.0-134-generic linux-image-extra-4.4.0-134-generic
    sudo dpkg --purge linux-image-4.4.0-137-generic linux-image-extra-4.4.0-137-generic
    sudo dpkg --purge linux-image-4.4.0-138-generic linux-image-extra-4.4.0-138-generic
    sudo dpkg --purge linux-image-4.4.0-139-generic linux-image-extra-4.4.0-139-generic
    Does that work? It usually works. If not, we need even lower level tools.

  3. #23
    Join Date
    Oct 2010
    Beans
    19

    Re: Unable to clean/clear old kernels from /boot...

    Quote Originally Posted by Impavidus View Post
    Now try to remove some old kernels:
    Code:
    sudo dpkg --purge linux-image-4.4.0-130-generic linux-image-extra-4.4.0-130-generic
    sudo dpkg --purge linux-image-4.4.0-134-generic linux-image-extra-4.4.0-134-generic
    sudo dpkg --purge linux-image-4.4.0-137-generic linux-image-extra-4.4.0-137-generic
    sudo dpkg --purge linux-image-4.4.0-138-generic linux-image-extra-4.4.0-138-generic
    sudo dpkg --purge linux-image-4.4.0-139-generic linux-image-extra-4.4.0-139-generic
    Does that work? It usually works. If not, we need even lower level tools.
    Output:

    Code:
    susr@sys:~$ sudo dpkg --purge linux-image-4.4.0-130-generic linux-image-extra-4.4.0-130-generic
    [sudo] password for usr: 
    (Reading database ... 213420 files and directories currently installed.)
    Removing linux-image-extra-4.4.0-130-generic (4.4.0-130.156) ...
    run-parts: executing /etc/kernel/postinst.d/apt-auto-removal 4.4.0-130-generic /boot/vmlinuz-4.4.0-130-generic
    run-parts: executing /etc/kernel/postinst.d/initramfs-tools 4.4.0-130-generic /boot/vmlinuz-4.4.0-130-generic
    update-initramfs: Generating /boot/initrd.img-4.4.0-130-generic
    
    
    gzip: stdout: No space left on device
    E: mkinitramfs failure cpio 141 gzip 1
    update-initramfs: failed for /boot/initrd.img-4.4.0-130-generic with 1.
    run-parts: /etc/kernel/postinst.d/initramfs-tools exited with return code 1
    dpkg: error processing package linux-image-extra-4.4.0-130-generic (--purge):
     subprocess installed post-removal script returned error exit status 1
    Removing linux-image-4.4.0-130-generic (4.4.0-130.156) ...
    Examining /etc/kernel/postrm.d .
    run-parts: executing /etc/kernel/postrm.d/initramfs-tools 4.4.0-130-generic /boot/vmlinuz-4.4.0-130-generic
    update-initramfs: Deleting /boot/initrd.img-4.4.0-130-generic
    run-parts: executing /etc/kernel/postrm.d/zz-update-grub 4.4.0-130-generic /boot/vmlinuz-4.4.0-130-generic
    Generating grub configuration file ...
    Found linux image: /boot/vmlinuz-4.4.0-148-generic
    Found linux image: /boot/vmlinuz-4.4.0-145-generic
    Found initrd image: /boot/initrd.img-4.4.0-145-generic
    Found linux image: /boot/vmlinuz-4.4.0-143-generic
    Found initrd image: /boot/initrd.img-4.4.0-143-generic
    Found linux image: /boot/vmlinuz-4.4.0-142-generic
    Found initrd image: /boot/initrd.img-4.4.0-142-generic
    Found linux image: /boot/vmlinuz-4.4.0-141-generic
    Found initrd image: /boot/initrd.img-4.4.0-141-generic
    Found linux image: /boot/vmlinuz-4.4.0-139-generic
    Found initrd image: /boot/initrd.img-4.4.0-139-generic
    Found linux image: /boot/vmlinuz-4.4.0-138-generic
    Found initrd image: /boot/initrd.img-4.4.0-138-generic
    Found linux image: /boot/vmlinuz-4.4.0-137-generic
    Found initrd image: /boot/initrd.img-4.4.0-137-generic
    Found linux image: /boot/vmlinuz-4.4.0-134-generic
    Found initrd image: /boot/initrd.img-4.4.0-134-generic
    done
    Purging configuration files for linux-image-4.4.0-130-generic (4.4.0-130.156) ...
    Examining /etc/kernel/postrm.d .
    run-parts: executing /etc/kernel/postrm.d/initramfs-tools 4.4.0-130-generic /boot/vmlinuz-4.4.0-130-generic
    run-parts: executing /etc/kernel/postrm.d/zz-update-grub 4.4.0-130-generic /boot/vmlinuz-4.4.0-130-generic
    Errors were encountered while processing:
     linux-image-extra-4.4.0-130-generic
    And the last one:

    Code:
    user@sys:~$ sudo dpkg --purge linux-image-4.4.0-139-generic linux-image-extra-4.4.0-139-generic
    (Reading database ... 190936 files and directories currently installed.)
    Removing linux-image-extra-4.4.0-139-generic (4.4.0-139.165) ...
    run-parts: executing /etc/kernel/postinst.d/apt-auto-removal 4.4.0-139-generic /boot/vmlinuz-4.4.0-139-generic
    run-parts: executing /etc/kernel/postinst.d/initramfs-tools 4.4.0-139-generic /boot/vmlinuz-4.4.0-139-generic
    update-initramfs: Generating /boot/initrd.img-4.4.0-139-generic
    run-parts: executing /etc/kernel/postinst.d/unattended-upgrades 4.4.0-139-generic /boot/vmlinuz-4.4.0-139-generic
    run-parts: executing /etc/kernel/postinst.d/update-notifier 4.4.0-139-generic /boot/vmlinuz-4.4.0-139-generic
    run-parts: executing /etc/kernel/postinst.d/zz-update-grub 4.4.0-139-generic /boot/vmlinuz-4.4.0-139-generic
    Generating grub configuration file ...
    Found linux image: /boot/vmlinuz-4.4.0-148-generic
    Found linux image: /boot/vmlinuz-4.4.0-145-generic
    Found initrd image: /boot/initrd.img-4.4.0-145-generic
    Found linux image: /boot/vmlinuz-4.4.0-143-generic
    Found initrd image: /boot/initrd.img-4.4.0-143-generic
    Found linux image: /boot/vmlinuz-4.4.0-142-generic
    Found initrd image: /boot/initrd.img-4.4.0-142-generic
    Found linux image: /boot/vmlinuz-4.4.0-141-generic
    Found initrd image: /boot/initrd.img-4.4.0-141-generic
    Found linux image: /boot/vmlinuz-4.4.0-139-generic
    Found initrd image: /boot/initrd.img-4.4.0-139-generic
    done
    Purging configuration files for linux-image-extra-4.4.0-139-generic (4.4.0-139.165) ...
    Removing linux-image-4.4.0-139-generic (4.4.0-139.165) ...
    Examining /etc/kernel/postrm.d .
    run-parts: executing /etc/kernel/postrm.d/initramfs-tools 4.4.0-139-generic /boot/vmlinuz-4.4.0-139-generic
    update-initramfs: Deleting /boot/initrd.img-4.4.0-139-generic
    run-parts: executing /etc/kernel/postrm.d/zz-update-grub 4.4.0-139-generic /boot/vmlinuz-4.4.0-139-generic
    Generating grub configuration file ...
    Found linux image: /boot/vmlinuz-4.4.0-148-generic
    Found linux image: /boot/vmlinuz-4.4.0-145-generic
    Found initrd image: /boot/initrd.img-4.4.0-145-generic
    Found linux image: /boot/vmlinuz-4.4.0-143-generic
    Found initrd image: /boot/initrd.img-4.4.0-143-generic
    Found linux image: /boot/vmlinuz-4.4.0-142-generic
    Found initrd image: /boot/initrd.img-4.4.0-142-generic
    Found linux image: /boot/vmlinuz-4.4.0-141-generic
    Found initrd image: /boot/initrd.img-4.4.0-141-generic
    done
    Purging configuration files for linux-image-4.4.0-139-generic (4.4.0-139.165) ...
    Examining /etc/kernel/postrm.d .
    run-parts: executing /etc/kernel/postrm.d/initramfs-tools 4.4.0-139-generic /boot/vmlinuz-4.4.0-139-generic
    run-parts: executing /etc/kernel/postrm.d/zz-update-grub 4.4.0-139-generic /boot/vmlinuz-4.4.0-139-generic
    Same basic output for all the lines you recommended. Should I continue with 141 & 142? Or should I try updating/upgrading like normal?

    Thanks again!

  4. #24
    Join Date
    Oct 2010
    Beans
    19

    Re: Unable to clean/clear old kernels from /boot...

    Quote Originally Posted by Impavidus View Post
    Now try to remove some old kernels:
    Code:
    sudo dpkg --purge linux-image-4.4.0-130-generic linux-image-extra-4.4.0-130-generic
    sudo dpkg --purge linux-image-4.4.0-134-generic linux-image-extra-4.4.0-134-generic
    sudo dpkg --purge linux-image-4.4.0-137-generic linux-image-extra-4.4.0-137-generic
    sudo dpkg --purge linux-image-4.4.0-138-generic linux-image-extra-4.4.0-138-generic
    sudo dpkg --purge linux-image-4.4.0-139-generic linux-image-extra-4.4.0-139-generic
    Does that work? It usually works. If not, we need even lower level tools.

    It looks like I'm good to go!

    After doing an 'apt-get -f install' followed by a couple update/upgrades and finally autoremoves, it looks like I'm all up to date and have ~280MB free on /boot!

    Finally!

    Thank you all so much for all the help. I'll be sure to keep 'autoremove' in my normal maintenance from now on. Sheesh.

    Thank you again, so much.

  5. #25
    Join Date
    Aug 2011
    Location
    51.8° N 5.8° E
    Beans
    4,720
    Distro
    Xubuntu 19.04 Disco Dingo

    Re: Unable to clean/clear old kernels from /boot...

    Good.

    Could you mark this thread as solved? Thread tools -> mark as solved.

  6. #26
    Join Date
    Mar 2007
    Beans
    471

    Re: Unable to clean/clear old kernels from /boot...

    Adding to this thread. I've done an investigation and determined that if the kernel version files are not loaded the related files in /boot can simply be deleted.
    I used Synaptic to search for packages containing the kernel number like 4.4.0-130, but there are other ways to check. If the packages aren't present the files in boot can simply be deleted.

Page 3 of 3 FirstFirst 123

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
  •