New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Raspberry pi Segmentation fault when compiled with LuaJIT #12850
Comments
another detail that might be of insterest, I boot the raspberry off a USB HDD. |
I'm also getting a segfault trying to run a minetest server with LuaJIT enabled on a Pi 4 (from an SD card, for now) Built 5.6.1 using: -- *** Will build version 5.6.1 ***
-- Using user-provided IrrlichtMt at subdirectory 'lib/irrlichtmt'
-- Using GMP provided by system.
-- Using JsonCpp provided by system.
-- Using LuaJIT provided by system.
-- cURL support enabled.
-- GetText disabled.
-- ncurses console enabled.
-- PostgreSQL backend enabled
-- PostgreSQL includes: /usr/include/postgresql
-- LevelDB not found!
-- Redis not found!
-- Prometheus client disabled.
-- SpatialIndex not found!
-- Looking for ZSTD_initCStream
-- Looking for ZSTD_initCStream - found
-- Could NOT find Doxygen (missing: DOXYGEN_EXECUTABLE)
-- Configuring done
-- Generating done
-- Build files have been written to: /home/cyberarm/Code/minetest Crash Dump: Reading symbols from /home/cyberarm/Code/minetest/bin/minetestserver...
(No debugging symbols found in /home/cyberarm/Code/minetest/bin/minetestserver)
Starting program: /home/cyberarm/Code/minetest/bin/minetestserver --world /home/cyberarm/MineTest/ --config /home/cyberarm/MineTest/minetest.conf
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/aarch64-linux-gnu/libthread_db.so.1".
[New Thread 0xfffff68106c0 (LWP 431131)]
[New Thread 0xfffff600f6c0 (LWP 431132)]
[MOD] Bees Loaded
[OK] Mesecons
[MOD] Mobs Redo loaded
[MOD] Mobs Redo Animals loaded
[MOD] Mob Horse loaded
[UnifiedDyes] Loaded!
[New Thread 0xffffefffc6c0 (LWP 431157)]
[New Thread 0xffffedbfa6c0 (LWP 431158)]
[New Thread 0xffffed3f96c0 (LWP 431159)]
[New Thread 0xffffecbf86c0 (LWP 431160)]
[New Thread 0xffffdbffc6c0 (LWP 431161)]
Unified Inventory. Inventory size: 950
[Thread 0xffffdbffc6c0 (LWP 431161) exited]
[New Thread 0xffffdbffc6c0 (LWP 431162)]
[Thread 0xffffdbffc6c0 (LWP 431162) exited]
[New Thread 0xffffdbffc6c0 (LWP 431191)]
[Thread 0xffffdbffc6c0 (LWP 431191) exited]
[New Thread 0xffffdbffc6c0 (LWP 431486)]
[Thread 0xffffdbffc6c0 (LWP 431486) exited]
Thread 5 "Server" received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0xffffedbfa6c0 (LWP 431158)]
0x0000fffff7cc3e0c in ?? () from /lib/aarch64-linux-gnu/libluajit-5.1.so.2
#0 0x0000fffff7cc3e0c in ?? () from /lib/aarch64-linux-gnu/libluajit-5.1.so.2
#1 0x0000fffff7d132b0 in lua_pcall ()
from /lib/aarch64-linux-gnu/libluajit-5.1.so.2
#2 0x00000002001258c8 in ScriptApiBase::runCallbacksRaw(int, RunCallbacksMode, char const*) ()
#3 0x00000002001293f4 in ScriptApiEnv::environment_Step(float) ()
#4 0x0000000200392af8 in ServerEnvironment::step(float) ()
#5 0x0000000200378e0c in Server::AsyncRunStep(bool) ()
#6 0x000000020037b210 in ServerThread::run() ()
#7 0x00000002001aeeb8 in Thread::threadProc(Thread*) ()
#8 0x0000fffff7966cac in ?? () from /lib/aarch64-linux-gnu/libstdc++.so.6
#9 0x0000fffff7c06648 in start_thread (arg=0xffffedbf9fc0)
at pthread_create.c:477
#10 0x0000fffff7729c1c in thread_start ()
at ../sysdeps/unix/sysv/linux/aarch64/clone.S:78 |
Try recompiling Minetest with LuaJIT from git first to see if that fixes the crashes. |
@sfan5 I totally wipped the Raspberry server and did a full reinstall. Right now the server looks stable, I had no Segentation Fault. So, I feel that replacing the LuaJIT package does fix the issue, but I had to do this before the first minetest compile. Thanks @sfan5 for suggesting the LuaJIT package replacement, it looks like it fixed the problem. |
Uhm, if the problem is LuaJIT itself, it's not up to us, is it? |
It seems to be working. It's been running since a bit before sfan5 posted. I ensured that the luajit-dev package was completely removed and then cloned luajit from (The server was crashing less and less often each time I restarted the server before trying without luajit and then running with luajit from source so it might still crash- eventually.) |
Working settings:
Crash constently :
Recompiled for debug :
After running:
I get:
The config use is a minimal "Minetest Game" with no mod activated.
Once in a while it runs for few minutes.
When LuaJIT is not used, it is stable but a lot slower :)
I hope there is enough info here to get help.
Thanks
The text was updated successfully, but these errors were encountered: