[0.17.37][Linux] Game freezes (and CPU utilization jumps up to 100%)

Bugs that are actually features.
Post Reply
hasezoey
Burner Inserter
Burner Inserter
Posts: 18
Joined: Sun Apr 19, 2015 9:18 am
Contact:

[0.17.37][Linux] Game freezes (and CPU utilization jumps up to 100%)

Post by hasezoey »

Factorio Versions: 0.17.30 .31 .32 .33 .34 .37 (versions between .34 and .37 not tested)
Visual Footage: https://youtu.be/Kurzk-OhFuA (happens around 27 minutes)
Save File, Log File & more: https://drive.google.com/open?id=1ziX7k ... 0NVRo9zVHe
System Infomation:
- System: Linux Mint Cinnamon 19.1 (tried on Kernel 4.15-47.* & 4.15-48.* & 5.0.9 & 5.0.10)
- Graphics card(s): used Nvidia GTX 1080 (Nvidia GTX 950 used for VM's (also vfio))
- Graphic Drivers: 418 & 430 from launchpad
Tested in: SP & MP
VSYNC is: ON
Nvidia Force Full Composite-line is: both ON
Additonal Infomation:

(at the kernel, i dont know what i had after -47.*)
Only the Graphics seem to lockup
I let it run for ~30 minutes, and it didnt come back
first i encountered this Graphic lockup steadily at a specific time, but then mod updates came, and it did still come, but not at the specific time anymore.
now the intervals (from loading the save file to the graphic lockup) are at max about ~30min
and after the lockup it consumes 1 thread fully to 100% the others are low (as seens in the footage from htop)
i couldnt confirm that it is a mod issue because of no log or error
strace didnt gave anything meaningful (because it detaches because of the steam client, and trying after that, it is too late)

until now, i cant confirm that it is maschine specific

...this is the infomation i could only get and provide
Last edited by hasezoey on Wed May 08, 2019 7:58 am, edited 1 time in total.

posila
Factorio Staff
Factorio Staff
Posts: 5201
Joined: Thu Jun 11, 2015 1:35 pm
Contact:

Re: [0.17.34][Linux] Graphical Lockup

Post by posila »

Thanks for the report.
Instead of strace, can you use GDB to dump backtrace of the thread that takes up 100% CPU when the lockup happens?

Run

Code: Select all

gdb attach <pid>
where <pid> must be ID of the main thread (which would be 6500 in your video), then type

Code: Select all

info threads
to list all threads, then use command

Code: Select all

thread <thread-id>
to switch to the thread that uses 100% CPU (that would be 6572 in your video) and use

Code: Select all

bt
to print out backtrace.

hasezoey
Burner Inserter
Burner Inserter
Posts: 18
Joined: Sun Apr 19, 2015 9:18 am
Contact:

Re: [0.17.34][Linux] Graphical Lockup

Post by hasezoey »

i have done it, but after i attach, all thready go to 0.0 usage and "gdb attach" goes to 100
here is the log:

Code: Select all

GNU gdb (Ubuntu 8.1-0ubuntu3) 8.1.0.20180409-git
Copyright (C) 2018 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
attach: Datei oder Verzeichnis nicht gefunden.
Attaching to process 12282
[New LWP 12559]
[New LWP 12560]
[New LWP 12561]
[New LWP 12562]
[New LWP 12563]
[New LWP 12564]
[New LWP 12565]
[New LWP 12566]
[New LWP 12567]
[New LWP 12568]
[New LWP 12570]
[New LWP 12571]
[New LWP 12614]
[New LWP 12627]
[New LWP 12628]
[New LWP 12629]
[New LWP 12630]
[New LWP 12631]
[New LWP 12632]
[New LWP 12633]
[New LWP 12634]
[New LWP 12636]
[New LWP 12638]
[New LWP 12639]
[New LWP 13530]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x1fcf7a8 <MainLoop::updateThreadCondition+40>) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
88	../sysdeps/unix/sysv/linux/futex-internal.h: Datei oder Verzeichnis nicht gefunden.
(gdb) info threads
  Id   Target Id         Frame 
* 1    Thread 0x7fc8345351c0 (LWP 12282) "factorio" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x1fcf7a8 <MainLoop::updateThreadCondition+40>) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  2    Thread 0x7fc82d3e4700 (LWP 12559) "TaskManager" 0x00007fc833cc6f85 in futex_abstimed_wait_cancelable (private=<optimized out>, 
    abstime=0x7fc82d3e3410, expected=0, futex_word=0x32242a4) at ../sysdeps/unix/sysv/linux/futex-internal.h:205
  3    Thread 0x7fc82cbb2700 (LWP 12560) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x32ea2d4) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  4    Thread 0x7fc82c3b1700 (LWP 12561) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x32e6120) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  5    Thread 0x7fc82bbb0700 (LWP 12562) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x329ca64) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  6    Thread 0x7fc82b3af700 (LWP 12563) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x32cea00) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  7    Thread 0x7fc82abae700 (LWP 12564) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x32cb2e4) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  8    Thread 0x7fc82a3ad700 (LWP 12565) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x32c77d4) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  9    Thread 0x7fc829bac700 (LWP 12566) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x32c11c0) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  10   Thread 0x7fc8293ab700 (LWP 12567) "SDLTimer" 0x00007fc833cc96d6 in futex_abstimed_wait_cancelable (private=0, abstime=0x0, 
    expected=0, futex_word=0x32e3c00) at ../sysdeps/unix/sysv/linux/futex-internal.h:205
  11   Thread 0x7fc81ede3700 (LWP 12568) "factorio" 0x00007fc83258b03f in __GI___select (nfds=nfds@entry=53, 
    readfds=readfds@entry=0x7fc81ede2220, writefds=writefds@entry=0x0, exceptfds=exceptfds@entry=0x0, timeout=timeout@entry=0x7fc81ede2210)
    at ../sysdeps/unix/sysv/linux/select.c:41
  12   Thread 0x7fc817cd0700 (LWP 12570) "threaded-ml" 0x00007fc832588bf9 in __GI___poll (fds=0x7fc8100045d0, nfds=3, timeout=1500)
    at ../sysdeps/unix/sysv/linux/poll.c:29
  13   Thread 0x7fc8174cf700 (LWP 12571) "factorio" 0x00007fc832588bf9 in __GI___poll (fds=0x7fc8174ce310, nfds=1, timeout=10)
    at ../sysdeps/unix/sysv/linux/poll.c:29
  14   Thread 0x7fc815d82700 (LWP 12614) "GameUpdate" __memcmp_avx2_movbe () at ../sysdeps/x86_64/multiarch/memcmp-avx2-movbe.S:187
  15   Thread 0x7fc6a53eb700 (LWP 12627) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x7fc67181a6a0) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  16   Thread 0x7fc7f8ac2700 (LWP 12628) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x7fc6717c50a0) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  17   Thread 0x7fc7f82c1700 (LWP 12629) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
---Type <return> to continue, or q <return> to quit---
    futex_word=0x7fc67187b980) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  18   Thread 0x7fc7f7ac0700 (LWP 12630) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x7fc67187ded0) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  19   Thread 0x7fc69ebb3700 (LWP 12631) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x7fc67173dc30) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  20   Thread 0x7fc69e3b2700 (LWP 12632) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x7fc671674af0) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  21   Thread 0x7fc69dbb1700 (LWP 12633) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x7fc7ea627e50) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  22   Thread 0x7fc69d3b0700 (LWP 12634) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x7fc67144fcc0) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  23   Thread 0x7fc69cbaf700 (LWP 12636) "factorio" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x7fc628c34f74) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  24   Thread 0x7fc6a4bea700 (LWP 12638) "factorio" 0x00007fc833ccac60 in __GI___nanosleep (requested_time=0x7fc6a4be9330, 
    remaining=0x7fc6a4be9330) at ../sysdeps/unix/sysv/linux/nanosleep.c:28
  25   Thread 0x7fc69c3ae700 (LWP 12639) "TransferSource" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, 
    expected=0, futex_word=0x54b7740) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  26   Thread 0x7fc816583700 (LWP 13530) "factorio" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x7fc610006548) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
PS: i have never used gdb before
Last edited by hasezoey on Mon Apr 29, 2019 12:21 pm, edited 2 times in total.

hasezoey
Burner Inserter
Burner Inserter
Posts: 18
Joined: Sun Apr 19, 2015 9:18 am
Contact:

Re: [0.17.34][Linux] Graphical Lockup

Post by hasezoey »

after i closed the first gdb, one thread returned to 100 again
steam spawn PID: 12279
sh -c PID: 12280
factorio main process PID: 12282 (attached to this)
factorip process that took nearly 100 PID: 12614
heres the log (of attaching to the main process):

Code: Select all

GNU gdb (Ubuntu 8.1-0ubuntu3) 8.1.0.20180409-git
Copyright (C) 2018 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
attach: Datei oder Verzeichnis nicht gefunden.
Attaching to process 12282
[New LWP 12559]
[New LWP 12560]
[New LWP 12561]
[New LWP 12562]
[New LWP 12563]
[New LWP 12564]
[New LWP 12565]
[New LWP 12566]
[New LWP 12567]
[New LWP 12568]
[New LWP 12570]
[New LWP 12571]
[New LWP 12614]
[New LWP 12627]
[New LWP 12628]
[New LWP 12629]
[New LWP 12630]
[New LWP 12631]
[New LWP 12632]
[New LWP 12633]
[New LWP 12634]
[New LWP 12636]
[New LWP 12638]
[New LWP 12639]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x1fcf7a8 <MainLoop::updateThreadCondition+40>) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
88	../sysdeps/unix/sysv/linux/futex-internal.h: Datei oder Verzeichnis nicht gefunden.
(gdb) info threads
  Id   Target Id         Frame 
* 1    Thread 0x7fc8345351c0 (LWP 12282) "factorio" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x1fcf7a8 <MainLoop::updateThreadCondition+40>) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  2    Thread 0x7fc82d3e4700 (LWP 12559) "TaskManager" 0x00007fc833cc6f85 in futex_abstimed_wait_cancelable (private=<optimized out>, 
    abstime=0x7fc82d3e3410, expected=0, futex_word=0x32242a4) at ../sysdeps/unix/sysv/linux/futex-internal.h:205
  3    Thread 0x7fc82cbb2700 (LWP 12560) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x32ea2d4) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  4    Thread 0x7fc82c3b1700 (LWP 12561) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x32e6120) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  5    Thread 0x7fc82bbb0700 (LWP 12562) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x329ca64) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  6    Thread 0x7fc82b3af700 (LWP 12563) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x32cea00) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  7    Thread 0x7fc82abae700 (LWP 12564) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x32cb2e4) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  8    Thread 0x7fc82a3ad700 (LWP 12565) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x32c77d4) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  9    Thread 0x7fc829bac700 (LWP 12566) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x32c11c0) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  10   Thread 0x7fc8293ab700 (LWP 12567) "SDLTimer" 0x00007fc833cc96d6 in futex_abstimed_wait_cancelable (private=0, abstime=0x0, 
    expected=0, futex_word=0x32e3c00) at ../sysdeps/unix/sysv/linux/futex-internal.h:205
  11   Thread 0x7fc81ede3700 (LWP 12568) "factorio" 0x00007fc83258b03f in __GI___select (nfds=nfds@entry=53, 
    readfds=readfds@entry=0x7fc81ede2220, writefds=writefds@entry=0x0, exceptfds=exceptfds@entry=0x0, timeout=timeout@entry=0x7fc81ede2210)
    at ../sysdeps/unix/sysv/linux/select.c:41
  12   Thread 0x7fc817cd0700 (LWP 12570) "threaded-ml" 0x00007fc832588bf9 in __GI___poll (fds=0x7fc8100045d0, nfds=3, timeout=574)
    at ../sysdeps/unix/sysv/linux/poll.c:29
  13   Thread 0x7fc8174cf700 (LWP 12571) "factorio" 0x00007fc832588bf9 in __GI___poll (fds=0x7fc8174ce310, nfds=1, timeout=10)
    at ../sysdeps/unix/sysv/linux/poll.c:29
  14   Thread 0x7fc815d82700 (LWP 12614) "GameUpdate" __memcmp_avx2_movbe () at ../sysdeps/x86_64/multiarch/memcmp-avx2-movbe.S:184
  15   Thread 0x7fc6a53eb700 (LWP 12627) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x7fc67181a6a0) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  16   Thread 0x7fc7f8ac2700 (LWP 12628) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x7fc6717c50a0) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  17   Thread 0x7fc7f82c1700 (LWP 12629) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
