1.1.59 Linux installed 2nd GPU to drive secondary display and game is stuck rendering on the 2nd GPU

Anything that prevents you play the game properly. Do you have issues with paying for the game, downloading it or properly running it on your computer? Let us know here.
cpufreak101
Burner Inserter
Burner Inserter
Posts: 17
Joined: Sat Nov 07, 2020 1:12 am
Contact:

1.1.59 Linux installed 2nd GPU to drive secondary display and game is stuck rendering on the 2nd GPU

Post by cpufreak101 »

As the title says, I installed a 2nd GPU (NOT identical to my primary GPU) to drive a secondary display in my system. the game worked just fine on my main GPU before installing the 2nd GPU, but after putting in the 2nd GPU the game performed very poorly, and checking Nvidia settings showed that the memory usage of the 2nd card was maxxing out, making me believe that the game is running on that GPU instead of my main one. I can provide any other needed info.

EDIT: when the game is open, it seems both GPU's are using a similar amount of VRAM, so maybe this isn't the issue?

EDIT 2: If I disable the 2nd screen in Nvidia settings, the issue goes away entirely and the game performs as normal, just minus my 2nd screen.

FuryoftheStars
Smart Inserter
Smart Inserter
Posts: 1198
Joined: Tue Apr 25, 2017 2:01 pm
Contact:

Re: 1.1.59 Linux installed 2nd GPU to drive secondary display and game is stuck rendering on the 2nd GPU

Post by FuryoftheStars »

Isn’t there a way in the nVidia CP to force (on a per app basis, even) which GPU it uses? I’m not at my computer so can’t verify.

cpufreak101
Burner Inserter
Burner Inserter
Posts: 17
Joined: Sat Nov 07, 2020 1:12 am
Contact:

Re: 1.1.59 Linux installed 2nd GPU to drive secondary display and game is stuck rendering on the 2nd GPU

Post by cpufreak101 »

FuryoftheStars wrote: ↑
Thu Jun 16, 2022 3:40 pm
Isn’t there a way in the nVidia CP to force (on a per app basis, even) which GPU it uses? I’m not at my computer so can’t verify.
there may be, but I've yet to figure out how to do it. will give another look when able.

EDIT: Maybe there is a way, but I cannot figure it out
Last edited by cpufreak101 on Thu Jun 16, 2022 7:41 pm, edited 1 time in total.

lyvgbfh
Long Handed Inserter
Long Handed Inserter
Posts: 98
Joined: Fri Jul 10, 2020 6:48 pm
Contact:

Re: 1.1.59 Linux installed 2nd GPU to drive secondary display and game is stuck rendering on the 2nd GPU

Post by lyvgbfh »

Can you provide a copy of your factorio-current.log? It should give us some more information about what's going on here.
(☞゚ヮ゚)☞Electric Grid Enforcer║Custom Circuit Network Colors║Enable Steam Achievements w/ Mods☜(゚ヮ゚☜)

FuryoftheStars
Smart Inserter
Smart Inserter
Posts: 1198
Joined: Tue Apr 25, 2017 2:01 pm
Contact:

Re: 1.1.59 Linux installed 2nd GPU to drive secondary display and game is stuck rendering on the 2nd GPU

Post by FuryoftheStars »

cpufreak101 wrote: ↑
Thu Jun 16, 2022 7:24 pm
FuryoftheStars wrote: ↑
Thu Jun 16, 2022 3:40 pm
Isn’t there a way in the nVidia CP to force (on a per app basis, even) which GPU it uses? I’m not at my computer so can’t verify.
there may be, but I've yet to figure out how to do it. will give another look when able.

EDIT: Maybe there is a way, but I cannot figure it out
Here's a screenshot of mine. I'm on Windows, though, so I don't know if it'll functionally be different or not. Also, I imagine there may be multiple settings that will allow selection of specific GPUs. I haven't taken the time to verify and merely took a screenshot of one of them.

Edit: Ah, the only other one I found is "OpenGL rendering GPU".
Attachments
nVidia CP.png
nVidia CP.png (158.32 KiB) Viewed 336 times

cpufreak101
Burner Inserter
Burner Inserter
Posts: 17
Joined: Sat Nov 07, 2020 1:12 am
Contact:

Re: 1.1.59 Linux installed 2nd GPU to drive secondary display and game is stuck rendering on the 2nd GPU

Post by cpufreak101 »

lyvgbfh wrote: ↑
Thu Jun 16, 2022 7:40 pm
Can you provide a copy of your factorio-current.log? It should give us some more information about what's going on here.
here you go! dual monitors with Xinerama is enabled.

for extra info. the first launch gives me a completely black screen that requires me to CTRL+ALT+function key into another TTY to run "killall factorio" then CTRL+ALT+F7 to go back to my desktop to exit factorio. relaunching after this gives me a display in the game but performance is VERY poor.
Attachments
factorio-current.log
(4.33 KiB) Downloaded 116 times

cpufreak101
Burner Inserter
Burner Inserter
Posts: 17
Joined: Sat Nov 07, 2020 1:12 am
Contact:

Re: 1.1.59 Linux installed 2nd GPU to drive secondary display and game is stuck rendering on the 2nd GPU

Post by cpufreak101 »

also Fury, the Linux control panel looks entirely different. IK how to do that on windows, but I cannot find any equivalent setting on the Linux version of the control panel

lyvgbfh
Long Handed Inserter
Long Handed Inserter
Posts: 98
Joined: Fri Jul 10, 2020 6:48 pm
Contact:

Re: 1.1.59 Linux installed 2nd GPU to drive secondary display and game is stuck rendering on the 2nd GPU

Post by lyvgbfh »

cpufreak101 wrote: ↑
Fri Jun 17, 2022 4:25 am
here you go! dual monitors with Xinerama is enabled.

for extra info. the first launch gives me a completely black screen that requires me to CTRL+ALT+function key into another TTY to run "killall factorio" then CTRL+ALT+F7 to go back to my desktop to exit factorio. relaunching after this gives me a display in the game but performance is VERY poor.
Thanks.
1. I see it's bound to a GTX 1070 on your 1080p display, is that the correct configuration as far as GPU/monitor?
2. I also see that it shows both screens as 0Hz but vsync is on, I'm wondering if this is contributing - have you tried disabling vsync?
3. Have you tried launching the game in windowed mode?
4. Any reason for specifically Xinerama? It has a pretty big performance penalty out of the box and is less robust than systems like xrandr (in my experience)
(☞゚ヮ゚)☞Electric Grid Enforcer║Custom Circuit Network Colors║Enable Steam Achievements w/ Mods☜(゚ヮ゚☜)

cpufreak101
Burner Inserter
Burner Inserter
Posts: 17
Joined: Sat Nov 07, 2020 1:12 am
Contact:

Re: 1.1.59 Linux installed 2nd GPU to drive secondary display and game is stuck rendering on the 2nd GPU

Post by cpufreak101 »

hello, thank you for the reply!

yes, I'm trying to use the 1070 on the 1080P display, that is all correct.

I have disabled vsync in the game settings. it had made no difference.

same story for windowed mode, no change.

Xinerama is what has the toggle box in the Nvidia X server settings. running my dual monitors with this disabled results in the Desktop Environment (cinnamon, distro is Linux Mint) crashing and restarting in fallback mode. if there's a way to use something else without causing cinnamon to crash I can give it a try!

lyvgbfh
Long Handed Inserter
Long Handed Inserter
Posts: 98
Joined: Fri Jul 10, 2020 6:48 pm
Contact:

Re: 1.1.59 Linux installed 2nd GPU to drive secondary display and game is stuck rendering on the 2nd GPU

Post by lyvgbfh »

cpufreak101 wrote: ↑
Fri Jun 17, 2022 6:35 am
hello, thank you for the reply!

yes, I'm trying to use the 1070 on the 1080P display, that is all correct.

I have disabled vsync in the game settings. it had made no difference.

same story for windowed mode, no change.

