[GH-ISSUE #2364] [Bug] AmneziaVPN-service not work in Windows Server 2016, 2019, 2022 (and all oldest), but work in 2025 server version #1044

Open
opened 2026-10-13 20:33:21 +00:00 by bsakaguchi · 2 comments
Owner

Originally created by @Andrew-1111111 on GitHub (Mar 17, 2026).
Original GitHub issue: https://github.com/amnezia-vpn/amnezia-client/issues/2364

Service AmneziaVPN-service.exe not started, error code: 103.

If run the file directly in 2019, 2022, error: wlanapi.dll is missing.
If run the file directly in 2016, error: The procedure entry point SetThreadDescription could not be found in the Qt6Core.dll library.
In 2012 r2 installation error: missing d3d12.dll

Originally created by @Andrew-1111111 on GitHub (Mar 17, 2026). Original GitHub issue: https://github.com/amnezia-vpn/amnezia-client/issues/2364 Service AmneziaVPN-service.exe not started, error code: 103. If run the file directly in 2019, 2022, error: wlanapi.dll is missing. If run the file directly in 2016, error: The procedure entry point SetThreadDescription could not be found in the Qt6Core.dll library. In 2012 r2 installation error: missing d3d12.dll
Author
Owner

@funkwerkstatt-design commented on GitHub (Mar 24, 2026):

just install wireless lan service via server manager

<!-- gh-comment-id:4115900064 --> @funkwerkstatt-design commented on GitHub (Mar 24, 2026): just install wireless lan service via server manager
Author
Owner

@Andrew-1111111 commented on GitHub (Mar 24, 2026):

Hi.

Yes, it works for 2019 and 2022 OS versions.
But need integrate this step in installation process.

#include <windows.h>
#include <stdio.h>

typedef LONG NTSTATUS;
#define STATUS_SUCCESS ((NTSTATUS)0x00000000L)

typedef struct _RTL_OSVERSIONINFOEXW {
    ULONG dwOSVersionInfoSize;
    ULONG dwMajorVersion;
    ULONG dwMinorVersion;
    ULONG dwBuildNumber;
    ULONG dwPlatformId;
    WCHAR szCSDVersion[128];
    USHORT wServicePackMajor;
    USHORT wServicePackMinor;
    USHORT wSuiteMask;
    UCHAR  wProductType;
    UCHAR  wReserved;
} RTL_OSVERSIONINFOEXW, *PRTL_OSVERSIONINFOEXW;

typedef NTSTATUS (WINAPI* RtlGetVersionPtr)(PRTL_OSVERSIONINFOEXW);

bool GetRealOSInfo(RTL_OSVERSIONINFOEXW& osInfo)
{
    HMODULE hMod = GetModuleHandleW(L"ntdll.dll");
    if (!hMod) return false;

    auto fxPtr = (RtlGetVersionPtr)GetProcAddress(hMod, "RtlGetVersion");
    if (!fxPtr) return false;

    osInfo.dwOSVersionInfoSize = sizeof(osInfo);
    return fxPtr(&osInfo) == STATUS_SUCCESS;
}

bool IsWindowsServer2019Or2022()
{
    RTL_OSVERSIONINFOEXW os = { 0 };

    if (!GetRealOSInfo(os))
        return false;

    if (os.wProductType == VER_NT_WORKSTATION)
        return false;

    // Windows Server 2019 → build 17763
    // Windows Server 2022 → build 20348
    return (os.dwBuildNumber == 17763 || os.dwBuildNumber == 20348);
}

And:

PowerShell: Install-WindowsFeature -Name Wireless-Networking
... over installation steps ...
A system reboot is required!

<!-- gh-comment-id:4116745963 --> @Andrew-1111111 commented on GitHub (Mar 24, 2026): Hi. Yes, it works for 2019 and 2022 OS versions. But need integrate this step in installation process. ``` #include <windows.h> #include <stdio.h> typedef LONG NTSTATUS; #define STATUS_SUCCESS ((NTSTATUS)0x00000000L) typedef struct _RTL_OSVERSIONINFOEXW { ULONG dwOSVersionInfoSize; ULONG dwMajorVersion; ULONG dwMinorVersion; ULONG dwBuildNumber; ULONG dwPlatformId; WCHAR szCSDVersion[128]; USHORT wServicePackMajor; USHORT wServicePackMinor; USHORT wSuiteMask; UCHAR wProductType; UCHAR wReserved; } RTL_OSVERSIONINFOEXW, *PRTL_OSVERSIONINFOEXW; typedef NTSTATUS (WINAPI* RtlGetVersionPtr)(PRTL_OSVERSIONINFOEXW); bool GetRealOSInfo(RTL_OSVERSIONINFOEXW& osInfo) { HMODULE hMod = GetModuleHandleW(L"ntdll.dll"); if (!hMod) return false; auto fxPtr = (RtlGetVersionPtr)GetProcAddress(hMod, "RtlGetVersion"); if (!fxPtr) return false; osInfo.dwOSVersionInfoSize = sizeof(osInfo); return fxPtr(&osInfo) == STATUS_SUCCESS; } bool IsWindowsServer2019Or2022() { RTL_OSVERSIONINFOEXW os = { 0 }; if (!GetRealOSInfo(os)) return false; if (os.wProductType == VER_NT_WORKSTATION) return false; // Windows Server 2019 → build 17763 // Windows Server 2022 → build 20348 return (os.dwBuildNumber == 17763 || os.dwBuildNumber == 20348); } ``` And: `PowerShell: Install-WindowsFeature -Name Wireless-Networking ` ... over installation steps ... A system reboot is required!
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#1044
No description provided.