How can I stop pulseaudio from spawning?

Questions about applications and software
Forum rules
Before you post please read how to get help
Post Reply
MarkSteele
Level 1
Level 1
Posts: 13
Joined: Thu Apr 02, 2020 2:42 am

How can I stop pulseaudio from spawning?

Post by MarkSteele »

The old method of adding autospawn = no to client.conf doesn't seem to work with LM 20 or LMDE 4. What do I have to do now to stop it loading? I'm using an old laptop as my music player through a usb dac and I really don't want pulseaudio getting its grubby paws on the audio stream.

User avatar
MrEen
Level 20
Level 20
Posts: 11577
Joined: Mon Jun 12, 2017 8:39 pm

Re: How can I stop pulseaudio from spawning?

Post by MrEen »

MarkSteele wrote:
Wed Jul 01, 2020 4:51 pm
The old method of adding autospawn = no to client.conf doesn't seem to work with LM 20 or LMDE 4. What do I have to do now to stop it loading? I'm using an old laptop as my music player through a usb dac and I really don't want pulseaudio getting its grubby paws on the audio stream.
While that should work to stop the autospawn, that doesn't prevent the initial loading at boot time. Running pulseaudio -k in the terminal right after booting up should disable it.

To stop it completely, you'll have to find what calls it. On my 18.3 Xfce install, it's in the Application Autostart tab of Session and Startup. Find something similar to Application Autostart and disable PulseAudio Sound System.

MarkSteele
Level 1
Level 1
Posts: 13
Joined: Thu Apr 02, 2020 2:42 am

Re: How can I stop pulseaudio from spawning?

Post by MarkSteele »

Thanks very much. Unfortunately it no longer seems to work either. On the plus side, Xfce doesn't seem to mind if you remove pulseaudio completely. I have known other desktops to refuse to start a session when I've tried it before. Pulseaudio is like a cockroach, hard to kill but well worth the effort.

User avatar
MrEen
Level 20
Level 20
Posts: 11577
Joined: Mon Jun 12, 2017 8:39 pm

Re: How can I stop pulseaudio from spawning?

Post by MrEen »

MarkSteele wrote:
Wed Jul 01, 2020 5:46 pm
Thanks very much. Unfortunately it no longer seems to work either. On the plus side, Xfce doesn't seem to mind if you remove pulseaudio completely. I have known other desktops to refuse to start a session when I've tried it before. Pulseaudio is like a cockroach, hard to kill but well worth the effort.
LOL.

Yeah, Cinnamon is destroyed by uninstalling PulseAudio, but Xfce and MATE (I believe) don't care.

If you'd like, we could try to fix whatever's wrong in your case instead of trying to not use PA.

MarkSteele
Level 1
Level 1
Posts: 13
Joined: Thu Apr 02, 2020 2:42 am

Re: How can I stop pulseaudio from spawning?

Post by MarkSteele »

That would be kind of handy. At the mo I'm using an old laptop just for the sound but it would have been nicer to put Cinnamon on it instead of Xfce. It used to be simple enough to stop it autospawning but now it seems close to impossible. Perhaps I should try getting in touch with the pa team and ask them...

User avatar
MrEen
Level 20
Level 20
Posts: 11577
Joined: Mon Jun 12, 2017 8:39 pm

Re: How can I stop pulseaudio from spawning?

Post by MrEen »

