Ubuntu – vncserver grey screen ubuntu 16.04 LTS

16.04tightvncservervnc

Greeting.
I am on ubuntu 16.04 LTS. It is an amazon EC2 instance
I got grey screen upon installing and starting the vncserver
I try many suggestion regarding this issue but still cant get it work….
Thanks for the help

enter image description here

My logfile:

Xvnc Free Edition 4.1.1 - built Feb 25 2015 23:02:21
Copyright (C) 2002-2005 RealVNC Ltd.
See http://www.realvnc.com for information on VNC.
Underlying X server release 40300000, The XFree86 Project, Inc
Tue Jul 19 03:03:37 2016
 vncext:      VNC extension running!
 vncext:      Listening for VNC connections on port 5901
 vncext:      created VNC server for screen 0
error opening security policy file /etc/X11/xserver/SecurityPolicy
Could not init font path element /usr/X11R6/lib/X11/fonts/Type1/, removing from list!
Could not init font path element /usr/X11R6/lib/X11/fonts/Speedo/, removing from list!
Could not init font path element /usr/X11R6/lib/X11/fonts/misc/, removing from list!
Could not init font path element /usr/X11R6/lib/X11/fonts/75dpi/, removing from list!
Could not init font path element /usr/X11R6/lib/X11/fonts/100dpi/, removing from list!
Could not init font path element /usr/share/fonts/X11/75dpi/, removing from list!
Could not init font path element /usr/share/fonts/X11/100dpi/, removing from list!
Tue Jul 19 03:03:44 2016
 Connections: accepted: 0.0.0.0::61550
 SConnection: Client needs protocol version 3.8
 SConnection: Client requests security type VncAuth(2)
Tue Jul 19 03:03:50 2016
 VNCSConnST:  Server default pixel format depth 16 (16bpp) little-endian rgb565
Tue Jul 19 03:03:51 2016
 VNCSConnST:  Client pixel format depth 8 (8bpp) colour-map

my xstartup

#!/bin/sh
# Uncomment the following two lines for normal desktop:
 unset SESSION_MANAGER
 exec /etc/X11/xinit/xinitrc
[ -x /etc/vnc/xstartup ] && exec /etc/vnc/xstartup
[ -r $HOME/.Xresources ] && xrdb $HOME/.Xresources
xsetroot -solid grey
vncconfig -iconic &
x-terminal-emulator -geometry 80x24+10+10 -ls -title "$VNCDESKTOP Desktop" &
gnome-session &

Best Answer

I had the same issue on Ubuntu 16.04 LTS (64bit). I updated ~/.vnc/xstartup file to look like below, worked successfully for me.

# Uncomment the following two lines for normal desktop:
# unset SESSION_MANAGER
# exec /etc/X11/xinit/xinitrc

[ -x /etc/vnc/xstartup ] && exec /etc/vnc/xstartup
[ -r $HOME/.Xresources ] && xrdb $HOME/.Xresources
xsetroot -solid grey
vncconfig -iconic &
x-terminal-emulator -geometry 80x24+10+10 -ls -title "$VNCDESKTOP Desktop" &
x-window-manager &

gnome-panel &
gnome-settings-daemon &
metacity &
nautilus &

Reference: https://www.linode.com/docs/applications/remote-desktop/install-vnc-on-ubuntu-16-04

Related Question