pulseaudio assert failure: pulseaudio: mixer.c:929: snd_mixer_elem_get_callback_private: Assertion `mixer' failed.

Bug #1663528 reported by dino99
174
This bug affects 25 people
Affects Status Importance Assigned to Milestone
PulseAudio
Fix Released
Medium
pulseaudio (Ubuntu)
Fix Released
High
Unassigned
Bionic
Won't Fix
High
Daniel van Vugt
Cosmic
Fix Released
High
Unassigned
Disco
Fix Released
High
Unassigned
Eoan
Fix Released
High
Unassigned

Bug Description

[Impact]

https://errors.ubuntu.com/problem/a8bcc8185d5b1da4614bcdcf99daf57011bf9250
https://errors.ubuntu.com/problem/5e10f78db7c4d1d3ab1cd6cd5d0b7cda2299eaad
https://errors.ubuntu.com/problem/0f07e226e7db1d0fb140736a956760871e695669

This is one of the top pulseaudio crashes in Ubuntu 18.04 according to:
https://errors.ubuntu.com/?release=Ubuntu%2018.04&package=pulseaudio&period=year

[Test Case]

No manual test case known. Just watch errors.ubuntu.com to check for recurrences.

[Regression Potential]

Low. The fix is already in PulseAudio 12 so has been used in Ubuntu 18.10 and later for a year so far.

[Other Info]

SRU sponsorship tracked in bug 1556439.

[Original Report]

Sidenote: Imediatly got that crash after the apt-xapian-index one ( lp:1663524 ); does not know if it can exist a possible relationship between them.

Got an other crash, and that time 'sound' is fully lost (pulseaudio not reloaded). Wonder if lp:1662860 can be concerned.

ProblemType: Crash
DistroRelease: Ubuntu 17.04
Package: pulseaudio 1:10.0-1ubuntu1
ProcVersionSignature: Ubuntu 4.9.0-16.17-generic 4.9.6
Uname: Linux 4.9.0-16-generic x86_64
NonfreeKernelModules: nvidia_uvm nvidia_drm nvidia_modeset nvidia
ApportVersion: 2.20.4-0ubuntu2
Architecture: amd64
AssertionMessage: pulseaudio: mixer.c:929: snd_mixer_elem_get_callback_private: Assertion `mixer' failed.
AudioDevicesInUse:
 USER PID ACCESS COMMAND
 /dev/snd/controlC1: oem 4084 F.... pulseaudio
 /dev/snd/controlC0: oem 4084 F.... pulseaudio
CurrentDesktop: GNOME
Date: Fri Feb 10 09:55:45 2017
ExecutablePath: /usr/bin/pulseaudio
ProcCmdline: /usr/bin/pulseaudio --start --log-target=syslog
ProcEnviron:
 LANGUAGE=en_GB:en
 PATH=(custom, no user)
 XDG_RUNTIME_DIR=<set>
 LANG=en_GB.UTF-8
 SHELL=/bin/bash
Signal: 6
SourcePackage: pulseaudio
StacktraceTop:
 __assert_fail_base (fmt=<optimised out>, assertion=assertion@entry=0x7f92818e7188 "mixer", file=file@entry=0x7f92818e7419 "mixer.c", line=line@entry=929, function=function@entry=0x7f92818e76a0 "snd_mixer_elem_get_callback_private") at assert.c:92
 __GI___assert_fail (assertion=0x7f92818e7188 "mixer", file=0x7f92818e7419 "mixer.c", line=929, function=0x7f92818e76a0 "snd_mixer_elem_get_callback_private") at assert.c:101
 snd_mixer_elem_get_callback_private () from /usr/lib/x86_64-linux-gnu/libasound.so.2
 ?? () from /usr/lib/pulse-10.0/modules/module-alsa-card.so
 ?? () from /usr/lib/pulse-10.0/modules/module-alsa-card.so
