Hello Proxmox community,
I'm currently facing an issue when trying to remove the `pve-kernel-5.15.116-1-pve` package on Debian 11. Here's the context of my problem:
- Operating System: Debian 11
- Context: I initially attempted to install Proxmox alongside OpenMediaVault (OMV) on this Debian 11 system. However, I encountered an error during the installation process, and my primary issue now is related to removing the problematic package.
Issue Description:
I attempted to remove the `pve-kernel-5.15.116-1-pve` package using the following command:
However, I received the following error:
I've tried installing proxmox-kernel-helper as suggested by others, but it didn't resolve the issue. It seems like the post-removal script for pve-kernel-5.15.116-1-pve is encountering problems.
If anyone has encountered a similar issue or has any insights on how to resolve this, your assistance would be greatly appreciated. My goal is to successfully remove the pve-kernel-5.15.116-1-pve package from my Debian 11 system.
Thank you in advance for your help!
Additional Information:
I'm currently facing an issue when trying to remove the `pve-kernel-5.15.116-1-pve` package on Debian 11. Here's the context of my problem:
- Operating System: Debian 11
- Context: I initially attempted to install Proxmox alongside OpenMediaVault (OMV) on this Debian 11 system. However, I encountered an error during the installation process, and my primary issue now is related to removing the problematic package.
Issue Description:
I attempted to remove the `pve-kernel-5.15.116-1-pve` package using the following command:
sudo dpkg --remove --force-remove-reinstreq pve-kernel-5.15.116-1-pve
However, I received the following error:
Bash:
Removing pve-kernel-5.15.116-1-pve (5.15.116-1) ...
Examining /etc/kernel/postrm.d.
run-parts: executing /etc/kernel/postrm.d/initramfs-tools 5.15.116-1-pve /boot/vmlinuz-5.15.116-1-pve
update-initramfs: Deleting /boot/initrd.img-5.15.116-1-pve
run-parts: executing /etc/kernel/postrm.d/proxmox-auto-removal 5.15.116-1-pve /boot/vmlinuz-5.15.116-1-pve
/etc/kernel/postrm.d/proxmox-auto-removal: 4: .: cannot open /usr/share/proxmox-kernel-helper/scripts/functions: No such file
run-parts: /etc/kernel/postrm.d/proxmox-auto-removal exited with return code 2
Failed to process /etc/kernel/postrm.d at /var/lib/dpkg/info/pve-kernel-5.15.116-1-pve.postrm line 14.
dpkg: error processing package pve-kernel-5.15.116-1-pve (--remove):
installed pve-kernel-5.15.116-1-pve package post-removal script subprocess returned error exit status 1
dpkg: too many errors, stopping
Errors were encountered while processing:
pve-kernel-5.15.116-1-pve
Processing was halted because there were too many errors.
E: Sub-process /usr/bin/dpkg returned an error code (1)
I've tried installing proxmox-kernel-helper as suggested by others, but it didn't resolve the issue. It seems like the post-removal script for pve-kernel-5.15.116-1-pve is encountering problems.
If anyone has encountered a similar issue or has any insights on how to resolve this, your assistance would be greatly appreciated. My goal is to successfully remove the pve-kernel-5.15.116-1-pve package from my Debian 11 system.
Thank you in advance for your help!
Additional Information:
- Output of cat /var/lib/dpkg/info/pve-kernel-5.15.116-1-pve.postrm:
Perl:
#!/usr/bin/perl -w
use strict;
# Ignore all 'upgrade' invocations .
exit 0 if $ARGV[0] =~ /upgrade/;
my $imagedir = "/boot";
my $version = "5.15.116-1-pve";
if (-d "/etc/kernel/postrm.d") {
print STDERR "Examining /etc/kernel/postrm.d.\n";
system ("run-parts --verbose --exit-on-error --arg=$version " .
"--arg=$imagedir/vmlinuz-$version " .
"/etc/kernel/postrm.d") &&
die "Failed to process /etc/kernel/postrm.d";
}
unlink "$imagedir/initrd.img-$version";
unlink "$imagedir/initrd.img-$version.bak";
unlink "/var/lib/initramfs-tools/$version";
# Ignore all invocations except when called on to purge.
exit 0 unless $ARGV[0] =~ /purge/;
my @files_to_remove = qw{
modules.dep modules.isapnpmap modules.pcimap
modules.usbmap modules.parportmap
modules.generic_string modules.ieee1394map
modules.ieee1394map modules.pnpbiosmap
modules.alias modules.ccwmap modules.inputmap
modules.symbols modules.ofmap
modules.seriomap modules.*.bin
modules.softdep modules.devname
};
foreach my $extra_file (@files_to_remove) {
for (glob("/lib/modules/$version/$extra_file")) {
unlink;
}
}
system ("rmdir", "/lib/modules/$version") if -d "/lib/modules/$version";
exit 0;
Last edited: