How To: Completely remove PulseAudio & replace it with ALSA

Archived topics about LMDE 1 and LMDE 2
mads

How To: Completely remove PulseAudio & replace it with ALSA

Post by mads »

The following How To was originally posted on the thread: Is Pulse Audio the worst tragedy in the history of Linux?

Please note:
This guide was written at the time of Gnome 2, and before the release of Gnome 3, MATE and Cinnamon.
- There is no reason to remove PulseAudio unless you are having some issues with it.
- This how to is only for LMDE users (tested with both 32 bit and 64 bit versions).
- Mint 10 users: Please refer to this guide. (The issue with volume control applet is resolved now.)


Completely remove PulseAudio & replace it with ALSA (LMDE):

A. Menu > Preferences > Startup Applications > uncheck "PulseAudio Sound System", PulseAudio Sound System KDE Routing Policy" and "Volume Control"
B. Menu > Administration > Services > uncheck "pulseaudio"
C. Remove pulseaudio, related packages and configuration files

Code: Select all

killall pulseaudio
sudo killall pulseaudio
sudo apt-get purge pulseaudio pulseaudio-utils gstreamer0.10-pulseaudio libpulse-browse0 paman pavumeter pavucontrol
sudo mv /etc/asound.conf /etc/asound.conf-bak
rm ~/.pulse-cookie
rm -r ~/.pulse
D. Install libalsaplayer0 package

Code: Select all

sudo apt-get install libalsaplayer0
E. Restart your computer
F. Right click Panel, select "Add to Panel" and add "Volume Control" to Panel


Here are some reasons why you might want to remove PulseAudio:
...this fix has made all of my sound issues disappear. Even running World of Warcraft in wine has less sound issues now for me.
...It solved the audio lag I had in veetle. Pulse gives fits for a lot of people.
...I removed pulseaudio and got rid of three annoying problems:
1) sound settings reset at boot even having alsactl restore at startup applications
2) mic working randomly
3) first call in Skype was always garbled
...Just what I needed to know. Got pSX working properly now.
Suggestions are welcome!
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 15 times in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
kwevej

Re: How To: Completely remove PulseAudio & replace it with A

Post by kwevej »

is esound really needed?
I purged PA a while ago, running without esound ... doesn't experience any problems.
mads

Re: How To: Completely remove PulseAudio & replace it with A

Post by mads »

kwevej wrote:is esound really needed?
Yes, it is needed to mix several streams for playback by a single device, and to redirect sound to remote servers.
kwevej

Re: How To: Completely remove PulseAudio & replace it with A

Post by kwevej »

mads wrote:
kwevej wrote:is esound really needed?
Yes, it is needed to mix several streams for playback by a single device, and to redirect sound to remote servers.
Then I don't need it ;)
thx for reply

EDIT: "mix several streams for playback by a single device" works with ALSA alone as well (because of dmix)
Last edited by kwevej on Thu Mar 10, 2011 2:42 am, edited 1 time in total.
mneumonic

Re: How To: Completely remove PulseAudio & replace it with A

Post by mneumonic »

This guide is great. After doing this everything works great, except when i right click my panel and add to panel, there is no volume control listed. In fact the only way i have found to control sound levels is to install gnome alsa mixer, but it would be more convenient to get a volume control on the panel again.

any ideas?
mads

Re: How To: Completely remove PulseAudio & replace it with A

Post by mads »

mneumonic wrote:This guide is great. After doing this everything works great, except when i right click my panel and add to panel, there is no volume control listed. In fact the only way i have found to control sound levels is to install gnome alsa mixer, but it would be more convenient to get a volume control on the panel again.

any ideas?
@ update: The issue with volume control applet is resolved now. Please refer to this guide.


I have no idea why you don't have it. Please see screenshot attached.

However, you could try:
Right click Panel > Add to Panel > Custom Application Launcher
Type: Application
Name: Volume Control
Command: gnome-volume-control
Comment: Adjust the sound volume
Last edited by mads on Sun Apr 17, 2011 5:38 am, edited 1 time in total.
damien.caci

Re: How To: Completely remove PulseAudio & replace it with A

Post by damien.caci »

Hi, i have the same problem as mneumonic. I have tried the custom application volume control but all that does is bring up a prompt saying "waiting for sound system to respond." Any help would be greatly apprecieted, as i am not sure if mneumonic has fixed his problem as well.

damien.caci
apexx

Re: How To: Completely remove PulseAudio & replace it with A

Post by apexx »

This guide solved my sound problems. gnome-volume-control doesn't work anymore but that really isn't a problem. I just added gnome-alsamixer to the panel. Using it to change volume doesn't require more clicks :wink:

