package linux-image-4.13.0-32-generic 4.13.0-32.35 failed to install/upgrade: subprocess installed post-installation script returned error exit status 2

Bug #1746519 reported by Mattias
38
This bug affects 7 people
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Confirmed
Low
Unassigned

Bug Description

lsb_release -rd
Description: Ubuntu 17.10
Release: 17.10

After executing:
sudo apt-get autoremove
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be REMOVED:
  linux-headers-4.13.0-21 linux-headers-4.13.0-21-generic
  linux-image-4.13.0-21-generic linux-image-extra-4.10.0-42-generic
  linux-image-extra-4.13.0-21-generic
0 upgraded, 0 newly installed, 5 to remove and 10 not upgraded.
7 not fully installed or removed.
After this operation, 474 MB disk space will be freed.
Do you want to continue? [Y/n] y
(Reading database ... 297436 files and directories currently installed.)
Removing linux-headers-4.13.0-21-generic (4.13.0-21.24) ...
Removing linux-headers-4.13.0-21 (4.13.0-21.24) ...
Removing linux-image-extra-4.13.0-21-generic (4.13.0-21.24) ...
run-parts: executing /etc/kernel/postinst.d/apt-auto-removal 4.13.0-21-generic /boot/vmlinuz-4.13.0-21-generic
run-parts: executing /etc/kernel/postinst.d/dkms 4.13.0-21-generic /boot/vmlinuz-4.13.0-21-generic

dkms process is stuck and does not end

ProblemType: Package
DistroRelease: Ubuntu 17.10
Package: linux-image-4.13.0-32-generic 4.13.0-32.35
ProcVersionSignature: Ubuntu 4.13.0-31.34-generic 4.13.13
Uname: Linux 4.13.0-31-generic x86_64
ApportVersion: 2.20.7-0ubuntu3.7
AptOrdering: NULL: ConfigurePending
Architecture: amd64
AudioDevicesInUse:
 USER PID ACCESS COMMAND
 /dev/snd/controlC1: gdm 2144 F.... pulseaudio
                      mvh 2739 F.... pulseaudio
 /dev/snd/controlC0: gdm 2144 F.... pulseaudio
                      mvh 2739 F.... pulseaudio
Date: Wed Jan 31 14:41:24 2018
ErrorMessage: subprocess installed post-installation script returned error exit status 2
InstallationDate: Installed on 2017-04-15 (291 days ago)
InstallationMedia: Ubuntu 17.04 "Zesty Zapus" - Release amd64 (20170412)
MachineType: Dell Inc. Latitude E6540
ProcFB:
 0 radeondrmfb
 1 inteldrmfb
ProcKernelCmdLine: BOOT_IMAGE=/vmlinuz-4.13.0-31-generic root=UUID=aa4075ec-5629-4eb4-9fa7-6e90dd0cd274 ro quiet splash vt.handoff=7
PulseList: Error: command ['pacmd', 'list'] failed with exit code 1: No PulseAudio daemon running, or not running as session daemon.
Python3Details: /usr/bin/python3.6, Python 3.6.3, python3-minimal, 3.6.3-0ubuntu2
PythonDetails: /usr/bin/python2.7, Python 2.7.14, python-minimal, 2.7.14-2ubuntu1
RelatedPackageVersions: grub-pc 2.02~beta3-4ubuntu7
SourcePackage: linux
Title: package linux-image-4.13.0-32-generic 4.13.0-32.35 failed to install/upgrade: subprocess installed post-installation script returned error exit status 2
UpgradeStatus: Upgraded to artful on 2018-01-01 (29 days ago)
dmi.bios.date: 02/02/2015
dmi.bios.vendor: Dell Inc.
dmi.bios.version: A13
dmi.board.name: 0725FP
dmi.board.vendor: Dell Inc.
dmi.board.version: A00
dmi.chassis.type: 9
dmi.chassis.vendor: Dell Inc.
dmi.modalias: dmi:bvnDellInc.:bvrA13:bd02/02/2015:svnDellInc.:pnLatitudeE6540:pvr01:rvnDellInc.:rn0725FP:rvrA00:cvnDellInc.:ct9:cvr:
dmi.product.name: Latitude E6540
dmi.product.version: 01
dmi.sys.vendor: Dell Inc.

Revision history for this message
Mattias (mt410) wrote :
Revision history for this message
Ubuntu Kernel Bot (ubuntu-kernel-bot) wrote : Status changed to Confirmed

This change was made by a bot.

Changed in linux (Ubuntu):
status: New → Confirmed
tags: removed: need-duplicate-check
Revision history for this message
Joseph Salisbury (jsalisbury) wrote :

You may need to run the following from a terminal:

sudo apt-get install -f
sudo apt-get clean
sudo apt-get update

Then re-install the package or updates.

If that does not resolve your issue, please mark the bug as "Confirmed"

Changed in linux (Ubuntu):
importance: Undecided → Low
status: Confirmed → Incomplete
Revision history for this message
Mattias (mt410) wrote :

It does not work.

$ sudo apt-get install -f
E: dpkg was interrupted, you must manually run 'sudo dpkg --configure -a' to correct the problem.

$ sudo dpkg --configure -a
Setting up linux-headers-4.13.0-32-generic (4.13.0-32.35) ...
Examining /etc/kernel/header_postinst.d.
run-parts: executing /etc/kernel/header_postinst.d/dkms 4.13.0-32-generic /boot/vmlinuz-4.13.0-32-generic

(This command is stuck, when I press Ctrl+C after 4 hours it gives:)

^CFailed to process /etc/kernel/header_postinst.d at /var/lib/dpkg/info/linux-headers-4.13.0-32-generic.postinst line 110.
dpkg: error processing package linux-headers-4.13.0-32-generic (--configure):
 subprocess installed post-installation script returned error exit status 2
Setting up linux-image-4.13.0-32-generic (4.13.0-32.35) ...
Running depmod.
^CFailed to run depmod
dpkg: error processing package linux-image-4.13.0-32-generic (--configure):
 subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of linux-image-extra-4.13.0-32-generic:
 linux-image-extra-4.13.0-32-generic depends on linux-image-4.13.0-32-generic; however:
  Package linux-image-4.13.0-32-generic is not configured yet.

dpkg: error processing package linux-image-extra-4.13.0-32-generic (--configure):
 dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of linux-image-generic:
 linux-image-generic depends on linux-image-4.13.0-32-generic; however:
  Package linux-image-4.13.0-32-generic is not configured yet.
 linux-image-generic depends on linux-image-extra-4.13.0-32-generic; however:
  Package linux-image-extra-4.13.0-32-generic is not configured yet.

dpkg: error processing package linux-image-generic (--configure):
 dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of linux-headers-generic:
 linux-headers-generic depends on linux-headers-4.13.0-32-generic; however:
  Package linux-headers-4.13.0-32-generic is not configured yet.

dpkg: error processing package linux-headers-generic (--configure):
 dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of linux-image-extra-virtual:
 linux-image-extra-virtual depends on linux-image-generic (= 4.13.0.32.34); however:
  Package linux-image-generic is not configured yet.

dpkg: error processing package linux-image-extra-virtual (--configure):
 dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of linux-generic:
 linux-generic depends on linux-image-generic (= 4.13.0.32.34); however:
  Package linux-image-generic is not configured yet.
 linux-generic depends on linux-headers-generic (= 4.13.0.32.34); however:
  Package linux-headers-generic is not configured yet.

dpkg: error processing package linux-generic (--configure):
 dependency problems - leaving unconfigured
Errors were encountered while processing:
 linux-headers-4.13.0-32-generic
 linux-image-4.13.0-32-generic
 linux-image-extra-4.13.0-32-generic
 linux-image-generic
 linux-headers-generic
 linux-image-extra-virtual
 linux-generic

Changed in linux (Ubuntu):
status: Incomplete → Confirmed
Revision history for this message
Eclipticon (eclipticon) wrote :

Exactly the same problem here, updates/installations via the package management system are no longer possible.

Please let me know if I can contribute any information on my Ubuntu 17.10 64 bit system for the big picture.

Revision history for this message
Gijs Vermariën (gijs-vermarien) wrote :

Unfortunately I encountered the same problem. Tried to run it for two hours but after that it remained stuck, so I ctrl+C-ed and then the same error messages showed.

Revision history for this message
Jos Krieckaart (titanium.shadow) wrote :

I was facing the same issue. After running apt-get autoremove is was resolved/gone.

Revision history for this message
Eclipticon (eclipticon) wrote :

Unfortunately not here:

$sudo apt-get autoremove
E: dpkg was interrupted, you must manually run 'sudo dpkg --configure -a' to correct the problem.

And once I do that, I am stuck again ...

Revision history for this message
erik manor (erik-d-not) wrote :

I was running into the same/similar error. Inside of /var/lib/dpkg/updates one of the files appeared to be stopping my update process. The contents of the file was,

#padding
#padding
#padding
#padding
#padding

repeating for 150 something lines.

I moved that file out of /var/lib/dpkg/updates and everything seems to be working fine afterwards. Whether this was the root cause or not I am not sure, but it might be worth while grep(ing) for this in all the files in /var/lib/dpkg/updates.

Revision history for this message
Eclipticon (eclipticon) wrote :

Can confirm Erik's solution works ... thanks a lot, you saved me HOURS or DAYS!

Revision history for this message
Marcel Richter (mrclrchtr) wrote :

Erik's solution works for me, but every time when i call "apt upgrade" the file with hundreds of #padding will be created again.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.