From the ALSA wiki
|The FAQs have been reorganized. The new location of this question is FAQ#How can I find which processes are using Alsa devices?|
How can I find which processes are using Alsa devices?
Short answer: man fuser
Longer answer from Takashi on ALSA mailing-list,
On 2.6 with sysfs:
/sys/class/sound and check the corresponding devices.
Check the minor number of each device file and compare with the list on
Example on 2.6;
# fuser -v /dev/snd/* USER PID ACCESS COMMAND /dev/snd/controlC0 admin 7575 f.... kmix admin 14841 f.... xmms
Also useful might be using lsof:
lsof -n |grep "/dev/snd"