If you can't hear sound coming from your Ubuntu Linux computer, you might wonder if the problem is a hardware problem (the sound card) a kernal problem (perhaps a bad kernal driver) or a software problem, such as mplayer if that is what you were trying to use. Before blaming software setup, it is good to check the sound devise to see if it is really working properly, that your speakers are powered on, and that they are plugged in properly to the computer box. It is usually the simple things that cause problems.
Ubuntu Linux has a neat way to check out to see if the sound devise is working properly.
First find a wav file. To do that, open a terminal and type
find /usr -name *.wav -print
to find where some wav files are stored on your computer.
If you took the default setup of Hoary Hedgehog Ubuntu Linux, you don't even need to search. Simply to to the the sounds sub-directory of the library directory of openoffice:
cd /usr/lib/openoffice/share/gallery/sounds to move to that directory
In that directory is a file called train.wav (You can find that or other wav files with the command ls )
cat train.wav > /dev/dsp
If you did not change your directory, type the following instead:
cat /usr/lib/openoffice/share/gallery/sounds/train.wav > /dev/dsp
If you hear a train sound, the sound card is working properly.
If not, you know that your problem is that your speakers are not working, not turned on, or not plugged in correctly --- or that your sound card is bad, not making good contact to your motherboard, or without the correct driver.
How this works:
In this example cat reads the file train.wav
If you only type cat train.wav , the output of the file would have printed gobble-de-gook to your LCD or CRT computer screen. That is because a wav file was not meant to be displayed as a text file on a computer monitor! However by adding the > /dev/dsc to the end of the command, it transferred the standard output from the computer monitor to the registered sound devise.
When you hear the train sound (from the above example), you know that your sound card is functioning correctly with the correct kernal driver. Thus, it eliminates hardware as the cause of the problem.