I noticed that setting gpu delegation to container via gpu and nvidia.runtime: "true" is not complete as it lacks the directory /proc/driver/nvidia/gpu mount from the host.
moreover when i added this mount via:
nvdock1:
path: /proc/driver/nvidia/gpus
source: /proc/driver/nvidia/gpus
type: disk
cuda started to work correctly but after restart of the guest it seems that this disk is attempted to be mounted before the essential part of the gpu/nvidia delegation is run, so in result it is not mounted as it should.
questions are two:
why /proc/driver/nvidia/gpus is not included in nvidia.runtime?
or
how to defer mounting ‘/proc/driver/nvidia/gpus’ disk after the nvidia.runtime is started?
Hi @RandomUser,
What do you want to achieve? Have you ever add the nvidia gpu to container? Have you checked the directory /dev on the container after adding the gpu device?
Have a look at that video, please. Nvidia video
Regards.
I think my post was clear, the directory /proc/driver/nvidia/gpu is missing from the container. I want to permanently add it to allow CUDA programs to run.
Yeah, the /proc stuff is managed by nvidia-container (when nvidia.runtime=true).
Incus does tell what GPUs we care about though so I’m not sure why it doesn’t provide the correct entries.
You may want to play around with maybe specifying what GPU you want by PCI address as that may help the nvidia scripts figure it out better?