I’ve found this page about a solution for SUID problem: What’s with chrome sandbox & electron? – Hacking and Learning
I’ve just set the owner and permissions as following: root:trilium
4755
. Now I get the following error:
Jul 10 13:11:14 systemd[1]: Started trilium.service - Trilium: notes server.
Jul 10 13:11:14 trilium[2950727]: The setuid sandbox is not running as root. Common causes:
Jul 10 13:11:14 trilium[2950727]: * An unprivileged process using ptrace on it, like a debugger.
Jul 10 13:11:14 trilium[2950727]: * A parent process set prctl(PR_SET_NO_NEW_PRIVS, ...)
Jul 10 13:11:14 trilium[2950727]: Failed to move to new namespace: PID namespaces supported, Network namespace supported, but failed: errno = Operation not permitted
Jul 10 13:11:14 trilium[2950706]: [2950706:0710/131114.811952:FATAL:zygote_host_impl_linux.cc(207)] Check failed: . : Invalid argument (22)
Jul 10 13:11:14 systemd[1]: trilium.service: Main process exited, code=killed, status=5/TRAP
Jul 10 13:11:14 systemd[1]: trilium.service: Failed with result 'signal'.
EDIT
I tried another solution based on this article: Solve “The SUID sandbox helper binary was found, but is not configured correctly.” (3 solutions!) | by Authmane Terki | Medium
systemctl edit trilium
and added the following lines:
[Service]
ExecStart=
ExecStart=/var/www/trilium/trilium --disable-gpu --no-sandbox
Started the service, it was almost going to start but… I get a display error:
Jul 10 14:13:36 systemd[1]: Started trilium.service - Trilium: notes server.
Jul 10 14:13:38 trilium[2961867]: (node:2961867) ExperimentalWarning: Importing JSON modules is an experimental feature and might change at any time
Jul 10 14:13:38 trilium[2961867]: (Use `trilium --trace-warnings ...` to show where the warning was created)
Jul 10 14:13:39 trilium[2961867]: Language option not found, falling back to en.
Jul 10 14:13:40 trilium[2961867]: Language option not found, falling back to en.
Jul 10 14:13:40 trilium[2961867]: Generated session secret
Jul 10 14:13:41 trilium[2961867]: DB not initialized, please visit setup page
Jul 10 14:13:41 trilium[2961867]: DB size: 4 KB
Jul 10 14:13:41 trilium[2961867]: {
Jul 10 14:13:41 trilium[2961867]: "appVersion": "0.91.6",
Jul 10 14:13:41 trilium[2961867]: "dbVersion": 228,
Jul 10 14:13:41 trilium[2961867]: "nodeVersion": "v20.18.1",
Jul 10 14:13:41 trilium[2961867]: "syncVersion": 34,
Jul 10 14:13:41 trilium[2961867]: "buildDate": "2025-02-03T17:08:06Z",
Jul 10 14:13:41 trilium[2961867]: "buildRevision": "79e830b6ea22e51196bdca4c021f30ecfad92723",
Jul 10 14:13:41 trilium[2961867]: "dataDirectory": "/home/yunohost.app/trilium",
Jul 10 14:13:41 trilium[2961867]: "clipperProtocolVersion": "1.0",
Jul 10 14:13:41 trilium[2961867]: "utcDateTime": "2025-07-10T11:13:39.070Z"
Jul 10 14:13:41 trilium[2961867]: }
Jul 10 14:13:41 trilium[2961867]: CPU model: Intel(R) Xeon(R) CPU E5-2697 v2 @ 2.70GHz, logical cores: 4, freq: 0 Mhz
Jul 10 14:13:41 trilium[2961867]: Trusted reverse proxy: false
Jul 10 14:13:41 trilium[2961867]: App HTTP server starting up at port 37840
Jul 10 14:13:41 trilium[2961867]: Listening on port 37840
Jul 10 14:13:41 trilium[2961867]: [2961867:0710/141341.205839:ERROR:ozone_platform_x11.cc(246)] Missing X server or $DISPLAY
Jul 10 14:13:41 trilium[2961867]: [2961867:0710/141341.206120:ERROR:env.cc(257)] The platform failed to initialize. Exiting.
Jul 10 14:13:41 systemd[1]: trilium.service: Main process exited, code=killed, status=11/SEGV
So, if it will be deployed as a server, it should be started in the sandbox, therefore this solution was for desktop applications 