Code: Select all

$ gnome-volume-control

** (gnome-volume-control:2736): WARNING **: Connection failed, reconnecting...

** (gnome-volume-control:2736): WARNING **: Failed to connect context: Connection refused
stormadvisor

Re: How To: Completely remove PulseAudio & replace it with A

Post by stormadvisor »

apexx wrote:This guide solved my sound problems. gnome-volume-control doesn't work anymore but that really isn't a problem. I just added gnome-alsamixer to the panel. Using it to change volume doesn't require more clicks :wink:

Code: Select all

$ gnome-volume-control

** (gnome-volume-control:2736): WARNING **: Connection failed, reconnecting...

** (gnome-volume-control:2736): WARNING **: Failed to connect context: Connection refused

I get the same thing but my Warning is for gnome-volume-control:4192
mads

Re: How To: Completely remove PulseAudio & replace it with A

Post by mads »

stormadvisor wrote:
apexx wrote:This guide solved my sound problems. gnome-volume-control doesn't work anymore but that really isn't a problem. I just added gnome-alsamixer to the panel. Using it to change volume doesn't require more clicks :wink:

Code: Select all

$ gnome-volume-control

** (gnome-volume-control:2736): WARNING **: Connection failed, reconnecting...

** (gnome-volume-control:2736): WARNING **: Failed to connect context: Connection refused
I get the same thing but my Warning is for gnome-volume-control:4192
@ Edit: I assume you are using a non-LMDE version. Please have a look at the new how-to here.

It seems that this is a bug (#556948 gnome-volume-control-applet: Connection failed). See: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=556948.

Workaround: https://launchpad.net/~dtl131/+archive/ppa
Last edited by mads on Mon Apr 18, 2011 4:21 pm, edited 1 time in total.
runbei

Re: How To: Completely remove PulseAudio & replace it with A

Post by runbei »

This worked for me. For others with similar problems - I have a home-built PC with a Biostar 790GX A2+ motherboard that has the following audio device: ATI Technologies Inc SBx00 Azalia (Intel HDA).

With speaker and headset connected to the rear panel, and speaker connect to a front outlet, I was unable to get the microphone working before completely removing PulseAudio as directed. After reboot, the mic worked fine but I didn't have sound - yikes, I forgot the last two commands in the code: sudo rm -rf /etc/asound.conf and sudo rm ~/.pulse-cookie. After running those and rebooting, everything is working. I'm very grateful, as I use Skype Online service for my main phone.
lazerbeat

Re: How To: Completely remove PulseAudio & replace it with A

Post by lazerbeat »

I would really love to get PulseAudio off my system but I an having a couple of problem. I have tried this how to a couple of times and after rebooting I have no sound at all. The only step I can't follow is this one
B. Menu - Services Settings - uncheck "pulseaudio"
I can't find "service settings" under my menu anywhere. Also I would assume after removing pulse and it's dependencies I would need to add ALSA to the start up?

Any help would be most appreciated here.
mads

Re: How To: Completely remove PulseAudio & replace it with A

Post by mads »

lazerbeat wrote:I would really love to get PulseAudio off my system but I an having a couple of problem. I have tried this how to a couple of times and after rebooting I have no sound at all. The only step I can't follow is this one
B. Menu - Services Settings - uncheck "pulseaudio"
I can't find "service settings" under my menu anywhere. Also I would assume after removing pulse and it's dependencies I would need to add ALSA to the start up?
Any help would be most appreciated here.
@ EDit:
lazerbeat, you are right about not finding "Services". This "How To" is for Mint Debian Edition.
I have posted a new one for Mint 10 users: How To: Remove PulseAudio & replace it with ALSA (Mint 10)
Last edited by mads on Sun Apr 17, 2011 5:54 am, edited 1 time in total.
Lendo

Re: How To: Completely remove PulseAudio & replace it with A

Post by Lendo »

After so much trial and error, this fix was so simple. Thanks, but now I gotta talk to my family again. The unintended consequences LOL :shock:
sespela

Re: How To: Completely remove PulseAudio & replace it with A

Post by sespela »

Thank you so much for a great tutorial!
I use LMDE on my Acer Aspire One ZG5. I had problems using the mic on Skype, and after searching the interwebs and trying different "solutions" and going through different tutorials I posted a request for other ideas or solutions from people using Acer Aspire one. I recieved a link to this tutorial, and after doing as described, and doing some small adjustments in on ALSA it worked out just perfectly. What I did was disable "Allow Skype to automatically adjust your audio settings", then I went into the ALSA settings, disabled mute on internal mic, then I unhooked the "chain" below the mic adjuster and volum adjuster and turned the volum a bit down, and the mic levels not just below max. Now it all works as intended.
Hope my describsion makes sense as English is not my first language.

But thanks once a great for this tutorial!:)
kc6ufm
Level 1
Level 1
Posts: 28
Joined: Tue Dec 07, 2010 12:17 am