Title: pulseaudio assert failure: pulseaudio: mixer.c:929: snd_mixer_elem_get_callback_private: Assertion `mixer' failed.
UpgradeStatus: No upgrade log present (probably fresh install)
UserGroups: adm cdrom colord dip lpadmin nvidia-persistenced plugdev sambashare sudo users
dmi.bios.date: 07/22/2010
dmi.bios.vendor: American Megatrends Inc.
dmi.bios.version: 3002
dmi.board.asset.tag: To Be Filled By O.E.M.
dmi.board.name: P5W DH Deluxe
dmi.board.vendor: ASUSTeK Computer INC.
dmi.board.version: Rev 1.xx
dmi.chassis.asset.tag: Asset-1234567890
dmi.chassis.type: 3
dmi.chassis.vendor: Chassis Manufacture
dmi.chassis.version: Chassis Version
dmi.modalias: dmi:bvnAmericanMegatrendsInc.:bvr3002:bd07/22/2010:svnASUSTEKCOMPUTERINC:pnP5WDHDeluxe:pvrSystemVersion:rvnASUSTeKComputerINC.:rnP5WDHDeluxe:rvrRev1.xx:cvnChassisManufacture:ct3:cvrChassisVersion:
dmi.product.name: P5W DH Deluxe
dmi.product.version: System Version
dmi.sys.vendor: ASUSTEK COMPUTER INC

Revision history for this message
dino99 (9d9) wrote :
information type: Private → Public
Revision history for this message
Apport retracing service (apport) wrote :

StacktraceTop:
 __assert_fail_base (fmt=<optimized out>, assertion=assertion@entry=0x7f92818e7188 "mixer", file=file@entry=0x7f92818e7419 "mixer.c", line=line@entry=929, function=function@entry=0x7f92818e76a0 <__PRETTY_FUNCTION__.9666> "snd_mixer_elem_get_callback_private") at assert.c:92
 __GI___assert_fail (assertion=assertion@entry=0x7f92818e7188 "mixer", file=file@entry=0x7f92818e7419 "mixer.c", line=line@entry=929, function=function@entry=0x7f92818e76a0 <__PRETTY_FUNCTION__.9666> "snd_mixer_elem_get_callback_private") at assert.c:101
 snd_mixer_elem_get_callback_private (mixer=mixer@entry=0x0) at mixer.c:929
 report_jack_state (melem=0x0, mask=mask@entry=0) at modules/alsa/module-alsa-card.c:362
 card_suspend_changed (c=<optimized out>, card=<optimized out>, u=0x5594b6172160) at modules/alsa/module-alsa-card.c:628

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 pulseaudio (Ubuntu):
importance: Undecided → Medium
tags: removed: need-amd64-retrace
dino99 (9d9)
description: updated
Revision history for this message
dino99 (9d9) wrote :

After experimenting, the faulty package seems that newer nvidia-375 driver from the zesty-proposed archive ( lp:1662860 ). Made the reverting to avoid the too many crashes.

Revision history for this message
Luke Yelavich (themuso) wrote : Re: [Bug 1663528] Re: pulseaudio assert failure: pulseaudio: mixer.c:929: snd_mixer_elem_get_callback_private: Assertion `mixer' failed.

After making the changes you made, are you still getting crashes?

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

@Luke

no more pulseaudio crash with the graphic driver from ppa (that one has no install issue)

Revision history for this message
Luke Yelavich (themuso) wrote :

 affects ubuntu/pulseaudio
 status invalid

Ok, closing for now. Feel free to re-open if this crops up again.

Changed in pulseaudio (Ubuntu):
status: New → Invalid
dino99 (9d9)
Changed in pulseaudio (Ubuntu):
status: Invalid → Confirmed
Revision history for this message
dino99 (9d9) wrote :

Status changed as a crash happened quickly after a gnome-shell session ; was only checking archives upload via synaptic.
Stangely Apport have decided that is a duplicate of that report (which was set as invalid many days back).
So im joining the crash file as many upgraded packages has been done

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

