[Touch-packages] [Bug 2027847] Re: Updating kernel does not check for free space left on device beforehand

2023-07-15 Thread Bump
> APT only keeps 2 kernel versions around
Yes, but when installing a new kernel, it does not remove beforehand the oldest 
kernel, so there's a situation where there are 3 kernels installed at the same 
time, until you reboot and run upgrade again.

** Summary changed:

- Updating kernel does not check for free space left on device beforehand
+ APT installs 3 kernels at once so /boot runs out of free space left and 
partition size does not increase alongside with newer ubuntu versions

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to apt in Ubuntu.
https://bugs.launchpad.net/bugs/2027847

Title:
  APT installs 3 kernels at once so /boot runs out of free space left
  and partition size does not increase alongside with newer ubuntu
  versions

Status in apt package in Ubuntu:
  Won't Fix
Status in dpkg package in Ubuntu:
  Invalid
Status in kernel-package package in Ubuntu:
  Invalid
Status in linux package in Ubuntu:
  Invalid
Status in linux-firmware package in Ubuntu:
  Invalid
Status in linux-kernel-headers package in Ubuntu:
  Invalid
Status in linux-restricted-modules package in Ubuntu:
  Invalid

Bug description:
  System information:
  ubuntu 23.04 x86_64
  6.2.0-24-generic

  Upgrading the system:

  $ sudo dpkg --configure -a
  Setting up linux-firmware (20230323.gitbcdcfbcf-0ubuntu1.2) ...
  update-initramfs: Generating /boot/initrd.img-6.2.0-24-generic
  I: The initramfs will attempt to resume from /dev/dm-2
  I: (/dev/mapper/ubuntu--vg-swap_1)
  I: Set the RESUME variable to override this.
  zstd: error 70 : Write error : cannot write block : No space left on device 
  E: mkinitramfs failure zstd -q -1 -T0 70

  Check space left (none):
  $ df -h /boot
  Filesystem  Size  Used Avail Use% Mounted on
  /dev/sdb2   707M  693M 0 100% /boot

  What is required is to remove older kernels (and purge them most likely). 
List all the installed kernels except the current one:
  $ dpkg -l 'linux-*' | sed '/^ii/!d;/'"$(uname -r | sed 
"s/\(.*\)-\([^0-9]\+\)/\1/")"'/d;s/^[^ ]* [^ ]* \([^ ]*\).*/\1/;/[0-9]/!d'
  linux-headers-6.2.0-23
  linux-headers-6.2.0-23-generic
  linux-headers-6.2.0-25
  linux-headers-6.2.0-25-generic
  linux-image-6.2.0-23-generic
  linux-libc-dev:amd64
  linux-libc-dev:i386
  linux-modules-6.2.0-23-generic
  linux-modules-6.2.0-25-generic
  linux-modules-extra-6.2.0-23-generic
  linux-modules-extra-6.2.0-25-generic

  Is not possible to uninstall any kernel because fails:
  $ sudo apt purge linux-headers-6.2.0-23
  E: dpkg was interrupted, you must manually run 'sudo dpkg --configure -a' to 
correct the problem.

  Reconfigure fails again so some kernel have to be manually removed to free up 
space:
  $ sudo rm /boot/initrd.img-6.2.0-23-generic
  $ sudo rm -rf /boot/initrd.img-6.2.0-25-generic.new

  Now you can reconfigure:
  $ 

  Remove kernels:
  $ sudo apt purge linux-headers-6.2.0-23 linux-headers-6.2.0-23-generic 
linux-headers-6.2.0-25 linux-headers-6.2.0-25-generic 
linux-image-6.2.0-23-generic linux-modules-6.2.0-23-generic 
linux-modules-6.2.0-25-generic linux-modules-extra-6.2.0-23-generic 
linux-modules-extra-6.2.0-25-generic

  Reboot:
  $ sudo reboot

  Upgrade as usual:
  $ sudo apt update && sudo apt upgrade

  Before upgrading new kernels I need to check for free space and remove
  older kernels manually. Fix this so there's only one kernel left.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/apt/+bug/2027847/+subscriptions


-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp


[Touch-packages] [Bug 2027847] Re: Updating kernel does not check for free space left on device beforehand

2023-07-15 Thread Bump
There are 3 kernels installed:
6.2.0-24-generic (running)
linux-image-6.2.0-23-generic
/boot/initrd.img-6.2.0-25-generic.new (file 225MB placed by apt upgrade but 
remember the upgrade broke).

