Sound isn't working right

I’ve been having issues with my audio ever since installing SUSE 11.1. I used the wiki on here (SDB:AudioTroubleshooting - openSUSE) and got the sound working by running alsaconf. After running alsaconf, the audio mixer widget dissapears. I check in Yast>sound and it says my sound card isn’t configured. However, the sound works. The problem is (aside from the audio mixer being gone) that after I reboot, the sound stops working again (and the audio mixer widget comes back) and I have to run alsaconf to get sound working again. Any ideas on what’s going on?

I’ve seen this happen when the loading of a PC’s wireless at boot interfers with the loading of the alsa sound driver.

After a fresh reboot, what happens if instead of running alsaconf, you type in a gnome-terminal or kde konsole: su -c ‘rcalsasound restart’ and enter root password when prompted for a password ?

If that works, then to have that run everytime at boot, edit your /etc/init.d/boot.local file, adding at the end the line: rcalsasound restart

You can edit that file by typing

  • in gnome: gnomesu 'gedit /etc/init.d/boot.local’

]in kde: ** kdesu ‘kwrite /etc/init.d/boot.local’*
in both cases typing the root password when prompted for a password.

I tried that command and sound still doesn’t work. Audio mixer dissapears, though.

After a fresh restart what is your criteria for saying that your sound does not work ?? Please do NOT use the startup sound as your criteria, as that has to be one of the worst criterias for determining sound functionality.

Instead, please try the speaker tests here: SDB:AudioTroubleshooting - openSUSE - speaker test and here: SoundcardTesting - AlsaProject One of those should work (you MUST try them all if one does not work).

I ask this as I know of many cases where users claimed their sound did not work at boot, when in fact it did if they only ran the appropriate sound test.

If the above does not work, then I will need specific information on your PC’s hardware and software audio setup in order to give a recommendation. In that case, post here, and I can provide you the commands that you will need to run in order to provide the information that I need.

It’s not just startup. I tried that first one and I think the second one on that first link you gave. I didn’t try out the second link. I won’t be able to try it out in my office till monday, so I’ll get back to you then.

Okay, the second test on the first link worked today and my music players work too. They weren’t on Thursday, so I’m not really sure what happened (I know I checked that sound wasn’t muted then). I guess I’ll just keep an eye on it and post again if it stops working.

Alright, I’m having trouble again. I just tried playing a song with Amarok and there’s no sound. I tried the second sound test again,

speaker-test -c2 -l5 -twav

and it works, but no sound when trying to play music. How do I obtain the specs you would need?

No need for specs if that speaker test works. If it works and you have sound, then your issues are likely either

  • you are struggling with a pulse audio bug, or
  • one of your installed multimedia applications is misbehaved and has seized the audio device and is not letting it go, or
  • you do not have your codecs setup completely, and so for files where you have the codecs sound will play, but for files where you do not have the codec, sound will not play, or
  • your mixer settings are varying, and you have not learned how yet as to what you need to check in your mixer
    I suspect a combination of all 4.

First off, wrt your mixer, you need to ensure Master, PCM, and in some cases “speaker” volume are moved up to a reasonably HIGH value. Each time you play a multimedia file, the PCM in particular may change dynamically, and you should test it again.

wrt codecs, take a read here: openSUSE Forums - View Single Post - setting up your codecs/multimedia apps

I downloaded the codecs you had listed in that link. Sound still didn’t work (but the sound test did). I restarted the audio driver using

su -c 'rcalsasound restart'

and it started working right after. So what does this mean? Is there a problem that could be fixed or do I have to do this every time I start the computer?

If the test sound worked, but other sounds did not work, and you had to type “rcalsasound restart”, then that suggests to me that a badly behaved application had seized your sound, and did not let go of the sound driver. When you ran “rcalsasound restart” that basically forced a restart of alsa, taking away the sound from any badly behaved sound application.

You could identify what application had seized your driver (and did not let go) and then stop using that badly behaved application. To check, that is possible by typing in a konsole or terminal: lsof /dev/dsp* /dev/audio* /dev/mixer* /dev/snd/*Typically, one should run that when their sound works ok, with sound playing and without sound playing in order to get a flavour as to what it looks like with their hardare and functional sound configuration. Once that baseline is established, then also run that when one has a sound problem. Then compare the outputs.

Don’t post the output here, as I am not interested in looking at it. :slight_smile:

You could also try switching your output audio mode in all your multimedia applications to the alsa api (where the alsa api allows the sharing of audio) so that if an application is not letting go of the sound driver, it is at least still sharing it (with other alsa apps).

Okay, thanks. I typed it in with sound working now, and nothing comes up, so I guess I’ll just wait till I have problems again with sound and type it again to see what’s using it.