Jump to content
  • 25

GPU Passthrough


Question

25 answers to this question

Recommended Posts

  • 2
Posted

Here is how I got GPU passthru to work.

First I logged into the trunas UI and went to System -> Shell
Once in the shell I ran a command to find my gpu slot and uuid

truenas_admin@YOUR-NAS[~]$ midclt call app.gpu_choices | jq

{
  "PCI_SLOT_VALUE": {
    "vendor": "NVIDIA",
    "description": "NVIDIA GeForce GTX 960",
    "vendor_specific_config": {
      "uuid": "GPU_UUID"
    },
    "pci_slot": "PCI_SLOT_VALUE"
  }
}


Then I ran a command to set those values in the plex app

truenas_admin@YOUR-NAS[~]$ midclt call -job app.update plex '{"values": {"resources": {"gpus": {"use_all_gpus": false, "nvidia_gpu_selection": {"PCI_SLOT_VALUE": {"use_gpu": true, "uuid": "GPU_UUID"}}}}}}'



SORRY I DID NOT CAPTURE THE OUTPUT

 

  • Like 2
  • 0
Posted
  On 12/4/2024 at 2:37 PM, Chris said:

Here is how I got GPU passthru to work.

First I logged into the trunas UI and went to System -> Shell
Once in the shell I ran a command to find my gpu slot and uuid

truenas_admin@YOUR-NAS[~]$ midclt call app.gpu_choices | jq

{
  "PCI_SLOT_VALUE": {
    "vendor": "NVIDIA",
    "description": "NVIDIA GeForce GTX 960",
    "vendor_specific_config": {
      "uuid": "GPU_UUID"
    },
    "pci_slot": "PCI_SLOT_VALUE"
  }
}


Then I ran a command to set those values in the plex app

truenas_admin@YOUR-NAS[~]$ midclt call -job app.update plex '{"values": {"resources": {"gpus": {"use_all_gpus": false, "nvidia_gpu_selection": {"PCI_SLOT_VALUE": {"use_gpu": true, "uuid": "GPU_UUID"}}}}}}'



SORRY I DID NOT CAPTURE THE OUTPUT

 

Expand  

just out of curiosity (as someone who isnt in the beta yet), the current TrueNAS version has a checkbox that handles the gpu passthrough and does this automagically by its own. i use this right now with my plex setup.

have you tried it? if not, its worth a shot for the rest of your app needs. i wonder if this breaks something in the HexOS interface (i don't think it should, but meh)

  • 0
Posted
  On 12/4/2024 at 7:51 PM, ysuissa said:

just out of curiosity (as someone who isnt in the beta yet), the current TrueNAS version has a checkbox that handles the gpu passthrough and does this automagically by its own. i use this right now with my plex setup.

have you tried it? if not, its worth a shot for the rest of your app needs. i wonder if this breaks something in the HexOS interface (i don't think it should, but meh)

Expand  

I tried the checkbox and would get some error so I googled it and this was the fix I came across. After that it was fine.

  • 0
Posted
  On 12/5/2024 at 12:32 AM, Chris said:

I tried the checkbox and would get some error so I googled it and this was the fix I came across. After that it was fine.

Expand  

After you did this can you still manage the app through HexOS? I haven't gotten to test setting up apps in TrueNAS directly and seeing if Hex sees them at all (I'd assume not), but edited apps I'm not sure of.

  • 0
Posted
  On 12/5/2024 at 6:37 PM, firrae said:

After you did this can you still manage the app through HexOS? I haven't gotten to test setting up apps in TrueNAS directly and seeing if Hex sees them at all (I'd assume not), but edited apps I'm not sure of.

Expand  

The settings button in HexOS just dumps you into the truenas settings for plex. I am not sure if it did that before or not.

  • 0
Posted

Gpu usage would also be nice, but from my understanding truenas scale dosen't even have a widget for this either on their dashboard. I do not recall if truenas core did been too long since I tried core. I now this is possible on unraid via gpu statistics plugin which would show usage, what apps, and vms that where utilizing in real time along with temps.

  • Like 1
  • 0
Posted

This would be awesome to be able to not only use a gpu but for multiple apps and maybe prioritizes for example if Plex is needing GPU it can take it completely aware from OpenUI while rendering stuff in real time.

  • Like 1
  • 0
Posted
  On 12/4/2024 at 2:37 PM, Chris said:

Here is how I got GPU passthru to work.

First I logged into the trunas UI and went to System -> Shell
Once in the shell I ran a command to find my gpu slot and uuid

truenas_admin@YOUR-NAS[~]$ midclt call app.gpu_choices | jq

{
  "PCI_SLOT_VALUE": {
    "vendor": "NVIDIA",
    "description": "NVIDIA GeForce GTX 960",
    "vendor_specific_config": {
      "uuid": "GPU_UUID"
    },
    "pci_slot": "PCI_SLOT_VALUE"
  }
}


Then I ran a command to set those values in the plex app

truenas_admin@YOUR-NAS[~]$ midclt call -job app.update plex '{"values": {"resources": {"gpus": {"use_all_gpus": false, "nvidia_gpu_selection": {"PCI_SLOT_VALUE": {"use_gpu": true, "uuid": "GPU_UUID"}}}}}}'



SORRY I DID NOT CAPTURE THE OUTPUT

 

Expand  

This ended up working for me! After running these commands though, I did have to go back into the TrueNAS UI and enable the 'Use this GPU' button.

  • Like 2

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...