Suddenly no sound in Firefox after update

Pulseaudio was designed to work with systemd and with systemd it typically starts with user permissions. If pulseaudio is started in /etc/rc.conf that may not be the case. See this pulseaudio thread. It might be better to start pulseaudio in /etc/rc.local.
 
I build my own desktop repository by ports-mgmt/poudriere with non default options.

I use www/firefox with audio/pulseaudio only.
As www/libxul depends on audio/alsa-plugins, if you want to use audio/pulseaudio, you also need to build audio/alsa-plugins with non-default pulseaudio option.

Here is my ports or ports-mgmt/poudriere option selections for www/firefox, audio/pulseaudio & audio/alsa-plugins
Code:
##=============================================================##
www_firefox_SET=BUNDLED_CARIO FFMPEG GIO GSTREAMER GTK3 LOGGING OPTIMIZED_CFLAGS
www_firefox_SET+=PULSEAUDIO
www_firefox_UNSET=ALSA CANBERRA DBUS DEBUG DTRACE GCONF GNOMEUI GTK2
www_firefox_UNSET+=INTEGER_SAMPLES LIBPROXY PGO PROFILE TEST
##=============================================================##
audio_alsa-plugins_SET=FFMPEG IO_PTR PULSEAUDIO
audio_alsa-plugins_UNSET=BLKCNT_P2 BUFSZ_P2 JACK SAMPLERATE SPEEX VERBOSE
##=============================================================##
audio_pulseaudio_SET= ALSA AVAHI SIMD
audio_pulseaudio_UNSET=JACK GCONF
##=============================================================##
 
It works for me too with the default packages. Pulseaudio requires that Dbus is available. Do you have it enabled? sysrc dbus_enable=YES
 
It works for me too with the default packages. Pulseaudio requires that dbus is available. Do you have it enabled? sysrc dbus_enable=YES
Of course I do. But I'm not talking about packages, I'm talking about a locally-built system. As all the discussion here turns around different options, which is only available with local build...

However, it seems packages have some default config files set up the right way, which is not provided with local build then.
 
Do you mean it just works for you upon install, without any additional interference on your part? That you just make a fresh install including these two ports above, then open, say, www.youtube.com in firefox browser -- and enjoy your sound?

That's what I expected it to be, but which doesn't work for me.

One of my old Acer Laptop which use /dev/dsp1.0 for audio output
Code:
$cat /dev/sndstat  
Installed devices:
pcm0: <ATI RS690/780 (HDMI)> (play)
pcm1: <Realtek ALC272 (Analog 2.0+HP/2.0)> (play/rec) default
pcm2: <Realtek ALC272 (Left Analog Mic)> (rec)

I add two lines in /etc/sysctl.conf
Code:
hw.snd.default_unit=1
hw.snd.default_auto=0

I configure pulseaudio in /usr/local/etc/pulse/default.pa
uncomment the line start with load-module module-oss and change the device name to my actual device file

Code:
### Load audio drivers statically
### (it's probably better to not load these drivers manually, but instead
### use module-udev-detect -- see below -- for doing this automatically)
load-module module-oss device="/dev/dsp1.0" sink_name=output source_name=input
#load-module module-oss-mmap device="/dev/dsp1.0" sink_name=output source_name=input
#load-module module-null-sink
#load-module module-pipe-sink
 
One of my old Acer Laptop which use /dev/dsp1.0 for audio output
$cat /dev/sndstat
Installed devices:
pcm0: <ATI RS690/780 (HDMI)> (play)
pcm1: <Realtek ALC272 (Analog 2.0+HP/2.0)> (play/rec) default
pcm2: <Realtek ALC272 (Left Analog Mic)> (rec)


I add two lines in /etc/sysctl.conf
Code:
hw.snd.default_unit=1
hw.snd.default_auto=0

I configure pulseaudio in /usr/local/etc/pulse/default.pa
uncomment the line start with load-module module-oss and change the device name to my actual device file

Code:
### Load audio drivers statically
### (it's probably better to not load these drivers manually, but instead
### use module-udev-detect -- see below -- for doing this automatically)
load-module module-oss device="/dev/dsp1.0" sink_name=output source_name=input
#load-module module-oss-mmap device="/dev/dsp1.0" sink_name=output source_name=input
#load-module module-null-sink
#load-module module-pipe-sink
Thanks a lot for the info! The part about /etc/sysctl.conf is somewhere in the documentation, I think.

But regarding pulseaudio I've never ever had to configure it, so I really didn't know what to do when it didn't work. Install some funny additional "controls" packages etc. I mean, in Linux it used to work out of the box. Just like with alsa, it used to be once upon a time just alsaconf and you're done. Then alsa-mixer was of some help.

Thankfully, now I know that on FreeBSD it actually is not needed at all.
 
Back
Top