FS#51882 - [dkms] Hooks building stop right after an invalid kernel

Attached to Project: Arch Linux
Opened by michael Lojkovic (zerophase) - Saturday, 19 November 2016, 02:07 GMT
Last edited by Sébastien Luttringer (seblu) - Saturday, 14 January 2017, 15:41 GMT
Task Type Bug Report
Category Packages: Extra
Status Closed
Assigned To Sébastien Luttringer (seblu)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 1
Private No

Details

Description:
The current version of lightdm fails to start. There's a couple newer versions than the current arch version.

Additional info:
lightdm 1:1.18.3-1



Steps to reproduce: Update nvidia drivers to the latest version, reboot, and lightdm should fail.
This task depends upon

Closed by  Sébastien Luttringer (seblu)
Saturday, 14 January 2017, 15:41 GMT
Reason for closing:  Fixed
Additional comments about closing:  dkms-2.3-2
Comment by Doug Newgard (Scimmia) - Saturday, 19 November 2016, 02:14 GMT
Without logs, this is useless.
Comment by michael Lojkovic (zerophase) - Saturday, 19 November 2016, 02:31 GMT
Here's the log.
Comment by Doug Newgard (Scimmia) - Saturday, 19 November 2016, 06:58 GMT
So that says the xorg isn't working. How about that log?
Comment by michael Lojkovic (zerophase) - Saturday, 19 November 2016, 07:50 GMT
So, I've fixed the issue. It isn't an issue with lightdm, but rather /usr/lib/dkms/alpm-hook install. If there's an old kernel module directory left behind, without an installed kernel, the dkms install gives up on the rest of the kernels currently installed.
   x-0.log (1.4 KiB)
Comment by Doug Newgard (Scimmia) - Saturday, 19 November 2016, 07:57 GMT
So you're using linux-ck, and presumable nvidia-ck? And you seem to have a Xorg.conf. So far, this isn't looking to be an Arch issue.
Comment by michael Lojkovic (zerophase) - Saturday, 19 November 2016, 08:09 GMT
It's check_kernel() in dkms/alpm-hook that's causing failure, when it hits a kernel that hasn't been removed completely.
Comment by TesX (tesfabpel) - Saturday, 19 November 2016, 08:29 GMT
Maybe it's related, but after this update games aren't starting anymore, they hang at startup and do nothing (even a my SDL2 + OpenGL stupid test C app)...
KWin works though, but when I go in the Compositor settings in the control panel the window hangs...

EDIT: Blender 2.78 too

EDIT 2: Happens only with Steam open...

EDIT 3: Happens when there are two OpenGL apps open at the same time... (for example, if I try to start two blender instances, the second hangs undefinitely)
Comment by Doug Newgard (Scimmia) - Saturday, 19 November 2016, 16:13 GMT
TesX, please don't hijack tickets with unrelated issues.
Comment by Sébastien Luttringer (seblu) - Monday, 21 November 2016, 16:20 GMT
@zerophase: Doug already asked 2 times so could you consider providing logs or something to support for each assertion you make?
You says that a DKMS alpm script issue, could you provide the appropriate console output? The best would be with env variable DKMS_ALPM_HOOK_DEBUG set.
Comment by michael Lojkovic (zerophase) - Monday, 21 November 2016, 18:08 GMT
Sure, just let me rollback the computer so I can recreate the issue. With DKMS_ALPM_HOOK_DEBUG set would all of the information you need be in the pacman log?
Comment by michael Lojkovic (zerophase) - Monday, 21 November 2016, 20:03 GMT
Here's the console output. I don't see any difference between having DKMS_ALPM_HOOK_DEBUG set to 1 or not.
Comment by Sébastien Luttringer (seblu) - Sunday, 01 January 2017, 05:14 GMT
1) Did you set DKMS_ALPM_HOOK_DEBUG as an env variable?
2) Could you point what's line is an bug. I don't see what's wrong.

Comment by michael Lojkovic (zerophase) - Sunday, 01 January 2017, 21:08 GMT
1) Did you set DKMS_ALPM_HOOK_DEBUG as an env variable?

Yes, I did. I believe I set it in /etc/environment

2) Could you point what's line is an bug. I don't see what's wrong.

I believe line 31 has the issue. If a kernel isn't completely uninstalled it's causing the hook to exit, upon hitting the condition and trying to install a dkms module. It looks like it bubbles up to line 80, returns from the function and exits from there.
Comment by Sébastien Luttringer (seblu) - Thursday, 12 January 2017, 23:43 GMT
1) This is a system wide config file for env. That doesn't means you have it loaded in your processs launching the pacman. Did you check with export or something like that?

2) Line 31 is:
11/21 14:00:17 [NOTICE] Download complete: /var/lib/pacman/sync/infinality-bundle.db.sig

Except you are using unsupported repo and packages, nothing is wrong at that line.
Comment by michael Lojkovic (zerophase) - Friday, 13 January 2017, 08:55 GMT
1) I'll have to add the files back to repeat the issue.

2) it's how the error is handled at line 81 that's the problem. If an error is found on line 31 pacman skips processing other kernels. How I look at it the return should be a continue at line 81. How it's working right now if a directory is corrupted other kernels won't receive the dkms update till that corrupted directory is fixed. (any other cause of throwing an error has the same effect)

Just replacing return with continue will allow functional kernels to still receive updates.
Comment by Sébastien Luttringer (seblu) - Saturday, 14 January 2017, 15:39 GMT
ok, lines refer to the dkms hook script not the dkms-install.log your sent earlier.
I get what you are reporting now, the issue only happen when at least one kernel is not dkms «compliant» and so all others build fail.

Loading...