We can try some things here. but first we need to know what the issue is with PA. What is (or isn't) happening that is an issue?

The answer to that along with the output of the following should help us determine how to proceed:

Code: Select all

curl https://gitlab.freedesktop.org/pulseaudio/pulseaudio/raw/master/src/utils/pa-info?inline=false | bash | nc termbin.com 9999
Please have PA running when you run that so we get a good luck at your sound setup. The last line of the output will have a URL pointing to the info.

MarkSteele
Level 1
Level 1
Posts: 13
Joined: Thu Apr 02, 2020 2:42 am

Re: How can I stop pulseaudio from spawning?

Post by MarkSteele »

I just ran it on my main machine by mistake... I'll try it on the problem machine in a bit.

MarkSteele
Level 1
Level 1
Posts: 13
Joined: Thu Apr 02, 2020 2:42 am

Re: How can I stop pulseaudio from spawning?

Post by MarkSteele »

MrEen wrote:
Sun Jul 05, 2020 1:47 am
We can try some things here. but first we need to know what the issue is with PA. What is (or isn't) happening that is an issue?

The answer to that along with the output of the following should help us determine how to proceed:

Code: Select all

curl https://gitlab.freedesktop.org/pulseaudio/pulseaudio/raw/master/src/utils/pa-info?inline=false | bash | nc termbin.com 9999
Please have PA running when you run that so we get a good luck at your sound setup. The last line of the output will have a URL pointing to the info.
The output has gone to https://termbin.com/wyk0 The issue is that I can't stop PA from spawning with autospawn = no in client.conf with Linux Mint 20.

Cheers

User avatar
Flemur
Level 18
Level 18
Posts: 8458
Joined: Mon Aug 20, 2012 9:41 pm
Location: Potemkin Village

Re: How can I stop pulseaudio from spawning?

Post by Flemur »

MarkSteele wrote:
Sun Jul 05, 2020 4:12 am
The output has gone to https://termbin.com/wyk0 The issue is that I can't stop PA from spawning with autospawn = no in client.conf with Linux Mint 20.
How about

Code: Select all

sudo mv /usr/bin/pulseaudio /usr/bin/pulseaudio.save
?
A note: recent firefox versions require pulseaudio, you can get around that with package 'apulse', and start FF like:

Code: Select all

apulse firefox
Please edit your original post title to include [SOLVED] if/when it is solved!
Your data and OS are backed up....right?

MarkSteele
Level 1
Level 1
Posts: 13
Joined: Thu Apr 02, 2020 2:42 am

Re: How can I stop pulseaudio from spawning?

Post by MarkSteele »

Flemur wrote:
Sun Jul 05, 2020 9:28 am
MarkSteele wrote:
Sun Jul 05, 2020 4:12 am
The output has gone to https://termbin.com/wyk0 The issue is that I can't stop PA from spawning with autospawn = no in client.conf with Linux Mint 20.
How about

Code: Select all

sudo mv /usr/bin/pulseaudio /usr/bin/pulseaudio.save
?
A note: recent firefox versions require pulseaudio, you can get around that with package 'apulse', and start FF like:

Code: Select all

apulse firefox
Yup, that does the trick. Wondering why it's ignoring the client.conf file though.

User avatar
MrEen
Level 20
Level 20
Posts: 11577
Joined: Mon Jun 12, 2017 8:39 pm

Re: How can I stop pulseaudio from spawning?

Post by MrEen »

You made an extra change in client.conf that maybe was helping cause this:

Code: Select all

autospawn = no
daemon-binary = /bin/true
That second line is normally this:

Code: Select all

; daemon-binary = /usr/bin/pulseaudio
I've seen some changes in PA's config files break PA completely, so it wouldn't surprise me if this was the issue. Also, if you had a client.conf in ~/.config/pulse, that would take precedence over the copy in /etc/pulse, though that obviously wasn't the case here.

What I had meant about fixing PA was to fix the reason you didn't want it involved in your sound output, but if you're happy with where things stand now, it doesn't matter.

MarkSteele
Level 1
Level 1
Posts: 13
Joined: Thu Apr 02, 2020 2:42 am

Re: How can I stop pulseaudio from spawning?

Post by MarkSteele »

MrEen wrote:
Sun Jul 05, 2020 12:18 pm
You made an extra change in client.conf that maybe was helping cause this:

Code: Select all

autospawn = no
daemon-binary = /bin/true
That second line is normally this:

Code: Select all

; daemon-binary = /usr/bin/pulseaudio
I've seen some changes in PA's config files break PA completely, so it wouldn't surprise me if this was the issue. Also, if you had a client.conf in ~/.config/pulse, that would take precedence over the copy in /etc/pulse, though that obviously wasn't the case here.

What I had meant about fixing PA was to fix the reason you didn't want it involved in your sound output, but if you're happy with where things stand now, it doesn't matter.
Ah... penny dropped. I'm using the old laptop purely as a sound source and in the past I have found that it sounds slightly better if I cut out pa and go directly as possible to alsa. On 19.3 and earlier all I needed to do was create the client.conf in ~/.config/pulse and put autospawn = no in it. I picked up the daemon-binary line from somewhere while I was searching.

User avatar
MrEen
Level 20
Level 20
Posts: 11577
Joined: Mon Jun 12, 2017 8:39 pm

Re: How can I stop pulseaudio from spawning?

Post by MrEen »

It can be quite a pain in the you-know-what to remember all the little things we do to get things running the way we like, can't it? :D

MarkSteele
Level 1
Level 1
Posts: 13
Joined: Thu Apr 02, 2020 2:42 am

Re: How can I stop pulseaudio from spawning?

Post by MarkSteele »

MrEen wrote:
Tue Jul 07, 2020 5:25 pm
It can be quite a pain in the you-know-what to remember all the little things we do to get things running the way we like, can't it? :D
Yup... that's why I bookmark all the useful links I find and have a folder in Firefox specifically for them.

User avatar
MrEen
Level 20
Level 20
Posts: 11577
Joined: Mon Jun 12, 2017 8:39 pm

Re: How can I stop pulseaudio from spawning?

Post by MrEen »

MarkSteele wrote:
Fri Jul 10, 2020 11:43 am
MrEen wrote:
Tue Jul 07, 2020 5:25 pm
It can be quite a pain in the you-know-what to remember all the little things we do to get things running the way we like, can't it? :D
Yup... that's why I bookmark all the useful links I find and have a folder in Firefox specifically for them.
Smart! My bookmarks started out like that, but became a horrendous mess eventually. I got too lazy to organize them as I create them.

twerq
Level 2
Level 2
Posts: 52
Joined: Sun Jul 05, 2020 10:55 am

Re: How can I stop pulseaudio from spawning?

Post by twerq »

MrEen wrote:
Fri Jul 10, 2020 7:06 pm
Smart! My bookmarks started out like that, but became a horrendous mess eventually. I got too lazy to organize them as I create them.
Ahhh, I do believe keeping bookmarks organized and use Bookmark Manager as a knowledge base is nearly impossible.

User avatar
MrEen
Level 20
Level 20
Posts: 11577
Joined: Mon Jun 12, 2017 8:39 pm

Re: How can I stop pulseaudio from spawning?

Post by MrEen »

twerq wrote:
Sun Jul 12, 2020 11:12 am
MrEen wrote:
Fri Jul 10, 2020 7:06 pm
Smart! My bookmarks started out like that, but became a horrendous mess eventually. I got too lazy to organize them as I create them.
Ahhh, I do believe keeping bookmarks organized and use Bookmark Manager as a knowledge base is nearly impossible.
Yeah. I always start with good intentions, but it was gets out of hand too fast. At least I learned to create a text file with all the frequently used commands I paste here.

twerq
Level 2
Level 2
Posts: 52
Joined: Sun Jul 05, 2020 10:55 am

Re: How can I stop pulseaudio from spawning?

Post by twerq »

MrEen wrote:
Sun Jul 12, 2020 12:38 pm
At least I learned to create a text file with all the frequently used commands I paste here
I prefer to store oneliners in individual files. And collect them in separate directory.
From time to time I tend to add something in mostly used oneliners. Some of them become my own scripted tools.

MarkSteele
Level 1
Level 1
Posts: 13
Joined: Thu Apr 02, 2020 2:42 am

Re: How can I stop pulseaudio from spawning?

Post by MarkSteele »

twerq wrote:
Mon Jul 13, 2020 6:50 am
MrEen wrote:
Sun Jul 12, 2020 12:38 pm
At least I learned to create a text file with all the frequently used commands I paste here
I prefer to store oneliners in individual files. And collect them in separate directory.
From time to time I tend to add something in mostly used oneliners. Some of them become my own scripted tools.
Thanks for the ideas... I'm now thinking separate text files containing related useful commands. For example, a set of useful apt commands in one text file, useful rsync commands in another. I'll hang on to the bookmarks folder as well as not every link is about command lines.

Post Reply

Return to “Software & Applications”