warnim after sudo apt-get dist-upgrade?


19 posts
by n9mfk » Tue Dec 04, 2012 4:22 pm
Hi all,
i got this Waring after i did a sudo apt-get dist-upgrade
[warn] PulseAudio configured for per-user sessions ... (warning).
What do i need to do?
Beau
Posts: 26
Joined: Fri Nov 09, 2012 10:39 pm
by pgonzalez115 » Fri Dec 07, 2012 10:46 pm
This exact error happened to me too. Now my pygames wont play their .WAVs Any suggestions?
Posts: 4
Joined: Fri Dec 07, 2012 10:45 pm
by ThexDLolNoob » Thu Dec 13, 2012 3:16 pm
Same thing here, audio doesn't work at all either.
Posts: 3
Joined: Thu Dec 13, 2012 3:14 pm
by BerryPicker » Thu Dec 13, 2012 4:22 pm
n9mfk wrote:[warn] PulseAudio configured for per-user sessions ... (warning).

I see this message every time I power up my Pi.
Posts: 127
Joined: Tue Oct 16, 2012 3:03 pm
Location: The East of England
by bgirardot » Thu Dec 13, 2012 4:47 pm
That appears to be the recommended way it should be run, the "warning" is somewhat misleading, it should really be an "info" type message.

For more information you can read this file:

Code: Select all
cat /etc/default/pulseaudio


If for some reason you think it running in per session mode is your problem, that same file is the place to change it so it runs system wide.

Code: Select all
sudo service pulseaudio restart


will restart the service for you if you want to test it.
Posts: 517
Joined: Wed Oct 10, 2012 6:20 am
Location: Switzerland
by n9mfk » Thu Dec 13, 2012 8:31 pm
here what i got back
Code: Select all
# Start the PulseAudio sound server in system mode.
# (enables the pulseaudio init script - requires that users be in the
# pulse-access group)
# System mode is not the recommended way to run PulseAudio as it has some
# limitations (such as no shared memory access) and could potentially allow
# users to disconnect or redirect each others' audio streams. The
# recommended way to run PulseAudio is as a per-session daemon. For GNOME/KDE/
# Xfce sessions in Ubuntu Lucid/10.04, /etc/xdg/autostart/pulseaudio.desktop
# handles this function of automatically starting PulseAudio on login, and for
# it to work correctly your user must *not* have "autospawn = no" set in
# ~/.pulse/client.conf (or in /etc/pulse/client.conf). By default, autospawn
# is enabled. For other sessions, you can simply start PulseAudio with
# "pulseaudio --daemonize".
# 0 = don't start in system mode, 1 = start in system mode
PULSEAUDIO_SYSTEM_START=0

# Prevent users from dynamically loading modules into the PulseAudio sound
# server. Dynamic module loading enhances the flexibility of the PulseAudio
# system, but may pose a security risk.
# 0 = no, 1 = yes
DISALLOW_MODULE_LOADING=1
Posts: 26
Joined: Fri Nov 09, 2012 10:39 pm
by BerryPicker » Fri Dec 14, 2012 10:36 pm
I've seen it reported elsewhere that installing pulseaudio breaks alsa.

By removing pulseaudio with
Code: Select all
sudo apt-get autoremove pulseaudio

then rebooting, then re-installing alsa with
Code: Select all
sudo apt-get install alsa

and also doing the requested
Code: Select all
sudo apt-get autoremove

then again rebooting, I now have alsa working again!

I'll take all this as a warning not to do apt-get dist-upgrade as it may cause additional packages, not part of the recommended distribution, to be installed.
Posts: 127
Joined: Tue Oct 16, 2012 3:03 pm
Location: The East of England
by Mursili » Fri Dec 14, 2012 10:53 pm
This is odd since I have used 'apt-get dist-upgrade' and it did not break audio.
User avatar
Posts: 28
Joined: Fri Nov 23, 2012 2:12 am
by BerryPicker » Sat Dec 15, 2012 10:55 am
Mursili wrote:This is odd since I have used 'apt-get dist-upgrade' and it did not break audio.


Do you know whether your audio originates from alsa? Can you still use the alsamixer control? Can you still play a sound file with the aplay command? Can you still control the audio output (i.e. analogue or digital) with the amixer cset and sset commands?
Posts: 127
Joined: Tue Oct 16, 2012 3:03 pm
Location: The East of England
by efflandt » Sat Dec 15, 2012 4:57 pm
Earlier I messed up something in audio trying to get internet radio stations working. But that card got a little messed up doing overclock testing (had to e2fsck it from another computer at some point) and sudo apt-get dist-upgrade had stopped working due to something missing from scripts. I am using HDMI audio.

But I just did a fresh Raspian install to that SD last night, then:

sudo apt-get update && sudo apt-get dist-upgrade -y

rebooted, untarred some things including sshd config & keys and my home directory, added lxmusic, xmms2-plugin-all, and my other user to necessary groups.

For some reason lxmusic volume control said "muted" and does not do anything moving the slider even though I hear the internet music. I added the volume control to the taskbar in X, and other than the icon being stealthy (black on charcoal gray), when I click on the invisible icon the visible slider does work. alsamixer can control sound volume with pulseaudio shown as audio device. And following works from text console or X terminal:

aplay /usr/share/sounds/alsa/Front_Center.wav

So the pulseaudio warning after dist-upgrade is a non-issue, unless you messed something up yourself.

In Lubuntu (lxde version of Ubuntu) or a minimal version of Debian with lxde that I installed on SD for my tablet PC before I had my Pi, I could not get alsa sound working at all until I installed pulseaudio.
Posts: 359
Joined: Mon Dec 03, 2012 2:47 am
Location: Elgin, IL USA
by Mursili » Sat Dec 15, 2012 5:25 pm
BerryPicker wrote:Do you know whether your audio originates from alsa?


Now that you ask, I do not know. It is clear to me now that the Pi I am talking about seems to only use omxplayer to produce sound and that does not seem to be affected by whether I can get aplay to work. However, I would appreciate making sure that my sound system is working otherwise. Is there a good way to test that alsa is working (other than what I describe below)?

BerryPicker wrote:Can you still use the alsamixer control?


The control comes up, but as I will say below, I have yet to produce any sound with aplay.

BerryPicker wrote:Can you still play a sound file with the aplay command?


I downloaded a couple of .wav files online. One gives and error about wrong encoding when using 'aplay filename.wav' The other one gives no error, but still produces nary a sound.

BerryPicker wrote:Can you still control the audio output (i.e. analogue or digital) with the amixer cset and sset commands?


I did not try these.
User avatar
Posts: 28
Joined: Fri Nov 23, 2012 2:12 am
by BerryPicker » Sat Dec 15, 2012 7:10 pm
@Mursili If you can use alsamixer, and aplay /usr/share/sounds/alsa/Front_Center.wav shows no errors, then alsa is probably working for you, and it may be that some of the no sound solutions in the wiki will help achieve an actual sound output.
@efflandt I take encouragement from what you say that the latest update/upgrade does not break alsa sound.
Posts: 127
Joined: Tue Oct 16, 2012 3:03 pm
Location: The East of England
by Mursili » Sat Dec 15, 2012 10:26 pm
I can now say that I installed a fresh image of Raspbian (10-28-2012). In that case, 'aplay /usr/share/sounds/alsa/Front_Center.wav' works fine.

I then performed 'sudo apt-get update' and 'sudo apt-get upgrade'. After the update the same aplay command still worked.

I then performed 'sudo apt-get dist-upgrade' which installed/updated pulseaudio. After the dist-upgrade, the aplay command no longer works.

I suppose that I will go on the wiki to try to resolve this issue (or just go without dist-upgrading).
User avatar
Posts: 28
Joined: Fri Nov 23, 2012 2:12 am
by visage13 » Tue Dec 18, 2012 4:32 am
I was having a problem with mpg123 after doing the apt-get dist-upgrade just as the original poster. I could only play mp3's as root. I solved the issue by changing 2 config files to make the system boot pulse audio in system mode instead of per user session.

Change the following item: PULSEAUDIO_SYSTEM_START=0 to PULSEAUDIO_SYSTEM_START=1

In the following config files:

/etc/init.d/pulseaudio
/etc/default/pulseaudio

No guarantee it'll work but I hope this helps anyone else out that is having an issue.
Posts: 2
Joined: Sun Nov 11, 2012 4:44 pm
by winkleink » Sat Dec 29, 2012 1:39 am
same problem here.
audio all good until I did an upgrade and now fails.

aplay worked in sudo but not in apps
i uninstalled pulseaudio using the instructions above.
No joy and now even sudo aplay fails.

alsamixer still runs and shows volume.

i went to the wiki and checked my hdmi_drive was set to 2.
rebuilt hello_audio.bin and ran it with option 1 for hdmi and I get audio.

so, the physical connections work, but doing a dist upgrade has messed up the config.

any and all advice appreciated.
Twitter:Winkleink
Google+: Winkleink
User avatar
Posts: 218
Joined: Mon Nov 07, 2011 9:12 am
Location: UK
by micerinos » Tue Jan 08, 2013 3:09 pm
winkleink wrote:same problem here.
audio all good until I did an upgrade and now fails.

aplay worked in sudo but not in apps
i uninstalled pulseaudio using the instructions above.
No joy and now even sudo aplay fails.

alsamixer still runs and shows volume.

i went to the wiki and checked my hdmi_drive was set to 2.
rebuilt hello_audio.bin and ran it with option 1 for hdmi and I get audio.

so, the physical connections work, but doing a dist upgrade has messed up the config.

any and all advice appreciated.


Could you post the contents of the files /etc/asound.conf and /home/pi/asound.rc ? Any reference to pulseaudio should be removed. If that also fails, you can try to purge alsa and reinstall it:

apt-get autoremove alsa-base alsa-utils --purge
apt-get install alsa-base alsa-utils

Hope this helps
Posts: 74
Joined: Fri Nov 09, 2012 11:15 am
Location: Madrid, Spain
by micerinos » Tue Jan 08, 2013 3:11 pm
Typo: it should read /home/pi/.asoundrc
Posts: 74
Joined: Fri Nov 09, 2012 11:15 am
Location: Madrid, Spain
by winkleink » Tue Jan 08, 2013 4:58 pm
Decided to cut my losses.
Reimaged and did a
Code: Select all
sudo apt-get --yes purge pulseaudio

Rebooted and all good after that.

I got sound in Stella
Sound in Scratch
Sound in FreeDroid (Paradroid clone) Had the music and the sound effects.

So, it looks like PulseAudio is not there yet.

I remember Ubuntu going through something similar when they went to PulseAudio so I expect the Raspberry Pi will have some growing pains too. Hopefully, the final destination will be worth it.

For now I'm leaving PulseAudio off my Pi.
Twitter:Winkleink
Google+: Winkleink
User avatar
Posts: 218
Joined: Mon Nov 07, 2011 9:12 am
Location: UK
by gebser » Thu Jan 16, 2014 11:18 pm
wanted to play an mp3. As root installed mpg123 and as regular user played a (known to work) tune. mpg123 started, played the tune fine for five to fifteen seconds, then hung... the entire system: the term for root was frozen, couldn't communicate over the (wifi) network with the system (no ssh, no ping), not even the mouse pointer on the system's own monitor would move. The only thing to do was to yank the plug. This exact scenario played out three times in a row. This amounts to a security issue.

# mpg123 --version
mpg123 1.14.4


# apt-get purge pulseaudio
Reading package lists... Done
Building dependency tree
Reading state information... Done
Package 'pulseaudio' is not installed, so not removed

....

Also, I've never done an 'apt-get dist-upgrade'.
Posts: 6
Joined: Fri Dec 27, 2013 9:28 am