issue: warning "Cannot invoke 'uname` to get architecture type" emitted #72

Closed
opened 2026-02-16 12:51:19 -05:00 by yindo · 8 comments
Owner

Originally created by @MarioninD on GitHub (Oct 8, 2024).

Originally assigned to: @IAmTomahawkx on GitHub.

What happened?

I can't quite understand what the error is related to, I think I did everything according to the instructions :)

docker-compose logs api and minio/mc

Attaching to revolt_api_1
api_1            |  INFO  revolt_config > Starting revolt-delta@0.7.16
api_1            |  WARN  revolt_config > No Captcha key specified! Remember to add hCaptcha key.
api_1            |  **ERROR os_info::architecture > Cannot invoke 'uname` to get architecture type: Os { code: 2, kind: NotFound, message: "No such file or directory" }**
api_1            |  INFO  revolt_database::models::admin_migrations::ops::mongodb > Migrating the database.



createbuckets_1  | mc: <ERROR> Couldn't construct anonymous client for `minio`. No valid configuration found for 'minio' host alias.
createbuckets_1  | Waiting minio...
Originally created by @MarioninD on GitHub (Oct 8, 2024). Originally assigned to: @IAmTomahawkx on GitHub. ### What happened? I can't quite understand what the error is related to, I think I did everything according to the instructions :) docker-compose logs api and minio/mc ``` Attaching to revolt_api_1 api_1 | INFO revolt_config > Starting revolt-delta@0.7.16 api_1 | WARN revolt_config > No Captcha key specified! Remember to add hCaptcha key. api_1 | **ERROR os_info::architecture > Cannot invoke 'uname` to get architecture type: Os { code: 2, kind: NotFound, message: "No such file or directory" }** api_1 | INFO revolt_database::models::admin_migrations::ops::mongodb > Migrating the database. createbuckets_1 | mc: <ERROR> Couldn't construct anonymous client for `minio`. No valid configuration found for 'minio' host alias. createbuckets_1 | Waiting minio... ```
yindo added the bug label 2026-02-16 12:51:19 -05:00
yindo closed this issue 2026-02-16 12:51:19 -05:00
Author
Owner

@JoCat commented on GitHub (Oct 9, 2024):

Check to see if you can invoke the uname command on the system console

@JoCat commented on GitHub (Oct 9, 2024): Check to see if you can invoke the `uname` command on the system console
Author
Owner

@Sirse commented on GitHub (Oct 9, 2024):

Same issue. uname and uname -a works fine in host machine

@Sirse commented on GitHub (Oct 9, 2024): Same issue. uname and uname -a works fine in host machine
Author
Owner

@Deswolrd commented on GitHub (Oct 10, 2024):

Not sure if it's the same issue, but looks quite the same for me. Happens when trying to connect WebSocket

events-1         |  INFO  revolt_config > Starting revolt-bonfire@0.7.16
events-1         |  ERROR os_info::architecture > Cannot invoke 'uname` to get architecture type: Os { code: 2, kind: NotFound, message: "No such file or directory" }

Right after that, main thread collapses

events-1         | thread 'main' panicked at /home/rust/src/crates/core/presence/src/lib.rs:166:43:
events-1         | Redis connection: FailedConnection
events-1         | note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

uname in host machine looks good as far as I can tell

uname -a
Linux debian 6.1.0-18-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.76-1 (2024-02-01) x86_64 GNU/Linux

Fresh setup with .env / Revolt.toml changes for external access via reverse proxy (curl and wscat from local machine directly provides the same results). Used mongo version (4.4 for older CPU as guide says).

@Deswolrd commented on GitHub (Oct 10, 2024): Not sure if it's the same issue, but looks quite the same for me. Happens when trying to connect WebSocket ``` events-1 | INFO revolt_config > Starting revolt-bonfire@0.7.16 events-1 | ERROR os_info::architecture > Cannot invoke 'uname` to get architecture type: Os { code: 2, kind: NotFound, message: "No such file or directory" } ``` Right after that, main thread collapses ``` events-1 | thread 'main' panicked at /home/rust/src/crates/core/presence/src/lib.rs:166:43: events-1 | Redis connection: FailedConnection events-1 | note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace ``` uname in host machine looks good as far as I can tell ``` uname -a Linux debian 6.1.0-18-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.76-1 (2024-02-01) x86_64 GNU/Linux ``` Fresh setup with .env / Revolt.toml changes for external access via reverse proxy (curl and wscat from local machine directly provides the same results). Used mongo version (4.4 for older CPU as guide says).
Author
Owner

@Sirse commented on GitHub (Oct 10, 2024):

Not sure if it's the same issue, but looks quite the same for me. Happens when trying to connect WebSocket

events-1         |  INFO  revolt_config > Starting revolt-bonfire@0.7.16
events-1         |  ERROR os_info::architecture > Cannot invoke 'uname` to get architecture type: Os { code: 2, kind: NotFound, message: "No such file or directory" }

Right after that, main thread collapses

events-1         | thread 'main' panicked at /home/rust/src/crates/core/presence/src/lib.rs:166:43:
events-1         | Redis connection: FailedConnection
events-1         | note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

uname in host machine looks good as far as I can tell

uname -a
Linux debian 6.1.0-18-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.76-1 (2024-02-01) x86_64 GNU/Linux

Fresh setup with .env / Revolt.toml changes for external access via reverse proxy (curl and wscat from local machine directly provides the same results). Used mongo version (4.4 for older CPU as guide says).

Yes, absolutely same issue (Ubuntu 24.04.1 LTS), old homelab Intel NUC with mongo 4.4.

@Sirse commented on GitHub (Oct 10, 2024): > Not sure if it's the same issue, but looks quite the same for me. Happens when trying to connect WebSocket > > ``` > events-1 | INFO revolt_config > Starting revolt-bonfire@0.7.16 > events-1 | ERROR os_info::architecture > Cannot invoke 'uname` to get architecture type: Os { code: 2, kind: NotFound, message: "No such file or directory" } > ``` > > Right after that, main thread collapses > > ``` > events-1 | thread 'main' panicked at /home/rust/src/crates/core/presence/src/lib.rs:166:43: > events-1 | Redis connection: FailedConnection > events-1 | note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace > ``` > > uname in host machine looks good as far as I can tell > > ``` > uname -a > Linux debian 6.1.0-18-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.76-1 (2024-02-01) x86_64 GNU/Linux > ``` > > Fresh setup with .env / Revolt.toml changes for external access via reverse proxy (curl and wscat from local machine directly provides the same results). Used mongo version (4.4 for older CPU as guide says). Yes, absolutely same issue (Ubuntu 24.04.1 LTS), old homelab Intel NUC with mongo 4.4.
Author
Owner

@JVT038 commented on GitHub (Oct 13, 2024):

Same error here, on Synology DS918+.

@JVT038 commented on GitHub (Oct 13, 2024): Same error here, on Synology DS918+.
Author
Owner

@Macarthurval commented on GitHub (Oct 24, 2024):

Same issue here.

uname -a
Linux revolt-chat 5.14.0-513.el9.x86_64 #1 SMP PREEMPT_DYNAMIC Fri Sep 27 07:50:59 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
@Macarthurval commented on GitHub (Oct 24, 2024): Same issue here. ``` uname -a Linux revolt-chat 5.14.0-513.el9.x86_64 #1 SMP PREEMPT_DYNAMIC Fri Sep 27 07:50:59 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux ```
Author
Owner

@brownian-motion commented on GitHub (Nov 10, 2024):

I'm hosting on Linux/Ubuntu and ran into the same problem.

The error message is created in the os_info library, when i tries to run uname: https://github.com/stanislav-tkach/os_info/blob/master/os_info/src/architecture.rs#L10
Because the revolt image is stripped-down and has no executables, this library call fails to execute uname and fails.

I was able to work around it by modifying my compose.yml to manually copy uname from the original image used to build revolt in the first place.

Specifically, I made this change to my compose.yml:

BEFORE

  # API server (delta)
  api:
    image: ghcr.io/revoltchat/server:20240929-1

AFTER

  # API server (delta)
  api:
    build:
      dockerfile_inline: |
        FROM rust:1.77.2-slim-bookworm AS builder
        FROM ghcr.io/revoltchat/server:20240929-1 AS target
        COPY --from=builder /bin/uname /usr/bin/uname
@brownian-motion commented on GitHub (Nov 10, 2024): I'm hosting on Linux/Ubuntu and ran into the same problem. The error message is created in the `os_info` library, when i tries to run `uname`: https://github.com/stanislav-tkach/os_info/blob/master/os_info/src/architecture.rs#L10 Because the `revolt` image is stripped-down and has no executables, this library call fails to execute `uname` and fails. I was able to work around it by modifying my `compose.yml` to manually copy `uname` from the original image used to build `revolt` in the first place. Specifically, I made this change to my `compose.yml`: BEFORE ```yml # API server (delta) api: image: ghcr.io/revoltchat/server:20240929-1 ``` AFTER ```yml # API server (delta) api: build: dockerfile_inline: | FROM rust:1.77.2-slim-bookworm AS builder FROM ghcr.io/revoltchat/server:20240929-1 AS target COPY --from=builder /bin/uname /usr/bin/uname ```
Author
Owner

@IAmTomahawkx commented on GitHub (Dec 12, 2024):

This is fixed in build 20241212-1

@IAmTomahawkx commented on GitHub (Dec 12, 2024): This is fixed in build 20241212-1
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: stoatchat/self-hosted#72