Patch to alsa-plugins causes regression in java applet (webex)

Bug #805940 reported by Tom Ellis
68
This bug affects 11 people
Affects Status Importance Assigned to Milestone
Baltix
New
Undecided
Unassigned
alsa-plugins (Ubuntu)
Fix Released
Undecided
David Henningsson
Lucid
Won't Fix
Undecided
Unassigned
Oneiric
Fix Released
Undecided
Unassigned
Precise
Won't Fix
Undecided
Unassigned
pulseaudio (Ubuntu)
Fix Released
Undecided
David Henningsson
Lucid
Won't Fix
Undecided
Unassigned
Oneiric
Won't Fix
Undecided
Unassigned
Precise
Won't Fix
Undecided
Unassigned

Bug Description

# Issue

* Patch to alsa-plugins causes regression in java applet (webex)

## Environment

Ubuntu 10.04.2 LTS x86
sun-java6-plugin-6.24-1build0.10.04.1
linux-backports-modules-alsa-2.6.32-32-generic
libasound2-plugins-1.0.22-0ubuntu6
pulseaudio 1:0.9.22~0.9.21+stable-queue-32-g8478-0ubuntu14

Dell Latitude 2120

## Resolution

* (workaround) Disable pulseaudio and use alsa directly
or
* Revert patch debian/patches/lp464008lp503174.patch which ignores underruns

## Diagnostic Steps

1. Connect to a webex meeting
2. Speak to a user, confirm mic and audio is working correctly
3. Shout loudly/tap microphone and watch java app adjust mic volume
4. Observe that with headphones you can no longer hear the other user
5. Use package that reverts patch from http://people.canonical.com/~trellis/alsa/libasound2-plugins_1.0.22-0ubuntu6~tellis01_i386.deb
6. Repeat and notice all works well

## Other information

Ran pulseaudio debug logs for both good and bad packages and attaching to bug. Note you can see when the java plugin changes
the volume and after this point it stops putting audio through headphones/speakers.

Tags: pse
Revision history for this message
Tom Ellis (tellis) wrote :
Revision history for this message
Tom Ellis (tellis) wrote :
description: updated
Revision history for this message
Tom Ellis (tellis) wrote :
Revision history for this message
David Henningsson (diwic) wrote :

We can't simply revert the patch as that would cause issues in other applications. I think we need to extend PulseAudio's protocol to include information about when the underrun happened in order to determine whether the underrun should be ignored or not.

description: updated
Changed in alsa-plugins (Ubuntu):
status: New → Triaged
Revision history for this message
Tom Ellis (tellis) wrote :

OK, will you work on a patch that helps this with upstream?

Revision history for this message
Tom Ellis (tellis) wrote :

Hi David, I see bug #503174 has a fix for underruns too, I'm going to test this with webex.

Changed in alsa-plugins (Ubuntu):
assignee: nobody → David Henningsson (diwic)
Changed in pulseaudio (Ubuntu):
assignee: nobody → David Henningsson (diwic)
Changed in pulseaudio (Ubuntu):
status: New → In Progress
Revision history for this message
Tom Ellis (tellis) wrote :

Fix from #503174 had no affect. Reverting lp464008lp503174.patch still works.

Revision history for this message
David Henningsson (diwic) wrote :
Revision history for this message
Tom Ellis (tellis) wrote :

Thanks David, do you have any packages with these patches so I can test them on the Latitude 2120?
I can knock one together if the answer is no :)

Revision history for this message
David Henningsson (diwic) wrote :

