[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [libvirt] PCI devices passthough to LXC containers using libvirt

Hi Daniel,

Thanks for the reply.

I am trying to access GPU devices from inside
the containers.

(Only way I know)For this I need to add the GPU device numbers in ACL/(device whiteist)
to get access to these devices  from inside the container.

I found that libvirt lxc driver currently allows set of devices while starting the container.

I have browsed through the libvirt lxc code and I believe there is no elegant way 
currently where you can request the devices to be allowed inside LXC container using the
usual libvirt xml file.CORRECT ME IF I AM WRONG.

Please provide your suggestions if any.

Thanks in advance


----- Original Message -----
From: "Daniel P. Berrange" <berrange redhat com>
To: "Devendra K. Modium" <dmodium isi edu>
Cc: libvir-list redhat com
Sent: Thursday, August 4, 2011 11:53:02 AM
Subject: Re: [libvirt] PCI devices passthough to LXC containers using libvirt

On Wed, Jul 27, 2011 at 02:13:13PM -0700, Devendra K. Modium wrote:
> Hi All
> Please let me know if anyone have given access to
> PCI devices for a LXC container.

What are you actually trying to achieve as your end result ?

PCI device assignment doesn't entirely make sense in the LXC world. Since
the container shares a kernel with the "host" OS, there's nothing to
really assign the PCI device to.

If you're trying to use a PCI NIC, then is the bridging/NAT setup not
sufficient ?

If you're trying to use a block device, I've got a patch which will
let libvirt's LXC code automatically mount any host block as a filesystem
inside the container at startup. Your next mail about cgroups device ACL
makes me think this is what you're trying todo...

If neither of these are suitable, then we could think about how to support
logical device assignment. ie assign a NIC, or assign a block device,
rather than assigning the PCI device proividing it.

|: http://berrange.com      -o-    http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org              -o-             http://virt-manager.org :|
|: http://autobuild.org       -o-         http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org       -o-       http://live.gnome.org/gtk-vnc :|

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]