A ThinLinc system administrator using Ubuntu 20.04 contacted us and reported that he did not succeed to make ThinLinc work. He gets a message saying that the connection lasts less than 10 seconds and that it may have a setup problem. What should be checked to solve this issue? What are the most common causes?
the log files on the server … to see why the thinlinc session is dying there … the content of /var/opt/thinlinc might be interesting
Yes - specifically
/var/opt/thinlinc/sessions/<username>/last/xinit.log. This file should contain information about why the session failed to start (or ended very quickly).
Dear @muitotri, thanks for your invitation to participate from this community, and for posting my issue. Dear @tobias.oetiker and @aaron, thank you for your immediate support as well. My apologies for the long time I took to reply your comments. Please see below the log info. Any additional suggestion on how to solve the issue will be very welcome.
xauth: file /var/opt/thinlinc/sessions/.../11/Xauthority does not exist tl-xinit: Waiting for Xserver to accept connections... Xvnc ThinLinc release 4.14.0 build 2408 - built Jan 26 2022 10:15:02 Copyright (C) 1999-2022 TigerVNC Team and many others (see README.rst) See https://www.tigervnc.org for information on TigerVNC. Underlying X server release 12013000 (II) Initializing extension VNC-EXTENSION Sat Jul 2 13:24:20 2022 vncext: VNC extension running! vncext: Listening for VNC connections on local interface(s), port 5911 vncext: created VNC server for screen 0 (II) Initializing extension Generic Event Extension (II) Initializing extension SHAPE (II) Initializing extension MIT-SHM (II) Initializing extension XInputExtension (II) Initializing extension XTEST (II) Initializing extension BIG-REQUESTS (II) Initializing extension SYNC (II) Initializing extension XKEYBOARD (II) Initializing extension XC-MISC (II) Initializing extension XFIXES (II) Initializing extension RENDER (II) Initializing extension RANDR (II) Initializing extension COMPOSITE (II) Initializing extension DAMAGE (II) Initializing extension MIT-SCREEN-SAVER (II) Initializing extension DOUBLE-BUFFER (II) Initializing extension RECORD (II) Initializing extension DPMS (II) Initializing extension Present (II) Initializing extension DRI3 (II) Initializing extension X-Resource (II) Initializing extension XVideo (II) Initializing extension XVideo-MotionCompensation (II) Initializing extension GLX (II) IGLX: Loaded and initialized swrast (II) GLX: Initialized DRISWRAST GL provider for screen 0 The XKEYBOARD keymap compiler (xkbcomp) reports: > Warning: Unsupported high keycode 372 for name <I372> ignored > X11 cannot support keycodes above 255. > This warning only shows for the first high keycode. Errors from xkbcomp are not fatal to the X server Connections: accepted: 127.0.0.1::36744 VNCSConnST: closing 127.0.0.1::36744: Clean disconnection EncodeManager: Framebuffer updates: 0 EncodeManager: Total: 0 rects, 0 pixels EncodeManager: 0 B (1:-nan ratio) Connections: closed: 127.0.0.1::36744 ComparingUpdateTracker: 0 pixels in / 0 pixels out ComparingUpdateTracker: (1:-nan ratio) tl-xinit: Xserver ready for clients. Sat Jul 2 13:24:21 2022 Connections: accepted: 127.0.0.1::36746 SConnection: Client needs protocol version 3.8 SConnection: Client requests security type VncAuth(2) VNCSConnST: Replacing existing connection VNCSConnST: Server default pixel format depth 24 (32bpp) little-endian rgb888 /etc/profile.d/setup_readline.sh: line 1: bind: warning: line editing not enabled /etc/profile.d/setup_readline.sh: line 2: bind: warning: line editing not enabled --- System information --- ThinLinc 4.14.0 Linux gff 5.4.0-121-generic #137-Ubuntu SMP Wed Jun 15 13:33:07 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux Ubuntu 20.04.4 LTS \n \l No LSB modules are available. --- End system information --- xsetroot: unable to open display 'gff:10.0' Cannot find xsri. Background image support not available. xsetroot: unable to open display 'gff:10.0' Failed to open display /opt/thinlinc/libexec/xprop: unable to open display 'gff:10.0' Openbox-Message: Failed to open the display from the DISPLAY environment variable. Running /opt/thinlinc/etc/xstartup.d/01-tl-kinit.sh (Obtaining Kerberos ticket) Running /opt/thinlinc/etc/xstartup.d/02-tl-dbus-launch.sh (Starting session D-Bus server) Existing session D-Bus server found. Setting initial D-Bus and systemd environment... Unable to init server: Could not connect: Connection refused Running /opt/thinlinc/etc/xstartup.d/11-tl-set-title (Setting client window title) Unable to init server: Could not connect: Connection refused Running /opt/thinlinc/etc/xstartup.d/12-tl-default-keyboard (Configuring default keyboard layout) Unable to init server: Could not connect: Connection refused /opt/thinlinc/libexec/tl-run-xstartup-feedback: warning: Unable to initialize GTK+ /opt/thinlinc/libexec/tl-run-xstartup-feedback: warning: Won't present xstartup.d feedback Setting default keyboard layout to "us" Cannot open display "gff:10.0" Running /opt/thinlinc/etc/xstartup.d/15-tl-shadow-notify (Enabling notifications when the session is shadowed) Can't open display: gff:10.0 Running /opt/thinlinc/etc/xstartup.d/20-tl-select-profile.sh (Choosing a profile) Unable to init server: Could not connect: Connection refused Unable to init server: Could not connect: Connection refused Unable to init server: Could not connect: Connection refused /opt/thinlinc/libexec/tl-select-profile: warning: Unable initialize GTK+ /opt/thinlinc/libexec/tl-select-profile: warning: Can't show introduction text /opt/thinlinc/libexec/tl-select-profile: warning: Using first available profile as fallback Running /opt/thinlinc/etc/xstartup.d/30-tl-xdg-user-dirs (Translating standard folders) Running /opt/thinlinc/etc/xstartup.d/40-tl-mount-localdrives (Mounting local drives) Running /opt/thinlinc/etc/xstartup.d/41-tl-lp-redir-launch (Setting up printer port redirection) Unable to open DISPLAY, exiting ... Running /opt/thinlinc/etc/xstartup.d/43-tl-pulseaudio-launch.sh (Starting session PulseAudio server) Unable to open DISPLAY, exiting ... Failed to start session PulseAudio server Running /opt/thinlinc/etc/xstartup.d/50-tl-wait-smartcard (Waiting for smart card connection) Stopping initial window manager... Openbox-Message: Failed to open the display from the DISPLAY environment variable. Done. Executing profile: ubuntu Using XDG session: ubuntu Updating D-Bus and systemd environment... Ignoring invalid environment variable: 'BASH_FUNC_spack%%' Executing XDG session command: env GNOME_SHELL_SESSION_MODE=ubuntu /usr/bin/gnome-session --systemd --session=ubuntu Profile command exited with exit code 1 Running /opt/thinlinc/etc/xlogout.d/tl-kdestroy.sh Running /opt/thinlinc/etc/xlogout.d/tl-umount-localdrives tl-xinit: client terminated and returned 0 tl-xinit: Terminating X server... Sat Jul 2 13:24:26 2022 VNCSConnST: closing 127.0.0.1::36746: Server shutdown EncodeManager: Framebuffer updates: 1 EncodeManager: Tight: EncodeManager: Solid: 1 rects, 786.432 kpixels EncodeManager: 16 B (1:196609 ratio) EncodeManager: Total: 1 rects, 786.432 kpixels EncodeManager: 16 B (1:196609 ratio) ComparingUpdateTracker: 0 pixels in / 0 pixels out ComparingUpdateTracker: (1:-nan ratio) tl-xinit: X server has terminated tl-xinit: deleting ../11.1656778675.ended tl-xinit: Session terminated. Exiting.
Hi @abonatto, welcome to the forum.
There is something strange with your user environment here. The
$DISPLAY variable is being set with a hostname (
gff) which either can’t be resolved, or isn’t accessible.
Are you logged in locally (i.e. at the computer) as the same user as you are trying to connect to ThinLinc with? Is there anything in your home directory, for example
~/.bashrc, which might be manipulating the
If you’re unsure, you could try creating a new user on the system and connecting as them instead.
Indeed, I had the following line in my .profile:
It was added ages ago, when I was trying to solve some issues with remote access of graphical applications (I do not remember the context). I just commented it, logged out and in, and now the ThinLinc client works flawlessly!
You’re welcome @abonatto, if there is anything else just let us know.