spacedrive
spacedrive copied to clipboard
Server container fails to start [/usr/lib/spacedrive/libonnxruntime.so.1.16.3: cannot allocate memory in static TLS block"]
Describe the bug
It fails to load the libonnxruntime, seems like an issue with memory allocation
Reproduction
- Setup SD server container with docker compose
services:
sd:
image: ghcr.io/spacedriveapp/spacedrive/server
container_name: 'spacedrive'
restart: unless-stopped
ports:
- '8080:8080'
volumes:
- sd-data:/data
volumes:
sd-data:
compose up
Expected behavior
Container successfully starts
Platform and versions
- Docker Desktop 4.26.1 and observed the same on another docker host
- Latest container image
Stack trace
2024-01-25 22:50:49 2024-01-25T21:50:49.331434Z INFO sd_core: core/src/lib.rs:88: Starting core with data directory '/data'
2024-01-25 22:50:49 2024-01-25T21:50:49.331779Z WARN sd_core::util::version_manager: core/src/util/version_manager.rs:159: Config file for sd_core::node::config::NodeConfig does not exist, trying to create a new one with version -> V2
2024-01-25 22:50:49 2024-01-25T21:50:49.332338Z ERROR sd_core: core/src/lib.rs:205: panicked at /root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ort-2.0.0-alpha.2/src/lib.rs:95:79:
2024-01-25 22:50:49 could not load the library at `/usr/lib/spacedrive/libonnxruntime.so.1.16.3`: DlOpen { desc: "/usr/lib/spacedrive/libonnxruntime.so.1.16.3: cannot allocate memory in static TLS block" } panic.file="/root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ort-2.0.0-alpha.2/src/lib.rs:95" panic.column=79
2024-01-25 22:50:50 2024-01-25T21:50:50.129179Z INFO sd_core: core/src/lib.rs:88: Starting core with data directory '/data'
2024-01-25 22:50:50 2024-01-25T21:50:50.130041Z ERROR sd_core: core/src/lib.rs:205: panicked at /root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ort-2.0.0-alpha.2/src/lib.rs:95:79:
2024-01-25 22:50:50 could not load the library at `/usr/lib/spacedrive/libonnxruntime.so.1.16.3`: DlOpen { desc: "/usr/lib/spacedrive/libonnxruntime.so.1.16.3: cannot allocate memory in static TLS block" } panic.file="/root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ort-2.0.0-alpha.2/src/lib.rs:95" panic.column=79
Additional context
No response
Weird, this was a known issue (happened with the desktop version), that was technically already fixed, and the fix should apply to the server version too. here. But for some reason it stopped working, I will take a look at it, thanks for reporting.
(not that it matters), but I can confirm that this issue still exists in 0.2.3.
2024-02-04T22:30:35.734928Z INFO sd_core: core/src/lib.rs:88: Starting core with data directory '/data'
2024-02-04T22:30:35.736211Z ERROR sd_core: core/src/lib.rs:211: panicked at /root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ort-2.0.0-alpha.2/src/lib.rs:95:79:
could not load the library at `/usr/lib/spacedrive/libonnxruntime.so.1.16.3`: DlOpen { desc: "/usr/lib/spacedrive/libonnxruntime.so.1.16.3: cannot allocate memory in static TLS block" } panic.file="/root/.cargo/registry/src/index.crates.io-6f17d22bba15001f/ort-2.0.0-alpha.2/src/lib.rs:95" panic.column=79
fatal runtime error: failed to initiate panic, error 3