---Type <return> to continue, or q <return> to quit---
    futex_word=0x7fc67187b980) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  18   Thread 0x7fc7f7ac0700 (LWP 12630) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x7fc67187ded0) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  19   Thread 0x7fc69ebb3700 (LWP 12631) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x7fc67173dc30) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  20   Thread 0x7fc69e3b2700 (LWP 12632) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x7fc671674af0) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  21   Thread 0x7fc69dbb1700 (LWP 12633) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x7fc7ea627e50) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  22   Thread 0x7fc69d3b0700 (LWP 12634) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x7fc67144fcc0) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  23   Thread 0x7fc69cbaf700 (LWP 12636) "factorio" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x7fc628c34f74) at ../sysdeps/unix/sysv/linux/futex-internal.h:88

  24   Thread 0x7fc6a4bea700 (LWP 12638) "factorio" 0x00007fc833ccac60 in __GI___nanosleep (requested_time=0x7fc6a4be9330, 
    remaining=0x7fc6a4be9330) at ../sysdeps/unix/sysv/linux/nanosleep.c:28
  25   Thread 0x7fc69c3ae700 (LWP 12639) "TransferSource" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, 
    expected=0, futex_word=0x54b7740) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
(gdb) 
(gdb) thread 1
[Switching to thread 1 (Thread 0x7fc8345351c0 (LWP 12282))]
#0  0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x1fcf7a8 <MainLoop::updateThreadCondition+40>) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
88	in ../sysdeps/unix/sysv/linux/futex-internal.h
(gdb) bt
#0  0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x1fcf7a8 <MainLoop::updateThreadCondition+40>) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
#1  __pthread_cond_wait_common (abstime=0x0, mutex=0x1fcf7c0 <MainLoop::updateThreadConditionMutex>, 
    cond=0x1fcf780 <MainLoop::updateThreadCondition>) at pthread_cond_wait.c:502
#2  __pthread_cond_wait (cond=0x1fcf780 <MainLoop::updateThreadCondition>, mutex=0x1fcf7c0 <MainLoop::updateThreadConditionMutex>)
    at pthread_cond_wait.c:655
#3  0x000000000184f7ac in std::condition_variable::wait(std::unique_lock<std::mutex>&) ()
#4  0x0000000000f56a0f in MainLoop::mainLoopStep(WorkerThread&, MainLoop::HeavyMode) () at /tmp/factorio-build-yPgHjl/src/MainLoop.cpp:582
#5  0x0000000000f56e6e in MainLoop::run(Filesystem::Path const&, Filesystem::Path const&, bool, bool, std::function<void ()>, Filesystem::Path const&, MainLoop::HeavyMode) () at /tmp/factorio-build-yPgHjl/src/MainLoop.cpp:375
#6  0x00000000005237be in main () at /tmp/factorio-build-yPgHjl/src/Main.cpp:1257
#7  0x00007fc832495b97 in __libc_start_main (main=0x517dc0 <main>, argc=2, argv=0x7ffcdb295fa8, init=<optimized out>, 
    fini=<optimized out>, rtld_fini=<optimized out>, stack_end=0x7ffcdb295f98) at ../csu/libc-start.c:310
