The ultimate gaming virtual machine on proxmox

Sdílet
Vložit
  • čas přidán 27. 06. 2024
  • In this video I show you how to install and configure a proxomox virtual machine with gpu passthrough for all your creative needs!
    ######### Commands used #########
    lspci | grep -i nvidia
    lspci -v
    echo 'vfio-pci' > /etc/modules-load.d/vfio-pci.conf
    nano /etc/modules-load.d/vfio-pci.conf
    lspci -nn | grep -i nvidia
    echo 'options vfio-pci ids=10de:1d81,10de:10f2' > /etc/modprobe.d/vfio.conf
    nano /etc/modprobe.d/vfio.conf
    nano /etc/default/grub
    intel_iommu=on
    update-grub
    lsmod | grep vfio
    nano /root/iommu_group.sh
    ###### iommu script ######
    #!/bin/bash
    shopt -s nullglob
    for g in $(find /sys/kernel/iommu_groups/* -maxdepth 0 -type d | sort -V); do
    echo "IOMMU Group ${g##*/}:"
    for d in $g/devices/*; do
    echo -e "\t$(lspci -nns ${d##*/})"
    done;
    done;
    ######################
    chmod +x /root/iommu_group.sh
    /root/iommu_group.sh
    ###############################
    Virt-io drivers
    fedorapeople.org/groups/virt/...
    Windows 10 iso
    www.microsoft.com/en-ca/softw...
    ###### AMD cpus or single gpu machines ######
    Add the following to your grub configuration right next to intel_iommu=on
    A. Disabling the Framebuffer: video=vesafb:off,efifb:off
    B. ACS Override for IOMMU groups: pcie_acs_override=downstream,multifunction
    0:00 - vfio configuration
    2:58 - iommu configuration
    4:46 - bios settings
    5:48 - vfio validation
    6:37 - iommu validation
    7:49 - Windows vm creation
    11:13 - windows vfio drivers
    12:17 - gpu passthrough
    13:24 - nvidia driver installation
    14:59 - moment of truth
    15:25 - options for using the vm
    16:35 - vm vs baremetal benchmark
    #proxmox #gpubenchmark #debian #linux_tutorial #linux #gpupassthrough
  • Věda a technologie