oem@u64:~$ journalctl | grep pulseaudio
Feb 18 11:57:43 u64 systemd[1]: session-c1.scope: Killing process 2546 (pulseaudio) with signal SIGTERM.
Feb 18 11:57:57 u64 pulseaudio[2917]: [pulseaudio] bluez5-util.c: GetManagedObjects() failed: org.freedesktop.DBus.Error.TimedOut: Failed to activate service 'org.bluez': timed out
Feb 18 11:59:32 u64 pulseaudio[4792]: [pulseaudio] main.c: User-configured server at {c4b2c6660980c357474aa5a35400a0f7}unix:/run/user/1000/pulse/native, which appears to be local. Probing deeper.
Feb 18 11:59:32 u64 pulseaudio[4795]: [pulseaudio] pid.c: Stale PID file, overwriting.
Feb 18 11:59:34 u64 pulseaudio[4795]: [pulseaudio] module-alsa-card.c: Failed to open mixer for jack detection
Feb 18 11:59:44 u64 systemd[1]: session-c3.scope: Killing process 4989 (pulseaudio) with signal SIGTERM.
Feb 18 11:59:46 u64 pulseaudio[5197]: [pulseaudio] pid.c: Stale PID file, overwriting.
Feb 18 11:59:59 u64 pulseaudio[5197]: [pulseaudio] bluez5-util.c: GetManagedObjects() failed: org.freedesktop.DBus.Error.TimedOut: Failed to activate service 'org.bluez': timed out

Note: this system has no bluetooth hardware; so hopes 'bluez' is not disturbing pulseaudio.

Revision history for this message
Fredrik Jacobsson (smask) wrote :

I'm getting this error message on a system that's pretty recently upgraded to 17.10

Revision history for this message
Daniel van Vugt (vanvugt) wrote :
Changed in pulseaudio (Ubuntu):
importance: Medium → High
description: updated
tags: added: artful
Revision history for this message
Domar (domar) wrote :

I can confirm this problem for a fresh installation of Ubuntu 17.10

Revision history for this message
In , Paulepanter (paulepanter) wrote :
Download full text (4.0 KiB)

Created attachment 136388
(gdb) t a a bt; t a a bt f; info registers

Looking through the core dump files of one system with Debian 9 (Stretch), I noticed some of PulseAudio 10.0, where it terminates with SIGABRT.