#8  0x000000000053190e in _start ()
(gdb) 
here is the log of attaching to the nearly 100 process:

Code: Select all

GNU gdb (Ubuntu 8.1-0ubuntu3) 8.1.0.20180409-git
Copyright (C) 2018 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
attach: Datei oder Verzeichnis nicht gefunden.
Attaching to process 12282
[New LWP 12559]
[New LWP 12560]
[New LWP 12561]
[New LWP 12562]
[New LWP 12563]
[New LWP 12564]
[New LWP 12565]
[New LWP 12566]
[New LWP 12567]
[New LWP 12568]
[New LWP 12570]
[New LWP 12571]
[New LWP 12614]
[New LWP 12627]
[New LWP 12628]
[New LWP 12629]
[New LWP 12630]
[New LWP 12631]
[New LWP 12632]
[New LWP 12633]
[New LWP 12634]
[New LWP 12636]
[New LWP 12638]
[New LWP 12639]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x1fcf7a8 <MainLoop::updateThreadCondition+40>) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
88	../sysdeps/unix/sysv/linux/futex-internal.h: Datei oder Verzeichnis nicht gefunden.
(gdb) info threads
  Id   Target Id         Frame 
* 1    Thread 0x7fc8345351c0 (LWP 12282) "factorio" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x1fcf7a8 <MainLoop::updateThreadCondition+40>) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  2    Thread 0x7fc82d3e4700 (LWP 12559) "TaskManager" 0x00007fc833cc6f85 in futex_abstimed_wait_cancelable (private=<optimized out>, 
    abstime=0x7fc82d3e3410, expected=0, futex_word=0x32242a4) at ../sysdeps/unix/sysv/linux/futex-internal.h:205
  3    Thread 0x7fc82cbb2700 (LWP 12560) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x32ea2d4) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  4    Thread 0x7fc82c3b1700 (LWP 12561) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x32e6120) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  5    Thread 0x7fc82bbb0700 (LWP 12562) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x329ca64) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  6    Thread 0x7fc82b3af700 (LWP 12563) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x32cea00) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  7    Thread 0x7fc82abae700 (LWP 12564) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x32cb2e4) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  8    Thread 0x7fc82a3ad700 (LWP 12565) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x32c77d4) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  9    Thread 0x7fc829bac700 (LWP 12566) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x32c11c0) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  10   Thread 0x7fc8293ab700 (LWP 12567) "SDLTimer" 0x00007fc833cc96d6 in futex_abstimed_wait_cancelable (private=0, abstime=0x0, 
    expected=0, futex_word=0x32e3c00) at ../sysdeps/unix/sysv/linux/futex-internal.h:205
  11   Thread 0x7fc81ede3700 (LWP 12568) "factorio" 0x00007fc83258b03f in __GI___select (nfds=nfds@entry=53, 
    readfds=readfds@entry=0x7fc81ede2220, writefds=writefds@entry=0x0, exceptfds=exceptfds@entry=0x0, timeout=timeout@entry=0x7fc81ede2210)
    at ../sysdeps/unix/sysv/linux/select.c:41
  12   Thread 0x7fc817cd0700 (LWP 12570) "threaded-ml" 0x00007fc832588bf9 in __GI___poll (fds=0x7fc8100045d0, nfds=3, timeout=1194)
    at ../sysdeps/unix/sysv/linux/poll.c:29
  13   Thread 0x7fc8174cf700 (LWP 12571) "factorio" 0x00007fc832588bf9 in __GI___poll (fds=0x7fc8174ce310, nfds=1, timeout=10)
    at ../sysdeps/unix/sysv/linux/poll.c:29
  14   Thread 0x7fc815d82700 (LWP 12614) "GameUpdate" 0x000000000053f644 in std::string::_M_mutate ()
    at /usr/include/c++/8/bits/basic_string.tcc:947
  15   Thread 0x7fc6a53eb700 (LWP 12627) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x7fc67181a6a0) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  16   Thread 0x7fc7f8ac2700 (LWP 12628) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x7fc6717c50a0) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