The /boot partition is sized for 3, but maybe today in 2023. This ubuntu system 
has been being upgraded for several years, so maybe back in the day a kernel 
image didn't weight 200+ MB but 100MB.
So now I have the problem that I must resize the partition, because kernels are 
only getting bigger.

With time, my 707M /boot partition will only be fit for one kernel,
maybe ubuntu 26.10 or whatever it be.

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to apt in Ubuntu.
https://bugs.launchpad.net/bugs/2027847

Title:
  APT installs 3 kernels at once so /boot runs out of free space left
  and partition size does not increase alongside with newer ubuntu
  versions

Status in apt package in Ubuntu:
  Won't Fix
Status in dpkg package in Ubuntu:
  Invalid
Status in kernel-package package in Ubuntu:
  Invalid
Status in linux package in Ubuntu:
  Invalid
Status in linux-firmware package in Ubuntu:
  Invalid
Status in linux-kernel-headers package in Ubuntu:
  Invalid
Status in linux-restricted-modules package in Ubuntu:
  Invalid

Bug description:
  System information:
  ubuntu 23.04 x86_64
  6.2.0-24-generic

  Upgrading the system:

  $ sudo dpkg --configure -a
  Setting up linux-firmware (20230323.gitbcdcfbcf-0ubuntu1.2) ...
  update-initramfs: Generating /boot/initrd.img-6.2.0-24-generic
  I: The initramfs will attempt to resume from /dev/dm-2
  I: (/dev/mapper/ubuntu--vg-swap_1)
  I: Set the RESUME variable to override this.
  zstd: error 70 : Write error : cannot write block : No space left on device 
  E: mkinitramfs failure zstd -q -1 -T0 70

  Check space left (none):
  $ df -h /boot
  Filesystem  Size  Used Avail Use% Mounted on
  /dev/sdb2   707M  693M 0 100% /boot

  What is required is to remove older kernels (and purge them most likely). 
List all the installed kernels except the current one:
  $ dpkg -l 'linux-*' | sed '/^ii/!d;/'"$(uname -r | sed 
"s/\(.*\)-\([^0-9]\+\)/\1/")"'/d;s/^[^ ]* [^ ]* \([^ ]*\).*/\1/;/[0-9]/!d'
  linux-headers-6.2.0-23
  linux-headers-6.2.0-23-generic
  linux-headers-6.2.0-25
  linux-headers-6.2.0-25-generic
  linux-image-6.2.0-23-generic
  linux-libc-dev:amd64
  linux-libc-dev:i386
  linux-modules-6.2.0-23-generic
  linux-modules-6.2.0-25-generic
  linux-modules-extra-6.2.0-23-generic
  linux-modules-extra-6.2.0-25-generic

  Is not possible to uninstall any kernel because fails:
  $ sudo apt purge linux-headers-6.2.0-23
  E: dpkg was interrupted, you must manually run 'sudo dpkg --configure -a' to 
correct the problem.

  Reconfigure fails again so some kernel have to be manually removed to free up 
space:
  $ sudo rm /boot/initrd.img-6.2.0-23-generic
  $ sudo rm -rf /boot/initrd.img-6.2.0-25-generic.new

  Now you can reconfigure:
  $ 

  Remove kernels:
  $ sudo apt purge linux-headers-6.2.0-23 linux-headers-6.2.0-23-generic 
linux-headers-6.2.0-25 linux-headers-6.2.0-25-generic 
linux-image-6.2.0-23-generic linux-modules-6.2.0-23-generic 
linux-modules-6.2.0-25-generic linux-modules-extra-6.2.0-23-generic 
linux-modules-extra-6.2.0-25-generic

  Reboot:
  $ sudo reboot

  Upgrade as usual:
  $ sudo apt update && sudo apt upgrade

  Before upgrading new kernels I need to check for free space and remove
  older kernels manually. Fix this so there's only one kernel left.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/apt/+bug/2027847/+subscriptions


-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp


[Touch-packages] [Bug 2027847] Re: Updating kernel does not check for free space left on device beforehand

2023-07-15 Thread Julian Andres Klode
We generally don't know how much space is going to be needed. APT only
keeps 2 kernel versions around, and the /boot partition is sized
accordingly for 3.

