If some application accesses the sound card though one of the lower audio layers (see [[audio layers overview]]), the sound card might become inaccessible and other applications might fail to open the sound card, or even hang. ===== Finding out which application is holding your sound card ===== ==== OSS ==== You can see which applications are using OSS (or the ALSA OSS Emulation layer) with: $ sudo fuser /dev/dsp* ==== ALSA ==== You can see which applications are using ALSA with: $ sudo fuser /dev/snd/pcm* ===== Resolving the problem ===== ==== Stopping the application holding the card ==== In most cases you can simply close or kill the application that is using your sound card. === PulseAudio === If [[apps:all:PulseAudio]] is holding your sound card, you can stop it with 'pulseaudio -k'. === TiMiDity++ === Some distributions start [[apps:all:timidity]] on startup. It can generally be stopped with 'sudo /etc/init.d/timidity stop' ==== Using Dmix ==== [[apps:all:ALSA]] has a [[http://alsa.opensrc.org/DmixPlugin|Dmix plugin]] that allows multiple applications to use the sound card. Using [[http://alsa.opensrc.org/DmixPlugin|Dmix]] is not recommended for audio work, as it might increase latencies and reduce quality because of resampling. ==== Using a sound server ==== For audio work, use [[apps:all:JACK]]. For desktop audio, you might want to consider [[apps:all:PulseAudio]] or use the [[http://alsa.opensrc.org/DmixPlugin|Dmix plugin]] mentioned above.