unity8 crashed with SIGSEGV in QLightDM::GreeterImpl::authenticateWithPam() when logging in

Bug #1425362 reported by Marco Trevisan (Treviño)
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
unity8 (Ubuntu)
Fix Released
Medium
Michael Terry
Vivid
New
Undecided
Unassigned
unity8 (Ubuntu RTM)
Fix Released
Undecided
Unassigned

Bug Description

I'm trying to run unity8 in a vivid vmware session (mir works fine here).
But unity8 crashes when logging in, and it happens again everytime I insert my password in the u8 lockscreen.
---
The only way to successfully log in unity8 was to add myself to the "nopasswdlogin" group. This made the unity8 pam module checks, and thus no crash.

ProblemType: CrashDistroRelease: Ubuntu 15.04
Package: unity8 8.02+15.04.20150224-0ubuntu1
ProcVersionSignature: Ubuntu 3.18.0-13.14-generic 3.18.5
Uname: Linux 3.18.0-13-generic x86_64
ApportVersion: 2.16.1-0ubuntu2
Architecture: amd64
CrashCounter: 1
Date: Tue Feb 24 18:09:32 2015
ExecutablePath: /usr/bin/unity8
InstallationDate: Installed on 2015-02-25 (0 days ago)
InstallationMedia: Ubuntu 15.04 "Vivid Vervet" - Alpha amd64 (20150224)
ProcCmdline: unity8
SegvAnalysis:
 Segfault happened at: 0x7fb33b34c3a9 <_IO_vfprintf_internal+5561>: repnz scas %es:(%rdi),%al
 PC (0x7fb33b34c3a9) ok
 source "%es:(%rdi)" (0xffffffff) not located in a known VMA region (needed readable region)!
 destination "%al" ok
 Stack memory exhausted (SP below stack segment)
SegvReason: reading unknown VMA
Signal: 11SourcePackage: unity8
StacktraceTop:
 _IO_vfprintf_internal (s=s@entry=0x7fb2ea5b69d0, format=<optimized out>, format@entry=0x7fb2f7a8f2d3 "%s(%s:%s):", ap=ap@entry=0x7fb2ea5b6b08) at vfprintf.c:2039
 __GI___vasprintf_chk (result_ptr=0x7fb2ea5b6be8, flags=1, format=0x7fb2f7a8f2d3 "%s(%s:%s):", args=args@entry=0x7fb2ea5b6b08) at vasprintf_chk.c:66
 __asprintf_chk (result_ptr=<optimized out>, flags=<optimized out>, format=<optimized out>) at asprintf_chk.c:32
 pam_vsyslog () from /lib/x86_64-linux-gnu/libpam.so.0
 pam_syslog () from /lib/x86_64-linux-gnu/libpam.so.0
Title: unity8 crashed with SIGSEGV in _IO_vfprintf_internal()
UpgradeStatus: No upgrade log present (probably fresh install)
UserGroups: adm cdrom dip lpadmin plugdev sambashare sudo

Related branches

Revision history for this message
Marco Trevisan (Treviño) (3v1n0) wrote :
Revision history for this message
Apport retracing service (apport) wrote :

StacktraceTop:
 _IO_vfprintf_internal (s=s@entry=0x7fb2ea5b69d0, format=<optimized out>, format@entry=0x7fb2f7a8f2d3 "%s(%s:%s):", ap=ap@entry=0x7fb2ea5b6b08) at vfprintf.c:2039
 __GI___vasprintf_chk (result_ptr=0x7fb2ea5b6be8, flags=1, format=0x7fb2f7a8f2d3 "%s(%s:%s):", args=args@entry=0x7fb2ea5b6b08) at vasprintf_chk.c:66
 __asprintf_chk (result_ptr=result_ptr@entry=0x7fb2ea5b6be8, flags=flags@entry=1, format=format@entry=0x7fb2f7a8f2d3 "%s(%s:%s):") at asprintf_chk.c:32
 asprintf (__fmt=0x7fb2f7a8f2d3 "%s(%s:%s):", __ptr=0x7fb2ea5b6be8) at /usr/include/x86_64-linux-gnu/bits/stdio2.h:178
 pam_vsyslog (pamh=0x2330710, priority=3, fmt=0x7fb2f7a8dc38 "application failed to re-exec stack [%d:%d]", args=args@entry=0x7fb2ea5b6c40) at pam_syslog.c:81

Revision history for this message
Apport retracing service (apport) wrote : Stacktrace.txt
Revision history for this message
Apport retracing service (apport) wrote : StacktraceSource.txt
Revision history for this message
Apport retracing service (apport) wrote : ThreadStacktrace.txt
Changed in unity8 (Ubuntu):
importance: Undecided → Medium
tags: removed: need-amd64-retrace
Revision history for this message
Marco Trevisan (Treviño) (3v1n0) wrote :

Full stacktrace, including u8 symbols (missing in the automatic retrace).

Unity seems fine actually, but crash happens when calling pam_authenticate where the pamHandle is something like:

{authtok = 0x7fb300000000 <error: Cannot access memory at address 0x7fb300000000>,
  caller_is = 3944807584, pam_conversation = 0xffffffff, oldauthtok = 0x0, prompt = 0x0,
  service_name = 0x0, user = 0x0, rhost = 0x0,
  ruser = 0xffffffff <error: Cannot access memory at address 0xffffffff>, tty = 0x0,
  xdisplay = 0x0, authtok_type = 0x0, data = 0x0, env = 0x0, fail_delay = {set = PAM_FALSE,
    delay = 0, begin = 0, delay_fn_ptr = 0x0}, xauth = {namelen = 0,
    name = 0xffffffffffffffff <error: Cannot access memory at address 0xffffffffffffffff>,
    datalen = 36901392,
    data = 0xffffffff00000001 <error: Cannot access memory at address 0xffffffff00000001>},
  handlers = {module = 0x232d370, modules_allocated = 36855568, modules_used = 0,
    handlers_loaded = 36898784, conf = {authenticate = 0x0, setcred = 0x21,
      acct_mgmt = 0x6d6f6e675f6d6170, open_session = 0x6e697279656b5f65,
      close_session = 0x7f006f730067, chauthtok = 0x21}, other = {
      authenticate = 0x6c61776b5f6d6170, setcred = 0x6f730074656c, acct_mgmt = 0x0,
      open_session = 0xd1, close_session = 0x7fb300000000, chauthtok = 0x0}}, former = {
    choice = -1, depth = 0, impression = 0, status = 0, substates = 0x0, fail_user = 0,
    want_user = 0, prompt = 0x0, update = PAM_FALSE},
  mod_name = 0xffffffff <error: Cannot access memory at address 0xffffffff>, mod_argc = 0,
  mod_argv = 0x0, choice = 0, audit_state = 0}

Not sure if it might be a threading issue

summary: - unity8 crashed with SIGSEGV in _IO_vfprintf_internal() - When logging in
+ unity8 crashed with SIGSEGV in
+ QLightDM::GreeterImpl::authenticateWithPam() when logging in
description: updated
Changed in unity8 (Ubuntu):
assignee: nobody → Michael Terry (mterry)
Revision history for this message
Michael Terry (mterry) wrote :

Yeah, seems to be a threading issue, I can reproduce by stress-testing rapidly asking our pam glue layer for logins. Working on it.

Changed in unity8 (Ubuntu):
status: New → In Progress
Revision history for this message
Michael Terry (mterry) wrote :

OK, I have a proposed fix: https://code.launchpad.net/~mterry/unity8/cancel-pam-harder/+merge/251174

When jenkins makes debs for that MP, could you try those debs and see if they help?

kevin gunn (kgunn72)
tags: added: vivid-stab-candidate
Revision history for this message
Marco Trevisan (Treviño) (3v1n0) wrote :

Sorry, I missed your ping on IRC (I was giving a talk about this stuff at that time :)), but yes: I've just downloaded latest vivid, installed the unity8 desktop on mir, unblacklisted the mesa drivers from virtualbox (to get 3d acceleration), and that's it.

I'll try the debs as soon as jenkins will build them (in case I miss that, please ping me)

Thanks

Revision history for this message
Michael Terry (mterry) wrote :

@Marco, the debs are there now

Revision history for this message
Marco Trevisan (Treviño) (3v1n0) wrote :

Cool, fix works here!

Revision history for this message
Michael Terry (mterry) wrote :

@Marco, thank you so much! I'll note that the fix has been tested in the MP.

Revision history for this message
kevin gunn (kgunn72) wrote :

untagging for vivid-stab-candidate, this code should be the same for rtm - and evidence seen
and this is only reproducible on vmware desktop (so not priority for mobile devices)

kevin gunn (kgunn72)
tags: removed: vivid-stab-candidate
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package unity8 - 8.02+15.10.20150518.1-0ubuntu1

---------------
unity8 (8.02+15.10.20150518.1-0ubuntu1) wily; urgency=medium

  [ Albert Astals Cid ]
  * Add overrides to override functions
  * Implement "rating-edit" preview widget (LP: #1318144)
  * Make the DashContent::test_mainNavigation test more stable (LP:
    #1450809)
  * Use art height as implicitHeight when the header is overlayed and
    there's no summary

  [ CI Train Bot ]
  * New rebuild forced.
  * Resync trunk.

  [ Daniel d'Andrada ]
  * Introducing FloatingFlickable
  * Make Ubuntu.Gestures components install TouchRegistry by themselves

  [ Michael Terry ]
  * Fix a possible crash in our PAM threading code. (LP: #1425362) (LP:
    #1425362)
  * Fix the lockscreen becoming unresponsive after testing an app on the
    device from QtCreator. (LP: #1435364)

  [ Nick Dedekind ]
  * Fixed desktop stage app focus.
  * Fixed issue in laggy indicator autpilot tests (LP: #1446846)

 -- CI Train Bot <email address hidden> Mon, 18 May 2015 23:04:39 +0000

Changed in unity8 (Ubuntu):
status: In Progress → Fix Released
Revision history for this message
Łukasz Zemczak (sil2100) wrote :
Download full text (3.8 KiB)

This bug was fixed in the package unity8 8.02+15.04.20150603.1-0ubuntu1 in https://launchpad.net/~ci-train-ppa-service/+archive/ubuntu/stable-phone-overlay

---------------

unity8 (8.02+15.04.20150603.1-0ubuntu1) vivid; urgency=medium

  [ CI Train Bot ]
  * New rebuild forced.
  * Resync trunk.

  [ Renato Araujo Oliveira Filho ]
  * Set the device led color to green. (LP: #1450894)

unity8 (8.02+15.10.20150518.1-0ubuntu1) wily; urgency=medium

  [ Albert Astals Cid ]
  * Add overrides to override functions
  * Implement "rating-edit" preview widget (LP: #1318144)
  * Make the DashContent::test_mainNavigation test more stable (LP:
    #1450809)
  * Use art height as implicitHeight when the header is overlayed and
    there's no summary

  [ CI Train Bot ]
  * New rebuild forced.
  * Resync trunk.

  [ Daniel d'Andrada ]
  * Introducing FloatingFlickable
  * Make Ubuntu.Gestures components install TouchRegistry by themselves

  [ Michael Terry ]
  * Fix a possible crash in our PAM threading code. (LP: #1425362) (LP:
    #1425362)
  * Fix the lockscreen becoming unresponsive after testing an app on the
    device from QtCreator. (LP: #1435364)

  [ Nick Dedekind ]
  * Fixed desktop stage app focus.
  * Fixed issue in laggy indicator autpilot tests (LP: #1446846)

unity8 (8.02+15.04.20150511-0ubuntu1) vivid; urgency=medium

  [ Albert Astals Cid ]
  * Workarounds for concierge mode.

  [ CI Train Bot ]
  * New rebuild forced.
  * Resync trunk.

unity8 (8.02+15.04.20150505-0ubuntu1) vivid; urgency=medium

  [ Albert Astals Cid ]
  * Make runtests fake a test error if make fails
  * Make the test more stable
  * Use dbus-test-runner instead of dbus-launch

  [ Daniel d'Andrada ]
  * DirectionalDragArea: improvements & API grooming (LP: #1417920)
  * Fix EdgeDragEvaluator when a drag can happen both ways
    (Direction.Horizontal)

  [ Josh Arenson ]
  * Remove panelHeight property as it is unused.

  [ Leo Arias ]
  * Initial clean up of the autopilot tests set up. Removed the touch
    device from the test case. Moved the restart of unity to a fixture.
    Removed the unused DragMixin. Updated the setUpClass to use
    process_helpers. Removed the workaround for bug #1238417, already
    fixed. Use the toolkit helper to set the testability environment
    variable. Fixed the indicators base class that was restarting unity
    twice. (LP: #1238417, #1447206)
  * Use the base class from the toolkit in autopilot tests.

  [ Michael Zanetti ]
  * emit application-stop when we're going down (LP: #1326513)

  [ Michał Sawicz ]
  * UNITY_SCOPES_LIST is no more

  [ handsome_feng<email address hidden> ]
  * When click the favorite scope in Dash Manager , it just return to
    the corresponding scope page. (LP: #1447056)

unity8 (8.02+15.04.20150422-0ubuntu1) vivid; urgency=medium

  [ Albert Astals Cid ]
  * Compile with Qt 5.5 (LP: #1437238)
  * Different way of top aligning labels when the other one in the row
    is multiline (LP: #1442085)
  * make pot_file

  [ Andrea Cimitan ]
  * Set sourceSize for DashBackground.qml Image

  [ CI Train Bot ]
  * New rebuild forced.
  * Resync trunk. added: po/sk.po

  [ Daniel d'Andrada ]
  * Move handling of comma...

Read more...

Changed in unity8 (Ubuntu RTM):
status: New → Fix Released
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.