ptitSeb / box64

Box64 - Linux Userspace x86_64 Emulator with a twist, targeted at ARM64 Linux devices
https://box86.org
MIT License
3.75k stars 267 forks source link

factorio server hangs with dynarec enabled on oracle linux #261

Open Slappy826 opened 2 years ago

Slappy826 commented 2 years ago

was trying to test out running factorio on an arm server i had and discovered that it wouldn't work if i compiled with dynarec enabled (i did have to change the page size from 4kb to 64kb as that is what the provided oracle linux image is compiled with? although im not so sure that increase the page size would have any bearing on whether or not it would work, due to 16k pages being supported)

this seems to only happen on oracle linux as i went out and tried both ubuntu on the same provider (oraclecloud) and suse linux on aws and it worked as expected

(oracle linux)

Dynarec for ARM64, with extension: ASIMD AES CRC32 PMULL ATOMICS PageSize:65536
Box64 with Dynarec v0.1.7 07a65d4 built on Mar 29 2022 11:44:07
Using default BOX64_LD_LIBRARY_PATH: ./:lib/:lib64/:x86_64/:bin64/:libs64/
Using default BOX64_PATH: ./:bin/
Counted 33 Env var
Looking for ./factorio/bin/x64/factorio
argv[1]="--create"
argv[2]="./asd.zip"
Using native(wrapped) librt.so.1
Using native(wrapped) libdl.so.2
Using native(wrapped) libm.so.6
Using native(wrapped) libpthread.so.0
Using native(wrapped) libc.so.6
Using native(wrapped) ld-linux-x86-64.so.2
   0.002 2022-03-29 13:49:00; Factorio 1.1.53 (build 59373, linux64, headless)
   0.003 Operating system: Linux
   0.004 Program arguments: "/home/opc/factorio/bin/x64/factorio" "--create" "./asd.zip" 
   0.005 Read data path: /home/opc/factorio/data
   0.005 Write data path: /home/opc/factorio [22159/36306MB]
   0.005 Binaries path: /home/opc/factorio/bin
   0.031 System info: [CPU:               Intel(R) Pentium(R) 4 CPU 1000MHz, 3 cores, RAM: 17102 MB]
   0.032 Environment: DISPLAY=<unset> WAYLAND_DISPLAY=<unset> DESKTOP_SESSION=<unset> XDG_SESSION_DESKTOP=<unset> XDG_CURRENT_DESKTOP=<unset> __GL_FSAA_MODE=<unset> __GL_LOG_MAX_ANISO=<unset> __GL_SYNC_TO_VBLANK=<unset> __GL_SORT_FBCONFIGS=<unset> __GL_YIELD=<unset>
   0.032 Running in headless mode
   0.111 Loading mod core 0.0.0 (data.lua)
   0.207 Loading mod base 1.1.53 (data.lua)
   0.706 Loading mod base 1.1.53 (data-updates.lua)
   0.908 Checksum for core: 1625176034
   0.908 Checksum of base: 98178652

the program seems to hang on that last output, turning debug on showed that it was seemingly doing something but i couldnt really see any useful information (on my part)

expected output (ran on ubuntu)

Dynarec for ARM64, with extension: ASIMD AES CRC32 PMULL ATOMICS PageSize:4096
Box64 with Dynarec v0.1.7 0a8bbe9 built on Mar 29 2022 13:42:09
Using default BOX64_LD_LIBRARY_PATH: ./:lib/:lib64/:x86_64/:bin64/:libs64/
Using default BOX64_PATH: ./:bin/
Counted 26 Env var
Looking for ./factorio/bin/x64/factorio
argv[1]="--create"
argv[2]="./test.zip"
Using native(wrapped) librt.so.1
Using native(wrapped) libdl.so.2
Using native(wrapped) libm.so.6
Using native(wrapped) libpthread.so.0
Using native(wrapped) libc.so.6
Using native(wrapped) ld-linux-x86-64.so.2
   0.001 2022-03-29 13:45:24; Factorio 1.1.53 (build 59373, linux64, headless)
   0.033 Operating system: Linux (Ubuntu 20.04)
   0.034 Program arguments: "/home/ubuntu/factorio/bin/x64/factorio" "--create" "./test.zip" 
   0.034 Read data path: /home/ubuntu/factorio/data
   0.034 Write data path: /home/ubuntu/factorio [43921/46053MB]
   0.034 Binaries path: /home/ubuntu/factorio/bin
   0.060 System info: [CPU:               Intel(R) Pentium(R) 4 CPU 1000MHz, 2 cores, RAM: 15971 MB]
   0.060 Environment: DISPLAY=<unset> WAYLAND_DISPLAY=<unset> DESKTOP_SESSION=<unset> XDG_SESSION_DESKTOP=<unset> XDG_CURRENT_DESKTOP=<unset> __GL_FSAA_MODE=<unset> __GL_LOG_MAX_ANISO=<unset> __GL_SYNC_TO_VBLANK=<unset> __GL_SORT_FBCONFIGS=<unset> __GL_YIELD=<unset>
   0.061 Running in headless mode
   0.166 Loading mod core 0.0.0 (data.lua)
   0.268 Loading mod base 1.1.53 (data.lua)
   0.815 Loading mod base 1.1.53 (data-updates.lua)
   1.035 Checksum for core: 1625176034
   1.035 Checksum of base: 98178652
   1.729 Prototype list checksum: 3034860339
   1.805 Info PlayerData.cpp:73: Local player-data.json unavailable
   1.805 Info PlayerData.cpp:78: Cloud player-data.json unavailable
   1.828 Factorio initialised
   1.829 Info Main.cpp:740: Creating new map /home/ubuntu/./test.zip
  94.688 Loading level.dat: 1242310 bytes.
  94.689 Info Scenario.cpp:198: Map version 1.1.53-0
  94.795 Checksum for script /home/ubuntu/factorio/temp/currently-playing/control.lua: 3795083680
Done.
  96.047 Goodbye
tsangsir commented 2 years ago

Sorry that I have no insight on this issue (yet), but just waiting to ask for information.

I would like to know change the page size from 4kb to 64kb? Actually I also wait to try box64 on Oracle Cloud.

rajdakin commented 2 months ago

Is this fixed now?