VNC server which can be managed from system settings?

Can anybody recommend a VNC server with a nice settings GUI, ideally one within System Settings?

tight vnc is an easyone

Unfortunately I'm getting a build error trying to install that. Any thoughts?

reparing...
Cloning tightvnc build files...
Checking tightvnc dependencies...
Resolving dependencies...
Checking inter-conflicts...

Building tightvnc...
==> Making package: tightvnc 1.3.10-10 (Mon 02 Aug 2021 13:03:58 BST)
==> Checking runtime dependencies...
==> Checking buildtime dependencies...
==> Retrieving sources...
  -> Found tightvnc-1.3.10_unixsrc.tar.bz2
  -> Found rgb.txt
  -> Found vncserver.service
  -> Found tightvnc.png
==> Validating source files with sha256sums...
    tightvnc-1.3.10_unixsrc.tar.bz2 ... Passed
    rgb.txt ... Passed
    vncserver.service ... Passed
    tightvnc.png ... Passed
==> Removing existing $srcdir/ directory...
==> Extracting sources...
  -> Extracting tightvnc-1.3.10_unixsrc.tar.bz2 with bsdtar
==> Starting prepare()...
[tightvnc]                        Generating desktop file... ok
==> Removing existing $pkgdir/ directory...
==> Starting build()...
imake -DUseInstalled -I/usr/lib/X11/config
make Makefiles
make[1]: Entering directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc'
making Makefiles in libvncauth...
make[2]: Entering directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc'
make[2]: Leaving directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc'
make[2]: Entering directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc/libvncauth'
make[2]: Nothing to be done for 'Makefiles'.
make[2]: Leaving directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc/libvncauth'
making Makefiles in vncviewer...
make[2]: Entering directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc'
make[2]: Leaving directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc'
make[2]: Entering directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc/vncviewer'
make[2]: Nothing to be done for 'Makefiles'.
make[2]: Leaving directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc/vncviewer'
making Makefiles in vncpasswd...
make[2]: Entering directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc'
make[2]: Leaving directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc'
make[2]: Entering directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc/vncpasswd'
make[2]: Nothing to be done for 'Makefiles'.
make[2]: Leaving directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc/vncpasswd'
making Makefiles in vncconnect...
make[2]: Entering directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc'
make[2]: Leaving directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc'
make[2]: Entering directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc/vncconnect'
make[2]: Nothing to be done for 'Makefiles'.
make[2]: Leaving directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc/vncconnect'
make[1]: Leaving directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc'
make depend
make[1]: Entering directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc'
depending in ./libvncauth...
make[2]: Entering directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc/libvncauth'
gccmakedep  -- -I. -I../include  -I/usr/include    -Dlinux -D__amd64__ -D_POSIX_C_SOURCE=199309L 				-D_POSIX_SOURCE -D_XOPEN_SOURCE 				-D_BSD_SOURCE -D_SVID_SOURCE                                 -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 				  				  -DFUNCPROTO=15 -DNARROWPROTO      -- vncauth.c d3des.c
make[2]: Leaving directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc/libvncauth'
depending in ./vncviewer...
make[2]: Entering directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc/vncviewer'
gccmakedep  -- -I../include -I. -I/usr/local/include -I/usr/local/include -I/usr/include  -I/usr/include    -Dlinux -D__amd64__ -D_POSIX_C_SOURCE=199309L 				-D_POSIX_SOURCE -D_XOPEN_SOURCE 				-D_BSD_SOURCE -D_SVID_SOURCE                                 -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 				  				  -DFUNCPROTO=15 -DNARROWPROTO      -- argsresources.c   caps.c   colour.c   cursor.c   desktop.c   dialogs.c   fullscreen.c   listen.c   misc.c   popup.c   rfbproto.c   selection.c   shm.c   sockets.c   tunnel.c   vncviewer.c
make[2]: Leaving directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc/vncviewer'
depending in ./vncpasswd...
make[2]: Entering directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc/vncpasswd'
gccmakedep  -- -I../include  -I/usr/include    -Dlinux -D__amd64__ -D_POSIX_C_SOURCE=199309L 				-D_POSIX_SOURCE -D_XOPEN_SOURCE 				-D_BSD_SOURCE -D_SVID_SOURCE                                 -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 				  				  -DFUNCPROTO=15 -DNARROWPROTO      -- vncpasswd.c
make[2]: Leaving directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc/vncpasswd'
depending in ./vncconnect...
make[2]: Entering directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc/vncconnect'
gccmakedep  --   -I/usr/include    -Dlinux -D__amd64__ -D_POSIX_C_SOURCE=199309L 				-D_POSIX_SOURCE -D_XOPEN_SOURCE 				-D_BSD_SOURCE -D_SVID_SOURCE                                 -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 				  				  -DFUNCPROTO=15 -DNARROWPROTO      -- 
make[2]: Leaving directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc/vncconnect'
make[1]: Leaving directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc'
make all
make[1]: Entering directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc'
making all in ./libvncauth...
make[2]: Entering directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc/libvncauth'
gcc -O2 -fno-strength-reduce -fno-strict-aliasing    -I. -I../include  -I/usr/include    -Dlinux -D__amd64__ -D_POSIX_C_SOURCE=199309L 				-D_POSIX_SOURCE -D_XOPEN_SOURCE 				-D_BSD_SOURCE -D_SVID_SOURCE                                 -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 				  				  -DFUNCPROTO=15 -DNARROWPROTO       -c -o vncauth.o vncauth.c
In file included from /usr/include/bits/libc-header-start.h:33,
                 from /usr/include/stdio.h:27,
                 from vncauth.c:24:
