No sound on my Linux box and alsamixer gives error in function snd_ctl_open failed

On my newly installed Fedora box (I said “newly” but this may be a bit misleading as I installed FC9, which is an old distribution but I have to use it for compatibility reasons with other software…) I had the following problem:

I had no sound (e.g. YouTube plays a clip and there is no sound) and starting alsamixer as a non-root user gives me the following error:

alsamixer: function snd_ctl_open failed for default: No such file or directory

I admit that ALSA and Linux sound configuration is not my forte, so this particular problem was solved with help from one of my colleagues (Emo).  I got as far as checking that my audio hardware was detected :

# /sbin/lspci | grep -i audio
00:1b.0 Audio device: Intel Corporation 82801JI (ICH10 Family) HD Audio Controller

Here’s what Emo made me do to solve the “function snd_ctl_open failed” problem:

Looking into /dev/snd/ and alsamixer revealed that all devices were owned by root:root so users could not write to the sound card.This apparently is a problem with that distro’s installer as it should have configured udev to make these devices user-writable.

Our quick solution was to transfer group ownership of these devs to group users:

cd /dev/snd/
sudo chown root:users *
cd /dev
sudo chown root:users mixer

After that the sound worked (I tested with a tube clip)!

The problem with this quick fix to the no sound problem in alsamixer is that all these changes will disappear upon reboot so I will have to execute the above chown commands each time I reboot 🙁

Naturally this is not a proper solution, but at least it proves that the problem lies exactly there. At some point later on (today? if time permits..) I will post here the proper solution which is (as done on many other distributions where sound and alsamixer work properly for intended users right from the start):

    create a group audio (or sound, snd, alsa, whatever…);
    add all users who are permitted to play sound to that group;
    make udev set the group ownership of the above devices to this group.

… cheers, hope this helps at least a little 😉

2 thoughts on “No sound on my Linux box and alsamixer gives error in function snd_ctl_open failed

  1. Another possibility why there may be no sound in Fedora (I know about FC 13, 14 and 15 that this was the problem) is that you need to remove PulseAudio. Somehow PulseAudio does not work properly in these versions (and possibly earlier and later versions too..).
    Do a “sudo yum remove pulseaudio”, reboot and this should fix the problem. Bow typing ‘alsamixer’ should show you all the controls for your audion card (not just one ‘Master’ control for the dummy card…)

Leave a Reply

Your email address will not be published. Required fields are marked *