Bug 753160 - pam files broke systemd on upgrade to F16
Summary: pam files broke systemd on upgrade to F16
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: systemd
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: ---
Assignee: systemd-maint
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-11-11 13:50 UTC by Kamil Páral
Modified: 2018-04-11 16:03 UTC (History)
15 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2012-01-30 09:22:54 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
Xorg.0.log (44.17 KB, text/plain)
2011-11-11 13:51 UTC, Kamil Páral
no flags Details
messages (1.08 MB, text/plain)
2011-11-11 13:51 UTC, Kamil Páral
no flags Details
rpm -qa output (62.26 KB, text/plain)
2011-11-11 13:58 UTC, Kamil Páral
no flags Details
dmesg with drm.debug=0x04 (123.63 KB, text/plain)
2011-11-11 14:58 UTC, Kamil Páral
no flags Details
system-auth (692 bytes, text/plain)
2011-11-11 15:48 UTC, Kamil Páral
no flags Details
system-auth-ac (932 bytes, text/plain)
2011-11-11 15:48 UTC, Kamil Páral
no flags Details
password-auth (692 bytes, text/plain)
2011-11-11 16:01 UTC, Kamil Páral
no flags Details
password-auth-ac (932 bytes, text/plain)
2011-11-11 16:02 UTC, Kamil Páral
no flags Details

Description Kamil Páral 2011-11-11 13:50:16 UTC
Description of problem:
I upgraded F15 to F16. In F15 everything worked great. In F16 I don't have hardware acceleration (and therefore no gnome-shell, etc). I did a clean installation of F16 Final RCsomething and 3D worked. The problem is only for upgraded system.

Intel GM45

no xorg.conf

# lspci -nn | grep VGA
00:02.0 VGA compatible controller [0300]: Intel Corporation Mobile 4 Series Chipset Integrated Graphics Controller [8086:2a42] (rev 07)

# glxinfo | grep -E '(vendor|render)'
direct rendering: Yes
server glx vendor string: SGI
client glx vendor string: Mesa Project and SGI
OpenGL vendor string: Tungsten Graphics, Inc
OpenGL renderer string: Mesa DRI Mobile Intel® GM45 Express Chipset 
    GL_EXT_vertex_array_bgra, GL_NV_conditional_render, 

# uname -a
Linux kparal 3.1.0-7.fc16.x86_64 #1 SMP Tue Nov 1 21:10:48 UTC 2011 x86_64 x86_64 x86_64 GNU/Linux

# ll /usr/lib64/libGL.so.1.2
-rwxr-xr-x. 1 root root 502120 Oct 29 02:42 /usr/lib64/libGL.so.1.2

# ll /usr/lib64/dri/i965_dri.so
-rwxr-xr-x. 1 root root 4006496 Oct 29 02:42 /usr/lib64/dri/i965_dri.so


Version-Release number of selected component (if applicable):
xorg-x11-drv-intel-2.16.0-2.fc16.x86_64
mesa-dri-drivers-7.11-8.fc16.x86_64
xorg-x11-server-Xorg-1.11.1-1.fc16.x86_64

How reproducible:
always

Comment 1 Kamil Páral 2011-11-11 13:51:39 UTC
Created attachment 533073 [details]
Xorg.0.log

Comment 2 Kamil Páral 2011-11-11 13:51:55 UTC
Created attachment 533074 [details]
messages

Comment 3 Kamil Páral 2011-11-11 13:58:01 UTC
Created attachment 533075 [details]
rpm -qa output

Comment 4 Matěj Cepl 2011-11-11 14:30:52 UTC
Thanks for the bug report.  We have reviewed the information you have provided above, and there is some additional information we require that will be helpful in our diagnosis of this issue.

Please add drm.debug=0x04 to the kernel command line, restart computer, and attach

* your X server config file (/etc/X11/xorg.conf, if available),
* output of the dmesg command, and

to the bug report as individual uncompressed file attachments using the bugzilla file attachment link above.

We will review this issue again once you've had a chance to attach this information.

Thanks in advance.

Comment 5 Kamil Páral 2011-11-11 14:58:39 UTC
Created attachment 533086 [details]
dmesg with drm.debug=0x04

Comment 6 Kamil Páral 2011-11-11 14:59:35 UTC
I have rebooted to a clean F16 RC installation and fully updated it. 3D accel works in there. But it still doesn't work for my F15->F16 upgraded system.

Comment 7 Kamil Páral 2011-11-11 15:13:35 UTC
This is the output from glxinfo on the broken system from logged-in user. I found out it differs from root's output:

$ glxinfo | grep -E '(vendor|render)'
direct rendering: Yes
server glx vendor string: SGI
client glx vendor string: Mesa Project and SGI
OpenGL vendor string: VMware, Inc.
OpenGL renderer string: Gallium 0.4 on llvmpipe

Comment 8 Kamil Páral 2011-11-11 15:16:58 UTC
$ ls -la /dev/dri/card*
crw-rw---- 1 root video 226, 0 Nov 11 15:53 /dev/dri/card0

airlied says this is to source of the problem, there should be ACL on that file

Comment 9 Kamil Páral 2011-11-11 15:27:07 UTC
There is a suspicion that systemd should set that ACL.

Comment 10 Kamil Páral 2011-11-11 15:46:38 UTC
michich found out that systemd-loginctl doesn't list my user session. That is probably caused by /etc/pam.d/system-auth not containing pam_systemd.so. My /etc/pam.d/system-auth is NOT a symlink to /etc/pam.d/system-auth-ac, which seems to be the default in F16. But I believe I did not "un-linked" those two files.

