TigerVNC

From Gentoo Wiki
Jump to:navigation Jump to:search
This page is a translated version of the page TigerVNC and the translation is 25% complete.
Other languages:
Resources

TigerVNC to oprogramowanie klient/serwer pozwalające na zdalny dostęp po sieci do pulpitu graficznego.

Instalacja

Flagi USE

USE flags for net-misc/tigervnc Remote desktop viewer display system

+drm Build with DRM support
+opengl Add support for OpenGL (3D graphics)
+server Build TigerVNC server
+viewer Build TigerVNC viewer
dri3 Build with DRI3 support
gnutls Prefer net-libs/gnutls as SSL/TLS provider (ineffective with USE=-ssl)
java Build TigerVNC Java viewer
nls Add Native Language Support (using gettext - GNU locale utilities)
xinerama Add support for querying multi-monitor screen geometry through the Xinerama API

Emerge

Ci którzy używają pakietu dla serwera VNC powinni zainstalować pakiet z włączoną flagą USE server. Może ona zostać dodana do pliku (lub katalogu) package.use, lub wyszczególniona podczas komendy instalacji:

root #USE="server" emerge --ask --update --newuse net-misc/tigervnc
Informacja
Ustawienie flagi USE="server" jak zaprezentowano w przykładzie powyżej zainstaluje przez emerge pakiet z wyszczególnionymi flagami USE, jednakże flagi te nie zostaną zachowane dla przyszłych aktualizacji pakietu. Upewnij się, że są ustawione również w package.use aby były zachowane w przypadku aktualizacji systemu.

Ci którzy instalują tylko klienta, mogą po prostu użyć emerge w ten sposób:

root #emerge --ask net-misc/tigervnc

Konfiguracja Pojedynczego Serwera

Ta konfiguracja pozwala na zdalny dostęp do całego serwera Xorg X11

The xorg module is always installed, but to make sure it is compatible with the currently installed server, those using this configuration can emerge the xorg-module package:

root #emerge --ask net-misc/tigervnc-xorg-module

Create the TigerVNC config file for Xorg X11:

root #mkdir -p /etc/X11/xorg.conf.d
FILE /etc/X11/xorg.conf.d/40-vnc.conf
Section "Module"
	Load "vnc"
EndSection
Section "Screen"
	Identifier "Default Screen"
	Option "PasswordFile" "/etc/X11/vncpasswd"
EndSection

Create /etc/X11/vncpasswd

root #vncpasswd /etc/X11/vncpasswd

Multiple Server Configuration

Starting with version 1.12, tigervnc no longer supports starting servers as 'normal' user. A global configuration with sessions is now required. This paragraph can still be used to test the configuration.

Login as 'normal' user. The following steps can be taken for any user who wishes to configure the VNC server for remote connection.

Set a password:

user $vncpasswd

Start the server giving it an unused display number (for example :1 or :2):

user $vncserver :N

If desired, use a VNC client on either a local or remote machine to test the connection.

Once finished, kill the running vncserver by pressing C-c.

Displays

Setup the displays for OpenRC. Substitute each 'user' value below with the name of a user who will be running the VNC server on the machine:

FILE /etc/conf.d/tigervnc
DISPLAYS="user:1 user2:2"

Typically the value of :0 will be used for the server's own X display. This is why the example above starts by using the :1 display handle.

The above step is not required for systemd.

Setup the displays in the TigerVNC configuration file:

FILE /etc/tigervnc/vncserver.users
:1=user
:2=user2

Desktop environments

To setup the default desktop environment, add it to session= (or uncomment one from below):

FILE /etc/tigervnc/vncserver-config-defaults
# session=gnome
# securitytypes=vncauth,tlsvnc
# geometry=2000x1200
# localhost
# alwaysshared
 
# Other possible working sessions:
#session=e16-session
#session=enlightenment
#session=fvwm
#session=gnome-classic
#session=gnome-custom-session
#session=gnome
#session=gnome-xorg
#session=LXDE
#session=lxqt
#session=openbox
#session=plasma
#session=xfce
#session=Xsession

Each user who will be running a VNC server can override this configuration by adding it to ~/.vnc/config. There is a file /etc/tigervnc/vncserver-config-mandatory where the system administrator can override user's config. ~/.vnc/xstartup is no longer supported and the current server ignores it.

Services

OpenRC

Start the server:

root #rc-service tigervnc start

systemd

Start the server:

root #systemctl enable vncserver@:<display>.service

for each :display in /etc/tigervnc/vncserver.users

Usage

Connecting

user $vncviewer server:1

Connect over ssh with high resolution

user $vncviewer -Fullcolor -QualityLevel 9 -via user@remotehost localhost:1
user $vncviewer -Fullcolor -QualityLevel 9 -via user2@remotehost localhost:2

See also

  • SSH — the ubiquitous tool for logging into and working on remote machines securely.