Cannot start on linux when logged in with mutiple X screens.

This subforum contains all the issues which we already resolved.
Post Reply
User avatar
nerwall
Burner Inserter
Burner Inserter
Posts: 11
Joined: Sat Sep 17, 2016 12:40 pm
Contact:

Cannot start on linux when logged in with mutiple X screens.

Post by nerwall »

Hardware:
CPU: i73930k 6c 12t @ 3.7GHz
GPU0: GeForce GTX 1060 6GB (Factorio should be running on this GPU)
GPU1: GeForce GTX 660
RAM: 8x4GB DDR3

Software:
Kernel: 4.13.0-43-generic X86_64
OS: Ubuntu 17.10
DE: XFCE
WM: Xfwm4
Nvidia Driver: 384.111 (Driver for both GPUs)
X.Org: 1.19.5

Display Configuration:
GPU0 --> X Screen 0 --> Monitor 0 2560x1440@60Hz, Monitor 1 1600x900@60Hz, Monitor 2 1440x900@60Hz, Monitor 3 1920x1200@60Hz
GPU1 --> X Screen 1 --> Monitor 4 1280x1024@75, Monitor 5 1280x1024@75

I am logged in with 1 desktop that is spanned across multiple X screens, each of which is spanned across multiple physical monitors. I am running multiple heterogenous GPUs since a single 1060 can drive at most 4 monitors and I have more than that. Factorio should be starting on Screen 0 on monitor 0 in fullscreen, that was what happened before I added the second GPU and final three monitors. Instead of this Factorio crashes on startup before even opening a window, this happens on 0.15.40 (Seablock) as well as on 0.16.42, additionally, the --fullscreen false command line argument does not seem to affect the crash. Attached are Several logs, My /etc/X11/xorg.conf and the output of xrandr and nvidia-xconfig commands since the factorio log seems to mention xrandr.
Attachments
factorio.16_steam_nofullscreen.dmp
The core dump produced by Factiorio 0.16.42 when started from steam with the --fullscreen false argument.
(186.36 KiB) Downloaded 173 times
factorio.16_steam_nofullscreen.log
The console log of Factiorio 0.16.42 when started from steam with the --fullscreen false argument.
(3.1 KiB) Downloaded 171 times
factorio.16_nofullscreen.dmp
The core dump produced by Factiorio 0.16.36 when started with the --fullscreen false argument
(179.63 KiB) Downloaded 163 times
factorio.16_nofullscreen.log
The console log of Factiorio 0.16.36 when started with the --fullscreen false argument
(3.35 KiB) Downloaded 169 times
factorio.16.log
The console log of Factiorio 0.16.36
(3.33 KiB) Downloaded 172 times
factorio.15_nofullscreen.log
The console log of Factiorio 0.15.40 seablock when started with the --fullscreen false argument
(3.14 KiB) Downloaded 163 times
factorio.15.log
The console log of Factiorio 0.15.40 seablock
(3.12 KiB) Downloaded 149 times
xorg.conf.txt
The config file that Xorg reads on graphical startup.
(2.92 KiB) Downloaded 167 times
xrandr.log
The output of the command "xrandr --listproviders && xrandr --query" This represents the GPU and monitor topology from the perspective of xrandr when run on the same X screen that Factorio is run from.
(1.35 KiB) Downloaded 171 times
nvidia.txt
output of command "nvidia-xconfig --query-gpu-info"
Lists the GPU and Monitor topology from the perspective of the Nvidia Driver.
(3.5 KiB) Downloaded 160 times
Last edited by nerwall on Fri May 25, 2018 10:04 pm, edited 1 time in total.

Oxyd
Former Staff
Former Staff
Posts: 1428
Joined: Thu May 07, 2015 8:42 am
Contact:

Re: Cannot start on linux when logged in with mutiple X screens.

Post by Oxyd »

Thanks for the report. I don't have a setup crazy enough to reproduce it, but I think I found the cause of the crash. So, hopefully it will be fixed in 0.16.46.

User avatar
nerwall
Burner Inserter
Burner Inserter
Posts: 11
Joined: Sat Sep 17, 2016 12:40 pm
Contact:

Re: Cannot start on linux when logged in with mutiple X screens.

Post by nerwall »

I have narrowed down the minimum possible configuration that causes the crash, I can be done on a computer with 1 GPU and 3 monitors. There just need to be at least 2 X screens and Factorio should be started from a terminal on the X screen that is spanned across 2 of the monitors. Attached are the files from the minimum crashing config.

The steps to reproduce, if you want to try, are as follows.
  1. Plug three monitors into a newish Nvidia card
  2. Boot into a linux environment running XFCE and Xfwm4. (Xubuntu works)
  3. Make sure the system is running the Nvidia Proprietary driver.
  4. Open the Nvidia X server settings application.
  5. Select the "X Server Display Configuration" tab.
  6. Select one of the three monitors, switch the "Configuration:" dropdown from "X Screen 0" to "New X Screen".
  7. Click "Save to X Configuration File" and name the file "xorg.conf". (requires password of sudoer)
  8. Press the "<Ctrl>+<Alt>+<F1>" Key combination to switch to tty1.
  9. Log in to user account in terminal.
  10. Run command "sudo service lightdm restart".(Or whatever your display manager and Init system are)
  11. Log in to graphical environment again.
  12. Start Factorio and watch it crash.
EDIT: For 0.16.46 the requirements have changed slightly. If both X screens are run from the same GPU and Screen 1 has only one monitor then Factorio will start on Screen 0 regardless of what screen it is started from. To reproduce the crash, 4 monitors or 2 GPUs are now needed. (2 monitors per X screen or 1 screen per GPU).
Attachments
1GPU2screens3monitors.xorg.conf.txt
Xorg.conf file from crashing screen config with minimum hardware requirements.
(2.84 KiB) Downloaded 167 times
factorio.16_1gpu2screens3monitors.log
Log file from crashing screen config with minimum hardware requirements.
(3.34 KiB) Downloaded 160 times
factorio.16_1gpu2screens3monitors.dmp
Core dump from crashing screen config with minimum hardware requirements.
(179.61 KiB) Downloaded 142 times

User avatar
nerwall
Burner Inserter
Burner Inserter
Posts: 11
Joined: Sat Sep 17, 2016 12:40 pm
Contact:

Re: Version 0.16.46

Post by nerwall »

FactorioBot wrote:Bugfixes
  • Another possible fix for multi-GPU setups on Linux. (60609)
Unfortunately it looks like this did not fix the issue. Attached are the newest log and dump. The reproduction steps in my comment on the bug report page still work, but I understand if changing up your setup is too much for a bug that is so specific to a very rare setup.
EDIT: It looks like this fixes the bug, but only if the second X screen contains only one monitor. If the second X screen has two monitors it still crashes. Additionally, if Factorio is started from an X screen other than 0, it will still start on screen 0, unlike most X applications.
Attachments
factorio-dump-current.dmp
0.14.46 crash with multiple X screens.
(175.61 KiB) Downloaded 165 times
factorio-current.log
0.14.46 crash with multiple X screens.
(3.9 KiB) Downloaded 173 times

Ericwu91
Burner Inserter
Burner Inserter
Posts: 14
Joined: Sun May 29, 2016 10:17 pm
Contact:

Re: Cannot start on linux when logged in with mutiple X screens.

Post by Ericwu91 »

Holy moses, that's a crazy configuration.

Koub
Global Moderator
Global Moderator
Posts: 7200
Joined: Fri May 30, 2014 8:54 am
Contact:

Re: Cannot start on linux when logged in with mutiple X screens.

Post by Koub »

[Koub] Moved nerwall's last post here (from minor update topic)
Koub - Please consider English is not my native language.

User avatar
nerwall
Burner Inserter
Burner Inserter
Posts: 11
Joined: Sat Sep 17, 2016 12:40 pm
Contact:

Re: Cannot start on linux when logged in with mutiple X screens.

Post by nerwall »

Here is a picture XD. Image

Oxyd
Former Staff
Former Staff
Posts: 1428
Joined: Thu May 07, 2015 8:42 am
Contact:

Re: Version 0.16.46

Post by Oxyd »

nerwall wrote:
FactorioBot wrote:Bugfixes
  • Another possible fix for multi-GPU setups on Linux. (60609)
Unfortunately it looks like this did not fix the issue. Attached are the newest log and dump. The reproduction steps in my comment on the bug report page still work, but I understand if changing up your setup is too much for a bug that is so specific to a very rare setup.
EDIT: It looks like this fixes the bug, but only if the second X screen contains only one monitor. If the second X screen has two monitors it still crashes. Additionally, if Factorio is started from an X screen other than 0, it will still start on screen 0, unlike most X applications.
I see. I guess it's a more complicated problem than it first seemed. It's caused by Allegro and, as you may have heard, we are planning to move away from Allegro with 0.17. So let's wait for 0.17 with this bug.

User avatar
nerwall
Burner Inserter
Burner Inserter
Posts: 11
Joined: Sat Sep 17, 2016 12:40 pm
Contact:

Re: Cannot start on linux when logged in with mutiple X screens.

Post by nerwall »

This issue has been resolved in 0.17.0, everything is working as expected on my funky system.

Post Reply

Return to “Resolved Problems and Bugs”