Comment 11 Kamil Páral 2011-11-11 15:48:09 UTC
Created attachment 533099 [details]
system-auth

Comment 12 Kamil Páral 2011-11-11 15:48:26 UTC
Created attachment 533100 [details]
system-auth-ac

Comment 13 Kamil Páral 2011-11-11 15:57:32 UTC
I symlinked system-auth to system-auth-ac. Still no user session listed in systemd-loginctl. Gnome-shell started to work, but still using software rendering  (same output of glxinfo). I had to force fallback mode.

There is now some ACL on /dev/dri/card0, but they seem to be wrong (not contain current user):

$ ls -la /dev/dri/card*
crw-rw----+ 1 root video 226, 0 Nov 11 16:51 /dev/dri/card0
$ getfacl /dev/dri/card*
getfacl: Removing leading '/' from absolute path names
# file: dev/dri/card0
# owner: root
# group: video
user::rw-
group::rw-
mask::rw-
other::---

Comment 14 Kamil Páral 2011-11-11 16:01:54 UTC
Created attachment 533103 [details]
password-auth

Comment 15 Kamil Páral 2011-11-11 16:02:13 UTC
Created attachment 533104 [details]
password-auth-ac

Comment 16 Kamil Páral 2011-11-11 16:04:17 UTC
The same problem for /etc/pam.d/password-auth{,-ac} .

Comment 17 Kamil Páral 2011-11-11 16:11:58 UTC
After making /etc/pam.d/password-auth symlink to /etc/pam.d/password-auth-ac the whole problem is fixed, hardware acceleration works now.

Comment 18 Kamil Páral 2011-11-11 16:18:41 UTC
I have looked into my F15 snapshot and I had password-auth{,-ac} and system-auth{,-ac} "un-linked" even on F15. I don't know how that happened, I didn't do it. But it worked in F15 and broke when upgrading to F15. Is that something authconfig maintainers want to deal with?

Comment 19 Tomas Mraz 2011-11-11 18:10:24 UTC
The systemd update is supposed to call authconfig that will put the pam_systemd to the system/password-auth-ac and the symlinks.

There was a %post script in the systemd package that did this.

Comment 20 Michal Schmidt 2011-11-14 08:19:16 UTC
Tomáš,
systemd's scriptlet adjusted Kamil's system-auth-ac as expected.
But for some reason he did not have /etc/pam.d/{system,password}-auth as symlinks, but distinct regular files.

Comment 21 Tomas Mraz 2011-11-14 09:24:42 UTC
That's weird as 'authconfig --update' or 'authconfig --updateall' that is called from the systemd %post will overwrite the system-auth and password-auth with symlinks. And I verified that this works fine with authconfig on Fedora 16.

Comment 22 Tomas Mraz 2011-11-14 10:06:00 UTC
OK, so the problem was that on the F15 the symlinks were already broken an the pam_systemd.so was already in system-auth-ac and password-auth-ac. As the systemd package postscript tests for the presence of pam_systemd in system-auth-ac / password-auth-ac it did not call authconfig.

I think the systemd should call authconfig also in case the system-auth and/or password-auth is not symlink. Here is the proposed change of the script snippet:

# Make sure pam_systemd is enabled
if ! /bin/grep -q pam_systemd /etc/pam.d/system-auth-ac || ! [ -h /etc/pam.d/system-auth ] ; then
        /usr/sbin/authconfig --update --nostart >/dev/null 2>&1 || :

        # Try harder
        /bin/grep -q pam_systemd /etc/pam.d/system-auth-ac || /usr/sbin/authconfig --updateall --nostart >/dev/null 2>&1 || :
fi

Comment 23 Jóhann B. Guðmundsson 2012-01-29 20:21:36 UTC
Is this still an issue on a fully updated release or can this bug be closed?

Comment 24 Kamil Páral 2012-01-30 08:32:14 UTC
This still might be issue for anyone upgrading from F15 to F16. And probably even for future releases. So I would say this is generic problem and Tomas's suggestion from comment 22 should be applied. Re-assigning to Rawhide.

Comment 25 Tomas Mraz 2012-01-30 09:09:35 UTC
But this post script should be already in the current systemd packages if I am not mistaken.

Comment 26 Jóhann B. Guðmundsson 2012-01-30 09:14:32 UTC
It is 

# Make sure pam_systemd is enabled
if ! /bin/grep -q pam_systemd /etc/pam.d/system-auth-ac >/dev/null 2>&1 || ! [ -h /etc/pam.d/system-auth ] ; then
        /usr/sbin/authconfig --update --nostart >/dev/null 2>&1 || :

        # Try harder
        /bin/grep -q pam_systemd /etc/pam.d/system-auth-ac >/dev/null 2>&1 || /usr/sbin/authconfig --updateall --nostart >/dev/null 2>&1 || :
fi

Comment 27 Jóhann B. Guðmundsson 2012-01-30 09:18:02 UTC
It got added [1] but this bug was never closed so I was not sure if it still was a problem or not...

1.Tue Nov 15 2011 Michal Schmidt <mschmidt> - 37-4
Run authconfig if /etc/pam.d/system-auth is not a symlink.
Resolves: #753160

Comment 28 Jóhann B. Guðmundsson 2012-01-30 09:22:54 UTC
I'm closing this as current release since it simply looks like this bug fell through the routine update process thus never was closed.

Just reopen it if it's still an issue.

Thanks


Note You need to log in before you can comment on or make changes to this bug.