Update to 2.2 failed.

Styg

Member
Oct 10, 2019
3
0
21
43
Hello
After an update from the latest 1.x version to 2.2-3 with dist-upgrade procedure I get the following erros.

running python post-rtupdate hooks for python3.9...
dpkg: dependency problems prevent configuration of linux-image-amd64:
linux-image-amd64 depends on linux-image-5.10.0-15-amd64 (= 5.10.120-1); however:
Package linux-image-5.10.0-15-amd64 is not configured yet.

dpkg: error processing package linux-image-amd64 (--configure):
dependency problems - leaving unconfigured
Setting up grub-pc-bin (2.04-20) ...
Setting up ifupdown2 (3.1.0-1+pmx3) ...
Setting up libpython2.7-stdlib:amd64 (2.7.18-8) ...
Setting up grub-pc (2.04-20) ...
Replacing config file /etc/default/grub with new version
Installing for i386-pc platform.
Installation finished. No error reported.
Generating grub configuration file ...
/etc/grub.d/000_proxmox_boot_header: 4: .: cannot open /usr/share/pve-kernel-helper/scripts/functions: No such file
dpkg: error processing package grub-pc (--configure):
installed grub-pc package post-installation script subprocess returned error exit status 2
Setting up python3-six (1.16.0-2) ...

update-initramfs: Generating /boot/initrd.img-5.10.0-15-amd64
/etc/initramfs/post-update.xmox-boot-sync: 10: /usr/sbin/proxmox-boot-tool: not found
run-parts: /etc/initramfs/post-update.d//proxmox-boot-sync exited with return code 127
dpkg: error processing package initramfs-tools (--configure):
installed initramfs-tools package post-installation script subprocess returned error exit status 1
Errors were encountered while processing:
linux-image-5.10.0-15-amd64
linux-image-amd64
grub-pc
initramfs-tools
E: Sub-process /usr/bin/dpkg returned an error code (1)

Any ideas?
 
Hmm - for completeness sake please post the complete output (in code tags) of:
* `apt update`
* `grep -r '' /etc/apt/sources.list*`

else:
linux-image-amd64 depends on linux-image-5.10.0-15-amd64 (= 5.10.120-1); however:
Package linux-image-5.10.0-15-amd64 is not configured yet.
* linux-image-amd64 (and the one with the ABI version) is the stock debian kernel - PBS pulls in and uses the pve-kernel
There was a change a while ago which resulted in both not being able to be installed side by side - the solution should be:
* removing linux-image-amd64 (`apt remove linux-image-amd64`)
* trying to fix the upgrade (`apt install -f`)

if this does not work - please post complete outputs (in code tags)

I hope this helps!
 
Code:
# apt update
Hit:1 http://security.debian.org/debian-security bullseye-security InRelease
Hit:2 http://deb.debian.org/debian bullseye InRelease
Hit:3 http://deb.debian.org/debian bullseye-updates InRelease
Hit:4 http://download.proxmox.com/debian/pbs bullseye InRelease
Ign:5 https://download.webmin.com/download/repository sarge InRelease
Hit:6 https://download.webmin.com/download/repository sarge Release
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
All packages are up to date.

Code:
/etc/apt/sources.list:#
/etc/apt/sources.list:
/etc/apt/sources.list:# deb cdrom:[Debian GNU/Linux 10.7.0 _Buster_ - Official amd64 NETINST 20201205-11:16]/ bullseye main
/etc/apt/sources.list:
/etc/apt/sources.list:#deb cdrom:[Debian GNU/Linux 10.7.0 _Buster_ - Official amd64 NETINST 20201205-11:16]/ bullseye main
/etc/apt/sources.list:
/etc/apt/sources.list:deb http://deb.debian.org/debian/ bullseye main
/etc/apt/sources.list:deb-src http://deb.debian.org/debian/ bullseye main
/etc/apt/sources.list:
/etc/apt/sources.list:deb http://security.debian.org/debian-security bullseye-security main
/etc/apt/sources.list:deb-src http://security.debian.org/debian-security bullseye-security main
/etc/apt/sources.list:
/etc/apt/sources.list:# bullseye-updates, previously known as 'volatile'
/etc/apt/sources.list:deb http://deb.debian.org/debian/ bullseye-updates main
/etc/apt/sources.list:deb-src http://deb.debian.org/debian/ bullseye-updates main
/etc/apt/sources.list:
/etc/apt/sources.list:# This system was installed using small removable media
/etc/apt/sources.list:# (e.g. netinst, live or single CD). The matching "deb cdrom"
/etc/apt/sources.list:# entries were disabled at the end of the installation process.
/etc/apt/sources.list:# For information about how to configure apt package sources,
/etc/apt/sources.list:# see the sources.list(5) manual.
/etc/apt/sources.list:
/etc/apt/sources.list:deb https://download.webmin.com/download/repository sarge contrib
/etc/apt/sources.list:
/etc/apt/sources.list:# PBS pbs-no-subscription repository provided by proxmox.com,
/etc/apt/sources.list:# NOT recommended for production use
/etc/apt/sources.list:deb http://download.proxmox.com/debian/pbs bullseye pbs-no-subscription
/etc/apt/sources.list.d/pbs-enterprise.list:#deb https://enterprise.proxmox.com/debian/pbs bullseye pbs-enterprise
/etc/apt/sources.list.d/pbs-enterprise.list.dpkg-old:#deb https://enterprise.proxmox.com/debian/pbs buster pbs-enterprise

Code:
# apt purge linux-image-4.19.0-17-amd64
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following packages will be REMOVED:
  linux-image-4.19.0-17-amd64
0 upgraded, 0 newly installed, 1 to remove and 0 not upgraded.
5 not fully installed or removed.
After this operation, 270 MB disk space will be freed.
Do you want to continue? [Y/n] y
(Reading database ... 113705 files and directories currently installed.)
Removing linux-image-4.19.0-17-amd64 (4.19.194-3) ...
/etc/kernel/postrm.d/initramfs-tools:
update-initramfs: Deleting /boot/initrd.img-4.19.0-17-amd64
/etc/kernel/postrm.d/proxmox-auto-removal:
/etc/kernel/postrm.d/proxmox-auto-removal: 4: .: cannot open /usr/share/pve-kernel-helper/scripts/functions: No such file
run-parts: /etc/kernel/postrm.d/proxmox-auto-removal exited with return code 2
dpkg: error processing package linux-image-4.19.0-17-amd64 (--remove):
 installed linux-image-4.19.0-17-amd64 package post-removal script subprocess returned error exit status 1
dpkg: too many errors, stopping
Errors were encountered while processing:
 linux-image-4.19.0-17-amd64
Processing was halted because there were too many errors.
E: Sub-process /usr/bin/dpkg returned an error code (1)
 
Seemingly I have solved the issue. I have moved away all proxmox postinstall scripts.

Code:
mv /etc/initramfs/post-update.d/proxmox-boot-sync /etc/initramfs/post-update.d/proxmox-boot-sync.bak
mv /etc/kernel/postinst.d/proxmox-auto-removal /etc/kernel/postinst.d/proxmox-auto-removal.bak
mv /etc/kernel/postinst.d/zz-proxmox-boot /etc/kernel/postinst.d/zz-proxmox-boot.bak
mv /etc/grub.d/000_proxmox_boot_header.bak ~

And upgrade finished as expected after that. Server works perfectly.
But it still uses Debian kernel.

Code:
# uname -v
#1 SMP Debian 5.10.120-1 (2022-06-09)

Should I change it somehow to pve kernel to avoid update problems in future?

where do these entries come from? (sarge is a debian distribution from 17 years ago?!)
Webmin is web GUI for linux servers, it is quite handy for people not familiar with CLI. And they just never changed the repo name, but it is up-to-date.

Regards
 
And upgrade finished as expected after that. Server works perfectly.
But it still uses Debian kernel.
Depends - I would recommend switching to pve-kernel (and remove the debian stock kernel, due to the incompatible dependencies):
* we do our testing internally with the pve-kernel - additionally most users are running with it - so if there's an error it's more likely to get noticed before you run into it - with the debian-kernel this is not a given
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!