Skip to content

jimlinntu/ubuntu-vnc-setup

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 

Repository files navigation

Ubuntu VNC Setup

Environment

  • Ubuntu 18.04 Desktop

Requirements

  • sudo apt install tigervnc-standalone-server tigervnc-viewer
  • sudo apt install xfce4

Setup

  • Put xstartup in ~/.vnc/
  • Run vncserver -localhost yes :1
    • Stop it by vncserver -kill :1
  • Then you can use your favorite VNC Viewer to connect to localhost:5901 (:1 refers to port 5901)

TODO

Troubleshooting

  • gnome-session --session=ubuntu --debug
  • ps aux | grep gnome: See how gdm invoke gnome-session
  • man gnome-session
  • man gnome-shell
  • man gdm3: It mentions /usr/share/xsessions
  • apt list --installed | grep gnome
    • gnome-shell-extension-ubuntu-dock
  • dbus-daemon
  • man vnc.conf
  • /etc/vnc.conf
  • man vncserver
  • man Xsession
  • /usr/lib/gdm3/gdm-x-session
  • cat /etc/X11/default-display-manager
  • vim /etc/X11/Xvnc-session
  • vim /etc/X11/Xsession
  • /etc/gdm3
  • /etc/X11/Xsession.d/20x11-common_process-args
  • /etc/X11/Xsession.d/50x11-common_determine-startup
    • In my Ubuntu 18.04, x-session-manager is an alias to /etc/alternatives/x-session-manager (where it eventually point usr/bin/gnome-session)
  • env |grep XDG_DATA_DIRS: This enviornment variable will control how the .desktop file are loaded.
  • /etc/profile.d/xdg_dirs_desktop_session.sh: This file explains why /usr/share/ubuntu is added in XDG_DATA_DIRS

References

About

A guide of setting up a VNC server on Ubuntu

Topics

Resources

Stars

Watchers

Forks

Languages