sound server error: error initializing the sound driver
SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
sound server error: error initializing the sound driver
i just switched to slackware recently and i'm still learning the basic stuff. but when i login and startx, an error window pops up reading:
Sound server informational message:
Error while initializing the sound driver:
device: default can't be opened for playback (No such file or directory)
The sound server will continue, using the null output device.
this error also pops up when i try to test my sound system in control center. so i'm guessing i need to do something with the sound driver, i just don't know what. i have no sound from either root or regular user accounts, and i'm on slack 12.1 with kde 3.5.9 (i'm still trying to upgrade to 4.1 but that's a different thread). i looked up some topics for this problem but a lot of the threads are really old or are for another distro. can anyone give me some pointers on what i should do? is this really a problem with the driver or is something just sitting in the wrong dir or something? thank you for any replies, i can't wait to make my system completely functional!
Try closing everything, including your x-session, maybe just perform a fresh reboot, and from a regular console with nothing else running run the "alsaconf" script and go through it.
hm i rebooted and ran the alsaconf script as you said, and it went through the setup and finished successfully, but when i startx i still get the same error, and still no sound
i read a while ago that it's possible to test sound from the console by typing
Code:
play example.mp3
but when i try this it says the file does not exist. am i just missing an essential package or something? i thought i installed slack completely.
As Robbie mentioned, you need to ensure your user account is a member of the appropriate groups.
The error message you are receiving is a KDE message. If you do not have much invested in your user KDE profile, then before starting X, temporarily rename your ~/.kde folder to something like ~/.kde-old. Then start KDE, answer the questions in the Personalizer, disable the moronic bouncing mouse cursor, and then see whether then sound error message continue.
As Robbie mentioned, you need to ensure your user account is a member of the appropriate groups.
The error message you are receiving is a KDE message. If you do not have much invested in your user KDE profile, then before starting X, temporarily rename your ~/.kde folder to something like ~/.kde-old. Then start KDE, answer the questions in the Personalizer, disable the moronic bouncing mouse cursor, and then see whether then sound error message continue.
how did you know i have the annoying bouncing cursor problem!?! i will try your idea right after this post.
this is how i test to see which groups the user is in, i set it up in the console once but forgot the commands already later went to the k menu > System > Kuser - User Manager and i used that. the groups that i have checked i put a * next to:
*adm
*apache
*audio
*bin
*cdrom
*console
daemon
*disk
*floppy
*ftp
*games
*gdm
haldaemon
kmen
*lp
*mall
man
mem
messagebus
mysql
news
nobody
nogroup
*plugdev
pop
*power
root
rpc
scanner
shadow
slocate
smmsp
sshd
*sys
tape
tty
*users(obviously)
utmp
uucp
*video
*wheel
btw when i put 'aplay /dev/urandom' into the console i get this,
Code:
russian@comp45:~$ aplay /dev/urandom
ALSA lib pcm_dmix.c:866:(snd_pcm_dmix_open) unable to open slave
aplay: main:546: audio open error: No such file or directory
russian@comp45:~$
Woodsman i did as you said and when i went through the personalizer again it helped. i didn't get an error message when i went startx. but i tried playing audio and didn't hear anything. so i rebooted and ran alsaconf, but then when i went startx i got the same error again. what am i doing wrong! i just want my sound :'(
oh and i also noticed my /proc/asound directory has the card 0 and card 1 folders and some other files and stuff, but they're all size 0 bytes. as if they don't exist but somehow still do O.o i donno what's going on...
EDIT:
fixed it! strangely i still get the error at startup, but i have sound and all it took was some simple tinkering. here's my process on how i fixed my sound problem, and it may be the same solution for others.
first i logged into root and before typing startx to start up the gui i typed in alsamixer and turned everything up to about 90.
(if you don't see any meters to turn up there's something wrong, when i saw this i exited out of alsamixer by pressing esc, then i gave myself a fresh .kde folder(thanks Woodsman ;P), do this by typing:
mv .kde .kde-old
remember to type this in the startup console, before you start x. ok so the mv renames a folder, and you basically renamed .kde and now it's called .kde-old. since there's no .kde anymore, a new one will be created on boot. so when you start x now you'll have to go through the personalizer again, this fixed the no meters in alsamixer for me.
also in alsamixer make sure the switches are on, just have the volume meter selected and
press m to toggle the volume mute. the default setting is off.(the switch is green when it's on) so after you turn up your stuff and unmute the meters, type in,
alsactl store
this will save the settings of your meters. now just startx and see if it worked. even if you get the warning don't be discouraged. play a video file to see if it has audio. then next time you can just tell the prompt to never prompt you again!
Last edited by SirPetrovich; 12-12-2008 at 02:08 PM.
If you're still getting the error, it's not setup right. I have answered a lot of sound questions. The most important information you can provide is the output of the following commands (as root):
It is also important to note that trying to get sound working after starting X (especially with KDE, since it immediately starts artsd and prevents applications from directly accessing the sound card) is not a good idea. You should get your sound working completely in runlevel 3 before starting X and THEN start X and see if it works there too. It is possible that the wrong module is loaded, or that certain options need to be passed to the module, etc.
If you're still getting the error, it's not setup right. I have answered a lot of sound questions. The most important information you can provide is the output of the following commands (as root):
It is also important to note that trying to get sound working after starting X (especially with KDE, since it immediately starts artsd and prevents applications from directly accessing the sound card) is not a good idea. You should get your sound working completely in runlevel 3 before starting X and THEN start X and see if it works there too. It is possible that the wrong module is loaded, or that certain options need to be passed to the module, etc.
this is where your 1337 skills show lol i go on youtube to watch a russian dj video and there's no sound ... so yeah i did probably screw something up to make things worse pandora.com and grooveshark both didn't work when i had sound.
A quick google suggests that the correct module (snd-intel8x0) is loaded. There are some options you can pass to the module, but I wouldn't try that until you have tried everything else (this module is not one of the ones that commonly needs options, unlike the snd-hda-intel module, for example, which almost always needs options passed to it). Let's try the simple procedure (which you have no doubt already done in steps, but let's try it all at once). As root (in the console, in runlevel 3, BEFORE starting X), run
Code:
# alsaconf
Select the most relevant driver (and if it doesn't work after this, post the possible options). Then, run
Code:
# alsamixer
Turn up the volume for everything (using the arrow keys). Make sure everything is unmuted (press the 'm' key until it displays 00 under each bar). Press Esc twice to exit alsamixer. Then run
Code:
# alsactl store
Then try to play a sound file. Here are two commands that you should try (since you have KDE installed, you should have the .wav file):
again and mute everything (some sound cards are goofy and detect mute as unmuted...) using the 'm' key. Press Esc twice to exit and again run
Code:
# alsactl store
Then try playing the sound files again. If that does not work, verify that you are indeed in the audio group by posting the output of the following command:
Code:
# grep audio /etc/group
Also check to make sure the permissions are correct on the audio device:
One or more of those may be missing from your system, but you should at least have audio and dsp and they should have the correct permissions of root:audio.
If none of that works, then you can try passing options to the module. But that explanation is for another time.
alsaconf went through and i saw and selected the correct module, but alsamixer had nothing under it... it's late but tomorrow i'm going to make a new .kde folder and try again
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.