---Type <return> to continue, or q <return> to quit---
  17   Thread 0x7fc7f82c1700 (LWP 12629) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x7fc67187b980) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  18   Thread 0x7fc7f7ac0700 (LWP 12630) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x7fc67187ded0) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  19   Thread 0x7fc69ebb3700 (LWP 12631) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x7fc67173dc30) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  20   Thread 0x7fc69e3b2700 (LWP 12632) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x7fc671674af0) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  21   Thread 0x7fc69dbb1700 (LWP 12633) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x7fc7ea627e50) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  22   Thread 0x7fc69d3b0700 (LWP 12634) "WorkerThread" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x7fc67144fcc0) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  23   Thread 0x7fc69cbaf700 (LWP 12636) "factorio" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, expected=0, 
    futex_word=0x7fc628c34f74) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
  24   Thread 0x7fc6a4bea700 (LWP 12638) "factorio" 0x00007fc833ccac60 in __GI___nanosleep (requested_time=0x7fc6a4be9330, 
    remaining=0x7fc6a4be9330) at ../sysdeps/unix/sysv/linux/nanosleep.c:28
  25   Thread 0x7fc69c3ae700 (LWP 12639) "TransferSource" 0x00007fc833cc69f3 in futex_wait_cancelable (private=<optimized out>, 
    expected=0, futex_word=0x54b7740) at ../sysdeps/unix/sysv/linux/futex-internal.h:88