If you override this by marking kernels as manually installed, or
manually installing other versions you need to ensure that there is
enough space for those.

I only see two kernels installed though, so it's not clear to me how you
could be running out of space in /boot in the first place.

Are there additional files in there? The kernels shouldn't fill that up.

** Changed in: apt (Ubuntu)
   Status: New => Won't Fix

** Changed in: dpkg (Ubuntu)
   Status: New => Invalid

** Changed in: kernel-package (Ubuntu)
   Status: New => Won't Fix

** Changed in: kernel-package (Ubuntu)
   Status: Won't Fix => Invalid

** Changed in: linux (Ubuntu)
   Status: New => Invalid

** Changed in: linux-firmware (Ubuntu)
   Status: New => Invalid

** Changed in: linux-kernel-headers (Ubuntu)
   Status: New => Invalid

** Changed in: linux-restricted-modules (Ubuntu)
   Status: New => Invalid

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to apt in Ubuntu.
https://bugs.launchpad.net/bugs/2027847

Title:
  Updating kernel does not check for free space left on device
  beforehand

Status in apt package in Ubuntu:
  Won't Fix
Status in dpkg package in Ubuntu:
  Invalid
Status in kernel-package package in Ubuntu:
  Invalid
Status in linux package in Ubuntu:
  Invalid
Status in linux-firmware package in Ubuntu:
  Invalid
Status in linux-kernel-headers package in Ubuntu:
  Invalid
Status in linux-restricted-modules package in Ubuntu:
  Invalid

Bug description:
  System information:
  ubuntu 23.04 x86_64
  6.2.0-24-generic

  Upgrading the system:

  $ sudo dpkg --configure -a
  Setting up linux-firmware (20230323.gitbcdcfbcf-0ubuntu1.2) ...
  update-initramfs: Generating /boot/initrd.img-6.2.0-24-generic
  I: The initramfs will attempt to resume from /dev/dm-2
  I: (/dev/mapper/ubuntu--vg-swap_1)
  I: Set the RESUME variable to override this.
  zstd: error 70 : Write error : cannot write block : No space left on device 
  E: mkinitramfs failure zstd -q -1 -T0 70

  Check space left (none):
  $ df -h /boot
  Filesystem  Size  Used Avail Use% Mounted on
  /dev/sdb2   707M  693M 0 100% /boot

  What is required is to remove older kernels (and purge them most likely). 
List all the installed kernels except the current one:
  $ dpkg -l 'linux-*' | sed '/^ii/!d;/'"$(uname -r | sed 
"s/\(.*\)-\([^0-9]\+\)/\1/")"'/d;s/^[^ ]* [^ ]* \([^ ]*\).*/\1/;/[0-9]/!d'
  linux-headers-6.2.0-23
  linux-headers-6.2.0-23-generic
  linux-headers-6.2.0-25
  linux-headers-6.2.0-25-generic
  linux-image-6.2.0-23-generic
  linux-libc-dev:amd64
  linux-libc-dev:i386
  linux-modules-6.2.0-23-generic
  linux-modules-6.2.0-25-generic
  linux-modules-extra-6.2.0-23-generic
  linux-modules-extra-6.2.0-25-generic

  Is not possible to uninstall any kernel because fails:
  $ sudo apt purge linux-headers-6.2.0-23
  E: dpkg was interrupted, you must manually run 'sudo dpkg --configure -a' to 
correct the problem.

  Reconfigure fails again so some kernel have to be manually removed to free up 
space:
  $ sudo rm /boot/initrd.img-6.2.0-23-generic
  $ sudo rm -rf /boot/initrd.img-6.2.0-25-generic.new

  Now you can reconfigure:
  $ 

  Remove kernels:
  $ sudo apt purge linux-headers-6.2.0-23 linux-headers-6.2.0-23-generic 
linux-headers-6.2.0-25 linux-headers-6.2.0-25-generic 
linux-image-6.2.0-23-generic linux-modules-6.2.0-23-generic 
linux-modules-6.2.0-25-generic linux-modules-extra-6.2.0-23-generic 
linux-modules-extra-6.2.0-25-generic

  Reboot:
  $ sudo reboot

  Upgrade as usual:
  $ sudo apt update && sudo apt upgrade

  Before upgrading new kernels I need to check for free space and remove
  older kernels manually. Fix this so there's only one kernel left.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/apt/+bug/2027847/+subscriptions


-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp