Latest kernel update gets stuck

Bug #1686107 reported by Bart Willemsen
60
This bug affects 12 people
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Invalid
High
Unassigned
Zesty
Invalid
High
Unassigned

Bug Description

I just installed the latest kernel update (4.10.0-20), but it gets stuck on the following line:

Examining /etc/kernel/header_postinst.d.
run-parts: executing /etc/kernel/header_postinst.d/dkms 4.10.0-20-generic /boot/vmlinuz-4.10.0-20-generic

I can't finish the update process now. I am also unable to install any software because dpkg informs it's corrupted. But running sudo dpkg --configure -a causes it to get stuck again on the line above.

More info is provided here on this AskUbuntu question: https://askubuntu.com/questions/908676/linux-kernel-update-stuck

I hope I reported this on the right location.

I am running Ubuntu GNOME 17.04

Revision history for this message
Brad Figg (brad-figg) wrote : Missing required logs.

This bug is missing log files that will aid in diagnosing the problem. From a terminal window please run:

apport-collect 1686107

and then change the status of the bug to 'Confirmed'.

If, due to the nature of the issue you have encountered, you are unable to run this command, please add a comment stating that fact and change the bug status to 'Confirmed'.

This change has been made by an automated script, maintained by the Ubuntu Kernel Team.

Changed in linux (Ubuntu):
status: New → Incomplete
Revision history for this message
Joseph Salisbury (jsalisbury) wrote :

Does the system boot if you select the prior kernel version?

Changed in linux (Ubuntu):
importance: Undecided → High
Changed in linux (Ubuntu Zesty):
importance: Undecided → High
status: New → Incomplete
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"

tags: added: kernel-da-key zesty
Revision history for this message
Bart Willemsen (b-willemsen8) wrote :

Hello, thanks for the response. The system does boot and actually boots from the older kernel by default. It's just that I am unable to use apt or dpkg because it will hang when configuring the new kernel. It's an incomplete installation at this point.

This also prevented me from collecting the necessary log files because I needed to install the python-apport package for that. If you need any specific log files, I can probably collect them manually.

Changed in linux (Ubuntu):
status: Incomplete → Confirmed
Changed in linux (Ubuntu Zesty):
status: Incomplete → Confirmed
Revision history for this message
Bart Willemsen (b-willemsen8) wrote :

This issue also prevents me from using apt-get install -f because it wants me to run dpkg --configure -a first... but when I do that, the original issue described above will occur..

Revision history for this message
MARTINEZ Sébastien (seb38) wrote :

I've got exactly the same problem...

Revision history for this message
Bart Willemsen (b-willemsen8) wrote :

I just found a solution. I was running Ubuntu on my Nvidia Graphics card. I tried switching back to the Build-in Intel Graphics with the Nvidia Control Center and ran dpkg --configure -a

This time things did work. The kernel configuration didn't hang anymore and everything is working fine again. Still, it's a pretty weird issue, but might be related to DKMS or the Nvidia DKMS module specifically...

Revision history for this message
MARTINEZ Sébastien (seb38) wrote :

Yes ! Your solution works fine, thanks a lot !

Revision history for this message
Alex Tu (alextu) wrote :

I experienced system hangs up even no response on mouse/keyboard on a machine which exported 64 cores in /proc/cpuinfo.

From iotop, it shows 35 process are using 90% IO during nvidia driver installation: http://paste.ubuntu.com/24471401/

Not sure if this is same as what I encountered, and kernel parameter maxcpus=16 could fix my problem.

Revision history for this message
Giorgio Salluzzo (giorgio.salluzzo) wrote :

A workaround is running APT updates from a text-only console (CTRL+ALT+F1 to F6).

Revision history for this message
Veron Rado (junket) wrote :

@ Giorgio Salluzzo Thanks for the workaround. It got me out of a real mess.

I am on Ubuntu 17.10 but the same issue happened to me
For any one else in a panic, stuck in the same situation, kernel half installed, this is what saved me:

* Kill Synaptic with "System Monitor"

* A dpkg process was left hung and was blocking further updates
 - So in "System Monitor" search for and kill the dpkg process that's running and locking things.
  - Searching the string "/var/lib/dpkg" found it for me.
  - It had this process "linux-headers-4.3.0-17-generic.postinst"

* Here's the trick that made it work (@ Giorgio Salluzzo's workaround)
   Go to a virtual console CTRL+ALT+F6
   Login as your user name and run this command from there
   $ sudo dpkg --configure -a

* That alone is probably the fix but I also ran these from the same virtual terminal
 $ sudo apt-get install -f
 $ sudo apt-get clean
 $ sudo apt-get update

* CTRL+ALT+F2 to get back to the desktop.

* Then "Software Updater" popped up a message saying run a "Partial Upgrade".
  Which I did. But it turned out I didn't need that so it stopped itself automatically!

* Then I opened Synaptic and checked for updates. None.

* Back-up any user data and reboot. For me all went well.
  The new kernel was installed.

NOTES: I tried "sudo dpkg --configure -a" in a normal Terminal but it failed.
It just hung again like Synaptic did.
Giorgio Salluzzo's virtual console workaround was the trick.

But the virtual consoles can be weird.
CTRL+ALT+F1 locks my screen (and then the monitor switches off!) When you wake the screen you can't log back in!!! You have to use CTRL+ALT+F2 to get back to the desktop.

CTRL+ALT+F6 seemed to work best for me but when I tried it for the first time it was just a black screen with a cursor. When I came back later it had a promt for me to login with.

Virtual consoles tips:
https://askubuntu.com/questions/157617/reverting-from-ctrl-alt-f1

Revision history for this message
Luca Ciavatta (cialu) wrote :

I am on Ubuntu 17.10 and I got the same issue. No working workaround because running APT updates from a text-only console is impossible due that CTRL+ALT+F6 (F1..F6) shows only a lighting cursor and can't login in a console.

Revision history for this message
windowsguy (something-f) wrote :

Same here, hosed 17.10 after kernel update to 4.13.0.19.
I have LUKS and I can’t boot to see the password prompt.
I can only boot back if I choose recovery mode, either with 0.19 or 0.17.
Now I removed the both of these and installed an older version (0.16), still the same problem.
Related: https://bugs.launchpad.net/ubuntu/xenial/+source/plymouth/+bug/1359689

Revision history for this message
Yu Lou (louyu1999) wrote :

I had a similar problem while upgrading from Ubuntu Gnome 17.04 to 17.10 on Dell XPS 15(with GTX 1050 graphics card). The kernel version that I was trying to install was 4.13.0-25.

I successfully solved the problem by killing dpkg, switching to text-only console(Ctrl+Alt+F6), and running `sudo dpkg --configure -a`.

It seems like this problem is related to Nvidia driver.

Revision history for this message
Anton Alexandrenok (the-spyke) wrote :

I had a similar issue while installing updates on my Ubuntu 17.10 x64 on Lenovo Thinkpad P50 (Nvidia Quadro M1000). The failing to install kernel was 4.13.0-31. I've managed to fix it by the steps from #11.

Revision history for this message
Chris (toefel) wrote :

I have the same issues without Nivdia drivers on ubuntu 17.10, lshw gives me

*-display
                description: VGA compatible controller
                product: Mars XTX [Radeon HD 8790M]
                vendor: Advanced Micro Devices, Inc. [AMD/ATI]
                physical id: 0
                bus info: pci@0000:01:00.0
                version: 00
                width: 64 bits
                clock: 33MHz
                capabilities: vga_controller bus_master cap_list rom
                configuration: driver=radeon latency=0
                resources: irq:29 memory:e0000000-efffffff memory:f7c00000-f7c3ffff ioport:e000(size=256) memory:f7c40000-f7c5ffff
        *-display
             description: VGA compatible controller
             product: 4th Gen Core Processor Integrated Graphics Controller
             vendor: Intel Corporation
             physical id: 2
             bus info: pci@0000:00:02.0
             version: 06
             width: 64 bits
             clock: 33MHz
             capabilities: vga_controller bus_master cap_list rom
             configuration: driver=i915 latency=0
             resources: irq:30 memory:f5800000-f5bfffff memory:d0000000-dfffffff ioport:f000(size=64) memory:c0000-dffff

uname -r gives me:
4.13.0-36-generic

Revision history for this message
Chris (toefel) wrote :

The solution of Veron Rado (junket), switching to a virtual console and then running sudo dpkg --configure -a worked for me too.

Revision history for this message
dino99 (9d9) wrote :

This is not a kernel problem, but a nvidia driver one.
https://help.ubuntu.com/community/BinaryDriverHowto/Nvidia

Changed in linux (Ubuntu Zesty):
status: Confirmed → Invalid
Changed in linux (Ubuntu):
status: Confirmed → Invalid
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.