/usr/include/features.h:187:3: warning: #warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" [-Wcpp]
  187 | # warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE"
      |   ^~~~~~~
vncauth.c: In function ‘vncEncryptAndStorePasswd’:
vncauth.c:60:13: warning: implicit declaration of function ‘vncEncryptAndStorePasswd2’; did you mean ‘vncEncryptAndStorePasswd’? [-Wimplicit-function-declaration]
   60 |     return (vncEncryptAndStorePasswd2(passwd, NULL, fname) == 0);
      |             ^~~~~~~~~~~~~~~~~~~~~~~~~
      |             vncEncryptAndStorePasswd
vncauth.c: In function ‘vncDecryptPasswdFromFile’:
vncauth.c:131:13: warning: implicit declaration of function ‘vncDecryptPasswdFromFile2’; did you mean ‘vncDecryptPasswdFromFile’? [-Wimplicit-function-declaration]
  131 |         if (vncDecryptPasswdFromFile2(fname, passwd, NULL) == 0) {
      |             ^~~~~~~~~~~~~~~~~~~~~~~~~
      |             vncDecryptPasswdFromFile
vncauth.c: In function ‘vncRandomBytes’:
vncauth.c:211:28: warning: implicit declaration of function ‘time’ [-Wimplicit-function-declaration]
  211 |       seed = (unsigned int)time(0) ^ (unsigned int)getpid();
      |                            ^~~~
gcc -O2 -fno-strength-reduce -fno-strict-aliasing    -I. -I../include  -I/usr/include    -Dlinux -D__amd64__ -D_POSIX_C_SOURCE=199309L 				-D_POSIX_SOURCE -D_XOPEN_SOURCE 				-D_BSD_SOURCE -D_SVID_SOURCE                                 -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 				  				  -DFUNCPROTO=15 -DNARROWPROTO       -c -o d3des.o d3des.c
rm -f libvncauth.a
ar clq libvncauth.a vncauth.o d3des.o
ar: libdeps specified more than once
make[2]: *** [Makefile:1042: libvncauth.a] Error 1
make[2]: Leaving directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc/libvncauth'
make[1]: *** [Makefile:1047: all] Error 2
make[1]: Leaving directory '/var/tmp/pamac-build-sam/tightvnc/src/vnc_unixsrc'
make: *** [Makefile:1037: World] Error 2
==> ERROR: A failure occurred in build().
    Aborting...

Just tested it myself same error :roll_eyes: l hate build errors

1 Like

Have you tried the repos?

pacman -Ss vnc
3 Likes

In the past I used tigervnc (a fork from tightvnc) from the arch repo and it was ok (althoguh I used it only for a short period).

3 Likes

Btw, if you want remote connection, you can also have a look at nomachine and dwservice.

Dwservice is free and really easy to use, but its security may be questionable.

Nomachine is nice for connection in the same network. It is again complicated for global connection.

Also, I heard that tigervnc in nice, but don't expect it to be easy to use. It currently don't have GUI setup. But we are lucky to have Archwiki page dedicated to it

https://wiki.archlinux.org/title/TigerVNC

3 Likes

Thanks guys.

Trying Tiger as per the wiki, but I'm getting an error on startup:

[🔍] × systemctl --user status x0vncserver.service
× x0vncserver.service - Remote desktop service (VNC)
Loaded: loaded (/home/sam/.config/systemd/user/x0vncserver.service; enabled; vendor preset: enabled)
Active: failed (Result: timeout) since Mon 2021-08-02 20:33:18 BST; 1min 9s ago
Process: 2427 ExecStartPre=/bin/sh -c while ! pgrep -U "$USER" Xorg; do sleep 2; done (code=killed, signa>
CPU: 359ms

Aug 02 20:31:48 sams-laptop systemd[2419]: Starting Remote desktop service (VNC)...
Aug 02 20:33:18 sams-laptop systemd[2419]: x0vncserver.service: start-pre operation timed out. Terminating.
Aug 02 20:33:18 sams-laptop systemd[2419]: x0vncserver.service: Control process exited, code=killed, status=1>
Aug 02 20:33:18 sams-laptop systemd[2419]: x0vncserver.service: Failed with result 'timeout'.
Aug 02 20:33:18 sams-laptop systemd[2419]: Failed to start Remote desktop service (VNC).

It worked when I ran it manually with x0vncserver -rfbauth ~/.vnc/passwd, it's just trying to start it with systemd that it's failing. My config file is exactly as in the wiki:

╭─[email protected] in ~ took 43ms
[🔴] × cat ~/.config/systemd/user/x0vncserver.service
File: /home/sam/.config/systemd/user/x0vncserver.service
[Unit]
Description=Remote desktop service (VNC)

[Service]
Type=simple
# wait for Xorg started by ${USER}
ExecStartPre=/bin/sh -c 'while ! pgrep -U "$USER" Xorg; do sleep 2; done'
ExecStart=/usr/bin/x0vncserver -rfbauth %h/.vnc/passwd
# or login with your username & password
#ExecStart=/usr/bin/x0vncserver -PAMService=login -PlainUsers=${USER} -SecurityTypes=TLSPlain

[Install]
WantedBy=default.target

Woah, hold on - the wiki says "create a systemd unit as follows replacing the user and the options with the desired ones" - does that mean $USER? I assumed that was a variable that contained the name of the current user automatically?

1 Like

OK, I was right the first time, $USER is the current user automagically.

So, my problem is the prerequisite line:

ExecStartPre=/bin/sh -c 'while ! pgrep -U "$USER" Xorg; do sleep 2; done'

If I comment this out the service works, but fails on reboot, presumably because it’s trying to start before the display server is running?

So, this is waiting for a running progress called Xorg, belonging to the current user, right? pgrep -U "$USER" Xorg doesn’t find anything - is the problem that Garuda uses Wayland? I’ve tried pgrep -U $USER wayland but that hasn’t found anything either.

I set it to wait for plasmashell. I don’t know if that’s the recommended process to use, but it seems to be working fine, even after a reboot :slight_smile:

2 Likes

Please, post the method you used for this.

1 Like

I changed the line

ExecStartPre=/bin/sh -c 'while ! pgrep -U "$USER" Xorg; do sleep 2; done'

to

ExecStartPre=/bin/sh -c 'while ! pgrep -U "$USER" plasmashell; do sleep 2; done'

If people think this is the right solution (there may be a better process to wait for, I’m no expert here) perhaps we should update the wiki? Lots of people use Wayland now, right?

I believe you can use multiple ExecStartPre= statements, and that may be a little cleaner way to execute the commands rather than chaining them all. But if it works who am I to say otherwise.

1 Like

I’m not sure what you mean - I haven’t chained anything, I’ve just changed the name of the process it pgreps for inside the while loop.

Nevermind it's all good, I didn't read it carefully enough.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.