pulseaudio fails to start with error: pa_mutex_unlock: Assertion `pthread_mutex_unlock(&m->mutex) == 0' failed.

Bug #165220 reported by Marques Johansson on 2007-11-26
18
This bug affects 2 people
Affects Status Importance Assigned to Milestone
pulseaudio (Ubuntu)
Low
Unassigned

Bug Description

Binary package hint: pulseaudio
Version: 0.9.7-3ubuntu2 (Hardy)

mjohansson@bang:/tmp$ sudo /etc/init.d/pulseaudio stop
 * Stopping PulseAudio Daemon No process in pidfile `/var/run/pulse/pid' found running; none killed.
... pulseaudio is not running [ OK ]
mjohansson@bang:/tmp$ sudo /etc/init.d/pulseaudio start
 * Starting PulseAudio Daemon pulseaudio: pulsecore/mutex-posix.c:98: pa_mutex_unlock: Assertion `pthread_mutex_unlock(&m->mutex) == 0' failed.
/etc/init.d/pulseaudio: line 28: 7531 Aborted (core dumped) start-stop-daemon -x $DAEMON -p $PIDFILE --start -- --system --daemonize --high-priority --log-target=syslog --disallow-module-loading=$DISALLOW_MODULE_LOADING

mjohansson@bang:/tmp$ sudo gdb /usr/bin/pulseaudio
GNU gdb 6.6-debian
Copyright (C) 2006 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details.
This GDB was configured as "i486-linux-gnu"...
Using host libthread_db library "/lib/tls/i686/cmov/libthread_db.so.1".
(gdb) run
Starting program: /usr/bin/pulseaudio
[Thread debugging using libthread_db enabled]
[New Thread -1208477472 (LWP 7562)]
[New process 7562]
pulseaudio: pulsecore/mutex-posix.c:98: pa_mutex_unlock: Assertion `pthread_mutex_unlock(&m->mutex) == 0' failed.
[New process 7562]

Program received signal SIGABRT, Aborted.
0xffffe410 in __kernel_vsyscall ()
(gdb) bt
#0 0xffffe410 in __kernel_vsyscall ()
#1 0x4647b875 in raise () from /lib/tls/i686/cmov/libc.so.6
#2 0x4647d355 in abort () from /lib/tls/i686/cmov/libc.so.6
#3 0x46474b6e in __assert_fail () from /lib/tls/i686/cmov/libc.so.6
#4 0x497b2e9f in pa_mutex_unlock () from /usr/lib/libpulsecore.so.4
#5 0x0804dd03 in libtool_unlock () at daemon/ltdl-bind-now.c:63
#6 0x469495f6 in lt_dlmutex_register () from /usr/lib/libltdl.so.3
#7 0x0804dab8 in pa_ltdl_init () at daemon/ltdl-bind-now.c:142
#8 0x0804deb6 in main (argc=1, argv=0x804dd10) at daemon/main.c:386
(gdb)

description: updated
Daniel T Chen (crimsun) wrote :

Is your install pure Hardy, or are you using the pulseaudio bits from Hardy while retaining a Feisty system?

Changed in pulseaudio:
importance: Undecided → Low
status: New → Incomplete

It has updated from Dapper to Edgy to Feisty to Gutsy to Hardy. This
is a full Hardy installation, as it has been dist-upgrade'd each step
of the way. I began using polyp early on, but pulseaudio has been
working for a while (a year maybe more) now and was working a few
weeks ago.

I couldn't say exactly when this problem started happening.
--
Marques Johansson
<email address hidden>

If someone edits my signature out of that last comment and removes this one I'll promise not to include it in future emailed bug replies. Spam Spam Spam...

Daniel T Chen (crimsun) wrote :

The above symptom smells pungently of a libtool error. Please attempt to reproduce the issue in Hardy Alpha 1.

I downloaded the 1.5.24 libtool packages after I noticed that "apt-get --reinstall " wasn't able to download the packages itself. Surprise, surprise, 1.6-0+1.5a-4 isn't in the repository.

mjohansson@bang:/var/cache/apt/archives$ sudo dpkg -i --force-downgrade libtool_1.5.24-1ubuntu1_i386.deb libltdl3_1.5.24-1ubuntu1_i386.deb
dpkg - warning: downgrading libtool from 1.6-0+1.5a-4 to 1.5.24-1ubuntu1.
(Reading database ... 407800 files and directories currently installed.)
Preparing to replace libtool 1.6-0+1.5a-4 (using libtool_1.5.24-1ubuntu1_i386.deb) ...
Unpacking replacement libtool ...
dpkg - warning: downgrading libltdl3 from 1.6-0+1.5a-4 to 1.5.24-1ubuntu1.
Preparing to replace libltdl3 1.6-0+1.5a-4 (using libltdl3_1.5.24-1ubuntu1_i386.deb) ...
Unpacking replacement libltdl3 ...
Setting up libtool (1.5.24-1ubuntu1) ...
Setting up libltdl3 (1.5.24-1ubuntu1) ...

