This guide is for Linux users with a graphical desktop. Check your distribution and architecture, then install the local package with APT or DNF. Once the app launches successfully, configure it to start at desktop login, then check the local proxy port and your apps' proxy settings.
Choose a package for your distribution and architecture
Check your system ID and machine architecture in a terminal. In /etc/os-release, ID and VERSION_ID identify your distribution and its version; uname -m reports the machine architecture. Before installing, check the release notes to make sure your system version is supported. A matching file extension does not guarantee compatible dependencies.
cat /etc/os-release
uname -m
Debian / Ubuntu
- Package format
.deb- Package manager
- APT
- Userspace architecture
dpkg --print-architecture- Common architecture names
amd64、arm64
Use the package's Architecture field and the system architecture reported by dpkg as your reference.
Fedora
- Package format
.rpm- Package manager
- DNF
- System architecture
rpm --eval '%{_arch}'- Common architecture names
x86_64、aarch64
Other RPM-based distributions may use different library versions and package names.
On the download page, x64 means x86_64, and arm64 means aarch64. If no package is available for your architecture and release, don't bypass the checks with a force-install option. The DNF commands below are for Fedora desktop installations that use DNF to manage system packages, not Fedora variants that manage software as system images.
Install the DEB or RPM package and verify the desktop launcher
-
Check package details
Open a terminal in the directory containing the package. To use the commands below as written, you can rename the downloaded file to
v2rayn.deborv2rayn.rpm. Renaming changes only the filename; the package manager reads the package name, version, and architecture from the package itself. -
Install the local package
Choose the command for your system.
./specifies a file in the current directory. APT and DNF will try to fetch missing dependencies from your configured repositories based on the package's dependency declarations. Review the transaction summary before confirming, especially any packages marked for removal. -
Verify the app launcher
Open the desktop app menu, search for “v2rayN,” and launch it. In GNOME, open Activities and search; in KDE Plasma, search from the Application Launcher. Launch it as your regular desktop user. Don't use
sudoto start a graphical app, as this can save settings under another user's account or cause permission issues. -
Check the proxy listener
In the main window, select an available node and note the local proxy port shown by the client. Check the logs to confirm the core started successfully, then use
ss -ltnpto verify that the port is listening. A visible window only confirms that the desktop app launched; it doesn't mean the core is accepting connections.
Debian / Ubuntu: Install with APT
dpkg-deb -f ./v2rayn.deb Package Version Architecture
sudo apt update
sudo apt install ./v2rayn.deb
Fedora: Install with DNF
rpm -qp --queryformat '%{NAME} %{VERSION}-%{RELEASE} %{ARCH}\n' ./v2rayn.rpm
sudo dnf install ./v2rayn.rpm
If you installed with dpkg -i and the package is left unconfigured because of missing dependencies, run sudo apt --fix-broken install. Check whether APT plans to install dependencies or remove the package that wasn't fully installed. If your repositories don't provide a dependency version that meets the requirement, recheck your system version and software sources rather than mixing repositories from other distributions. If Fedora reports “nothing provides,” identify the missing dependency instead of bypassing dependency checks.
Start v2rayN at desktop login
Autostart runs after you log in to the graphical desktop, not before the login screen appears. First make sure the app launches from the menu, then choose one of the methods below. Don't configure both a desktop startup entry and another autostart mechanism, or you may end up with duplicate processes or port conflicts.
Add a startup entry in desktop settings
RecommendedIn KDE Plasma, search for “Autostart” in System Settings, open it, then choose “Add” → “Add Application” and select v2rayN. In GNOME, if the Startup Applications tool is installed and available, find it in the app menu. If you need to enter a command manually, use the next method to reuse the launcher supplied with the package.
Best for: Desktops with a startup manager that lets you add v2rayN directly from the app list.
Copy the XDG launcher
Copy the .desktop file supplied by the package—the one that already launches correctly from the menu—to your current user's autostart directory. Keep the launch command as supplied. Don't guess the binary path or point the shortcut to the installer in your downloads folder.
Best for: Desktops without a startup manager, or when you need to inspect the current user's startup configuration.
If the app doesn't appear in the menu, first check whether the package installed a desktop file. Run only the command block that matches your package format. The query uses the package's actual name, not the downloaded filename. If it returns no output, don't treat the empty result as a launcher path.
pkg=$(dpkg-deb -f ./v2rayn.deb Package)
dpkg-query -L "$pkg" | grep '/applications/.*\.desktop$'
pkg=$(rpm -qp --queryformat '%{NAME}' ./v2rayn.rpm)
rpm -ql "$pkg" | grep '/applications/.*\.desktop$'
If the query returns multiple files, choose the launcher whose Name matches the main v2rayN app. After confirming you haven't already added a startup entry in the graphical settings, run the command below and paste in the full path you found. The default directory is ~/.config/autostart/; if XDG_CONFIG_HOME is set, use the autostart/ directory under it.
printf 'Enter the full path to the launcher: '
IFS= read -r launcher
autostart_dir="${XDG_CONFIG_HOME:-$HOME/.config}/autostart"
test -f "$launcher" && mkdir -p "$autostart_dir" && cp -i -- "$launcher" "$autostart_dir/"
Check GNOME, KDE, and app proxy settings
The client launching, the core listening, and apps using the proxy are three separate states. First verify the port on the loopback address, then configure proxy settings for your apps or desktop. The port and timeout below are example values for troubleshooting; replace the port with the one shown by your client.
- GNOME: Open Settings → Network → Network Proxy and select Manual. Enter the address and port for the relevant HTTP, HTTPS, or SOCKS listener. This applies to apps that read GNOME's proxy settings; it doesn't redirect all outgoing traffic from every program.
- KDE Plasma: Search for “Proxy” in System Settings, open the proxy settings, and choose manual configuration. Don't enter a SOCKS-only port in the HTTP proxy field. If the port supports both protocols, configure it for the type your app requires.
- Browsers and terminals: Apps with their own proxy settings may not follow the desktop configuration. First test with a command that explicitly specifies the proxy, then check the app's proxy settings. A terminal command won't automatically pick up the address just because the desktop is set to “Manual proxy.”
ss -ltnp 'sport = :10808'
curl --noproxy "" --proxy socks5h://127.0.0.1:10808 --max-time 10 -I https://example.com
The second command requires the port to support SOCKS5; socks5h sends the destination hostname to the proxy for resolution. If the port supports HTTP proxy only, change the proxy argument to http://127.0.0.1:10808 and replace the port with the one in use. An HTTP response from the destination confirms that this request used the specified local proxy, but it doesn't mean other apps are using the proxy or reveal which outbound route the routing rules selected.
Troubleshoot installation and autostart issues
Architecture mismatch: can I force the install?
Don't force the installation. Check the architecture field in the package and compare it with the output of dpkg --print-architecture or rpm --eval '%{_arch}'. This is especially important on ARM devices: a 64-bit kernel alone doesn't mean your system can install any 64-bit desktop package.
The app launches from the menu, but not after login. Why?
First make sure you're editing the startup directory for the user currently logged in, then check that the .desktop file still points to a valid executable. If an old launcher stopped working after an upgrade, remove that user's outdated startup entry, add the launcher from the new package, and test again after logging out and back in.
The logs say the port is in use. How do I find what's using it?
Replace the port in the ss command above with the one reported in the logs, then check the listening address and process. If multiple startup entries are launching the client, close the extra instances and keep just one entry. If another app that needs to stay running owns the port, change the local port in the client and update the desktop and app proxy settings to match.
Why does my browser lose network access when I quit v2rayN?
If your browser still points to the local proxy after the client stops listening, restore the desktop proxy settings and check whether the browser has its own manual proxy configured. If you launched the browser from a terminal, also check whether the session still has http_proxy, https_proxy, or all_proxy set.