OpenVZ Forum


Home » General » Support » Accessing ALSA sound devices within VPS
Accessing ALSA sound devices within VPS [message #35584] Mon, 06 April 2009 22:02 Go to next message
starfry is currently offline  starfry
Messages: 24
Registered: March 2009
Location: Coulsdon, Surrey, UK
Junior Member
Hi,

is it possible to use the host's ALSA dound devices from within a VPS?

I have tried enabling the devnodes:
# vzctl set 109 --devnodes snd/hwC0D0:rw
# vzctl set 109 --devnodes snd/controlC0:rw
# vzctl set 109 --devnodes snd/hwC0D1:rw
# vzctl set 109 --devnodes snd/pcmC0D0c:rw
# vzctl set 109 --devnodes snd/pcmC0D0p:rw
# vzctl set 109 --devnodes snd/seq:rw
# vzctl set 109 --devnodes snd/timer:rw

The card is listed by asoundconf but I can't get it to work:
$ asoundconf list
Names of available sound cards:
Intel
$ asoundconf set-default-card Intel
$ amixer
amixer: Mixer attach default error: No such device

I thought I'd ask here before i go any further in case getting this to work in a VPS is a no-go...


Re: Accessing ALSA sound devices within VPS [message #35587 is a reply to message #35584] Tue, 07 April 2009 08:48 Go to previous message
Tenyo is currently offline  Tenyo
Messages: 5
Registered: November 2008
Junior Member
Yes it's possible.
I've a container acting as an MPD server for my lan.
I've used the same procedure working for giving hardware access to my usb printer and my tv card:

- disable (if present) udev in the container
- create with mknod an exact replica of all the sound devices in HN
- assign within the container conf file access to the devices

Looking at your --devnodes settings i noticed that you assigned permissions to the snd subdirectory but not to other devices in /dev like adsp, dsp, sequencer and so on... recheck your HN /dev directory.

Bye^^
Previous Topic: Quota on mounted fs
Next Topic: /dev inside container
Goto Forum:
  


Current Time: Mon Oct 07 22:26:32 GMT 2024

Total time taken to generate the page: 0.05448 seconds