Re: How To: Completely remove PulseAudio & replace it with A

Post by kc6ufm »

Even to a totally unfamiliar type like me, pulseaudio is clearly the worst junk I have ever seen.

I followed the great tutorial, and pulseaudio is now a thing of the past. Many thanks!

But I still have one problem...

I am a Ham Radio operator, and I want to use gmFSK for digital radio. The application expects to find and control the soundcard via /dev/dsp, but this file is missing.

Any ideas?

Thanks!
mads

Re: How To: Completely remove PulseAudio & replace it with A

Post by mads »

kc6ufm wrote:But I still have one problem...
I am a Ham Radio operator, and I want to use gmFSK for digital radio. The application expects to find and control the soundcard via /dev/dsp, but this file is missing.
Any ideas?
Hi, I am not sure about this, but the following procedure is harmless, so you could try it. First run in Terminal:

Code: Select all

ls /dev | grep dsp
(The output in my system shows: adsp dsp)

Then, install "alsa-oss" package. In Terminal:

Code: Select all

sudo apt-get update && sudo apt-get install alsa-oss
Why this package? Synaptic says this about alsa-oss:

Code: Select all

This package contains a program loader, aoss, which wraps applications written for OSS in a compatibility library, thus allowing them to work with ALSA.

There are two ways of getting an application to work with ALSA if the application was written for OSS. The first way is to load the special ALSA drivers that emulate the OSS kernel interface; these allow the application to open /dev/dsp0 and other OSS device files. The second way is to wrap the application in the libaoss library provided in this package; the wrapper causes the application to access native ALSA device files such as /dev/snd/pcmC0D0c instead of OSS device files.

Use of the alsa-oss library is recommended over the use of OSS-emulation drivers if you want to use ALSA's PCM plugin layer.
See what happens, but if you still have problem, I advice to open a new thread (to get the attention and help of more experienced users).
kc6ufm
Level 1
Level 1
Posts: 28
Joined: Tue Dec 07, 2010 12:17 am

Re: How To: Completely remove PulseAudio & replace it with A

Post by kc6ufm »

Thanks for the info, but as far as I could see, nothing changed.

I'll start a new topic for this issue since, as you say, it is highly specific.

Now, on a more general note...

When I start the gnome ALSA Mixer, I get an error:

---
An error occurred while loading or saving configuration information for GNOME ALSA Mixer. Some of your configuration settings may not work properly.

Bad key or directory name: "/apps/gnome-alsamixer/display_mixers/": Key/directory may not end with a slash '/'
Bad key or directory name: "/apps/gnome-alsamixer/display_names/": Key/directory may not end with a slash '/'
---

Things seem to work, but I can't really say.

Thanks again!
mads

Re: How To: Completely remove PulseAudio & replace it with A

Post by mads »

kc6ufm wrote:When I start the gnome ALSA Mixer, I get an error ... Some of your configuration settings may not work properly...
As far as I can see, GNOME ALSA Mixer is not mentioned at all in this tutorial!

However, I searched and it seems that it is a bug totally unrelated to this tutorial.

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=403693
https://bugs.launchpad.net/ubuntu/+sour ... bug/184768
https://bugs.launchpad.net/ubuntu/+sour ... bug/461003
https://bugs.launchpad.net/ubuntu/+sour ... bug/106903
https://bugzilla.gnome.org/show_bug.cgi?id=429012

Users on this thread are discussing the same, and some of them report that turning the "Digital Audio Jack" has helped.

Starting a new thread about both issues is a good idea. Many experienced users out there, but it is unlikely that they
see your questions here. :)
sespela

Re: How To: Completely remove PulseAudio & replace it with A

Post by sespela »

Hey, I just used this tutorial to help a friend of mine which I have converted to LM.
She is very happy now, because Skype is working perfectly once more. So thank you very much for this great tutorial.

But there's one problem though, where did the volume control go? I've read through this page and seen that this seems to be an issue. So I'm just wondering, is there any updates on this issue? Have anybody found a way to get a working volum control?
I tried creating a custom icon as desribed in one of the replies, but sadly that didn't work.


FYI: All worked out perfectly on my LMDE, no problems what so ever!:D
Locked

Return to “LMDE Archive”