Solved

Launcher in a VM

  • 29 May 2020
  • 8 replies
  • 647 views

Badge

Hi all,

Quick question, does anyone had any success virtualizing the Shadow launcher?

Thanks for your input!

Best,

icon

Best answer by Tirus 30 May 2020, 16:30

View original

8 replies

Userlevel 3
Badge +3

Hi all,

Quick question, does anyone had any success virtualizing the Shadow launcher?

Thanks for your input!

Best,

What do you mean? If you mean running a VM in Shadow, that’s impossible at the moment since Shadow runs on a VM. If you mean running the shadow launcher in a VM, that’s 100% possible to do. Shadow staff did that once where they made a shadow-inception out of I think eight Shadow PCs.

Badge

Hi, thanks for your input.

Yes I mean the latter.

For some reason using two different guest OSes I was able to run the launcher, but once it successfully displays “the stream is ready” step, the actual streaming windows never pops up. If you say its possible, I may try to change the hypervisor or the host OS then.

thanks,

The launcher itself should not be a problem but the actual video decoding is.

Shadow use your local GPU to decode the video stream send by Shadow.
Therefore a local (and H264 capable) GPU is required to decode the video stream.

And this is the problem: Inside a virtual machine most likely you don’t have access to your real GPU and therefore the Shadow Client is unable to display the screen.

Unfortunately the Shadow Client is not very verbose when it comes to this kind of errors.

Userlevel 3
Badge +4

The launcher itself should not be a problem but the actual video decoding is.

Shadow use your local GPU to decode the video stream send by Shadow.
Therefore a local (and H264 capable) GPU is required to decode the video stream.

And this is the problem: Inside a virtual machine most likely you don’t have access to your real GPU and therefore the Shadow Client is unable to display the screen.

Unfortunately the Shadow Client is not very verbose when it comes to this kind of errors.

Yup, you need a hypervisor like KVM or Hyper V with PCIe passthrough to be able to fully pass a gpu through to the vm for decode.

Badge

Hello,

Thanks a lot for the answer. I began to suspect as much when reading a bit about the use of va-api in various github about the *nix compatibility of Shadow and you two sadly are confirming as much!
I guess I could pass a GPU then but it may not be much more interesting than just dedicating a low-power device then.
 

Thanks!

Badge

I began to suspect as much when reading a bit about the use of va-api in various github about the *nix compatibility of Shadow and you two sadly are confirming as much!

 

Are you concerned about Linux compatibility?  Is this why you wanted to run Shadow from within a VM?

My experience on Linux thus far was been generally good.  I’m using integrated graphics on my old i7-4771 and Shadow runs fine.  USB support is non-existent (get it together devs!) but there are work-arounds for that.  I recommend talking to the folks on Discord if you have specific hardware questions.

Lastly, as mentioned by Hascrack; you can run Shadow from within a VM.  I’ve done the same by doing PCI-passthrough on my discrete graphics card - but there’s really no point with Shadow working native on Linux.

Badge

Hi,

No I needed to virtualize mainly due to stability and security concerns. I could have done a PCI-pass through with an old gpu I had, but I just ended up moving shadow to it own mimi-pc box, it was simpler in the end. Linux is indeed pretty stable, except for the L-100 error that keeps happening here and there.

At the beginning of the Linux version (called “alpha”) i had also security concerns, specially as these days the client required access to /dev/input/event* directly and it was not compatible with my distro, as I am using Debian stable.

Also due to the problem of using a virtual machine i tried and finally used a LXC container which actually worked.

I build a Ubuntu LXC container and passed the gpu device (/dev/dri) and several other required handles like the X11 handle to the container. It was a big mess to setup initially and also made several problems with each update of the Shadow client.

Finally they released their current AppImage package with nearly works out of the box on Debian. So I switched to a more simple multi-user approach.

Today I just execute the Shadow Launcher/Client with a restricted user (using gksu) on my Debian Desktop.

Another possible way to isolate specific application are “firejail” but I did not test it with Shadow.

Reply