Linux

  1. Home
  2. Computing & Technology
  3. Linux

From The Linux Documentation Project, for About.com

/dev/dsp

fuser is similar; but it lets you send a signal to any process accessing the device file.


   

# fuser -vk /dev/dsp

USER PID ACCESS COMMAND
/dev/dsp root 1225 f.... mp3blaster
root 1282 f.... mp3blaster

After issuing this command, mp3blaster was killed with SIGKILL. See the man pages for lsof and fuser; they're very useful. Oh, you'll want to run them as root since you'll be asking for information from processes that may be owned by root.

8.2.4. You're using the wrong driver (or no driver)

There are only two ways to configure your card:

  • Support must be compiled directly into the kernel

  • You must have the correct driver loaded into memory

You can find out which driver your sound card is using by doing "lsmod" or looking at the output of "dmesg". Since sound is crucial for me, I always compile sound into my kernels. If you don't have a driver loaded, you need to figure out what's been compiled into your kernel. That's not so straight forward. Your best bet is to compile your kernel. BTW, let me say that compiling your own kernel is the first step towards proficiency with Linux. It's painful the first time you do it, but once you do it correctly, it becomes very easy down the right, especially if you keep all your old .config files and make use of things like "make oldconfig". See the Kernel HOWTO for details.

If you haven't compiled the kernel yourself, there is an overwhelmingly good chance that your system is set up to load sound drivers as modules. That's the way distros do things. Have everything under the sun compiled as a module and try to load them all. So if you don't see your sound card's driver with lsmod, your card probably isn't configured yet.

8.2.5. Permissions Problem

If the sound card works when you're root but not any other user, you probably have a permissions problem. If this is the case, as root, look at the group owner of the sound card using ls -l /dev/dsp ; it'll probably be audio . Then, as root, add your non-root user to the audio group in /etc/group . For example, I added the users p and wellspring to group audio on my system:


   

audio:x:29:p,wellspring

Don't forget to use grpconv if you use shadow passwords (which should be the case on most recent distributions) in order to maintain a consistent group configuration. Then log out and log back in as the non-root user. Your sound card should work. Thanks to James Barton for reminding me to add this to the howto.


   Prev    Home    Next
   Video Cards         Miscellaneous Problems

Explore Linux

About.com Special Features

Build Your Own Website

Step-by-step advice on how to do everything from choosing a Web host to promoting your content. More >

Connect Your Home Computers

Easy ways to connect two computers for networking purposes. More >

Linux

  1. Home
  2. Computing & Technology
  3. Linux

©2009 About.com, a part of The New York Times Company.

All rights reserved.