S
S
Sergey2017-01-15 08:37:48
linux
Sergey, 2017-01-15 08:37:48

How to use graphics card in LXC container?

I recently moved my home server from Hyper-V to Proxmox.
In order not to waste resources on virtualization, I want to run OpenMediaVault in an LXC container, but I can’t find instructions anywhere for forwarding a video card to a container ( as in KVM , for example ).
Tell me how to enable applications in LXC to use the video card for video decoding?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
M
Melkij, 2017-01-15
@LiS-31

The underlying focus is that LXC is a container, not a virtual machine. Therefore, it is necessary not to forward the video card, but to allow access to it.
For example, from Google an example for nvidia: sqream.com/setting-cuda-linux-containers-2
Please note that the driver must be installed both on the host system and in the container itself. Moreover, emnip, strictly one version, tk. the driver from the container will communicate with the kernel module of the host system.
PS: theory. In my practice, I did not figure out how to give the built-in intel gpu to the container, with an active radeon discrete on the host system.

A
Alexander, 2017-01-15
@asand3r

I have never thrown a video card into the container, but devices are added to the container through
Maybe the same with the GPU? ..

M
Maxim Moseychuk, 2017-01-15
@fshp

I had no business with LXC, but I solved a similar problem for docker. It all comes down to forwarding the device file from /dev to the guest and installing the driver.
https://gitlab.com/ksicorp/aladdin-docker

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question