In linux how can i find what is my sound card path and microphone path? Some application is using /dev/dsp but how to make sure what is mine?


  • This is't a programming question see the faq: stackoverflow.com/faq – marto Jul 14 '11 at 15:12
  • Because you program using a certain OS doesn't mean any question regarding the OS are 'programming questions' askubuntu.com – marto Jul 14 '11 at 15:18
  • You have several questions which have been migrated from StackOverflow to other places, you should know this by now. – marto Jul 14 '11 at 15:31
  • Is there any case like it blocks from other visitors? I don't believe so – marto Jul 14 '11 at 15:39
  • understand why there are different sections for different types of questions. Maybe you should do more research via google. – marto Jul 14 '11 at 15:44

/dev/dsp and /dev/mixer are devices for the OSS3 sound system. The device paths are always the same on all systems.

However, due to the many limits of OSS3, almost all modern Linux distributions use ALSA for sound, which doesn't have dsp and mixer devices. It's possible to use OSS emulation in several ways:

  • User-mode, PulseAudio:

    PulseAudio comes with OSS emulation libraries. Run your program through padsp:

    padsp ./sjphone
  • User-mode, direct ALSA:

    Install the alsa-oss package, then run your program through aoss:

    aoss ./sjphone

    This works on PulseAudio systems too (although maybe not as well as padsp).

  • Kernel-mode:

    Load the snd-pcm-oss and snd-mixer-oss kernel modules, then run your program normally:

    sudo modprobe snd-pcm-oss
    sudo modprobe snd-mixer-oss

    This method is not recommended – especially avoid it on PulseAudio systems, since kernel OSS emulation may conflict with how PulseAudio manages the hardware. User-mode padsp or aoss is usually the better choice.

  • Thank you. Its very nice answer and very confusing one of mine. I used "aoss ./sjphone", and i can use the slider of microphone only, but i cant use the speaker slider, which is disabled still. Is that has to do with aoss still or ./sjphone itself? – YumYumYum Jul 14 '11 at 22:10
  • Thanks again. Its just working super cool. You are genius!! – YumYumYum Jul 14 '11 at 22:13
  • Of note: The /dev/dsp does not show up in directory listings, but can be opened for reading or writing. Try padsp cat /dev/dsp >temp.wav for recording and padsp bash -c 'cp temp.wav /dev/dsp' for playback. – nobar Feb 8 '15 at 4:44

/dev/dsp is the standard device in Linux for outputting or recording sound. There isn't a special device path for your soundcard or microphone.

  • But as you can see here it using /dev/dsp. But i do not have any mic/headphone sounds for this. What else i can apply instead of /dev/dsp in that case? e.g: i.stack.imgur.com/7WPVw.png – YumYumYum Jul 14 '11 at 17:06

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.