Proxmox vGPU Gaming Tutorial - Share Your GPU With Multiple VMs!

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments

I immediately saw this and it's what I have been waiting/hoping for for MONTHS

👍︎︎ 9 👤︎︎ u/digitizedhermit 📅︎︎ Jul 06 2021 🗫︎ replies

"As always, iiiiiiiiiiiimmmmm jjjjeeeeeeeeeefffffffffff"

Thanks Jeff, another great video!

👍︎︎ 6 👤︎︎ u/CanadianButthole 📅︎︎ Jul 06 2021 🗫︎ replies

Many thanks for taking the time. Excellent tutorial

👍︎︎ 3 👤︎︎ u/dean1969cox 📅︎︎ Jul 06 2021 🗫︎ replies

This sounds like cool stuff, what are some practical use cases that you guys are going to be using this for?

👍︎︎ 1 👤︎︎ u/In000 📅︎︎ Jul 06 2021 🗫︎ replies

Can you install CUDA and CUDNN in a VM with a vGPU?

👍︎︎ 1 👤︎︎ u/VAL9THOU 📅︎︎ Jul 07 2021 🗫︎ replies
Captions
and finally the video you have all been waiting for how can you set up your own personal cloud gaming server today i'm going to walk through the instructions step by step on getting vgpu and proxmox set up and distributing cpu and gpu power to multiple thin clients at the same time welcome to two gamers one gpu the tutorial looking for a mechanical keyboard to upgrade your desk the z15 keyboard from evga is a perfect match for any setup with a professional looking aluminum backplate and perky rgb lighting to spice things up available with your choice of kale linear or clicky switches the hot swappable design makes it the perfect gateway into the world of custom keyboards where you'll spend every waking moment obsessing over your next switch upgrade which lubricant to use on your stabilizers and oh my god that is the best keycap set i have ever seen did i mention it comes with a magnetic wrist rest check out the z15 keyboard at evga.com or follow the link down in the video description welcome back to craft computing everyone as always i'm jeff starting off let's talk about what this project is and more importantly what this project isn't we'll go over both the hardware and software requirements for setting up gpu sharing inside of proxmox and some pros and cons against proxmox versus gpu para virtualization on windows hyper-v and don't worry there's a full tutorial on that one coming out shortly as well so what are we building today with proxmox using nvidia vgpu we're going to create multiple virtual machines and be able to share the resources of a single graphics card today's system will be configured and accessed only through thin clients such as a raspberry pi chromebook or another pc this server is not going to be designed to be used as a desktop computer by a local user but if you're looking for a linux desktop with a windows virtual machine thrown in on the side with full gpu acceleration that's also another tutorial i'm working on right now so make sure you're subscribed so you don't miss anything coming up on the channel the good news about all this is the hardware requirements aren't all that exotic your motherboard and cpu both need to support pci express passthrough also known as iommu intel systems refer to this as intel vtd while amd says amd i o mmu if you're not sure about your particular system supporting this refer to the documentation that came with your motherboard you want to make sure you have i o mmu or intel vtd enabled in the bios of your motherboard and don't ask me if your particular hardware supports it or how to turn it on the comment section of this video doesn't work nearly as well as a google search bar for the graphics card today's method is an nvidia only affair so sorry amd fans you're gonna have to sit this one out specifically you will need a card from the maxwell pascal volta or touring lineup unfortunately consumer amp your cards are not yet supported now while just about any card from these families will work keep in mind that the amount of video memory you have will dry up pretty quickly this is because gpu sharing is done through nvidia's vgpu profiles these profiles define the amount of memory dedicated to each virtual machine and must be split evenly for example a pascal gpu can have the following profiles available ranging from 1 to 24 gigabytes each when running vgpu you can only select a single vgpu profile to share out with your virtual machines at a single time so if you have an 8 gigabyte gtx 1080 you can choose a single eight gigabyte profile two four gigabyte profiles for two gigabyte profiles or eight one gigabyte profiles it's not possible to mix and match with a single four gigabyte vm and to two gigabyte vms when choosing your gpu for sharing keep this in mind as the more memory available on the card the more virtual machines you'll be able to run at the same time gpu power is a little bit more dynamic if you have that same gtx 1080 split into two four gigabyte profiles but only one of the vms is actively rendering that vm can use up to one hundred percent of the gpu's power but with only four gigabytes of video memory instead of the full eight if two vms are actively using 3d rendering applications the power will be split evenly between them finally we're going to be installing all of this on proxmox pve 6.4-1 if you've never installed proxmox it is a fairly straightforward process i do have a full tutorial linked down in the description if this is all new to you i recommend making sure you install proxmox as an efi operating system as it will make creating vms a lot more reliable when using vgpu profiles so step one is obviously to create a proxmox boot usb and install proxmox luckily it's already installed so that saves us tons of time once you have proxmox installed on your system and any storage you want to set up we can go ahead and get started we're going to be doing most of today's setup over ssh as there's a fair bit of copy and pasting to do the first step is to install all of the dependencies we're going to need all together we need to install git python 3 dkms pve headers for proxmox build essential jq along with the vgpu unlock script and mdev ctl for vgpu installation i've opened up a new ssh session and the first step is to actually add a new repository into proxmox so we're going to nano slash etc slash apt slash sources dot list this is the repository for proxmox itself specifically the pve kernels that we're going to need to compile a couple of pieces of software later on as the standard debian repository doesn't actually include pve headers inside a nano we're going to hit ctrl x to exit y to save and then enter to confirm the file name next up we're going to do an apt update to download all the new package information from our repositories then we're going to type at y upgrade by the way you will want to do this on a 100 clean installation of proxmox as there are a number of things that can go wrong during this installation causing you to wipe the entire system and have to start over ask me how i know so make sure you have a clean and solid proxmox or at the very least a recent backup of all your configurations so you can restore them if necessary next up we'll install all of our required dependencies so that is going to be apt-y install python3 python3pip git build essential pve headers dkms and jq and depending on your internet this will take two to five minutes to complete next up i do need one additional component inside of python and that is frida so pip three install frida now right here i'm going to demonstrate one thing that went wrong for me and one thing that fixed it for me that makes absolutely no sense at all and i'm going to try to demonstrate both and kind of see if it works out first off we're going to download the git repository for the vgpu unlock so that is git clone and then the url for the vgpu unlock script and go ahead and hit enter now i've gone ahead and connected with winscp which is a file transfer utility over ssh so i'm looking at the root directory right now and you can see there's the vgpu unlock script that i downloaded from git i'm going to go ahead and rename that vgpu unlock underscore get now i'm also going to copy over this vgpu unlock called vgpu unlock old now to be totally transparent these are the same exact files i actually went by line by line and had a couple different programs analyze them they are line for line and character for character identical but for some reason when i use the git clone command to download directly from git to the server regardless of any permission changes or creating executable files or whatever else that i did my compilation of the vgpu script would fail when i downloaded from git rather than downloading to my pc first unzipping and then copying over using winscp same files two very different results so i'm going to demonstrate both of them and we'll see if one of them fails and one of them works just in case this happens to you i'm going to download one other file and that is the mdev ctl file so that is done with the wget command to the following address we'll go ahead and download that and again it's a very small application and only takes about a second with everything downloaded there's only a couple more commands that we need to run first off we're going to run chmod dash capital r for recursive plus x to make executable vgpu underscore unlock now this will apply to the directory which will make everything underneath that directory executable which is required for this to work properly next up we're going to install the mdev ctl utility so that is done with dpkg-i and then mdev ctl followed by the version number that you have in this case it's 0.78-1 most of the software components out of the way now we move on to the hardware setup specifically vgpu relies on pci express passthrough so we need to enable iommu inside proxmox for everything to work properly first up we're going to do a nano etc default slash grub and we're going to modify the following line grub command line linux default equals quiet i like to comment out any line that i'm modifying and then paste in the actual line that i need in this case i'm going to type in grub command line linux default equals and then in quotes quiet amd i o mmu equals on and io mmu equals pt if you have an intel based system that line is going to read pretty much identically but just replace amd with intel other than that the commands are identical and yet again go ahead and save and exit so control x y and enter then we're going to type in update dash grub to apply those changes for mmu to actually work we also need to load some vfio modules so we're going to go nano slash etc modules and then we're going to paste the following four lines so it's going to be vfio vfio mmu type 1 vfiopci and vfiovir qfd and again save and exit and just four more commands to go we can give the system a reboot and move on to the nvidia installation first up we need to add vfio i o mmu type 1 to allow unsafe interrupts and that is done with an echo command similarly we're going to tell kvm to ignore any potential errors that come up on boot and then we're also going to blacklist the nuvo driver as we don't want that overriding the nvidia driver that we will be installing that enables vgpu everyone on the same page so far good by the way this text file is down in the video description and to apply those changes we're going to type in update dash init ramfs and then dash u with that taken care of let's go ahead and give this system a reboot when your system is back up and running we do need to verify that io mmu is running so we can move on to the next step and that is a pretty simple command we're going to type in dmesg followed by a pipe and then grep dash e d-m-a-r-e-i-o-m-m-u and you should get something that looks kind of similar to this where it defines some i o mmu groups and tells you that i o mmu is working this will look different depending on what system you have and again amd and intel both show up very different ways if you get no output that's a problem go back and check all of your work and then come back to this point so you can catch up if you do get some text that spits out from those lines we're probably good to move on to the nvidia installation assuming you're still with me now we need to get to the nvidia v gpu driver installation vgpu drivers are not available from the nvidia website instead you'll need to create an enterprise account and request a grid or vgpu demo license this will typically take nvidia a day or two to respond to the request and no i can't post the links to these drivers here because distributing them is technically not allowed once you have an account set up you'll need to download the package that we need head on over to the nvidia licensing portal and then go over to the left hand side and click on software downloads you'll need to click on the all available packages because for some reason nvidia likes to feature some graphics packages here but they're all for zen server running very very outdated software so click on all available then we're going to go over to the product family drop down and select vgpu which is the only option but you need to select an option so you can move on to the next drop down window on platform we're going to select linux kvm under platform version we're going to select all supported and finally under product version we're going to select the highest package that is available now they do list several packages that are not available for our particular platform so great job nvidia on the whole sorting feature the highest available package for linux kvm at this time is 11.1 so i'm gonna go ahead and click on that and you can see our package right here lasts updated in september of 2020 and go ahead and click on download the zip file will look a little something like this with a whole bunch of pdf documents a couple of windows executables and two linux executables the main file that we're concerned with right now is the vgpu kvm.run file this is the actual host driver that will be installed onto our proxmox server so yet again logging in with winscp i'm just going to drag and drop the nvidia vgpu kvm.run file into the root home directory and that should be all of the file browsing that we need to do so go ahead and close out of that that should now be everything we need to make all of this work now we do need to make the nvidia installer executable just like the vgpu unlock script so we're going to type in chmod plus x and then nvidia followed by the version that you have in this case it is 450.88 by the way a quick little secret if you're working with the linux command line for the first time if i type in chmod plus x but then i have a very long and obscure file name like nvidia linux x86 underscore 64-450 i don't need to type in that whole entire string all i need to do is type in the first couple of characters and then hit tab and the command line will autofill the rest of the file name for you and by the way this works inside of windows and powershell as well so tab is your best friend when working in the command line and it's finally time let's go ahead and install the nvidia vgpu driver but we're not just going to execute the vgpu driver we do need to add something to the end of it so we're going to type in dot and then forward slash which means execute or run then we're going to type in the name of the nvidia driver again just hit tab to auto complete it we're going to type in two dashes and then dkms to install this driver as a kernel module would you like to register the kernel module sources with dkms why yes i would and hopefully you should see installation of the nvidia accelerated graphics driver for linux is now complete and go ahead and hit ok to exit with the drivers installed we're finally to the secret sauce portion of this video and that is plugging in the nvidia vgpu unlock script the process is fairly straightforward as we just need to modify a couple files but these files can be in different locations depending on which kernel version distribution or version of linux that you happen to be running remember this tutorial is for proxmox 6.4 only if you're using a different version the path to these files may be different the first file is the nvidia vgpud.service file and that is located under usr slash library systemd system so go ahead and nano to that file and then hit enter and the line in question is this execute start so i'm going to comment that line out and we're going to add a hook in before that and that is going to be execute start slash root slash vgp unlock slash vgpu unlock which is the path to the vgpu unlock script itself then we're going to forward that to slash bin slash nvidia vgpud and again copy and paste everything below don't just listen to the words that i'm saying because you'll get as lost as i did so again close and save now inside proxmox there are actually two instances of the vgpud.service file and i'm not sure which one is actually used and if the other one is not or if they're both used or what's going on so i went ahead and modified both and the second file is located under usr slash library slash nvidia systemd and then slash nvidia vgpud.service and inside this one we're going to do the same exact thing so i'm going to comment out the execute start line and we're going to copy in execute start and then the path to the vgpu unlock script followed by the executable for vgpud and again save and quit we have one more file with two identical instances and they're in the same directories but this time it is the vgpu-manager.service so again we're going to modify that in both locations pretty much the exact same way so i'm going to comment out the execute start line and then paste in starting with the vgpu unlock and then forward slash to the executable for vgpu dash manager and exit and save and second time same as the first comment out paste that in exit and save to apply those changes we're going to type in system control daemon reload all right just two more files and we are ready to go the first one is the os dash interface dot c file and in proxmox that is located at user source nvidia dash version so 450.80 nvidia os interface we have one line to add to this file and it is here at the bottom of the include statements we are going to include again to the path of the vgpu unlock script vgpu unlock hooks dot c and go ahead and exit and save and we're on to the last file and that is the nvidia dot k build file located in user source slash nvidia version number slash nvidia so same exact directory and for this file we're going to go all the way to the bottom and simply paste this line right here and that is ld flags dash y plus equals dash t and then forward slash root v gpu unlock and then kern ld and again exit and save and for the last step on this side of things and that is we actually have to uninstall the nvidia kernel module and then reinstall it with the changes we just made so we're going to type in dkms remove dash m for module nvidia v for version 450.80 which is the nvidia driver version and then dash dash and all now to reinstall it again we type in dkms this time install dash m nvidia v 450.80 and press enter and hopefully at the bottom you will see dkms install completed which means we are finally good to start configuring our virtual machines go ahead and reboot your server and i'll see you back here in just a second with proxmox backup we're going to make sure the vgpu drivers and unlock script are all running as expected since we installed the vgbu drivers as a kernel module they should show up under dmesg go ahead and type in dmesg into your console and hit enter and we're looking for the line bgpu unlock patch apply and you can see that right down here in my session curling up just a little bit further you can see the gpu we unlocked is at pci bus address 42 colon zero zero we will need that information as well moving forward if you didn't get this output do go back and double check your work and i'll also be going over the little bit of frustration that i had at the end of this video when i downloaded directly from the git repository onto proxmox using git clone rather than downloading onto a windows machine first and then transferring the files over again files are identical results were not you can also confirm the nvidia driver is running as expected by typing in nvidia smi this will show the current status of your gpu and will use it to view the status of any vgpu profiles we've installed you can also use it to view current temperature load information fan speed and available memory on any nvidia graphics cards you have installed in your system and we are almost to the finish line now it's time to split your gpu into smaller chunks for today's video i'm rocking an nvidia rtx 2080 which has eight gigabytes of video memory as stated before we need to split the gpu into equal size chunks so that means two four gigabyte profiles or four two gigabyte profiles depending on your needs for your then clients and as a reminder we're not able to mix and match different size profiles on the same graphics card to view the available profiles on your particular gpu type in mdev ctl space types this will spit out a very long list of options each of them with slightly different memory sizes and properties the first couple characters indicate the card model the vgpu profile is from in this case the rtx 6000 a is for virtual applications b is for virtual desktops c for training or machine learning workloads and q is for virtual workstations we're actually interested in q as that enables all of the rasterization instructions we'll need for gaming like directx vulcan and opengl as well as envinc for video encoding alongside those profile names is a unique name for each profile and i know that sounds redundant and it very much is but it will make sense in just a second so today we are interested in the rtx 6000-4q profile otherwise known as the nvidia-259 this will allow us to run up to two virtual machines with four gigabytes of memory each again because that profile has four gigabytes of memory if you wanted to run two gigabytes per vm and run a total of four machines you could opt for the rtx 6000-2q otherwise known as the nvidia 257 each gpu architecture and sometimes even different cards within that architecture have their own specific vgpu profiles so don't necessarily copy mine unless you happen to be using an rtx 2080 you will need to find the profile that matches your particular card now for the part that does get a little bit tricky as we need to individually create each vgpu profile complete with its own uuid or universally unique identifier those uuids will be used to attach each vgpu profile to its corresponding virtual machine there are a number of ways to make your own uuids but i used uuidgenerator.net as it allows you to create them in bulk and download them as a text file which makes this next step infinitely easier since i'm creating two vgpu profiles i'll need two uuids so i'm going to type in a2 to the how many right here and hit generate and then download the file now i'm going to save that i'm going to save that as v4 underscore uuid no reason at all once you have the file downloaded go ahead and open it up and we can move on to actually creating a script to create these vgpu profiles first up i'm going to comment out the two uuids and rename them as quadro 1 and quadro 2. go ahead and create a new line and the first command is going to be mdev ctl start dash u followed by the uuid of choice so in this case we're going to select the first one and paste it in there after the uuid we're going to type in a dash p and this is where we need the pci express bus location of our particular graphics card remember that item i said to save earlier so in this case my cart is located at bus 42 and that looks like zero zero zero zero colon 42 colon zero zero dot zero and lastly we need to define the type of vgpu profile we'll be using so dash dash type and then nvidia 259 and we're going to copy that line and paste it right below only this time we're going to change the uuid to our second card and one last command for each card so mwctl actually remembers these we're going to type in mdev ctl define dash dash auto dash dash uuid followed by the uuid of each of our graphics cards and your file should look something like this right now i'm going to go ahead and save that and we'll minimize that and come back to it later with my gpus defined it is finally time to start building virtual machines and almost finish this thing up so here comes the home stretch first up we're going to create a new virtual machine we're going to leave the vm id as 100 for right now and i'm going to name this one vgpu-01 for quadro 0-1 moving on to os make sure you select windows so we get all of the appropriate drivers pre-installed and in my case i have a windows installation server so i'm just going to boot over the network with no physical media if only there were a really good tutorial where you could find more information on how to do that can't think of one under system you're going to want to make sure the advanced checkbox is indeed checked because we want to make this a uefi boot system so under bios we're going to select ovmf uefi and under machine type select q35 this will require a uefi boot disk so select the location of your boot drive right there moving on to hard drive i'm going to make this a 120 gigabyte virtual disk select cpu i'm going to give this six threads under memory we're going to give this eight gigabytes so 81.92 under network it should be intel e1000 unless you want to install drivers into your pre-boot environment but for right now we're just going to leave it at that and then we're going to confirm everything looks good and click on finish at this point install windows as you normally would again in my case i'm using a windows deployment server or you can boot off an iso that you've pre-installed into your proxmox server but i will see you once you have this whole process done once you have windows installed we can finally start to put a bow on this thing and maybe get to some gaming you know since that's the whole point of all this anyway you will need a couple additional pieces of software first and foremost you're going to need some kind of remote access to get into your virtual machine that is not the proxmox web gui that's because once we finish the graphics card configuration the web gui will no longer work you'll need to access either via remote desktop or vnc or some other solution that does not involve your video card so in this case parsec would not be a valid option i've installed type vnc just for the simplicity of everything second bit of software is called vb cable and it is a virtual audio device windows when there is no sound card present will disable the windows sound service meaning that no audio will be played and i think we all agree games are way better with sound this tricks windows into thinking there is an audio device and a cable is plugged in with some kind of output to it since we are using a virtual graphics card there's no hdmi plug on it meaning that not even the hdmi audio will be functional so this program kind of closes that gap and it helps if i run it as administrator and just a quick install process and now our little mute symbol went to a speaker symbol so we should be good to go on my bgpu systems i also install reba tuner and statistics server and i don't use it for the graphics overlays or frame rate counter rather i use it for the frame rate cap that it comes with i like to limit games inside my virtual machines to 60 frames per second and there's a couple really good reasons to do that first off we're not aiming for 4k 144hz gaming this is going to be aimed at 1080p 60 frames per second but allowing multiple people to play at the same time if you can accept having 60 frames per second as a hard cap that means you get a good gaming experience and you have more resources available for other gamers to play on the same graphics card remember we are sharing a finite resource here so the harder your graphics card is running on your virtual machine the less resources are available for other players to gain setting up riva tuner to do this is pretty simple first up we're just going to have it start with windows and then down here on frame rate limit i'm just going to set that to 60 and then we can minimize it and we are good to go all graphics rendering is now limited to 60 frames per second and that should be it for right now go ahead and shut down your virtual machine and we'll get a vgpu assigned to this machine now remember that text file i said we'd come back to with your uuid setup well it's time to bring that back up because this is the single line of text that will add the virtual gpu into your virtual machine so make sure you copy and paste this one before we get into the final copy and paste there's one last thing that we need to do and that's figure out what gpu you're going to emulate inside of your windows vm you see the way vgpu normally works is you download a package of drivers that is one for the proxmox or kvm host and one for your windows or linux guest those drivers work together to enable the vgpu to function inside of the vm the problem is they also require an nvidia license server and an active subscription this gpu emulation method goes completely against morality and nvidia license requirements and everything they're in however i'm kind of okay with it in this exact circumstance the reason being is using this technology is 100 sanctioned over on microsoft with windows hyper-v and that system is 100 free to use so in my mind this isn't really bypassing a license agreement this is just using a different host operating system to achieve the same means so what do i mean by gpu emulation well when you set up a vgpu server with an rtx 6000 which is what we told proxmox is installed in here right now instead of the rtx 2080 you pass through a vgbu profile to a virtual machine and then install the companion driver that matches the host driver we're going to tell the windows vm that it has an rtx 6000 installed as well instead of the rtx 6000 4q v gpu profile that's actually present to do that we're going to change the pci id of the vgpu profile inside of the virtual machine are you still with me good luckily i found this nvidia pci id database hosted by envy tools and if you want to look this up for yourself link is down in the video description now in my particular system i have an rtx 2080 which again is a touring based graphics card so i need to tell windows that i'm also installing a touring based graphics card the easiest one is the rtx 6000 which is what this card actually thinks it is so we're going to find rtx 6000 and there we can see the pci id of the rtx6000 it is 1e30 back over in our text file i'm going to find the pci id and i'm going to change that to 1e30 and i'm going to do that for both of the virtual graphics cards so 1e30 second thing we need to do is paste the uuid of each vgpu twice into this field so first up there's one right up here and secondly at the very end of the line and we'll do the same thing for the second vm paste it there and paste it there and i'll go ahead and save that file go ahead and open back up your ssh session and we are going to modify the configuration files of the virtual machine that i just created so we're going to type in nano forward slash etc forward slash pve forward slash qemu forward slash and then the id number of your virtual machine so in my case it is 100.conf we're going to paste this line right at the top of our configuration file so i'm going to take this entire line i'm gonna copy that and then paste it on over here in line one and you can see right here is my very long argument string and for hopefully the last time you can exit and save the file at this point go back to your windows vm and start it back up now we have not disabled the onboard graphics for this yet so your video console in the web gui should still be functional but before we move any further i do need to install the nvidia quadro drivers for the rtx 6000 so i'm going to go to nvidia.com drivers i'm going to select quadro rtx series and then quadro rtx 6000 and search current version was updated seven days ago so we are using the latest graphics driver 471.11 once that's downloaded go ahead and open it up and install the nvidia graphics driver as you normally would and when the driver is installed go ahead and restart when the nvidia driver first installs it's going to do something funky with your web console and that is your mouse will no longer track accurately now to be clear you can still use the mouse to its fullest extent and click anywhere you want on the screen but you can only move the mouse in the top left corner of your window right here what's happening is the virtual gpu has a full 1080p display off to the right hand side of this window that your web gui can't render because it's on the graphics card not in a virtual driver now if i go down here to the start menu and i go to device manager and we open up our display adapters you can see the virtual gpu is actually being recognized as a quadro rtx 6000 so the windows machine knows no difference between this and a physical graphics card that's installed the only difference is our rtx 6000 has four gigabytes of video memory instead of the actual rtx 6000 which has 24 gigabytes of virtual memory but that doesn't matter to the nvidia driver now there's one last thing that we need to do and that's get rid of this pesky first screen reason being is parsec won't actually work if your primary monitor doesn't support hardware rendering so let's install parsec and then get rid of the display adapter that doesn't support hardware rendering so i'm going to go to parsec.app and we're going to download the latest client the installer runs nice and quick we're going to select shared install so this will actually install parsec as a service meaning that even if a user is not currently logged into it we can still remote access the machine through parsec go ahead and click on next and it'll run through in about five or so seconds last thing is you'll need to log in now again parsec is a free service but you do need to create an account on parsec.app once you've logged into parsec let's go ahead and shut down the virtual machine and we'll get on to the final step the last thing to do before you start gaming is pretty darn simple i'm going to click on my virtual machine inside of parsec i'm going to go down to hardware and then under display i'm going to select for a graphics card none and then press ok what this does is delete the proxmox video driver while leaving the nvidia vgpu driver alone which means the vgpu is now the primary display which means you have full access to hardware encoding including nvenc and can fire up parsec and start gaming so let's give that a whirl i'm going to right-click on my machine and go to start and after a minute or so you can see vgpu one is now showing up inside of my parsec client so i'm gonna go ahead and click on connect and now finally after almost two years i can just play a game from a headless gpu running on a server to a thin client this is what i wanted all along what do you say we play a little crisis just to commemorate this you ready here we are let's go to options let's go to system graphics we're going to run at 1080p we're going to crank anti-aliasing and apply yes yes i'm going to go to advanced we're going to change all settings to very high except motion blur as linus says motion blur now let's play a game now while crysis is doing the first run video which you can't skip i'm going to show you how to monitor your virtual graphics card from your ssh session so i'm going to alt tab out of there and go back to ssh i'm going to type in nvidia dash smi dash l and then one what this will do will load up nvidia smi and give you an overview of what your graphics card is doing both physically and on the vgpu side so as you can see right here our graphics card is currently running at about 53 percent fan speed is at 38 we are at 55 degrees celsius using 138 watts of power and we have 4 gigabytes of video memory that's being used and where it's being used is in the vgpu which is right down here you can see four gigabytes of memory right there and the bottom of the screen will refresh once per second so if you just kind of keep an eye on that while we're playing you can see how much power we have available to this graphics card with 1080p 60 frames per second crisis running inside of a vm as you can see our gpu is hovering right around that 45 mark sometimes touching 50 percent but what that means is i have plenty of power for a second virtual machine to run this exact same game at the same speed and they wouldn't be competing for resources with each other all right we ready for one of the most quintessential scenes in gaming the sunrise over the bay in crisis oh yes oh that was a chicken is now that is what we call a success around here now there is one more thing that i wanted to show you and that is the issues that i had writing this tutorial and getting this video produced and it has to do with the download of the vgpu script once through git clone and the other through downloading it in a zip to my windows pc and then copying the folder over through winscp into the proxmox server so using the second method that is downloading to windows first and then scp-ing it over you can see if i type in dmesg we have that vgpu unlock patch applied which is the one line that we're looking for to make this whole system work but what if i just git clone the vgpunlock script will it still work then it's the same files after all well let's find out so if you remember right at the beginning of this video i copied over the vgpu unlock script as vgpu unlock and then i also downloaded the vgpunlock script with git clone and i renamed that to vgpu unlock git so we're going to go through and we're going to change the script files in the vgpud and vgpu manager over to this second directory and see if we're able to still compile our kernel driver so yet again i'm going to open up the vgpud service only this time vgpu unlock underscore get and we're gonna do the same exact thing for every single file that's in here just like before i'm going to uninstall the kms driver and now i'm going to reinstall the kms driver now note the driver will install but keep watching see dkms install completed we're going to reboot the system now all right our server is back up and running let's go ahead and reconnect to our ssh session there we go let's type in dmesg and as you can see it looks completely different than last time in fact if i scroll wherever there is no reference to vgpu i can even dmesg let's grip the gpu nothing about unlock nothing about nvidia well we do get a couple of things including the fact that the graphics driver is actually loaded so nvidia dash smi does in fact show us the rtx 2080. if we go mdev ctl types we can see that we do see vgpu types on here however the system is not fully unlocked unless inside of dmesg you see vgpu patch successfully applied nothing else will work even though it all appears to and this is the issue that had me just pulling my hair out i'm pretty sure this alone caused my forehead to grow another inch so if you have the same issue that i did just download the script to your pc first and then scp it over with the couple other files that you have to scp over anyway but that is going to wrap it up for today's tutorial let me know down in the comment section below what hardware do you plan on using to run this system genuinely curious what extra graphics cards or multiple graphics card configurations you want to go with pretty much every file you need from this tutorial will also be down in the video description minus of course the nvidia driver and all the parts that you see inside of this case as well as all of the parts that i've used over this entire project i will also have affiliate links for down below on your way down there make sure to drop this video a like and subscribe to craft computing if you haven't done so already follow me on twitter craft computing to keep up with shenanigans like this and if you like the content you see on this channel i want to help support me and what i do so i can afford to continue doing projects like this thing about joining the floatplane or patreon links are also down in the video description where else would they be as a bonus you can get exclusive access to my discord server where you can chat with myself and the other hosts from talking heads thank you all so much for watching this one and as always i will see you in the next video cheers guys you know when the klingons introduced rack to geno i'm pretty sure it would taste exactly like this this is the block 15 brewing company cosmic cold brew stout conditioned on cold brew coffee this is a seven percent stout and i could not help but use my brand new racquet genome mug oh that is tasty oh that is very very tasty that is so incredibly sweet but perfectly balanced with just a little bit of a bitterness from the coffee poking through oh wow ooh and then a roast hits very late like eight seconds late all of a sudden you get just a little roastiness to kind of finish you off that's good so i'm at the bottom of this cup and to be fair i've been at this what about an hour and 20 minutes now so the beer has warmed up quite a bit there's only maybe one or two swigs left in the bottom of this glass even though this is an insulated mug the coffee did warm up to pretty much room temperature maybe just below at this point the deeper i get into this stout the more the coffee is coming forward but it's more of the bitter and almost sour notes from the coffee that are really present now this is an interesting one because normally most stouts taste better as they warm up but we know coffee usually only tastes good really hot or really cold and in this case the coffee is kind of overriding that traditional stout flavor i still know it's an ale like it's still a beer in this glass but that day-old break room coffee taste has kind of overridden all of the good notes that were in this beer so it's a great beer to have cold but it's one you're going to want to drink within about 30 minutes you're not going to want to sit here and just kind of sip on this one like i have been not the most people do that with beers but i do yeah that's just bad coffee at this point on a quick side note why do companies insist on publishing releases to software that literally the existing functionality of that software or even changing wildly the way it works uh i'm using the ipad pad caster app from parrot as well as the official pad caster remote and it has been a fantastic teleprompter system you guys probably don't even know i use a teleprompter half the time uh anyway they completely changed the controls on the remote and how everything works it used to be press up to go up and down to go down and that kind of still works but now it's like doing this weird multi-line jump thing instead of being nice and smooth instead the smoothness is controlled by pressing and holding in the ok button which i press it in and the teleprompter moves ever so slightly and then stops however i can't have it auto scroll anymore i write in fairly large paragraphs i need auto scroll and i'm really kind of ticked it's gone so my watch has been fantastic for tracking steps and also getting notifications directly to my watch but uh it also does this thing because i've i'm trying to be a little bit more active where about once every 60 to 90 minutes it'll remind you that you're a fat tub of crap and maybe you should walk up the stairs most of the time it says would you like to get up and stretch or how about getting up and moving and and those aren't too bad this time it froze on the picture of like a fat dude and a wife beater with a headband thanks that's a reminder i needed as i'm drinking a coffee brewed stout at 10 o'clock in the morning
Info
Channel: Craft Computing
Views: 51,327
Rating: 4.9807196 out of 5
Keywords:
Id: cPrOoeMxzu0
Channel Id: undefined
Length: 45min 50sec (2750 seconds)
Published: Mon Jul 05 2021
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.