(gdb) thread 14
[Switching to thread 14 (Thread 0x7fc815d82700 (LWP 12614))]
#0  0x000000000053f644 in std::string::_M_mutate () at /usr/include/c++/8/bits/basic_string.tcc:947
947	/usr/include/c++/8/bits/basic_string.tcc: Datei oder Verzeichnis nicht gefunden.
(gdb) bt
#0  0x000000000053f644 in std::string::_M_mutate () at /usr/include/c++/8/bits/basic_string.tcc:947
#1  0x000000000053fb85 in std::string::_M_replace_safe () at /usr/include/c++/8/bits/basic_string.tcc:1134
#2  std::string::assign () at /usr/include/c++/8/bits/basic_string.tcc:714
#3  0x00000000008b0f3d in LuaBinder<LuaEntity>::parseKey () at /tmp/factorio-build-yPgHjl/src/Script/LuaBinder.hpp:204
#4  LuaBinder<LuaEntity>::processCommonLuaIndex () at /tmp/factorio-build-yPgHjl/src/Script/LuaBinder.hpp:210
#5  LuaEntity::luaIndex () at /tmp/factorio-build-yPgHjl/src/Script/LuaEntity.cpp:517
#6  0x00000000012d2c5a in LuaBinder<LuaEntity>::callWrapper () at /tmp/factorio-build-yPgHjl/src/Script/LuaBinder.hpp:341
#7  0x00000000014d986b in luaD_precall () at /tmp/factorio-build-yPgHjl/libraries/Lua/ldo.c:317
#8  0x00000000014d9a11 in luaD_call () at /tmp/factorio-build-yPgHjl/libraries/Lua/ldo.c:392
#9  0x00000000014e948b in callTM () at /tmp/factorio-build-yPgHjl/libraries/Lua/lvm.c:103
#10 luaV_gettable () at /tmp/factorio-build-yPgHjl/libraries/Lua/lvm.c:128
#11 0x00000000014eb5eb in luaV_execute () at /tmp/factorio-build-yPgHjl/libraries/Lua/lvm.c:589
#12 0x00000000014d9a68 in luaD_call () at /tmp/factorio-build-yPgHjl/libraries/Lua/ldo.c:393
#13 0x00000000014d9aee in luaD_rawrunprotected () at /tmp/factorio-build-yPgHjl/libraries/Lua/ldo.c:131
#14 luaD_pcall(lua_State*, void (*)(lua_State*, void*), void*, long, long) () at /tmp/factorio-build-yPgHjl/libraries/Lua/ldo.c:592
#15 0x00000000014d4476 in lua_pcallk () at /tmp/factorio-build-yPgHjl/libraries/Lua/lapi.c:1053
#16 0x00000000006e9fac in LuaHelper::pCallWithStackTrace () at /tmp/factorio-build-yPgHjl/src/Util/LuaHelper.cpp:3314
#17 0x0000000000df19f2 in LuaGameScript::signallingPCall () at /tmp/factorio-build-yPgHjl/src/Script/LuaGameScript.cpp:5764
#18 LuaGameScript::runEventHandler(unsigned int, int) () at /tmp/factorio-build-yPgHjl/src/Script/LuaGameScript.cpp:879
#19 0x000000000132a4ef in LuaEventDispatcher::run<GameAction> () at /tmp/factorio-build-yPgHjl/src/Script/LuaEventDispatcher.cpp:537
#20 0x0000000000df2b9f in LuaEventDispatcher::dispatch(unsigned int) () at /tmp/factorio-build-yPgHjl/src/Script/LuaEventDispatcher.cpp:94
#21 0x0000000000f0ac01 in LuaContext::update () at /tmp/factorio-build-yPgHjl/src/Script/LuaContext.cpp:140
#22 Scenario::update() () at /tmp/factorio-build-yPgHjl/src/Scenario/Scenario.cpp:1162
#23 0x0000000000f392b4 in Scenario::updateStep () at /tmp/factorio-build-yPgHjl/src/Scenario/Scenario.cpp:1063
#24 MainLoop::gameUpdateStep(MultiplayerManagerBase*, Scenario*, AppManager*, MainLoop::HeavyMode) ()
    at /tmp/factorio-build-yPgHjl/src/MainLoop.cpp:1145
#25 0x0000000000f398a0 in MainLoop::gameUpdateLoop(MainLoop::HeavyMode) () at /tmp/factorio-build-yPgHjl/src/MainLoop.cpp:1010
#26 0x0000000000b141f1 in std::function<void ()>::operator()() const () at /usr/include/c++/8/bits/std_function.h:687
#27 WorkerThread::loop() () at /tmp/factorio-build-yPgHjl/src/Util/WorkerThread.cpp:41
#28 0x0000000001822fbf in execute_native_thread_routine ()
#29 0x00007fc833cc06db in start_thread (arg=0x7fc815d82700) at pthread_create.c:463
#30 0x00007fc83259588f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95
(gdb) 
Update: added the htop image of the processes in the drive folder

posila
Factorio Staff
Factorio Staff
Posts: 5201
Joined: Thu Jun 11, 2015 1:35 pm
Contact:

Re: [0.17.34][Linux] Game freezes (and CPU utilization jumps up to 100%)

Post by posila »

Thanks for the additional info. It seems to me a mod causes infinite (or very long) loop that makes the game update take forever. I renamed the thread to make it clear the lockup is not due to rendering.

hasezoey
Burner Inserter
Burner Inserter
Posts: 18
Joined: Sun Apr 19, 2015 9:18 am
Contact:

Re: [0.17.34][Linux] Game freezes (and CPU utilization jumps up to 100%)

Post by hasezoey »

thanks, for me it just seemed like a graphical lockup because the log still worked but the graphics not,
is there any way to determine which mod? / how to fix it?

hasezoey
Burner Inserter
Burner Inserter
Posts: 18
Joined: Sun Apr 19, 2015 9:18 am
Contact:

