Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a computer that runs Mythbuntu 12.04. It has an external USB Kenwood Digital Audio device.

When I open up pavucontrol, I get this message:

pulse error

If I do as the message suggests and run start-pulseaudio-x11, I get this output:

$ start-pulseaudio-x11
Connection failure: Connection refused
pa_context_connect() failed: Connection refused

Error log file, created with these intructions, on Pastebin.

How do I correct this error?

share|improve this question
what happens when you ask 'pulseaudio --check' – DrSAR Oct 24 '11 at 17:51
@DrSAR: I get absolutely no response from that command. It immediately returns to the prompt. – Questioner Oct 27 '11 at 12:06
As the dialog suggests, what happens when you execute start-pulseaudio-x11? – William Nov 16 '11 at 3:33
@William: I added the results when executing start-pulseaudio-x11 to the question. – Questioner Nov 16 '11 at 9:03
ps auxw|grep pulse output? – Bruno Pereira Nov 16 '11 at 14:27
up vote 12 down vote accepted

The solution to this problem was discovered in the course of solving my other problem, with Pulseaudio and Flash.

First I needed to completely purge and reinstall Pulseaudio. One way to do this is to run the command:

sudo apt-get --purge --reinstall install pulseaudio

Then, after I had a clean start, I discovered there was this odd entry in /etc/pulse/client.conf. It had a line that said:

autospawn = now

It seems that now is not a valid option. I have no idea where that option was coming from, as I thought I was starting fresh after reinstalling.

I changed it to yes, and then commented it out as well anyway.

; autospawn = yes

Rebooted, and then I was able open pavucontrol without errors.

The lesson I took from this is that purging an application might not be as complete as one would assume it to be.

share|improve this answer

I'm assuming you've tried deleting ~/.pulse/* and restarting the sound server?

Your second option is to check /etc/pulse/client.conf in /etc/pulse, as suggested in the warning. Make sure everything is set to its default value by commenting out every line with a leading semicolon.

Finally, it could be related to this bug. The work-around here was to start pulseaudio in system mode, by changing the value of PULSEAUDIO_SYSTEM_START in /etc/default/pulseaudio to 1. This will prevent pulseaudio from loading '' in your /etc/pulse folder. If this fixes your problem and you are on a multi-user system so don't want to continue running pulse in system mode, then edit your post with the contents of Otherwise, just leave it fixed. I don't really see the problem with running it in system mode on a single-user system.

share|improve this answer
Thanks for responding. I've deleted ~/.pulse/* and restarted the sound server. I set PULSEAUDIO_SYSTEM_START to 1. I've set everything in etc/pulse/client.conf to be the default value. I've rebooted after every change to ensure they took hold. Unfortunately, none of them have fixed the problem. – Questioner Nov 17 '11 at 9:11
It's my pleasure. What model is your audio device? Do you get sound at all out of it, or is it just pavucontrol which are giving this error? – ovangle Nov 17 '11 at 9:37
ps. could you also post the result of 'cat /var/log/syslog | grep pulseaudio' – ovangle Nov 17 '11 at 9:51
Deleting ~/.pulse and starting pulseaudio fixed my problem - when I was inserting my USB headset (Logitech G35) it caused the built in speakers to be removed from the devices list in the sound manager as well as not working itself. – oscode Apr 20 '13 at 12:32

Open etc/pulse/ and try commenting out all these lines:

load-module module-jackdbus-detect

Run the steps again and check the log for changes, if possible give use another output.

If that does not work remove pulseaudio and reboot.

share|improve this answer

I received this "Connection to PulseAudio failed" error when there were different values of the XDG_RUNTIME_DIR environment variable.

The pulseaudio server was running with one value, and pavucontrol was running with a different value. Consequently, pavucontrol was looking in the wrong directory for the communication socket created by pulseaudio.

In this case, the solution is to make sure both processes have the same value for the XDG_RUNTIME_DIR environment variable.

share|improve this answer

protected by Community Nov 14 '11 at 1:03

Thank you for your interest in this question. Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).

Would you like to answer one of these unanswered questions instead?

Not the answer you're looking for? Browse other questions tagged or ask your own question.