fwupd crashed with SIGSEGV in _int_malloc()

Bug #1663548 reported by AnuxiVM
348
This bug affects 71 people
Affects Status Importance Assigned to Milestone
fwupd (Ubuntu)
Fix Released
High
Unassigned
Zesty
Fix Released
High
Unassigned

Bug Description

possible *workaround*
Comment out PrivateUsers=yes from /lib/systemd/system/fwupd.service

ProblemType: Crash
DistroRelease: Ubuntu 17.04
Package: fwupd 0.8.0-1
ProcVersionSignature: Ubuntu 4.9.0-16.17-generic 4.9.6
Uname: Linux 4.9.0-16-generic x86_64
ApportVersion: 2.20.4-0ubuntu2
Architecture: amd64
CrashCounter: 1
Date: Fri Feb 10 11:36:20 2017
ExecutablePath: /usr/lib/fwupd/fwupd
InstallationDate: Installed on 2017-02-10 (0 days ago)
InstallationMedia: Ubuntu 17.04 "Zesty Zapus" - Alpha amd64 (20170209)
ProcCmdline: /usr/lib/fwupd/fwupd
ProcEnviron:
 LANG=es_ES.UTF-8
 PATH=(custom, no user)
Signal: 11
SourcePackage: fwupd
StacktraceTop:
 _int_malloc (av=av@entry=0x7f9048af2b00 <main_arena>, bytes=bytes@entry=72) at malloc.c:3413
 __libc_calloc (n=<optimized out>, elem_size=<optimized out>) at malloc.c:3271
 g_malloc0 () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
 g_closure_new_simple () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
 g_cclosure_new () from /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
Title: fwupd crashed with SIGSEGV in _int_malloc()
UpgradeStatus: No upgrade log present (probably fresh install)
UserGroups:

Revision history for this message
AnuxiVM (anuxivm) wrote :
Revision history for this message
Apport retracing service (apport) wrote :

StacktraceTop:
 _int_malloc (av=av@entry=0x7f9048af2b00 <main_arena>, bytes=bytes@entry=72) at malloc.c:3413
 __libc_calloc (n=<optimized out>, elem_size=<optimized out>) at malloc.c:3271
 g_malloc0 () from /tmp/apport_sandbox_jj8QDg/lib/x86_64-linux-gnu/libglib-2.0.so.0
 g_closure_new_simple () from /tmp/apport_sandbox_jj8QDg/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0
 g_cclosure_new () from /tmp/apport_sandbox_jj8QDg/usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0

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 fwupd (Ubuntu):
importance: Undecided → Medium
tags: removed: need-amd64-retrace
Revision history for this message
Fabio Marconi (fabiomarconi) wrote :

It affects me too just after enabling wifi with a usb wifi adapter inserted .
Best regards and thanks

Changed in fwupd (Ubuntu):
status: New → Confirmed
Revision history for this message
Fabio Marconi (fabiomarconi) wrote :

It affects me too just after enabling wifi with a usb wifi adapter inserted .
Best regards

Changed in fwupd (Ubuntu):
importance: Medium → High
Revision history for this message
Fabio Marconi (fabiomarconi) wrote :

The presence of the wifi adapter is not related to this bug, it crashes even without it.
After the crash system is unusable and hardware power off is required.
Reproduced on real hardware

Revision history for this message
Fabio Marconi (fabiomarconi) wrote :

Threadstacktrace with dbgsym

Revision history for this message
Fabio Marconi (fabiomarconi) wrote :

Stacktrace+dbgsym

Revision history for this message
Fabio Marconi (fabiomarconi) wrote :

SegvAnalysis:
 Segfault happened at: 0x7f8eec398c8d <_int_malloc+109>: mov 0x10(%r14),%rdx
 PC (0x7f8eec398c8d) ok
 source "0x10(%r14)" (0x561200000010) not located in a known VMA region (needed readable region)!
 destination "%rdx" ok

Revision history for this message
Fabio Marconi (fabiomarconi) wrote :

feb 13 20:21:47 ZealantZebra systemd[1]: Failed to start Firmware update daemon.

Changed in fwupd (Ubuntu):
status: Confirmed → Triaged
Revision history for this message
Iain Lane (laney) wrote :

I see this too. For me it goes away if I comment out PrivateUsers=yes from /lib/systemd/system/fwupd.service.

