Frequent crashes with error "called `Option::unwrap()` on a `None` value" (AudioThreadPriorityError)
Categories
(Core :: Audio/Video: cubeb, defect, P2)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox77 | --- | fixed |
People
(Reporter: jpalecek, Assigned: padenot)
Details
Attachments
(3 files)
User Agent: Mozilla/5.0 (X11; Linux i686; rv:75.0) Gecko/20100101 Firefox/75.0
Steps to reproduce:
Hello,
when i browse some websites, like The Guardian, Reuters, I get frequent crashes, typically just as the article loads.
Actual results:
Crashes like these:
https://crash-stats.mozilla.org/report/index/34721275-2250-4a58-9242-fb6450200426
Expected results:
Possibly, no crash
Comment 1•5 years ago
|
||
Seems like the unwrap in From<dbus::Error>::from is failing.
| Assignee | ||
Comment 2•5 years ago
|
||
Unclear why this crashes, maybe this Firefox is sandboxed harder than normal ones. Easy to fix regardless.
| Assignee | ||
Updated•5 years ago
|
| Assignee | ||
Comment 3•5 years ago
|
||
| Assignee | ||
Comment 4•5 years ago
|
||
Depends on D72636
Updated•5 years ago
|
Comment 6•5 years ago
|
||
Backed out changeset 36cb992cb56a (Bug 1633266) for causing build bustages CLOSED TREE
Failure log: https://treeherder.mozilla.org/logviewer.html#/jobs?job_id=299740207&repo=autoland&lineNumber=1780
Backout: https://hg.mozilla.org/integration/autoland/rev/15650b89e468574a18179bfac89aa4b12cecaa6a
| Assignee | ||
Comment 7•5 years ago
|
||
Hrm screwed up and landed only one of the two patches.
| Reporter | ||
Comment 9•5 years ago
|
||
| Assignee | ||
Comment 10•5 years ago
|
||
(In reply to Jiri Palecek from comment #9)
Just out of curiosity, I checked what was failing by stracing firefox and
found:
- setpriority was indeed failing, but adding CAP_SYS_NICE to firefox didn't
help (ie. setpriority succeeds, firefox crashes)- the strace contains strange entries.
- socketcall failing due to seccomp and
- rt_sigreturn failing with ENAMETOOLONG? Never heard of it
The socket failing is intentional: in you configuration, this process is sandboxed and we can't promote thread this way: they are promoted differently, from another process, but we still try it here, because some users have special configuration that let it succeed. The issue is that this was supposed to fail without crashing, this is what I'm fixing here. You'll be able to check tomorrow in a Nightly build if it's fixed (I can't reproduce unfortunately).
I'm curious why you're facing this, do you have any special configuration on your machine? Is it a build from a distro? As far as I know, we have only around 20 crashes with this signature, so something is different from all other configurations, if I can find what it is, I might be able to make this work better.
When succeeding in playing audio, and while audio is playing, what does the following command output:
ps -eo pid,tid,class,rtprio,ni,pri,psr,pcpu,stat,wchan:14,comm -T | grep RR
This checks what threads are real-time currently on the machine. If this succeeds, then there should be a few thread with names starting with AudioIPC.
| Reporter | ||
Comment 11•5 years ago
|
||
When succeeding in playing audio, and while audio is playing, what does the following command output:
ps -eo pid,tid,class,rtprio,ni,pri,psr,pcpu,stat,wchan:14,comm -T | grep RR
This checks what threads are real-time currently on the machine. If this succeeds, then there should be a few thread with names starting with
AudioIPC.
Does youtube suffice in this case? I only got this:
$ ps -eo pid,tid,class,rtprio,ni,pri,psr,pcpu,stat,wchan:14,comm -T | grep RR
7419 7430 TS - 0 19 0 0.0 SLl - TRR Background
| Assignee | ||
Comment 12•5 years ago
|
||
Yep it doesn't work for you. I need more info to understand why, if you could answer this:
I'm curious why you're facing this, do you have any special configuration on your machine? Is it a build from a distro? As far as I know, we have only around 20 crashes with this signature, so something is different from all other configurations, if I can find what it is, I might be able to make this work better.
| Reporter | ||
Comment 13•5 years ago
|
||
(In reply to Paul Adenot (:padenot) from comment #12)
Yep it doesn't work for you. I need more info to understand why, if you could answer this:
I'm curious why you're facing this, do you have any special configuration on your machine? Is it a build from a distro? As far as I know, we have only around 20 crashes with this signature, so something is different from all other configurations, if I can find what it is, I might be able to make this work better.
Sorry my bad. It is normal Debian packaging, and nothing special i know of, even though i386 architecture and iso8859-2 locale could be borderline special. Reportbug gives:
Package: firefox
Version: 75.0-2
-- Extensions information
Name: Amazon.com
Location: /usr/lib/firefox/browser/omni.ja
Status: enabled
Name: Ant Video downloader
Location: ${PROFILE_EXTENSIONS}/anttoolbar@ant.com.xpi
Status: user-disabled
Name: Bing
Location: /usr/lib/firefox/browser/omni.ja
Status: enabled
Name: Clearly
Location: ${PROFILE_EXTENSIONS}/readable@evernote.com.xpi
Status: app-disabled
Name: ClixAddon
Location: ${PROFILE_EXTENSIONS}/jid1-wKRSK9TpFpr9Hw@jetpack.xpi
Status: enabled
Name: Dark theme
Location: /usr/lib/firefox/browser/omni.ja
Status: user-disabled
Name: Default theme
Location: /usr/lib/firefox/omni.ja
Status: enabled
Name: DoH Roll-Out
-- Addons package information
-- System Information:
Debian Release: 10.0
APT prefers testing
APT policy: (990, 'testing'), (500, 'unstable-debug'), (500, 'testing-debug'), (500, 'unstable'), (1, 'experimental-debug'), (1, 'experimental')
Architecture: i386 (i686)
Foreign Architectures: amd64
Kernel: Linux 5.5.0-rc5-686-pae (SMP w/2 CPU cores)
Kernel taint flags: TAINT_PROPRIETARY_MODULE, TAINT_OOT_MODULE, TAINT_UNSIGNED_MODULE
Locale: LANG=cs_CZ, LC_CTYPE=cs_CZ (charmap=ISO-8859-2), LANGUAGE=cs_CZ (charmap=ISO-8859-2)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
Versions of packages firefox depends on:
ii debianutils 4.9.1
ii fontconfig 2.13.1-4
ii libatk1.0-0 2.36.0-2
ii libc6 2.30-4
ii libcairo-gobject2 1.16.0-4
ii libcairo2 1.16.0-4
ii libdbus-1-3 1.12.16-2
ii libdbus-glib-1-2 0.110-4
ii libevent-2.1-7 2.1.11-stable-1
ii libffi7 3.3-3
ii libfontconfig1 2.13.1-4
ii libfreetype6 2.10.1-2
ii libgcc-s1 10-20200418-1
ii libgdk-pixbuf2.0-0 2.40.0+dfsg-1
ii libglib2.0-0 2.64.2-1
ii libgtk-3-0 3.24.18-1
ii libnspr4 2:4.25-1
ii libnss3 2:3.51-1
ii libpango-1.0-0 1.44.7-4
ii libstdc++6 10-20200418-1
ii libvpx6 1.8.2-dmo1
ii libx11-6 2:1.6.9-2
ii libx11-xcb1 2:1.6.9-2
ii libxcb-shm0 1.14-2
ii libxcb1 1.14-2
ii libxcomposite1 1:0.4.5-1
ii libxdamage1 1:1.1.5-1
ii libxext6 2:1.3.3-1+b2
ii libxfixes3 1:5.0.3-1
ii libxrender1 1:0.9.10-1
ii libxt6 1:1.1.5-1+b3
ii procps 2:3.3.16-4
ii zlib1g 1:1.2.11.dfsg-2
Versions of packages firefox recommends:
ii libavcodec58 10:4.2.2-dmo8
Versions of packages firefox suggests:
ii fonts-lmodern 2.004.5-5
ii fonts-stix [otf-stix] 1.1.1-3
ii libcanberra0 0.30-7
ii libgssapi-krb5-2 1.17-5
ii libgtk2.0-0 2.24.32-4
pn pulseaudio <none>
-- no debconf information
Comment 14•5 years ago
|
||
| bugherder | ||
https://hg.mozilla.org/mozilla-central/rev/59293945a1e1
https://hg.mozilla.org/mozilla-central/rev/33d5b34d9179
| Reporter | ||
Comment 15•5 years ago
|
||
(In reply to Paul Adenot (:padenot) from comment #12)
Yep it doesn't work for you. I need more info to understand why, if you could answer this:
I'm curious why you're facing this, do you have any special configuration on your machine? Is it a build from a distro? As far as I know, we have only around 20 crashes with this signature, so something is different from all other configurations, if I can find what it is, I might be able to make this work better.
Oh, after thinking about it, I think I can see what is the "special configuration on my machine". Could it be that I don't have pulseaudio installed? Debian still builds packages with alsa.
| Reporter | ||
Comment 16•5 years ago
|
||
And I can see in the Nightly build it doesn't crash anymore.
| Assignee | ||
Comment 17•5 years ago
|
||
(In reply to Jiri Palecek from comment #15)
(In reply to Paul Adenot (:padenot) from comment #12)
Yep it doesn't work for you. I need more info to understand why, if you could answer this:
I'm curious why you're facing this, do you have any special configuration on your machine? Is it a build from a distro? As far as I know, we have only around 20 crashes with this signature, so something is different from all other configurations, if I can find what it is, I might be able to make this work better.
Oh, after thinking about it, I think I can see what is the "special configuration on my machine". Could it be that I don't have pulseaudio installed? Debian still builds packages with alsa.
For sure. You need rtkit for all this to work, usually it's a dependency of pulseaudio (but you don't need to effectively use pulse to get those real-time threads). I believe you can install rtkit without pulseaudio, but I haven't tried.
| Reporter | ||
Comment 18•5 years ago
|
||
(In reply to Paul Adenot (:padenot) from comment #17)
(In reply to Jiri Palecek from comment #15)
(In reply to Paul Adenot (:padenot) from comment #12)
Yep it doesn't work for you. I need more info to understand why, if you could answer this:
I'm curious why you're facing this, do you have any special configuration on your machine? Is it a build from a distro? As far as I know, we have only around 20 crashes with this signature, so something is different from all other configurations, if I can find what it is, I might be able to make this work better.
Oh, after thinking about it, I think I can see what is the "special configuration on my machine". Could it be that I don't have pulseaudio installed? Debian still builds packages with alsa.
For sure. You need
rtkitfor all this to work, usually it's a dependency of pulseaudio (but you don't need to effectively use pulse to get those real-time threads). I believe you can installrtkitwithout pulseaudio, but I haven't tried.
I tried installing rtkit and now I indeed see the real time thread AudioIPC. However FF 75 still crashes regardless (with the same signature).
| Assignee | ||
Comment 19•5 years ago
|
||
(In reply to Jiri Palecek from comment #18)
I tried installing
rtkitand now I indeed see the real time thread AudioIPC. However FF 75 still crashes regardless (with the same signature).
As a workaround until the patch done in this bug is in a stable version, I believe you can go to about:config, type media.audiograph.single_thread.enabled, and flip that to false (it should be to true by default). This prevents another object called AudioWorklet to work, but AudioWorklet is only enabled in 76.
Description
•