Komentáře • 99

  • @AxeMask
    @AxeMask Před 7 dny

    Thanks dude! I've been tinkering about with this for the past few days and almost lost hope. Everything in your video was clear and concise and got me up and running. You earned my respect and my sub and if I wasn't poor I'd also give you money.

    • @distrodomain
      @distrodomain  Před 6 dny

      I'm glad it was helpful!, thank you for watching!

  • @mattfenderson948
    @mattfenderson948 Před 2 měsíci +1

    Youre the first video I could find that had nvidia cards, everyone else using amd, the grouping is what everyone is skipping and saved me thanks!

    • @distrodomain
      @distrodomain  Před 2 měsíci

      I'm glad it helped you, thank you for watching! :)

  • @kevinlegobrickmaster8015
    @kevinlegobrickmaster8015 Před měsícem +1

    been watching loads of videos some of which are over a year old and this is the first VM install I've seen that doesn't require us to manually swap the win10 ISO for the virtIO ISO. Dropped a sub look forward to seeing more while preparing for home network projects

    • @distrodomain
      @distrodomain  Před měsícem

      I'm glad you enjoyed it, thank you for watching!

  • @darthkielbasa
    @darthkielbasa Před 6 měsíci +12

    Proxmox is amazingly badass. If the steps you’ve outlined were added to the gui, PM could be unstoppable.
    Thanks for the content.

    • @distrodomain
      @distrodomain  Před 6 měsíci +3

      I'm glad you enjoyed it, I agree proxmox is badass! thank you for watching!

    • @SLTRM
      @SLTRM Před 5 měsíci +1

      Sorry was my mistake. The promox boot never freezes. It only change output to the integrated ATI graphic card. But my HDMI cable still connected to Nvidia. And look like boot stopped. But it not the case.

  • @MIKA-rz9fq
    @MIKA-rz9fq Před 5 měsíci +2

    Awesome video man!!

  • @randomdude12370
    @randomdude12370 Před 8 dny

    Cool video, just want to add that you can also use sunshine and moonlight for local gaming. Works great and i use it for my steam deck.

  • @noobreadyplayerone8969
    @noobreadyplayerone8969 Před měsícem +1

    Great guide on how to start Windows on proxmox and enable graphics. I'm using an RTX3050 and it works great.

  • @YofuMedia
    @YofuMedia Před 6 měsíci +1

    SO COOL!!!!!!!!!! thanks for sharing!!!

  • @davebilson
    @davebilson Před 5 měsíci +1

    Excellent tutorial and very timely as I want to try to virtualise my main Windows Desktop PC.
    I only use Windows for Adobe CC and Affinity Photo / Designer / Publisher, as I can use Linux or MacOS for other things. Also Windows 11 is not supported on my CPU - a Threadripper 1950x (16 Core, 32 Threads).

    • @distrodomain
      @distrodomain  Před 5 měsíci

      I'm glad you found it useful! Thank You for watching!

  • @BinaryOptimizer
    @BinaryOptimizer Před 5 měsíci +1

    thanks for such a great content

    • @distrodomain
      @distrodomain  Před 5 měsíci

      You are welcome, I'm glad you enjoyed it! thank you for watching :)

  • @adolv3x
    @adolv3x Před 5 měsíci +1

    Hey man, great video! Quick question, is it possible to share for example an RX 560 between 2 VM's in Proxmox? For example, I want to install Linux on one VM and MacOS?

    • @distrodomain
      @distrodomain  Před 5 měsíci

      You can share it with 2 vms, they just can't be turned on at the same time. thank you for watching :)

  • @JCCFlying
    @JCCFlying Před 3 měsíci +1

    Hi, Great explanation on configuring passthrough ( i'm new to this ) ... Having watched a few videos, I see that you didnt blacklist any drivers ?

    • @distrodomain
      @distrodomain  Před 3 měsíci +2

      Newer version of the kernel are able to load vfio driver in priority before any other drivers take over the device, so no need to blacklist although is a good practice if you encounter errors, thank you for watching! :)

  • @svanput
    @svanput Před 4 měsíci +3

    neat proof of concept! ive found passthrough to be buggy even when 100% "working". in my instance to complicate things i am using passthrough of e-gpu. at the end of the day i decided to go back to bare metal. if youre going to game youll need most of your storage and horsepower to get good experience anyway, for most modern games @60fps, which is really considered bare minimum for a good gaming experience. for a standard desktop install of a gpu it may be rock solid stable, but i still believe virtualization of a gaming pc, unless you can split the gpu up as well, has no real benefits for gaming. if you could add instructions for passthrough through an egpu you may save some poor person a day of troubleshooting! thanks for the content though!

    • @distrodomain
      @distrodomain  Před 3 měsíci

      Nothing beats bare metal, and there are some ways to split the gpu with grid but not super easy to setup, thank you for watching! :)

  • @YannMetalhead
    @YannMetalhead Před 8 dny

    Good guide.

    • @distrodomain
      @distrodomain  Před 6 dny +1

      Glad it was helpful! thank you for watching

  • @jothain
    @jothain Před 5 měsíci +2

    If you create another like Linux VM and bind the card the exact same way, in addition to Windows, will it work just fine? I suppose you can't use those simultaneusly, but invidually it would work?

    • @distrodomain
      @distrodomain  Před 5 měsíci +2

      Yes exactly you can't use both at the same time, as long as one vm is on at a time they can both have the same card, thank you for watching! :)

    • @jothain
      @jothain Před 5 měsíci +1

      @@distrodomain Thanks for clarifying. So it essentially just throws error to that event panel at bottom if one tries.

  • @SLTRM
    @SLTRM Před 5 měsíci +1

    Hello. What model of motherboard and cpu do you used in the video?. I tried a lot of tutorials of gpu and proxmox and never work. I suspect that work with very specific hardware.

    • @distrodomain
      @distrodomain  Před 5 měsíci

      The motherboard I'm using is Z170A Gaming Pro Carbon from msi, what are the issue you are encountering, I might be able to help you :)

    • @SLTRM
      @SLTRM Před 5 měsíci

      @@distrodomain I have a AMD Ryzen 5 4600G with motherboard gigabyte B450 aorus pro wifi, pci-e nvidia gigabyte 3060. When activate the echo 'vfio-pci' > /etc/modules-load.d/vfio-pci.conf and echo 'options vfio-pci ids=10de:2504,10de:228e' > /etc/modprobe.d/vfio.conf the computer not boot anymore. is stuck in "Loading initial ramdisk...". any idea what is happening?. My monitor need connected to integrated video card or to nvidia video card?.

    • @distrodomain
      @distrodomain  Před 5 měsíci

      open this file /etc/modprobe.d/vfio.conf with nano or vim, and make sure the contents are correct like this options vfio-pci ids=10de:2504,10de:228e, (wuth your corresponding gpu ids), do the same with /etc/modules-load.d/vfio-pci.conf and make sure the contents are just vfio-pci, once this is done, you are isolating the gpu this means that the kernel will load vfio driver on your gpu, so you won't have any image on your monitor or maybe the last image before the kerenl handled the gpu to vfio, test if your server pings and try connecting via ssh or web ui once you reboot, even if it's stuck at "Loading initial ramdisk..."., let me know if it works :)

  • @kellyvb9881
    @kellyvb9881 Před 5 měsíci +1

    GREAT video, I have a question tho, I am installing my win10 vm on a dell precision 7810 with 2 intel cpu's . I'm confused about loading the drivers for the hard drive. You say to use the amd64 folder and then the w10, BUT this is not an amd machine. what am I missing here

    • @distrodomain
      @distrodomain  Před 5 měsíci

      The amd64 refers to 64bit architecture is not spesifically the brand of the cpu, It's a bit confusing because It's a legacy nomenclature, Thank you for watching! :)

    • @kellyvb9881
      @kellyvb9881 Před 5 měsíci

      Thanks for the reply
      @@distrodomain

    • @kellyvb9881
      @kellyvb9881 Před 5 měsíci

      1 other question, don't understand how to tell if the pass thru is working. I see the correct GPU in device manager but I don't understand what input you changed. my display rez is 1200x800, shouldnt it be 1920x1080

    • @distrodomain
      @distrodomain  Před 5 měsíci

      If the driver is correctly installed you should be able to change the resolution on display settings, make sure you select the correct screen, since you might see more than 1, 1 for the nvidia card, the other for the virtualized display from the vm. let me know if that helps :)

  • @atlasv1238
    @atlasv1238 Před 5 měsíci +1

    Hello ty for the video! But I have a question can I do the same for a vm Ubuntu/flex?

    • @distrodomain
      @distrodomain  Před 5 měsíci +1

      yes you can passthrough the gpu to a ubuntu vm, just make usre you installed the corespoding driver in linux for the card. thank you for watching! :)

    • @atlasv1238
      @atlasv1238 Před 5 měsíci +1

      @@distrodomain thank you! Good luck!

  • @fevadevelopers7448
    @fevadevelopers7448 Před 5 měsíci +1

    Hi, is possible to Passthrough the IGPU? i have a mini pc with an Home Assistant VM and a new Ubuntu VM, my goal is to passthrough the IGPU with the Ubuntu VM, I have an Alder Lake-N95 pc, on the bios all settings are enabled like your, but i had no luck, can't figure out how to do, any advice is appreciated, thx

    • @distrodomain
      @distrodomain  Před 5 měsíci

      I have not tried to passthrough an igpu, but there's a good reading here wiki.archlinux.org/title/Intel_GVT-g , thank you for watching! :)

  • @ConectvideoBr
    @ConectvideoBr Před 2 měsíci +1

    We have a Xeon e5 2670 v3 processor and the motherboard doesn't even have integrated cards. We only have NVidia 1630.
    What would the grub edition quest look like?

    • @distrodomain
      @distrodomain  Před 2 měsíci

      The grub settings are the same if you have that cpu, just make sure iommu and vt-d or equivalent is enabled in your bios. thank you for watching! :)

  • @JamesWyseDotNet
    @JamesWyseDotNet Před 6 měsíci +1

    Great video! Would these instructions work with an AMD GPU as well? Looking at the Radeon RX 6700 XT..

    • @distrodomain
      @distrodomain  Před 6 měsíci +1

      Yes you can follow the same steps for amd cards, just make sure you get your pcie ids, and that you install the amd drivers in your windows vm, let me know if you have any issues, thank you for watching :)

    • @negocioslendarios
      @negocioslendarios Před měsícem

      @@distrodomain

    • @negocioslendarios
      @negocioslendarios Před měsícem

      Será que ele usa todo o poder na GPU ou não

  • @noobreadyplayerone8969
    @noobreadyplayerone8969 Před měsícem +1

    I have a question, do you have a guide to the integrated sound card?

    • @distrodomain
      @distrodomain  Před měsícem +1

      Not yet, but I'm planning out a new set of videos for this, the easiest part would be to use a pcie sound card, or using parsec built in audio, stay tuned and thank you for watching!

  • @specopbookie
    @specopbookie Před 3 měsíci +1

    5% performance hit using VM. Not too shabby at all!

    • @distrodomain
      @distrodomain  Před 3 měsíci

      Yea is pretty good if you have a beefy machine, thank you for watching!

  • @worldseriesofghosts3408
    @worldseriesofghosts3408 Před 3 měsíci +1

    I've been using Linux mainly via SSH for well over 4 years now, I am a c# and python programmer and currently working as an architect. I have windows modified to the point where Linux friends consider it the Linux of windows installs, for instance I replace explorer with directory opus, i use a sick indexer/filesearch/custom launcher called listary, and i really make windows my b*tch. But still, I know linux is the true definition of customizable. This was the video I really needed. My preferred for the past 2 years as been Arch, can you recommend me a desktop environment for arch or should I just go with somethin like xfce and call it a day? Thanks for reading and thanks for the video, I think it is time for me to commit to Arch, submit to Arch, and all mighty Prox Mox

    • @distrodomain
      @distrodomain  Před 3 měsíci

      If you want ultimate customaizable desktop experience, I would recommend a tiling window manager like i3,bspwm,Sway,Xmonad, and AwesomeWM, just beware you will go down a big rabbit hole configuring these ones, but you will learn a lot about linux by doing so, so I recommend it. thank you for watching! also here is my video on installing arch if you are intrested. czcams.com/video/Myihq26hJJo/video.html

  • @dr.sajjadmahmood86
    @dr.sajjadmahmood86 Před 4 měsíci +1

    I am installing proxmox 8 on dell precision t7910 with intel xeon 2683 v4, 64 GB RAM and rtx 3090 card but i am not able to install proxmox. It is not getting past the initial loading of drivers and it is stuck there for hours and not going to rest of installation setup.

    • @distrodomain
      @distrodomain  Před 4 měsíci

      When you load the installer and you see the blue grub menu press "e" and try adding some of these options to the boot command line "modprobe.blacklist=nouveau rd.driver.blacklist=nouveau nouveau.modeset=0 nomodeset" this will disable any nouveau driver in the installer, and you might be able to get to the installer, sometimes the nouveau driver in the installer has a hard time with newer gpus. Thank you for watching, let me know if it works :)

    • @dr.sajjadmahmood86
      @dr.sajjadmahmood86 Před 4 měsíci +1

      @@distrodomain thanks brother for reply. I saw your reply late, however i got it working first installing 7.4 then upgraded to 8.1. Moreover with your encouragment i was able to passthrough rtx 3090 to my vm, since other youtubers were saying that it is only possible to passthrough only older nvidia cards or amd cards.

  • @cyanoure
    @cyanoure Před 3 měsíci +1

    I have a vm with gpu passthrough, it runs fine, but after a longer run if I restart or shutdown my vm (through windows start menu), my entire host machine hangs and I have to power cycle it. I don't remember the messages on the CLI, it's something like "CPU #? stuck for ...".
    But if I just started the vm, I can restart/shutdown with no problem. It only stucks when it was running for a while.

    • @distrodomain
      @distrodomain  Před 3 měsíci

      I't might be something to do with the pcie reset the moment you turn off the vm, what hardware are you using? (motherboard/cpu)

    • @cyanoure
      @cyanoure Před 3 měsíci

      @@distrodomain It's a Dell Precision t7600 with 2x Intel Xeon E5-2643.
      I tried different slots and different GPUs.
      It doesn't have integrated graphics, but I use an older GPU as main display for the proxmox.

    • @cyanoure
      @cyanoure Před 3 měsíci

      ​@@distrodomain Can a memory problem cause errors like this? I'll check it later on, because sometimes there is a memory error correction warning at boot that I just ignored.

    • @distrodomain
      @distrodomain  Před 3 měsíci

      I would be intrested on the result , if this is the only gpu, you might need to disable the frambuffer in the grub config, check the description of the video for details but it's bsically this A. Disabling the Framebuffer: video=vesafb:off,efifb:off@@cyanoure

  • @nineteenmov
    @nineteenmov Před měsícem +1

    hi great video one question do you think lvm is best for performance and should we have a dedicated disk just for the windows vm ?

    • @nineteenmov
      @nineteenmov Před měsícem

      also what about disabling ballooning device

    • @distrodomain
      @distrodomain  Před měsícem +1

      lvm is good enough for vms, just keep in mind that is the drive that runs proxmox os too, If you have an additional ssd I would sugest having your vms in a separate disk for production use, for home use It won't change much, for the balloning device might give you a small boost in memory performace, but it will commit the full amount of ram on your host, thank you for watching!

  • @estqwerty
    @estqwerty Před 5 měsíci +1

    great video. but i cant get it working. is it possible my video card to be too old its nvidia gt210. i will be totaly happy if you make video for intel igpu from 6to 9th gen graphics. ok with gt210 at least i get the monitor to light up and shows prohmox boot only. but windows 11 in vm cant install the video - driver came with exclamation mark in vnovnc.

    • @distrodomain
      @distrodomain  Před 5 měsíci

      Maybe the gpu is not supported in win11 have you tried win10, maybe I'll work, do you get error 43 by chance?

    • @estqwerty
      @estqwerty Před 5 měsíci

      @@distrodomain yeah its code 43. same on win7. trying to figure it out.

    • @ilyarozental8338
      @ilyarozental8338 Před 5 měsíci

      @@distrodomain exactly, 43, any suggestions?

    • @distrodomain
      @distrodomain  Před 5 měsíci

      @@estqwerty check that the pci-express box is ticked under pci-e device in proxmox, is vfio and your iommu groups good?, make sure to pass all devices, or select all functions, let me know if that helps

    • @estqwerty
      @estqwerty Před 4 měsíci +1

      @@distrodomain got it running again with chis tutorial. it was defiantly too old nvidia. now tried again with 1070 and it worked first time. if you have first settings of proxmox or first things to do to setup will be happy to see the video.

  • @HusamNasrullah
    @HusamNasrullah Před 6 měsíci +1

    I changed the graphic adapter to IGD but now screen in proxmox is not working, I tried to switch hdmi cable from external gpu to mother as well not work , how to revert that 😢

    • @distrodomain
      @distrodomain  Před 6 měsíci +1

      Try turning the machine off, plug the hdmi to the mother board and turn the machine back on, you should be able to see the bios splash screen, if not you can try resetting the cmos, of you motherboard, let me know if works :), thanks for watching.

    • @HusamNasrullah
      @HusamNasrullah Před 6 měsíci +2

      @@distrodomain thanks it worked 😍, I love you man you saved my life ❤️❤️

    • @distrodomain
      @distrodomain  Před 6 měsíci

      @@HusamNasrullah I'm glad it worked :)

  • @darthkielbasa
    @darthkielbasa Před 6 měsíci +2

    13:38
    NVclean Install for a lighter driver installation

    • @distrodomain
      @distrodomain  Před 6 měsíci +1

      I'll keep that in mind thank you for the sugestion :)

  • @nicholaushilliard6811
    @nicholaushilliard6811 Před 4 měsíci +1

    Ty bro

    • @distrodomain
      @distrodomain  Před 4 měsíci

      You are welcome!

    • @jirehla-ab1671
      @jirehla-ab1671 Před 4 měsíci +1

      ​@@distrodomainare grub files & other linux configs are cross compatible across linux distributions?

    • @distrodomain
      @distrodomain  Před 3 měsíci

      for most distributions yes, some change the format a little bit, but it's basically the same, thanks for watching! :)

  • @cd819
    @cd819 Před 3 měsíci +1

    My proxmox server uses 50watt more power when the vm is off got any idea's on how to fix it ?

    • @distrodomain
      @distrodomain  Před 3 měsíci

      I'm not sure what could be causing that, what is the hardware that you are using?

    • @cd819
      @cd819 Před 3 měsíci

      cpu amd 5800x
      asus tuf x570-plus motherboard
      gpu asus tuf 6800xt
      64gb ram
      @@distrodomain

  • @FlipsydTech
    @FlipsydTech Před 21 dnem +1

    How can I pass through different nodes on different gpu ports.

    • @distrodomain
      @distrodomain  Před 20 dny

      You can only pass through devices on vm running on that node, IF you have multiple pcie devices in 1 node, if the vm is running in that node you can pass them through. Thank You for watching!

  • @ersguteralbaner188
    @ersguteralbaner188 Před 24 dny +1

    Does wsl2 work on the Windows VM?

    • @distrodomain
      @distrodomain  Před 20 dny

      Yes it should work like any other windows installtion, thank you for watching!

  • @FelixLantiguaCamacho
    @FelixLantiguaCamacho Před 5 měsíci +1

    Talking a lot make some people more confusing

    • @distrodomain
      @distrodomain  Před 5 měsíci

      Thank you for the feedback, do you have any questions about the setup? :)

  • @ewenchan1239
    @ewenchan1239 Před 5 měsíci +1

    If you run nvidia-smi -- does the details of the card show up properly?
    I tried passing through a Nvidia RTX A2000 6 GB to a CentOS VM, and in there -- when I type in nvidia-smi -- it doesn't recognise that the GPU is there, even though I was able to install the driver for it and everything.
    Thanks.

    • @distrodomain
      @distrodomain  Před 5 měsíci

      Check with "lspci | grep -i nvidia" or with "lshw -c display" to see if the gpu is detected by the vm, if it is you can check which driver is loaded, you might need to black list nouveau on the centos vm too, let me know if that works, Thank you for watching!

    • @ewenchan1239
      @ewenchan1239 Před 5 měsíci +1

      @@distrodomain
      Thank you.
      Yup, I ran those diagnostic checks and the VM is able to "see" the video card that was passed through.
      (If the VM wasn't able to see said video card, the Nvidia driver will not install.)
      And yes, I did blacklist nouveau and mgag200 in my standard deployment notes, in CentOS.
      Thank you.

    • @distrodomain
      @distrodomain  Před 4 měsíci

      What error do you get when you do nvidia-smi, or it's just not showing there? if you do lshw -c display do you see this under configuration "configuration: driver=nvidia latency=0" or similar, on the vm settings did you pass through all devices and also selected pci-express on the settings. also check with lsmod | grep nvidia to see if the nvidia kernel module is being loaded, I feel is a small bug somewhere.

    • @ewenchan1239
      @ewenchan1239 Před 4 měsíci

      @@distrodomain
      I don't remember because it's been a while (and said RTX A2000 is currently in my HP Z420 workstation as a result of this "error").
      But if my memory serves, the "error" that I was getting was that by passing through the GPU, I expected that the RTX A2000 would show up in nvidia-smi, but it was wholly absent.
      And I was only checking nvidia-smi because in the application (CFD/HPC/CAE application) wouldn't detect the GPU, so that's when I started trying to run the diagnostics to try and find/figure out why.
      So, unfortunately, the server is not in a state where I can power down the server, to put said RTX A2000 back in; for me to run the test again to get the screenshots.
      In the Proxmox settings, all functions were passed through and the checkbox for it being a GPU and a PCIe device were both checked as well.
      It'll be a while before both systems will be in a state where I will be able to pull the GPU out, for it to be reinstalled into said server, so I can re-run the test.
      Thanks.