Well, the PulseAudio patch is included in the next version of PulseAudio, which we are currently considering for Oneiric (see https://lists.launchpad.net/ubuntu-audio-dev/msg00212.html ), and the alsa-plugins patch is broken, but I'll attach a fixed version now. Note that the alsa-plugins patch would need the new PulseAudio to compile.

Revision history for this message
David Henningsson (diwic) wrote :
Changed in pulseaudio (Ubuntu):
status: In Progress → Fix Committed
Revision history for this message
Slava Goltser (slavikg) wrote :

Since Oneiric is a good 2 months away, is there any chance of the "fixed" alsa-plugins being backported to Natty?

Revision history for this message
David Henningsson (diwic) wrote :

@Slava, given the changes to the PulseAudio protocol that are preconditions to this additional protocol update, backporting this into Natty seems highly unlikely. Sorry.

Changed in pulseaudio (Ubuntu):
status: Fix Committed → Fix Released
Changed in alsa-plugins (Ubuntu):
status: Triaged → In Progress
Changed in alsa-plugins (Ubuntu):
status: In Progress → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package alsa-plugins - 1.0.24-0ubuntu6

---------------
alsa-plugins (1.0.24-0ubuntu6) oneiric; urgency=low

  * Use the new PulseAudio API for better underrun handling (LP: #805940)
 -- David Henningsson <email address hidden> Wed, 24 Aug 2011 10:16:12 +0200

Changed in alsa-plugins (Ubuntu):
status: Fix Committed → Fix Released
Revision history for this message
Tom Ellis (tellis) wrote :

is there anything that can be done to sort this for lucid? other than using a custom package?

Revision history for this message
David Henningsson (diwic) wrote :

@Tellis: Doing an SRU to change the behavior is not an option because that will regress other applications, and the better solution released in Oneiric requires the new PulseAudio API (which is not backportable to Lucid).

However, there might actually be ways to configure this behavior, but I don't know if such a configuration change would be easier to roll out than a custom package. I'm lacking knowledge of what is possible and not possible in your environment, so it's hard for me to know what to suggest.

So...maybe fixing webex not to abuse the API? :-)

Revision history for this message
Tom Ellis (tellis) wrote :

Thanks David, I don't think getting webex to change anything is possible.

It seems to me like the best approach is to run the slightly modified alsa-plugin package with the one patched removed and lock the package.

Revision history for this message
Mantas Kriaučiūnas (mantas) wrote :

It seems this bug also causes problems with WINE Windows compatibility layer, see http://wiki.winehq.org/Sound

Revision history for this message
Chris J Arges (arges) wrote :

This problem is still seen in 32-bit Precise. I've captured a log of pulseaudio of the failure. We are getting the same buffer Underrun.
I'm able to reproduce using webex using sun java 1.6.

Revision history for this message
Sean DS (se4n-1) wrote :

Unfortunately I still have this bug in 64 bit Precise.

Revision history for this message
Billy_bonk621 (billy-bonk621) wrote :

I confirm the instance of the bug under Ubuntu 12.04, wine 1.4.1
Using Civilization 4, Rise of Mankind - A New Dawn Mod

Sound will just drop out, or will play a 2x speed occasionally.

Most of play it remains fine, but will happen eventually.

Revision history for this message
Billy_bonk621 (billy-bonk621) wrote :

*Edit* Ubuntu 12.04 64 bit
Wine 1.4.1
Civilization IV, Beyond the Sword, Rise of Mankind - A New Dawn mod

Revision history for this message
Chris J Arges (arges) wrote :

I've done some additional testing recently using the above setup, and three versions of Ubuntu with and without Pulseaudio.

Java Version

Oracle JRE 7 (1.7.0_05) PulseAudio Enabled 12.04 i386 Fail [1]: 2
Oracle JRE 7 (1.7.0_05) PulseAudio Disabled 12.04 i386 Works: 6

Sun JRE (1.6.0_31) PulseAudio Enabled 11.10 i386 Works: 3
Sun JRE (1.6.0_31) PulseAudio Disabled 11.10 i386 Works: 2
Oracle JRE 7 (1.7.0_05) PulseAudio Enabled 11.10 i386 Works: 2
Oracle JRE 7 (1.7.0_05) PulseAudio Disabled 11.10 i386 Works:1

Sun JRE (1.6.0_31) PulseAudio Enabled 10.04 i386 Fail [1]: 1
Sun JRE (1.6.0_31) PulseAudio Disabled 10.04 i386 Works: 1

Changed in alsa-plugins (Ubuntu Lucid):
status: New → Confirmed
Changed in alsa-plugins (Ubuntu Oneiric):
status: New → Fix Released
Changed in alsa-plugins (Ubuntu Precise):
status: New → Confirmed
Revision history for this message
Chris J Arges (arges) wrote :

I hit the return key before completing my last comment accidentally.

The table shows the java version, if pulse audio is enabled, which version of Ubuntu, and if it failed or worked.
In summary, if pulse audio is disabled it works in all versions of Ubuntu (Lucid, Oneiric, Precise)
If Pulse audio is enabled, it only works in Oneiric and not in Precise nor Lucid.

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

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in pulseaudio (Ubuntu Lucid):
status: New → Confirmed
Changed in pulseaudio (Ubuntu Oneiric):
status: New → Confirmed
Changed in pulseaudio (Ubuntu Precise):
status: New → Confirmed
Revision history for this message
Roman Shipovskij (roman-shipovskij) wrote :

After many tests, the problem was solved by editing /etc/pulse/default.pa and replacing string:
load-module module-udev-detect
by
load-module module-udev-detect tsched=0

seurce: https://wiki.archlinux.org/index.php/PulseAudio#Glitches.2C_skips_or_crackling

Revision history for this message
Rolf Leggewie (r0lf) wrote :

oneiric has seen the end of its life and is no longer receiving any updates. Marking the oneiric task for this ticket as "Won't Fix".

Changed in pulseaudio (Ubuntu Oneiric):
status: Confirmed → Won't Fix
Revision history for this message
Rolf Leggewie (r0lf) wrote :

lucid has seen the end of its life and is no longer receiving any updates. Marking the lucid task for this ticket as "Won't Fix".

Changed in alsa-plugins (Ubuntu Lucid):
status: Confirmed → Won't Fix
Changed in pulseaudio (Ubuntu Lucid):
status: Confirmed → Won't Fix
Revision history for this message
Steve Langasek (vorlon) wrote :

The Precise Pangolin has reached end of life, so this bug will not be fixed for that release

Changed in alsa-plugins (Ubuntu Precise):
status: Confirmed → Won't Fix
Changed in pulseaudio (Ubuntu Precise):
status: Confirmed → Won't Fix
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.