Xinerama is what has the toggle box in the Nvidia X server settings. running my dual monitors with this disabled results in the Desktop Environment (cinnamon, distro is Linux Mint) crashing and restarting in fallback mode. if there's a way to use something else without causing cinnamon to crash I can give it a try!
I'm half tempted to blame cinnamon and call it a day but that seems.. half assed. Do you know how old your version of cinnamon is? There's this bug from mid-2021 that seems highly relevant to the crash issue and might be borking acceleration somewhere when this happens. Feels 50/50 whether I should be looking at cinnamon or xinerama first but nothing for it but to try.

edit: referring to your comment quoted below, this seems to almost exactly match the linked bugreport.
for extra info. the first launch gives me a completely black screen that requires me to CTRL+ALT+function key into another TTY to run "killall factorio" then CTRL+ALT+F7 to go back to my desktop to exit factorio. relaunching after this gives me a display in the game but performance is VERY poor.
Last edited by lyvgbfh on Fri Jun 17, 2022 7:19 am, edited 1 time in total.
(☞゚ヮ゚)☞Electric Grid Enforcer║Custom Circuit Network Colors║Enable Steam Achievements w/ Mods☜(゚ヮ゚☜)

cpufreak101
Burner Inserter
Burner Inserter
Posts: 17
Joined: Sat Nov 07, 2020 1:12 am
Contact:

Re: 1.1.59 Linux installed 2nd GPU to drive secondary display and game is stuck rendering on the 2nd GPU

Post by cpufreak101 »

from what I can find, cinnamon version is 5.2.7+una, which is listed as the latest

EDIT: if the issue is cinnamon though, I can switch DE's but it's understandably a bit less than ideal

lyvgbfh
Long Handed Inserter
Long Handed Inserter
Posts: 98
Joined: Fri Jul 10, 2020 6:48 pm
Contact:

Re: 1.1.59 Linux installed 2nd GPU to drive secondary display and game is stuck rendering on the 2nd GPU

Post by lyvgbfh »

cpufreak101 wrote: ↑
Fri Jun 17, 2022 7:18 am
from what I can find, cinnamon version is 5.2.7+una, which is listed as the latest

EDIT: if the issue is cinnamon though, I can switch DE's but it's understandably a bit less than ideal
Yeah I'm not well-versed enough in this to say that's worth the effort and I'm about near the end of my expertise - I'm a pretty casual linux user. Short of swapping WMs, we can look at other symptoms. Have you seen this issue with other games? You could test with Unigine Valley (free as in beer) if you aren't sure. Be warned, their non-torrent downloads are often quite slow.
(☞゚ヮ゚)☞Electric Grid Enforcer║Custom Circuit Network Colors║Enable Steam Achievements w/ Mods☜(゚ヮ゚☜)

cpufreak101
Burner Inserter
Burner Inserter
Posts: 17
Joined: Sat Nov 07, 2020 1:12 am
Contact:

Re: 1.1.59 Linux installed 2nd GPU to drive secondary display and game is stuck rendering on the 2nd GPU

Post by cpufreak101 »

sorry for the late reply.

I Have tried it with Minecraft, which does report the correct GPU, but it's getting ~20FPS when I know it should be getting over 60 (no shaders) I can try some additional games too if need be.

lyvgbfh
Long Handed Inserter
Long Handed Inserter
Posts: 98
Joined: Fri Jul 10, 2020 6:48 pm
Contact:

Re: 1.1.59 Linux installed 2nd GPU to drive secondary display and game is stuck rendering on the 2nd GPU

Post by lyvgbfh »

cpufreak101 wrote: ↑
Sun Jun 19, 2022 2:19 am
sorry for the late reply.

