USB sound card - Behringer UFO202 Audacity underrun occurred

When doing playback in Audacity 2.0.6 on Debian Jessie 8 with Behringer UFO202 and then stopping the playback I encountered the following error, causing the application to crash:

ALSA lib pcm.c:7843:(snd_pcm_recover) underrun occurred

The solutions are plenty.

If you have more than one sound card, you may open the sound card properties and try to switch sound card. This may unfreeze.

You may start Audacity with an environment variable:
PULSE_LATENCY_MSEC=30 audacity &

Or you can edit /etc/pulse/daemon.conf and make sure these lines are there:

default-fragments = 5
default-fragment-size-msec = 2

From what I've understood this will only affect playback and not recording.

Edit the file as root, but restart pulseaudio as the user you run Audacity with:
pulseaudio -k
pulseaudio -D

This is a personal note. Last updated: 2015-11-02 15:11:19.







Don't forget to pay my friend a visit too. Joakim