Howdy, I am playing around with asterisk within an LXC container on Ubuntu 11.04. I have asterisk (1.4.42) running fine, but want access to dahdi_dummy for timing (meetme). I have dahdi installed on the "host", and dahdi_dummy is loaded: root at astnorth:/# ls -ltr /dev/dahdi total 0 crw-rw---- 1 root root 196, 250 2011-06-08 13:59 transcode crw-rw---- 1 root root 196, 253 2011-06-08 13:59 timer crw-rw---- 1 root root 196, 255 2011-06-08 13:59 pseudo crw-rw---- 1 root root 196, 0 2011-06-08 13:59 ctl crw-rw---- 1 root root 196, 254 2011-06-08 13:59 channel root at astnorth:/# But in the container I don't see them: root at artha:/# ls -ltr /dev/dahdi total 0 even though /dev/dahdi showed up as soon as I loaded the kernel module in the host. Maybe this is more a question for an LXC list, but I noted that a few people had played with this (asterisk in LXC) and wondered if anyone managed to get dahdi_dummy shared across their containers... Thanks for any input, -- Jeff LaCoursiere SunFone 340-715-7600 x222 jeff at sunfone.com
On Wed, 8 Jun 2011, Jeff LaCoursiere wrote:> > Howdy, > > I am playing around with asterisk within an LXC container on Ubuntu 11.04. I > have asterisk (1.4.42) running fine, but want access to dahdi_dummy for > timing (meetme). I have dahdi installed on the "host", and dahdi_dummy is > loaded: > > root at astnorth:/# ls -ltr /dev/dahdi > total 0 > crw-rw---- 1 root root 196, 250 2011-06-08 13:59 transcode > crw-rw---- 1 root root 196, 253 2011-06-08 13:59 timer > crw-rw---- 1 root root 196, 255 2011-06-08 13:59 pseudo > crw-rw---- 1 root root 196, 0 2011-06-08 13:59 ctl > crw-rw---- 1 root root 196, 254 2011-06-08 13:59 channel > root at astnorth:/# > > But in the container I don't see them: > > root at artha:/# ls -ltr /dev/dahdi > total 0 > > even though /dev/dahdi showed up as soon as I loaded the kernel module in the > host. > > Maybe this is more a question for an LXC list, but I noted that a few people > had played with this (asterisk in LXC) and wondered if anyone managed to get > dahdi_dummy shared across their containers...It works very well for me. However I don't use udev and /dev is statically created like in the good old days. Gordon
On Wed, Jun 08, 2011 at 05:32:34PM -0400, Jeff LaCoursiere wrote:> > Howdy, > > I am playing around with asterisk within an LXC container on Ubuntu > 11.04. I have asterisk (1.4.42) running fine, but want access to > dahdi_dummy for timing (meetme). I have dahdi installed on the "host", > and dahdi_dummy is loaded: > > root at astnorth:/# ls -ltr /dev/dahdi > total 0 > crw-rw---- 1 root root 196, 250 2011-06-08 13:59 transcode > crw-rw---- 1 root root 196, 253 2011-06-08 13:59 timer > crw-rw---- 1 root root 196, 255 2011-06-08 13:59 pseudo > crw-rw---- 1 root root 196, 0 2011-06-08 13:59 ctl > crw-rw---- 1 root root 196, 254 2011-06-08 13:59 channel > root at astnorth:/# > > But in the container I don't see them: > > root at artha:/# ls -ltr /dev/dahdi > total 0 > > even though /dev/dahdi showed up as soon as I loaded the kernel module in > the host. > > Maybe this is more a question for an LXC list, but I noted that a few > people had played with this (asterisk in LXC) and wondered if anyone > managed to get dahdi_dummy shared across their containers...Maybe you need to enable the guest to access those devices? In the lxc guest conf file, you should probably have omething like: lxc.cgroup.devices.allow = c 196:0 rwm # /dev/dahdi/ctl lxc.cgroup.devices.allow = c 196:253 rwm # /dev/dahdi/timer lxc.cgroup.devices.allow = c 196:254 rwm # /dev/dahdi/channel lxc.cgroup.devices.allow = c 196:255 rwm # /dev/dahdi/pseudo # For the record: you don't probably don't need the following one: #lxc.cgroup.devices.allow = c 196:250 rwm # /dev/dahdi/transcode -- Tzafrir Cohen icq#16849755 jabber:tzafrir.cohen at xorcom.com +972-50-7952406 mailto:tzafrir.cohen at xorcom.com http://www.xorcom.com iax:guest at local.xorcom.com/tzafrir
>> >> Howdy, >> >> I am playing around with asterisk within an LXC container on Ubuntu >> 11.04. I have asterisk (1.4.42) running fine, but want access to >> dahdi_dummy for timing (meetme). I have dahdi installed on the "host", >> and dahdi_dummy is loaded: >> >> root at astnorth:/# ls -ltr /dev/dahdi >> total 0 >> crw-rw---- 1 root root 196, 250 2011-06-08 13:59 transcode >> crw-rw---- 1 root root 196, 253 2011-06-08 13:59 timer >> crw-rw---- 1 root root 196, 255 2011-06-08 13:59 pseudo >> crw-rw---- 1 root root 196, 0 2011-06-08 13:59 ctl >> crw-rw---- 1 root root 196, 254 2011-06-08 13:59 channel >> root at astnorth:/# >> >> But in the container I don't see them: >> >> root at artha:/# ls -ltr /dev/dahdi >> total 0 >> >> even though /dev/dahdi showed up as soon as I loaded the kernel modulein>> the host. >> >> Maybe this is more a question for an LXC list, but I noted that a few >> people had played with this (asterisk in LXC) and wondered if anyone >> managed to get dahdi_dummy shared across their containers... > > Maybe you need to enable the guest to access those devices? > > In the lxc guest conf file, you should probably have omething like: > > lxc.cgroup.devices.allow = c 196:0 rwm # /dev/dahdi/ctl > lxc.cgroup.devices.allow = c 196:253 rwm # /dev/dahdi/timer > lxc.cgroup.devices.allow = c 196:254 rwm # /dev/dahdi/channel > lxc.cgroup.devices.allow = c 196:255 rwm # /dev/dahdi/pseudo > # For the record: you don't probably don't need the following one: > #lxc.cgroup.devices.allow = c 196:250 rwm # /dev/dahdi/transcodeThat was indeed the ticket - I now have dahdi shared across all the containers. Now going to run some meetme test ;) Thanks Tzafrir! -- Jeff LaCoursiere SunFone 340-715-7600 x222 jeff at sunfone.com
Hi, Does it make sense to use LXC as mean to quickly switch from one dahdi version to another or shall other virtualization technologies be preferred ? Cheers -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20110612/a24cb6a4/attachment.htm>
On Sun, Jun 12, 2011 at 11:56:52AM +0200, Olivier wrote:> Hi, > > Does it make sense to use LXC as mean to quickly switch from one dahdi > version to another or shall other virtualization technologies be preferred ?LXC is basically the same as OpenVZ and Linux-VServer (and probably like Solaris Zones and FreeBSD Jails): The processes of the guest still run inder the same host (specifically: share the same kernel). LXC (or rather: cgroups) is now prt of mainline kernel. From palying with it on Debian Squeeze, it feels still a bit immature (and even more so: lacking documentation). But as the usage of cgroups grows in the coming years (e.g.: in systemd), I would expect to see it more and more common. KVM, Xen, VMWare and the likes "emulate" a complete virtual machine. Not just a set of processes. Specifically, your processes run on top of their own kernel. This requires more resources, but provides better isolation. -- Tzafrir Cohen icq#16849755 jabber:tzafrir.cohen at xorcom.com +972-50-7952406 mailto:tzafrir.cohen at xorcom.com http://www.xorcom.com iax:guest at local.xorcom.com/tzafrir