information type: Private → Public
Revision history for this message
Richard Hughes (richard-hughes) wrote :

If you comment out the NoNewPrivileges=yes in /usr/lib/systemd/system/fwupd.service -- does this now start normally?

Revision history for this message
comptastic (comptastic) wrote :

Commenting out NoNewPrivileges=yes in /lib/systemd/system/fwupd.service does not fix the issue.

Commenting out PrivateUsers=yes from /lib/systemd/system/fwupd.service fixes it for me!

So is this an appropriate workaround? What is the root of this issue?

Revision history for this message
Dimos lampros (dimos33) wrote :

Bug #1663548

How can I destroy the bug? What do I need to do?

Changed in fwupd (Ubuntu):
status: Triaged → Invalid
Changed in fwupd (Ubuntu):
status: Invalid → Triaged
description: updated
Revision history for this message
Fabio Marconi (fabiomarconi) wrote :

as this crash was originally reported via apport I revert it back to bag for the fix

Revision history for this message
Fabio Marconi (fabiomarconi) wrote :

As this crash was originally reported by apport I revert it back to a bug report

Revision history for this message
Iain Lane (laney) wrote :

I filed https://github.com/dell/libsmbios/pull/13 which is now waiting for review

Revision history for this message
Mario Limonciello (superm1) wrote :

@laney

Thanks for digging into that. I think that's definitely a part that should be solved, but at least in the interim I believe this can be avoided in fwupd too by only running this code on supported systems.

Can you please check if https://github.com/hughsie/fwupd/commit/e70e5513cae8a74a5a3cd4376ff8c8f963892386
helps you with the existing libsmbios?

If so, I'll issue a new build to Debian with that integrated and we can track the libsmbios task separately.

Thanks,

Revision history for this message
Achim Behrens (k1l) wrote :

having the same issue on a Lenovo Thinkpad x230

Revision history for this message
Achim Behrens (k1l) wrote :

Ok, the workaround with commenting out PrivateUsers=yes from /lib/systemd/system/fwupd.service worked here, too, on the 17.04 on the Lenovo Thinkpad x230.

fuwpd is not crashing anymore. But i dont really know what the consequences of this workaround are.

Revision history for this message
Iain Lane (laney) wrote :

Mario,

Just tried your commits (on top of the Debian pkg) and they seem to fix the crash for me. I tried on an XPS 13 9350 and on a random desktop machine. The problem also happened for me in a VM. I didn't try that patch in there, but that might be a good way for you to try the error path.

I also didn't try a success path because I don't have hardware for that - assuming you will.

Cheers for working on this. Please upload if your testing also looks good. :-)

Revision history for this message
Mario Limonciello (superm1) wrote :

I spent some more time with this today and concluded that it is systemd confinement that is causing a majority of this headache. The stuff that was happening with crashes was just the tip. There were further problems with refreshing not working, flashing not working too.

I believe this commit should resolve all of the issues thus far:
https://github.com/hughsie/fwupd/commit/20c112a8911a4d89469a37f925edbc415fad25d4

If someone affected can please apply that locally to their systemd unit (/lib/systemd/system/fwupd.service) and confirm, it would be appreciated.

Thanks,

Changed in fwupd (Ubuntu Zesty):
assignee: nobody → zawheinhtet (zawheinhtet)
dino99 (9d9)
Changed in fwupd (Ubuntu Zesty):
assignee: zawheinhtet (zawheinhtet) → nobody
Revision history for this message
Walter Garcia-Fontes (walter-garcia) wrote :

Does this bug affect the access to google accounts? After updating to zeisty, I can access "www.google.com", but "mail.googl.com", for instance, times out.

Revision history for this message
Walter Garcia-Fontes (walter-garcia) wrote :

Forget about comment #25, can't access "mail.google.com" from a particular wifi network (eduroam), maybe there is a new bug there but I will investigate further.

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package fwupd - 0.8.1-3

---------------
fwupd (0.8.1-3) unstable; urgency=medium

  * Backport upstream commit to make valgrind optional (Closes: #856344)
  * Backport upstream commit to make /boot/efi optional to start
    fwupd.service.

 -- Mario Limonciello <email address hidden> Tue, 28 Feb 2017 08:30:56 -0600

Changed in fwupd (Ubuntu Zesty):
status: Triaged → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers