[GH-ISSUE #3329] [Feature Request] Support for non-systemd Linux distributions (OpenRC, runit, dinit, s6, SysVinit) #3196

Closed
opened 2026-10-27 06:18:42 +07:00 by bsakaguchi · 2 comments
Owner

Originally created by @Werko1a on GitHub (Oct 26, 2026).
Original GitHub issue: https://github.com/amnezia-vpn/amnezia-client/issues/3329

I recently encountered a major problem: when I tried running AmneziaVPN on Gentoo Linux with OpenRC, the client immediately failed and crashed. When I reached out to official support, they couldn't help since non-systemd distributions are not officially supported. ( This relates to the problems discussed in #775 and #3000)

So I decided to investigate what was actually causing the failure and built a working solution myself.
After digging into the logs and daemon behavior, I found that AmneziaVPN-service itself is a standard Qt process and doesn't actually need systemd. The failures come down to three specific external dependencies:

  1. The installer hardcodes systemctl, failing on any alternative init system.
  2. Strict reliance on systemd-resolved via D-Bus (org.freedesktop.resolve1): when Amnezia connects, it applies iptables drop rules for port 53, but because systemd-resolved doesn't exist, the DNS configuration fails completely. The result is a connected tunnel with zero working Internet.
  3. Improper lifecycle and socket handling: killing the process leaves stale Unix sockets in /tmp/, causing immediate EADDRINUSE crash loops on restart, while stopping the daemon leaves orphaned amnvpn.* chains cluttering the firewall.

To solve this for Gentoo, Artix, Void, and other non-systemd distros, I created a universal compatibility layer with a lightweight D-Bus DNS bridge and supervised service scripts:
Repo: https://github.com/Werko1a/amneziavpn-non-systemd

It has been thoroughly tested and verified on an Artix Linux VM (OpenRC):

  • Service cleanly survives kill -9 without stale socket deadlocks;
  • DNS resolves properly through the tunnel via the D-Bus shim;
  • Firewall rules are completely purged across all tables on service stop.

(The initial scaffolding was assisted by AI tools, but every script, template, and fix has been manually verified, debugged, and tested on an Artix Linux OpenRC environment).

Originally created by @Werko1a on GitHub (Oct 26, 2026). Original GitHub issue: https://github.com/amnezia-vpn/amnezia-client/issues/3329 I recently encountered a major problem: when I tried running AmneziaVPN on Gentoo Linux with OpenRC, the client immediately failed and crashed. When I reached out to official support, they couldn't help since non-systemd distributions are not officially supported. ( This relates to the problems discussed in #775 and #3000) So I decided to investigate what was actually causing the failure and built a working solution myself. After digging into the logs and daemon behavior, I found that `AmneziaVPN-service` itself is a standard Qt process and doesn't actually need systemd. The failures come down to three specific external dependencies: 1. The installer hardcodes `systemctl`, failing on any alternative init system. 2. Strict reliance on `systemd-resolved` via D-Bus (`org.freedesktop.resolve1`): when Amnezia connects, it applies `iptables` drop rules for port 53, but because `systemd-resolved` doesn't exist, the DNS configuration fails completely. The result is a connected tunnel with zero working Internet. 3. Improper lifecycle and socket handling: killing the process leaves stale Unix sockets in `/tmp/`, causing immediate `EADDRINUSE` crash loops on restart, while stopping the daemon leaves orphaned `amnvpn.*` chains cluttering the firewall. To solve this for Gentoo, Artix, Void, and other non-systemd distros, I created a universal compatibility layer with a lightweight D-Bus DNS bridge and supervised service scripts: Repo: https://github.com/Werko1a/amneziavpn-non-systemd It has been thoroughly tested and verified on an Artix Linux VM (OpenRC): - Service cleanly survives `kill -9` without stale socket deadlocks; - DNS resolves properly through the tunnel via the D-Bus shim; - Firewall rules are completely purged across all tables on service stop. *(The initial scaffolding was assisted by AI tools, but every script, template, and fix has been manually verified, debugged, and tested on an Artix Linux OpenRC environment).*
Author
Owner

@Werko1a commented on GitHub (Oct 26, 2026):

Also, when I find some free time, I'm planning to write a native C++ patch for DnsUtilsLinux (to handle openresolv / /etc/resolv.conf fallback natively)

<!-- gh-comment-id:6416706094 --> @Werko1a commented on GitHub (Oct 26, 2026): Also, when I find some free time, I'm planning to write a native C++ patch for DnsUtilsLinux (to handle openresolv / /etc/resolv.conf fallback natively)
Author
Owner

@Werko1a commented on GitHub (Oct 28, 2026):

closed due to making a pr with native c++ patch

<!-- gh-comment-id:6464679375 --> @Werko1a commented on GitHub (Oct 28, 2026): closed due to making a pr with native c++ patch
Sign in to join this conversation.
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
amnezia-vpn/amnezia-client#3196
No description provided.