```
Thread 3 (Thread 0x7f60175f1700 (LWP 9319)):
#0 0x00007f6028922771 in __GI_ppoll (fds=0x56233965ece0, nfds=4, timeout=<optimized out>, sigmask=sigmask@entry=0x0) at ../sysdeps/unix/sysv/linux/ppoll.c:39
#1 0x00007f602a098df8 in ppoll (__ss=0x0, __timeout=<optimized out>, __nfds=<optimized out>, __fds=<optimized out>) at /usr/include/x86_64-linux-gnu/bits/poll2.h:77
#2 pa_rtpoll_run (p=0x56233978bbe0) at pulsecore/rtpoll.c:314
#3 0x00007f6022189a73 in thread_func (userdata=0x56233978b9c0) at modules/alsa/alsa-source.c:1516
#4 0x00007f6029e302c8 in internal_thread_func (userdata=0x56233964bf50) at pulsecore/thread-posix.c:81
#5 0x00007f6029302494 in start_thread (arg=0x7f60175f1700) at pthread_create.c:333
#6 0x00007f602892baff in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:97

Thread 2 (Thread 0x7f6017df2700 (LWP 9318)):
#0 0x00007f6028922771 in __GI_ppoll (fds=0x5623396d0b80, nfds=5, timeout=<optimized out>, sigmask=sigmask@entry=0x0) at ../sysdeps/unix/sysv/linux/ppoll.c:39
#1 0x00007f602a098df8 in ppoll (__ss=0x0, __timeout=<optimized out>, __nfds=<optimized out>, __fds=<optimized out>) at /usr/include/x86_64-linux-gnu/bits/poll2.h:77
#2 pa_rtpoll_run (p=0x562339750c60) at pulsecore/rtpoll.c:314
#3 0x00007f6022183575 in thread_func (userdata=0x562339750a10) at modules/alsa/alsa-sink.c:1799
#4 0x00007f6029e302c8 in internal_thread_func (userdata=0x562339668390) at pulsecore/thread-posix.c:81
#5 0x00007f6029302494 in start_thread (arg=0x7f6017df2700) at pthread_create.c:333
#6 0x00007f602892baff in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:97

Thread 1 (Thread 0x7f602a4684c0 (LWP 2624)):
#0 __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:51
#1 0x00007f60288773fa in __GI_abort () at abort.c:89
#2 0x00007f602886ee37 in __assert_fail_base (fmt=<optimized out>, assertion=assertion@entry=0x7f60224748e8 "mixer", file=file@entry=0x7f6022474b79 "mixer.c", line=line@entry=929, function=function@entry=0x7f6022474e00 <__PRETTY_FUNCTION__.9666> "snd_mixer_elem_get_callback_private") at assert.c:92
#3 0x00007f602886eee2 in __GI___assert_fail (assertion=assertion@entry=0x7f60224748e8 "mixer", file=file@entry=0x7f6022474b79 "mixer.c", line=line@entry=929, function=function@entry=0x7f6022474e00 <__PRETTY_FUNCTION__.9666> "snd_mixer_elem_get_callback_private") at assert.c:101
#4 0x00007f60223f503d in snd_mixer_elem_get_callback_private (mixer=mixer@entry=0x0) at mixer.c:929
#5 0x00007f60226be60b in report_jack_state (melem=0x0, mask=mask@entry=0) at modules/alsa/module-alsa-card.c:362
#6 0x00007f60226beb1b in card_suspend_changed (c=<optimized out>, card=<optimized out>, u=0x5623395de220) at modules/alsa/module-alsa-card.c:628
#7 0x00007f602a08d60c in pa_hook_fire (hook=0x562339555948, data=data@entry=0x5623395d0a40) at pulsecore/hook-list.c:104
#8 0x00007f602a089d8a in pa_card_suspend (c=c@entry=0x5623395d0a40, suspend=suspend@entry=false, cause=cause@entry=PA_SUSPEND_SESSION) at ...

Read more...

tags: added: bionic
Revision history for this message
In , Tanu Kaskinen (tanuk) wrote :

Sorry, I didn't notice this bug report until now. I think I have a fix for it, I'll submit it shortly.

Revision history for this message
In , Tanu Kaskinen (tanuk) wrote :

Here's the patch: https://patchwork.freedesktop.org/patch/225242/

If this is a reproducible problem and you're able to apply the patch, testing would be appreciated (I'm not sure the bug that I found is really the root cause of the crash).

Revision history for this message
In , Tanu Kaskinen (tanuk) wrote :

The patch is now in master.

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Fix Released, apparently. Zero reports of this crash after 17.10.

Changed in pulseaudio (Ubuntu):
status: Confirmed → Fix Released
Revision history for this message
Fergus Incoronato (fergus.incoronato) wrote :

I am still experiencing it on 18.04

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Sorry, my mistake. Yes you and 1000 other people have reported this against 18.04.

Changed in pulseaudio (Ubuntu):
status: Fix Released → Confirmed
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

It looks like this crash was fixed in PulseAudio 12.0 (Ubuntu 18.10) by commit 9e5be0899f60208046f1c5e2d32a2dd207d8fa00.

Changed in pulseaudio (Ubuntu):
status: Confirmed → Fix Released
Changed in pulseaudio:
importance: Unknown → Medium
status: Unknown → Fix Released
Revision history for this message
Valentin Wittich (vwittich) wrote :

Still having that issue with Ubuntu 18.04.2 LTS on a ThinkPad T480 and the stock pulseaudio 11.1.

Is there going to be a fix/upgrade for the LTS?

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

This looks like a common crash in 18.04. Not hugely common, but I don't think we could say no.

I just don't know when/if such an update to 18.04 will get done.

Changed in pulseaudio (Ubuntu Bionic):
status: New → Confirmed
description: updated
description: updated
Changed in pulseaudio (Ubuntu Bionic):
importance: Undecided → High
status: Confirmed → Triaged
Changed in pulseaudio (Ubuntu Bionic):
assignee: nobody → Daniel van Vugt (vanvugt)
description: updated
description: updated
description: updated
description: updated
Changed in pulseaudio (Ubuntu Bionic):
status: Triaged → In Progress
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Patch proposed in bug 1556439.

Changed in pulseaudio (Ubuntu Bionic):
status: In Progress → Fix Committed
description: updated
description: updated
Changed in pulseaudio (Ubuntu Cosmic):
status: New → Fix Released
importance: Undecided → High
Changed in pulseaudio (Ubuntu Disco):
status: New → Fix Released
importance: Undecided → High
Revision history for this message
Brian Murray (brian-murray) wrote : Please test proposed package

Hello dino99, or anyone else affected,

Accepted pulseaudio into bionic-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/pulseaudio/1:11.1-1ubuntu7.3 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested and change the tag from verification-needed-bionic to verification-done-bionic. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-bionic. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

tags: added: verification-needed verification-needed-bionic
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

I've been using 1:11.1-1ubuntu7.3 for a couple of weeks already and have had no problems. But I would rather someone actually affected by this crash responds to comment #26.

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

It appears there have been two occurrences of this crash even with the proposed version:

https://errors.ubuntu.com/?release=Ubuntu%2018.04&package=pulseaudio&period=month&version=1%3A11.1-1ubuntu7.3

tags: added: verification-failed-bionic
removed: verification-needed-bionic
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Actually, that looks impossible. Maybe someone has built their own with the same version?

tags: added: verification-needed-bionic
removed: verification-failed-bionic
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

I'll dig into this tomorrow.

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

I don't understand how we're getting two instances of this crash in version 1:11.1-1ubuntu7.3.

It sounds like either someone built their own package by the same name, or errors.ubuntu.com is not grouping the crashes correctly.

I say this because the fix does:

+++ pulseaudio/src/modules/alsa/module-alsa-card.c
@@ -625,7 +625,8 @@ static pa_hook_result_t card_suspend_changed
     if (card->suspend_cause == 0) {
         /* We were unsuspended, update jack state in case it changed while we were suspended */
         PA_HASHMAP_FOREACH(jack, u->jacks, state) {
- report_jack_state(jack->melem, 0);
+ if (jack->melem)
+ report_jack_state(jack->melem, 0);
         }
     }

Yet errors.ubuntu.com is saying it is still crashing due to a NULL melem:

  report_jack_state (melem=0x0, mask=mask@entry=0)
  card_suspend_changed

That NULL should be impossible with the patch.

I think most likely errors.ubuntu.com is grouping similar assertions in mixer.c:929 incorrectly. And it only shows the full symbolic stack trace from some older instance of the crash -- not the ones from version 1:11.1-1ubuntu7.3.

tags: removed: artful zesty
tags: added: verification-failed-bionic
removed: verification-needed-bionic
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Clearly errors.ubuntu.com is wrong with what crashes it groups into https://errors.ubuntu.com/problem/a8bcc8185d5b1da4614bcdcf99daf57011bf9250

But it's going to be more annoying forever arguing with bots about this than to just not fix it. So I choose to just not fix it for bionic.

There is some remaining crash that is hitting https://errors.ubuntu.com/problem/a8bcc8185d5b1da4614bcdcf99daf57011bf9250 that has a different stack trace to what that page shows, but of course, we can't find it out. What we do know is that it seems to be fully fixed in PulseAudio 12, or was fixed in ALSA around the same time as v12.

Changed in pulseaudio (Ubuntu Bionic):
status: Fix Committed → Won't Fix
Revision history for this message
Chris Halse Rogers (raof) wrote : Proposed package upload rejected

An upload of pulseaudio to bionic-proposed has been rejected from the upload queue for the following reason: "The changes file claims to fix #1663528, but this won't. We don't need to preserve the changelog of -proposed packages, so drop it from the 1ubuntu7.3 entry".

Mathew Hodson (mhodson)
tags: removed: verification-needed
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.