root@server:~# apt-get install --reinstall proxmox-kernel-helper
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following packages will be REMOVED:
pve-kernel-5.11.22-3-pve pve-kernel-5.4.78-2-pve
The following NEW packages will be installed:
proxmox-kernel-helper
0 upgraded, 1 newly installed, 2 to remove and 0 not upgraded.
3 not fully installed or removed.
Need to get 0 B/15.3 kB of archives.
After this operation, 679 MB disk space will be freed.
Do you want to continue? [Y/n] y
(Reading database ... 107244 files and directories currently installed.)
Removing pve-kernel-5.11.22-3-pve (5.11.22-7) ...
Examining /etc/kernel/postrm.d.
run-parts: executing /etc/kernel/postrm.d/initramfs-tools 5.11.22-3-pve /boot/vmlinuz-5.11.22-3-pve
update-initramfs: Deleting /boot/initrd.img-5.11.22-3-pve
run-parts: executing /etc/kernel/postrm.d/zz-proxmox-boot 5.11.22-3-pve /boot/vmlinuz-5.11.22-3-pve
/etc/kernel/postrm.d/zz-proxmox-boot: 31: .: cannot open /usr/share/pve-kernel-helper/scripts/functions: No such file
run-parts: /etc/kernel/postrm.d/zz-proxmox-boot exited with return code 2
Failed to process /etc/kernel/postrm.d at /var/lib/dpkg/info/pve-kernel-5.11.22-3-pve.postrm line 14.
dpkg: error processing package pve-kernel-5.11.22-3-pve (--remove):
installed pve-kernel-5.11.22-3-pve package post-removal script subprocess returned error exit status 1
dpkg: too many errors, stopping
Errors were encountered while processing:
pve-kernel-5.11.22-3-pve
Processing was halted because there were too many errors.
E: Sub-process /usr/bin/dpkg returned an error code (1)
root@server:~#