Re: [0.17.37][Linux] Game freezes (and CPU utilization jumps up to 100%)

Post by hasezoey »

Updated the thread to reflect that it is still happening in 0.17.37
Updated the drive with current logs, save files, mod list (only this time because of the "player -> character" rename i modifed *some* mods to work with this versions)

Rseding91
Factorio Staff
Factorio Staff
Posts: 13204
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: [0.17.37][Linux] Game freezes (and CPU utilization jumps up to 100%)

Post by Rseding91 »

Without a full set of mods (the actual mods in a zip) to reproduce this we can't look into it. Additionally I need a save file that locks up shortly (< 1 minute) after loading. Waiting 30 minutes to maybe reproduce the issue isn't viable.
If you want to get ahold of me I'm almost always on Discord.

hasezoey
Burner Inserter
Burner Inserter
Posts: 18
Joined: Sun Apr 19, 2015 9:18 am
Contact:

Re: [0.17.37][Linux] Game freezes (and CPU utilization jumps up to 100%)

Post by hasezoey »

uploading them now, sorry, they are 0.7GB big, and my net isnt the fastest...
and i couldnt reproduce it in < 1 minute, i can only reproduce it reliably in 30 minutes, because i dont really understand from wich mod it comes, and when i save right before it, it dosnt happen anymore for the next 20 minutes

Update: mods are all uploaded

Rseding91
Factorio Staff
Factorio Staff
Posts: 13204
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: [0.17.37][Linux] Game freezes (and CPU utilization jumps up to 100%)

Post by Rseding91 »

Set autosave interval to 1 minute and let the game run until it freezes. Then take the last autosave and load that - it should freeze within < 1 minute of that autosave.

If it doesn't, then there's some save/load issue with one of the mods in addition to what ever is causing the infinite loop.
If you want to get ahold of me I'm almost always on Discord.

hasezoey
Burner Inserter
Burner Inserter
Posts: 18
Joined: Sun Apr 19, 2015 9:18 am
Contact:

Re: [0.17.37][Linux] Game freezes (and CPU utilization jumps up to 100%)

Post by hasezoey »

i cant reproduce it in normal game speed in under 30 minutes, i tried it now with game speed 5, and it comes in ~2 Real Minutes (ingame were 10 minutes)
(from the same save)

i hope this works out, otherwise try it with game speed 7~10
(latest save with game speed 5 https://drive.google.com/open?id=1snKpc ... G7NcKpD6wU )
Last edited by hasezoey on Tue May 14, 2019 4:47 pm, edited 1 time in total.

Rseding91
Factorio Staff
Factorio Staff
Posts: 13204
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: [0.17.37][Linux] Game freezes (and CPU utilization jumps up to 100%)

Post by Rseding91 »

The Noxys Trees mod divided by zero and is sitting in an infinite loop. You'll need to contact the mod author to have them fix their code.

Code: Select all

  local tokill = 1 + mathceil(trees_count * config.trees_to_grow_per_chunk_percentage)
  if config.deaths_by_pollution_bias > 0 then
    tokill = tokill + mathceil(surface.get_pollution{chunk.x * 32 + 16, chunk.y * 32 + 16} / config.deaths_by_pollution_bias)
  end
  log("tokill: " .. tostring(tokill))
log wrote: 229.995 Script @__Noxys_Trees__/control.lua:714: tokill: nan
If you want to get ahold of me I'm almost always on Discord.

hasezoey
Burner Inserter
Burner Inserter
Posts: 18
Joined: Sun Apr 19, 2015 9:18 am
Contact:

Re: [0.17.37][Linux] Game freezes (and CPU utilization jumps up to 100%) [Noxy's Trees Mod Issue]

Post by hasezoey »

Yes can it is not happening after 30 ingame minutes when removing noxy's trees

so, i think this issue is closed

Post Reply

Return to “Not a bug”