Return to Level1Techs.com

Looking Glass - Triage

helpdesk
lookingglass
#1624

Hello,

I have some issues with FPS aswell using looking glass, I’d like to make some improvements to make it better, hence my question.

Let me start with my pc specs and setup:

I7-8700 (non K)
16gb Ram
GTX 1080 Ti

Running a windows VM on the GTX which runs my game fullscreen at 90 fps+
My linux which I run Looking glass from is connected to my igpu, once I start looking glass, frames drop to about 30 - 40.

The question here is of course ‘why?’.
But more important, how can I improve this, is it lack of ram, cpu power or simply because LG runs on the igpu and not on a second GPU?

Thanks in advance!

0 Likes

#1625

Because once you start the client the host starts capturing and sending frames to it.

Windows capture API and NVidia not playing ball with non NvFBC users (aka, not Quadro users).

Are you running your game in full screen windowed mode? or full screen? For an unknown reason running in “Full Screen” mode performs terrible on some titles.

Also, what is the title that runs slow?

0 Likes

#1626

when i type make, it says:
make: *** No targets specified and no makefile found. Stop.
running fedora 29, i installed fedora because i heard that qemu 3.0 included a patch for amd smt bug that allowed amd processors with smt to use it in a vm, im running amd threadripper 1950x and gtx 1080 ti. i saw a 30 fps gain coming from ubuntu which is running qemu 2.16, and yes ive tried to install qemu 3.0.0(on ubuntu), but like using Looking glass on fedora there are very few articles i could find to install it, and when i did install it it just made everything break. So im sticking with fedora, but id like to use looking glass.

0 Likes

Stay Glassy with PCI Passthrough + Looking Glass -- Guide
#1627

https://looking-glass.hostfission.com/quickstart/linux/build

0 Likes

#1628

i will try this, thank you
and thank you for your work its amazing

1 Like

#1629

after some work i got it installed “[100%] Built target looking-glass-client”
I do however want to note some of the issues i had when installing.
i made myself a crappy bash script to install it and it looks like this

sudo dnf install -y cmake git SDL2-devel SDL2_ttf-devel spice-protocol fontconfig-devel nettle* libX11-devel gnu-free-mono-fonts ivshmem-tools libgle-devel.x86_64 libconfig* wayland-devel

then

sudo dnf groupinstall -y "Development Tools" "Development Libraries"

  • you can run this or
    put it in a bash script like i did

next

cd /home/user
git clone https://github.com/gnif/LookingGlass.git
cd ./LookingGlass/client
cmake ./
make

change “user” to your user.

gnif i noticed that in your tutorial you said cmake ../
im not sure why but in fedora i just got this error

“CMake Error: The source directory “/LookingGlass” does not appear to contain CMakeLists.txt.
Specify --help for usage, or press the help button on the CMake GUI.
make: *** No targets specified and no makefile found. Stop.”

  • but using cmake ./ works fine and thats what i used
0 Likes

#1630

Because you skipped a step to build LG outside the source tree

mkdir client/build
cd client/build

This keeps your source tree clean

openssl-devel is not used by LG.

0 Likes

#1631

ok, will change this

0 Likes

#1632

when i run the windows exe this happends
An error occurred, re-run in forground mode (-f) for more information

i installed the red hat drivers for the pcie and such
and configured qemu and libvirt, but i also get this in fedora

[I] main.c:961 | run | Looking Glass (a12-109-gd1c0d2b5f8)
[I] main.c:962 | run | Locking Method: Atomic
[I] main.c:955 | try_renderer | Using Renderer: EGL
[I] main.c:1115 | run | Using Clipboard: X11
[E] main.c:919 | map_memory | Failed to map the shared memory file: /dev/shm/looking-glass
[E] main.c:1145 | run | Failed to map memory

After Rebooting :

[I] main.c:961 | run | Looking Glass (a12-109-gd1c0d2b5f8)
[I] main.c:962 | run | Locking Method: Atomic
[I] main.c:955 | try_renderer | Using Renderer: EGL
[I] main.c:1115 | run | Using Clipboard: X11
[E] main.c:904 | map_memory | Failed to stat the shared memory file: /dev/shm/looking-glass
[E] main.c:1145 | run | Failed to map memory

0 Likes

#1633
  1. That log is from the client, not the windows exe. Please do as the instructions state and run the host exe with the -f switch to get the log.

    Please be sure you have installed the IVSHMEM driver by following the instructions @ https://looking-glass.hostfission.com/quickstart/win/ivshmem.

    I really don’t know why I have to keep pointing people to the guide, it is all there and clear as day.

  2. Does /dev/shm/looking-glass even exist? Do you have permission to access it?

0 Likes

#1634

i used touch to create a directory like the tutorial

touch /dev/shm/looking-glass

when i try to cd to it

[[email protected] shm]$ ls
looking-glass
[[email protected] shm]$ cd looking-glass
bash: cd: looking-glass: Not a directory

im not sure if this is my mistake, after this i removed the file and used mkdir

[[email protected] shm]$ sudo rm -r looking-glass 
[[email protected] shm]$ sudo mkdir looking-glass
[[email protected] shm]$ cd looking-glass/
[[email protected] looking-glass]$ 

i changed the permissions aswell

screen shots :

After mkdir

0 Likes

#1635

Touch does not create directories, mkdir does. Touch creates a file. You are supposed to create a file, so touch is the command to use.

2 Likes

#1636

touch doesn’t create a directory, it creates an empty file.

You need to do this before starting QEMU, not the client. Qemu’s ivshemem virtual device needs access to this file and will create it. The touch and chmod are simply to set it’s initial permissions so that you can access it.

1 Like

#1637

Looking at your screenshots, you have NOT added the IVSHMEM device to the virtual machine, go back and follow the guide from the start.

1 Like

#1638

ok i will

0 Likes

#1639

do i at least have the red hat drivers installed?

0 Likes

#1640

How can you when you don’t even have the IVSHMEM device added to the VM configuration.

https://looking-glass.hostfission.com/quickstart/linux/libvirt

0 Likes

#1641


i had installed a red hat driver before but i was thinking of the wrong one.
i think it was called balloon

Is the host able to access the shared file if the vm is off?

0 Likes

#1642

The baloon driver has nothing to do with IVSHMEM. Like I said, follow the official guide, get rid of the custom qemu command arguments you have added. Then follow the guide and MANUALLY install the driver for the device.

0 Likes

#1643

i have tried everything, its just not showing up in windows at all under system devices
i created and changed the permissions for the file but nothing
the only odd device thats showing up is QEMU FwCfg Device

0 Likes