I Have tried it with Minecraft, which does report the correct GPU, but it's getting ~20FPS when I know it should be getting over 60 (no shaders) I can try some additional games too if need be.
The benchmark would be a nice third test, but it seems like you might have to end up swapping DE :(
(☞゚ヮ゚)☞Electric Grid Enforcer║Custom Circuit Network Colors║Enable Steam Achievements w/ Mods☜(゚ヮ゚☜)

cpufreak101
Burner Inserter
Burner Inserter
Posts: 17
Joined: Sat Nov 07, 2020 1:12 am
Contact:

Re: 1.1.59 Linux installed 2nd GPU to drive secondary display and game is stuck rendering on the 2nd GPU

Post by cpufreak101 »

ait, I'll be busy with work for the next few days, but when I get a chance I'll see about switching cause I do have one in mind (been even kinda looking for an excuse to switch to KDE anyways thanks to the development of an extension to make wallpaper engine compatible with it so a good of time as any!) so if it goes well, I shall report back

User avatar
ptx0
Smart Inserter
Smart Inserter
Posts: 1358
Joined: Wed Jan 01, 2020 7:16 pm
Contact:

Re: 1.1.59 Linux installed 2nd GPU to drive secondary display and game is stuck rendering on the 2nd GPU

Post by ptx0 »

check the launcher script in my signature. there might be something useful in there for nvidia display config.

cpufreak101
Burner Inserter
Burner Inserter
Posts: 17
Joined: Sat Nov 07, 2020 1:12 am
Contact:

Re: 1.1.59 Linux installed 2nd GPU to drive secondary display and game is stuck rendering on the 2nd GPU

Post by cpufreak101 »

ptx0 wrote: ↑
Sun Jun 19, 2022 6:24 am
check the launcher script in my signature. there might be something useful in there for nvidia display config.
possibly dumb question, but I just wanna make sure I'm not screwing it up, how do I use it?

User avatar
ptx0
Smart Inserter
Smart Inserter
Posts: 1358
Joined: Wed Jan 01, 2020 7:16 pm
Contact:

Re: 1.1.59 Linux installed 2nd GPU to drive secondary display and game is stuck rendering on the 2nd GPU

Post by ptx0 »

cpufreak101 wrote: ↑
Sun Jun 19, 2022 9:07 pm
ptx0 wrote: ↑
Sun Jun 19, 2022 6:24 am
check the launcher script in my signature. there might be something useful in there for nvidia display config.
possibly dumb question, but I just wanna make sure I'm not screwing it up, how do I use it?
i have separate factorio installs in ~/factorio/<name> where <name> is something like "spaceexploration" and then invoke that copy of the game using "~/factorio.sh spaceexploration"

if you have a perusal at the script at the bottom half, everything is commented what's happening. there's a section where it enables some nvidia optimizations. you might want to look at the nvidia docs to see if there are environment variables that maybe used to set it to a 2nd monitor. and if so, i can add that to the script as one more thing that's done while launching the game.

cpufreak101
Burner Inserter
Burner Inserter
Posts: 17
Joined: Sat Nov 07, 2020 1:12 am
Contact:

Re: 1.1.59 Linux installed 2nd GPU to drive secondary display and game is stuck rendering on the 2nd GPU

Post by cpufreak101 »

ptx0 wrote: ↑
Sun Jun 19, 2022 9:38 pm
cpufreak101 wrote: ↑
Sun Jun 19, 2022 9:07 pm
ptx0 wrote: ↑
Sun Jun 19, 2022 6:24 am
check the launcher script in my signature. there might be something useful in there for nvidia display config.
possibly dumb question, but I just wanna make sure I'm not screwing it up, how do I use it?
i have separate factorio installs in ~/factorio/<name> where <name> is something like "spaceexploration" and then invoke that copy of the game using "~/factorio.sh spaceexploration"

if you have a perusal at the script at the bottom half, everything is commented what's happening. there's a section where it enables some nvidia optimizations. you might want to look at the nvidia docs to see if there are environment variables that maybe used to set it to a 2nd monitor. and if so, i can add that to the script as one more thing that's done while launching the game.
that's all quite a bit over my head lmao, I may be a bit dumb for this, I'll see if I can figure out how to use it with the steam version, beyond that, it's gonna be some time lol

User avatar
ptx0
Smart Inserter
Smart Inserter
Posts: 1358
Joined: Wed Jan 01, 2020 7:16 pm
Contact:

Re: 1.1.59 Linux installed 2nd GPU to drive secondary display and game is stuck rendering on the 2nd GPU

Post by ptx0 »

yes, multiple GPUs is tricky enough without them being from the same vendor. it looks like SDL2 or Factorio themseves would need to be modified to allow selecting which GPU to render on, for OpenGL. this is naturally supported in Vulkan.

you're better off just driving both displays with one GPU.

Post Reply

Return to “Technical Help”