New to Pure [Free]BSD And Having Some Issues

Hello all! This is my first post here. I am new to FreeBSD and the like, but I've used (and currently have installed) Arch Linux and macOS on several computers in my room/home office here. I recently decided to wipe my Windows SSD on my main system (a custom AMD Ryzen 9 build I did) to play with FreeBSD because I'd never been able to experience a true pure BSD system before. I managed to get a base 13-RELEASE system installed with X and KDE Plasma 5 (I ultimately want GNOME 3.x and then upgrade to 40 or 41 whenever that's available... BUT I have an AMD Radeon RX 480 4GB GPU that has documented issues with X and GNOME and other stuff). I'm very happy with the speed and responsiveness of FreeBSD vs my Arch Linux install (of which is no slouch) but I can't really do anything without audio if I wanna use it as an alternate (and hopefully at some point replacement) desktop OS/workstation.

So, here's what's not working:

• No audio anywhere throughout the system. KDE's KMix or w/e it's called nowadays sees my GPU's HDMI audio out of which I'm not using, and I think it sees my motherboard's line out "green jack" but no audio plays at all through my speakers. Am I missing a driver pkg or is it just not in my kernel or something? KMix sees the non-HDMI audio out option as "Realtek ALC892 (Analog)". I read on another post here that the command "sndstat" can be run to see what has a connection, but I apparently don't have the pkg that provides it? What pkg provides sndstat? The audio chipset according to lspci is: "[AMD] Starship/Matisse HD Audio Controller".

• I cannot for the life of me get Grub on my Arch Linux NVMe to chainload into FreeBSD should I want to use it over Arch itself. That's a minor thing, as I can easily F11 (Boot menu on reboot) and choose the proper secondary SSD to boot into FreeBSD, but it'd be nice not to have to do that.

• YouTube does not play in Chromium but will in FireFox. I'd prefer to use Chromium as I have a deep

With all that said, I'm going to post this on FreeBSD's subreddit as well to get more exposure of my issues, but all in all I am loving FreeBSD and if these issues are resolved I might daily drive it for a bit to see how I like a BSD system vs a Linux system.

TIA,
Sorry if this kind of post was made before (I couldn't find it in a search),
Shiggitay#1839 (my Discord hash/handle. Feel free to DM me if you can help me get my issues sorted.)
 
I read on another post here that the command "sndstat" can be run to see what has a connection, but I apparently don't have the pkg that provides it? What pkg provides sndstat?
Not a command, not a package either. It's part of the sound driver framework; cat /dev/sndstat. Also see the use of the hw.snd.default_unit sysctl(8) to change the default audio output.

 
I'd prefer to use Chromium
Be aware that Chromium decided to not accept any portability patches required for BSD, they don't want to support BSD at all. That's why the FreeBSD port is littered with local patches. As a consequence
  • Bugs are more likely than on supported platforms (and happen regularly)
  • It takes quite some time for new versions to be ported (maintaining this huge mess of patches is a ton of work)
That said, Chromium works for me at the moment (with a few broken things that aren't too important for me). Still you might reconsider and prefer Firefox instead.
 
Not a command, not a package either. It's part of the sound driver framework; cat /dev/sndstat. Also see the use of the hw.snd.default_unit sysctl(8) to change the default audio output.

I tried doing all that (am I still missing something?), and in KMix when I play a local MKV video I can see audio playing, but I can't hear it.

Be aware that Chromium decided to not accept any portability patches required for BSD, they don't want to support BSD at all. That's why the FreeBSD port is littered with local patches. As a consequence
  • Bugs are more likely than on supported platforms (and happen regularly)
  • It takes quite some time for new versions to be ported (maintaining this huge mess of patches is a ton of work)
That said, Chromium works for me at the moment (with a few broken things that aren't too important for me). Still you might reconsider and prefer Firefox instead.
I mean sure.. I'll use whatever works the best... I don't mind building the port myself (I have a beefy enough system that it shouldn't take THAT long...).

How would I resolve my audio issues? I did kldload snd_driver and snd_hda, and it seems to have loaded since it didn't complain... kldstat shows some audio drivers loaded, but I still can't hear anything from my speakers. With ZERO changes to where the speakers are connected on my Linux side it works without a hitch.
 
I tried doing all that (am I still missing something?), and in KMix when I play a local MKV video I can see audio playing, but I can't hear it.
Forget about KDE for the moment, if FreeBSD itself doesn't activate or enable your sound card everything else won't be able to use it either.

How would I resolve my audio issues? I did kldload snd_driver and snd_hda, and it seems to have loaded since it didn't complain... kldstat shows some audio drivers loaded, but I still can't hear anything from my speakers.
Post the output of cat /dev/sndstat.
 
Forget about KDE for the moment, if FreeBSD itself doesn't activate or enable your sound card everything else won't be able to use it either.


Post the output of cat /dev/sndstat.
Code:
shiggitay@VocaloidHavenFreeBSD:~ % cat /dev/sndstat
Installed devices:
pcm0: <ATI R6xx (HDMI)> (play)
pcm1: <ATI R6xx (HDMI)> (play)
pcm2: <ATI R6xx (HDMI)> (play)
pcm3: <ATI R6xx (HDMI)> (play)
pcm4: <ATI R6xx (HDMI)> (play)
pcm5: <ATI R6xx (HDMI)> (play)
pcm6: <Realtek ALC892 (Analog)> (play/rec) default <===== that's the device I see getting audio in KMix
pcm7: <Realtek ALC892 (Front Analog Mic)> (rec)
pcm8: <USB audio> (rec)
pcm9: <USB audio> (rec)
pcm10: <USB audio> (play/rec)
Installed devices from userspace:
dsp: <Virtual OSS> (play/rec)
Thank you btw for your time.
 
pcm6 is likely the rear audio connectors. Is that where you have speakers or headphones plugged in?
please post output of (you may need to run as root or sudo)
sysctl hw.snd.default_unit
if it does not say "6" and you do have speakers/headphones plugged into the rear analog audio jacks, try the following as root:
sysctl -w hw.snd.default_unit=6

What are the USB Audio devices? Is pcm10 a set of USB headphones with a mic?
I don't use KDE/KMix but there should be a way for you to switch the "default device" somehow with the tools. If so, and you see something like the headphones for USB audio try setting to that.
 
pcm6 is likely the rear audio connectors. Is that where you have speakers or headphones plugged in?
please post output of (you may need to run as root or sudo)
sysctl hw.snd.default_unit
if it does not say "6" and you do have speakers/headphones plugged into the rear analog audio jacks, try the following as root:
sysctl -w hw.snd.default_unit=6

What are the USB Audio devices? Is pcm10 a set of USB headphones with a mic?
I don't use KDE/KMix but there should be a way for you to switch the "default device" somehow with the tools. If so, and you see something like the headphones for USB audio try setting to that.
shiggitay@VocaloidHavenFreeBSD:~ % sysctl hw.snd.default_unit
hw.snd.default_unit: 6
shiggitay@VocaloidHavenFreeBSD:~ % sysctl -w hw.snd.default_unit=6
hw.snd.default_unit: 6 -> 6

Also yes. The USB audio devices are a crappy Logitech headset I use only for its headphones and a USB mic. I've tried issuing sysctl -w hw.snd.default_unit=10 but no joy out of the Logitech headset's headphones.

I tried that but no dice.
 
If you want a complete desktop, it will not work out of the box. You will have to read and re-read the manual a few times, and spend at least a few days (more like a few years), to get everything running the way you like.

Sound most definitely can and does work.

Chromium does work for youtube.
 
I don't mind building the port myself
That won't change anything, the binary packages are just built from ports with default settings. Have a look at my link to understand why trying to catch up with keeping Chromium to work on FreeBSD at all is a major struggle...

About sound, maybe too obvious, but what's the output of mixer?
 
  • Like
Reactions: mer
That won't change anything, the binary packages are just built from ports with default settings. Have a look at my link to understand why trying to catch up with keeping Chromium to work on FreeBSD at all is a major struggle...

About sound, maybe too obvious, but what's the output of mixer?
Code:
shiggitay@VocaloidHavenFreeBSD:~ % mixer
Mixer vol      is currently set to 100:100
Mixer pcm      is currently set to 100:100
Mixer speaker  is currently set to 100:100
Mixer line     is currently set to 100:100
Mixer mic      is currently set to  97:97
Mixer mix      is currently set to 100:100
Mixer rec      is currently set to 100:100
Mixer igain    is currently set to 100:100
Mixer ogain    is currently set to 100:100
Recording source: line
Re: building chromium, I started a compile and it's going super quick... I don't intend on "keeping up" with it... I'll swap over to FireFox once I get everything working right, but I was just curious to see how all that works on FreeBSD.
 
If you want a complete desktop, it will not work out of the box. You will have to read and re-read the manual a few times, and spend at least a few days (more like a few years), to get everything running the way you like.

Sound most definitely can and does work.

Chromium does work for youtube.
I'm aware a vanilla FreeBSD install (i.e. not Dragonfly or GhostBSD that're tailored for desktop out of the box) won't work out of the box... I don't mind that. I've setup Linux (I know it's different) distro's from scratch (not LFS sadly) so I know what it all entails.... I want to learn FreeBSD, and the audio issues are about the only thing stopping me from using it as my daily driver.
 
Ok so all sound settings look fine (assuming it's indeed the correct device).

Then try this (turn down volume): cat /dev/random > /dev/dsp. Do you hear anything?
 
What
ls /dev/dsp*
says?
For every /dev/dspX from the command above try cat /dev/random > /dev/dspX
like this:
cat /dev/random > /dev/dsp7

If it plays nothing disable the virtual oss, and try the above again.

You can also post '/usr/local/etc/rc.d/virtual_oss' file
 
What
ls /dev/dsp*
says?
For every /dev/dspX from the command above try cat /dev/random > /dev/dspX
like this:
cat /dev/random > /dev/dsp7

If it plays nothing disable the virtual oss, and try the above again.
shiggitay@VocaloidHavenFreeBSD:~ % ls /dev/dsp*
/dev/dsp /dev/dsp0.1 /dev/dsp2.0 /dev/dsp5.0 /dev/dsp8.0
/dev/dsp.ctl /dev/dsp1.0 /dev/dsp3.0 /dev/dsp6.0 /dev/dsp9.0
/dev/dsp0.0 /dev/dsp10.0 /dev/dsp4.0 /dev/dsp7.0

And I just did cat /dev/random > /dev/dsp* on all I could in there and still nothing. I'll disable virtual oss and try again yeah.
 
I've just verified on a 13-release-p6 system, with chromium 94.0.4606.81 from packages that sound works with a USB headset. Firefox sound also works.
A difference is I am not running KDE or any desktop, rather just a simple windowmanager, so you should be able to get it to work.
 
shiggitay@VocaloidHavenFreeBSD:~ % ls /dev/dsp*
/dev/dsp /dev/dsp0.1 /dev/dsp2.0 /dev/dsp5.0 /dev/dsp8.0
/dev/dsp.ctl /dev/dsp1.0 /dev/dsp3.0 /dev/dsp6.0 /dev/dsp9.0
/dev/dsp0.0 /dev/dsp10.0 /dev/dsp4.0 /dev/dsp7.0

And I just did cat /dev/random > /dev/dsp* on all I could in there and still nothing. I'll disable virtual oss and try again yeah.
ANNNNDD nothing still.
 
I'm aware a vanilla FreeBSD install (i.e. not Dragonfly or GhostBSD that're tailored for desktop out of the box
GhostBSD / NomadBSD will have the same sound issue. All they do is just install FreeBSD with some default packages installed. Nothing that a pkg install shouldn't achieve. DragonflyBSD is fairly specialist and not tailored for the desktop (thus I assume you meant NomadBSD instead).

As for your problem, it could be that your hardware is working, it is just "mis-wired" by the driver. This seems a little common on FreeBSD for the snd_hda drivers (which most are these days). Check out:

https://www.freebsd.org/cgi/man.cgi?snd_hda#EXAMPLES

It is a complex procedure and I am only 75% certain of it when I had to do it myself a few years back. Perhaps the best guide I have found is here on the forums:

https://forums.freebsd.org/threads/internal-microphone-setup-question.77091/#post-479069
 
GhostBSD / NomadBSD will have the same sound issue. All they do is just install FreeBSD with some default packages installed. Nothing that a pkg install shouldn't achieve. DragonflyBSD is fairly specialist and not tailored for the desktop (thus I assume you meant NomadBSD instead).

As for your problem, it could be that your hardware is working, it is just "mis-wired" by the driver. This seems a little common on FreeBSD for the snd_hda drivers (which most are these days). Check out:

https://www.freebsd.org/cgi/man.cgi?snd_hda#EXAMPLES

It is a complex procedure and I am only 75% certain of it when I had to do it myself a few years back. Perhaps the best guide I have found is here on the forums:

https://forums.freebsd.org/threads/internal-microphone-setup-question.77091/#post-479069
Would the fact that I'm not running on Intel hardware cause any issues? I'm 100% AMD.
 
It depends :)

For now, try catting the random to dsps

Do you have sndio? According to wiki, it may not work well with virtual_oss.

Are you sure your output / cables work as expected? No power issues? ;)

I have a Realtec ALC sound card and it works as expected, so if yours is not broken it should work too, so check if you don't have any spelling mistakes in configs :)
 
I don't see a reason for it...

FreeBSD's OSS implementation already does multiplexing. I mostly use it directly. Some applications don't support OSS, for these you can use sndio, alsa with OSS backend, sdl, openal, whatever is supported :)
 
Back
Top