Processing triggers for libc6 ...
ldconfig deferred processing now taking place

mjohansson@bang:/var/cache/apt/archives$ /etc/init.d/pulseaudio restart
 * Stopping PulseAudio Daemon No process in pidfile `/var/run/pulse/pid' found running; none killed.
... pulseaudio is not running [ OK ]
 * Starting PulseAudio Daemon

Marques Johansson (marques) wrote :

Actually - you can see that the [ OK ] did not follow the "Starting PulseAudio Daemon" there.

The package won't configure because the daemon won't start. I try to start it the way /etc/init.d/pulseaudio does and I get this:

mjohansson@bang:/tmp$ sudo /usr/bin/pulseaudio --system --high-priority --log-target=syslog --disallow-module-loading=0
No protocol specified

I can only assume that message is coming from the esound module. Other than the module-esound-protocol-unix line, I can't find any configuration options to set the protocol.

Marques Johansson (marques) wrote :

Removing pulseaudio-esound-compat-dbg ...
Removing pulseaudio-esound-compat ...

... I've removed these packages and it still won't run, even after remarking out "load-module module-esound-protocol-unix" in /etc/pulse/default.pa (which the remove action probably should have done for me).

The pulseaudio package's configure action still won't complete.

Daniel T Chen (crimsun) wrote :

Likely it came from Debian experimental. (See http://packages.qa.debian.org/libt/libtool/news/20040414T181703Z.html) This confirms my suspicion; it's the first symptom in the KnownIssues section on the PulseAudio wiki.

I recommend you /purge/ (not just remove) all the pulseaudio-related binary packages (pulseaudio's the important one here, though libpulse* have conffiles, too), then use aptitude to reinstall pulseaudio-esound-compat and pulseaudio-module-gconf (which will pull in the necessary dependencies). Then, configure PA per-user, e.g., make sure that:

1) you have enabled software sound mixing in GNOME's System> Preferences> Sound tab;
2) you have selected pulseaudio as the default audio sink (and possibly default audio source if that suits you) using `gstreamer-properties`

Marques Johansson (marques) wrote :

I purged .*pulse.* and reinstalled pulse via aptitude. All is well now.

I did notice that PULSEAUDIO_SYSTEM_START in /etc/default/pulse is now disabled. My problems may have partially been due to that being enabled, since pulse seemed to start up fine in user mode.

The packages is configured and it works in user mode - which is enough.

Daniel T Chen (crimsun) wrote :

Thanks - closing due to noted libtool issue.

Changed in pulseaudio:
status: Incomplete → Invalid
Marques Johansson (marques) wrote :

On another Hardy system of mine that does not have the libtool issue, the package failed to configure until I changed the PULSEAUDIO_SYSTEM_START setting to 0 in /etc/default/pulseaudio. I don't know if this is a setting I manually changed or if it was once defaulted to 1.

Setting up pulseaudio (0.9.7-3ubuntu2) ...
 * Starting PulseAudio Daemon invoke-rc.d: initscript pulseaudio, action "start" failed.
dpkg: error processing pulseaudio (--configure):
 subprocess post-installation script returned error exit status 1

*edit /etc/default/pulseaudio*
displague@bound:~$ sudo dpkg --configure -a
Setting up pulseaudio (0.9.7-3ubuntu2) ...

Oli (oli) wrote :

> I purged .*pulse.* and reinstalled pulse via aptitude. All is well now.

Sorry for bumping this Marques, but how exactly did you do that? I've been trying it but it keeps trying to take ubuntu-desktop along with it.

I'm not sure the dependencies were the same at the time, but in the case you
describe I would apt-get remove .*pulse.*, ctrl+c, and copy the list of
packages to a 'dpkg --purge <package list>' command line (may need to add
--force-depends). Then 'aptitude install <paste package list>'.

PromoGest (m3nt0r3) wrote :

hardy on 64bit kubuntu
amarok
Amarok: [Loader] Starting amarokapp..
Amarok: [Loader] Don't run gdb, valgrind, etc. against this binary! Use amarokapp.
kdecore (KAction): WARNING: KAction::insertKAccel( kaccel = 0x7886c0 ): KAccel object already contains an action name "play_pause"
QLayout "unnamed" added to QVBox "unnamed", which already has a layout
kdecore (KAction): WARNING: KAction::insertKAccel( kaccel = 0x7886c0 ): KAccel object already contains an action name "play_pause"
QLayout: Adding KToolBar/mainToolBar (child of QVBox/unnamed) to layout for PlaylistWindow/PlaylistWindow
QObject::connect: Incompatible sender/receiver arguments
        StarManager::ratingsColorsChanged() --> ContextBrowser::ratingOrScoreOrLabelsChanged(const QString&)
vete@panGea:~/Desktop$ amarokapp: pulsecore/mutex-posix.c:98: pa_mutex_unlock: Asserzione 'pthread_mutex_unlock(&m->mutex) == 0' fallilita.

same thing with kaffeine or other application that use audio ...

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers