August 4, 2026 · Platforms · About 10 min

Install v2rayN on Linux: deb and rpm packages, autostart setup

Install v2rayN on Debian, Ubuntu, Fedora, or openSUSE with deb or rpm packages. Learn how to handle dependencies, add a desktop startup entry, and fix common permission issues.

At a glance

To install v2rayN on a Linux desktop, choose the package for your distribution and CPU architecture, then let the package manager handle dependencies. Launch it as a regular user, verify the local proxy, and then configure it to start at login. This guide distinguishes desktop autostart from background services and is for anyone running the desktop client on Debian, Ubuntu, Fedora, or openSUSE.

Before you install: check your distribution, architecture, and setup

v2rayN is a desktop client, and its Linux GUI uses Avalonia. The client manages configurations, starts the core, and displays logs; the selected core handles proxy connections. Installing the desktop package does not create a system service that runs at boot, nor does it automatically route every app through the proxy.

Run these two commands first. If uname -m returns x86_64, choose the x64 package; if it returns aarch64, choose arm64. Your distribution determines whether to use a deb or rpm package. Don’t infer the architecture from your computer’s brand.

cat /etc/os-release
uname -m

Debian / Ubuntu

Package format
deb
x64 architecture
amd64
ARM architecture
arm64
Install tool
apt

You can also read the package architecture with dpkg-deb and compare it with your system’s dpkg architecture.

Fedora / openSUSE

Package format
rpm
x64 architecture
x86_64
ARM architecture
aarch64
Install tool
dnf / zypper

Both use rpm packages, but repository configurations and dependency names may differ.

For the commands below, rename the downloaded package to v2rayN.deb or v2rayN.rpm and place it in ~/Downloads. This is just a local filename, not the package’s original name. If your downloads are in another directory, navigate there first. Get the package from the client download page, and don’t try to force-install a package built for a different architecture.

Debian and Ubuntu: install a local deb package with apt

Use apt install ./filename whenever possible. The ./ prefix identifies a local file, and apt resolves the package’s declared dependencies using your enabled repositories. You can also unpack a package with dpkg -i, but it won’t automatically download missing dependencies, so it shouldn’t be your only step for a first-time install.

cd ~/Downloads
dpkg --print-architecture
dpkg-deb -f ./v2rayN.deb Package Version Architecture
sudo apt update
sudo apt install ./v2rayN.deb
  1. Check package details

    Compare your system architecture with the package’s Architecture field. Note the Version field too, so you can include both the client and system versions when troubleshooting.

  2. Install dependencies

    Review apt’s installation plan. If it proposes removing a large number of desktop components, cancel rather than using force options to bypass the conflict.

  3. Launch it manually for the first time

    Find v2rayN in your desktop app menu and launch it as your current user. The install command requires sudo; launching the GUI does not.

  4. Capture error output

    If no window appears, check the Exec field in the desktop launcher file, then run the corresponding program from a terminal and capture the full error output.

If an earlier dpkg install left the package unconfigured, run the repair command below. It may install dependencies or propose removing packages with unresolved dependencies; review the plan before continuing. If your repositories are unreachable, fix your network or repository configuration first. Repeatedly unpacking the package won’t fix download failures.

sudo apt --fix-broken install
sudo dpkg --configure -a

Fedora and openSUSE: install rpm packages with your distribution’s package manager

rpm is a package format, not a guarantee of compatibility across distributions. Fedora uses dnf, while openSUSE uses zypper; use your system’s package manager to resolve dependencies. Check the package details and confirm its architecture and version before running the install command for your distribution.

cd ~/Downloads
rpm -qp --queryformat '%{NAME} %{VERSION}-%{RELEASE} %{ARCH}\n' ./v2rayN.rpm

# Fedora
sudo dnf install ./v2rayN.rpm

# openSUSE: use this command; don’t repeat the dnf command above
sudo zypper install ./v2rayN.rpm
IssueCheck firstHow to handle it
Architecture mismatchPackage ARCH and uname outputChoose the correct x64 or arm64 package; don’t force an architecture mismatch
Dependency not foundDistribution version and enabled repositoriesDon’t mix core runtime libraries across distributions
Runtime library version too oldGLIBC or other version requirements reported in the terminalConsider upgrading the system; don’t replace the system libc manually
Package source confirmation promptDownload source and package manager promptVerify the source before deciding; don’t disable security checks globally

If installation succeeds but the app won’t launch, distinguish between satisfied package dependencies and an available graphical environment. A missing graphical session, display environment variables, or a remote terminal not connected to the desktop can all prevent the GUI from opening. Don’t use sudo to mask these problems.

First launch: verify the local listener before enabling the system proxy

Import a node or subscription you already have, select an available node, and verify that the core is listening. A subscription contains server connection details; an arbitrary address won’t work as a test. Check that the protocol and transport combination is supported by your current core, and review the logs again after switching cores.

In versions that provide these menu items, go to “Settings” → “Parameter Settings” → “Basic Settings” to check the local listening port. Port numbers and menu names can change between versions, so use the values shown in your client. The examples below use an HTTP proxy listening on 127.0.0.1:10808 for troubleshooting; you don’t need to replace your existing settings.

10808
HTTP proxy port used in this guide
127.0.0.1
Listener address accessible only from this machine
15 seconds
Timeout for the curl request below
ss -lntp 'sport = :10808'
curl --proxy http://127.0.0.1:10808 --max-time 15 -I https://example.com/

The first command checks for a TCP listener; the second explicitly sends an HTTP proxy request to a test site. If the port provides SOCKS only, use socks5h://127.0.0.1:10808 instead; the proxy resolves the hostname. If nothing is listening, check for core startup errors first rather than assuming the connection is slow.

Desktop autostart: use a per-user login entry

For a desktop client, “start at boot” usually means launching automatically after you sign in to the graphical desktop. XDG Autostart is the recommended approach: reuse the desktop file provided by the package, keeping its correct Exec command, icon, and launch options. This avoids guessing the main program’s location and running the entire client as root.

XDG login startup

Recommended

Launches in the current user’s graphical session and uses the desktop environment and user settings. Best for desktop setups that need a tray icon and window.

Best for: personal Linux desktops that should connect automatically at login

systemd service

A service needs its own environment, permissions, and lifecycle configuration. A system-level service doesn’t automatically have access to a graphical session, so don’t apply one directly to a desktop GUI.

Best for: background setups that explicitly need the core to run independently

First, check whether “Settings” → “Parameter Settings” in the client offers a “Start automatically at boot” option. If your version already creates a working per-user startup entry, use it as is; don’t create another one, or the client may launch twice at login. To configure autostart manually, locate the desktop file included in the package first:

find /usr/share/applications -maxdepth 1 -type f -iname '*v2rayn*.desktop' -print

Only run the copy command below if you find exactly one matching file. The script checks the number of matches so it won’t arbitrarily choose one of multiple desktop launchers. If there are no matches, inspect the package contents with dpkg-deb -c for deb or rpm -qlp for rpm, and confirm the desktop file’s actual name and location.

bash <<'BASH'
mapfile -t entries < <(find /usr/share/applications -maxdepth 1 -type f -iname '*v2rayn*.desktop')
if [ "${#entries[@]}" -ne 1 ]; then
  printf 'Exactly one desktop entry is required; found %s.\n' "${#entries[@]}"
  exit 1
fi
target="${XDG_CONFIG_HOME:-$HOME/.config}/autostart"
mkdir -p "$target"
cp -- "${entries[0]}" "$target/v2rayN.desktop"
chmod 644 "$target/v2rayN.desktop"
grep -E '^(Type|Name|Exec|TryExec|Hidden|OnlyShowIn|NotShowIn|X-GNOME-Autostart-enabled)=' "$target/v2rayN.desktop"
BASH

After saving, log out and sign in again. Check that only one client process starts and that the example port is listening again. Closing and reopening the window doesn’t verify login startup. If a client update changes the install path or launch options, update any manually copied desktop file too.

Common issues with permissions, the tray, and relaunching

Follow the same troubleshooting order each time: can the program start, can the core listen, can a request get through, and does autostart work at login? This helps distinguish a hidden window, a port conflict, and a network problem. These four issues are especially common on a first setup.

Installed, but v2rayN isn’t in the app menu?

Run the find command above to check for the desktop file, then inspect the package contents. If the file exists, log out and back in to refresh the app menu. If it doesn’t, check that you downloaded the expected desktop package rather than guessing the executable path.

It launches with sudo, but a regular user gets a permissions error?

Stop the instance running as root first. Check the error in a terminal to identify the specific configuration directory, then use ls -ld to check its owner. Fix ownership only for confirmed application configuration directories belonging to your user. Don’t recursively change permissions on your entire home or install directory, and never make files globally writable.

No window after login—did the app start?

Use your system’s process viewer to search for v2rayN, then check whether it’s listening locally. The app may be minimized to the tray; some desktop environments require tray support to be enabled separately. For the initial test, turn off the client’s launch-hidden option. Once you’ve confirmed the window appears, you can change it back.

The log says “address already in use”—what now?

Run ss -lntp 'sport = :10808' to find the process using the port. If you don’t have permission, use sudo for this diagnostic command only. Rule out duplicate autostart entries first, then decide whether to stop the old instance or change the listening port. If you change the port, update your system proxy and command-line options too.

Updates and rollbacks: keep package management and startup entries in sync

For future updates, install the new package using the same package manager. Back up your configuration in the client first, and keep subscription URLs and node credentials secure; they may grant access and shouldn’t appear in public troubleshooting screenshots. After updating, check the client and core versions, listening port, and autostart entry again.

  1. Exit the client and confirm that the process and core have stopped before installing a package for the correct architecture.
  2. Launch the client manually, complete one request using an explicitly specified proxy, then log out and back in to verify autostart.
  3. If the new version fails, save the specific error and check whether its system runtime requirements have changed. Don’t delete all user configuration as a first step.
  4. To roll back, use the version management method supported by your package manager. Check compatibility with older-version settings separately; don’t assume compatibility in both directions.
  5. To disable manual login startup, remove the corresponding desktop file from your user’s autostart directory. Uninstalling the system package may not remove a file you copied there yourself.

A successful setup means more than just opening a window: the client starts as a regular user, proxy requests work, only one instance launches at login, and the app’s network state is restored when it exits. Verify each of these four points to quickly narrow down future issues to installation, the core, the proxy entry point, or the desktop session.

Download v2rayN