Проверено на Xubuntu 12.04 и 14.04

sudo x11vnc -storepasswd /etc/x11vnc.pass


lightDM
upstart job. Put this in /etc/init/x11vnc.conf :





lxdm – LUbuntu) – LXDM doesn’t seem to emit the right event, but instead is has /etc/lxdm/LoginReady which lets you specify pre-login events. However, we need to first get the xauth setup properly. Edit /etc/lxdm/lxdm.conf and uncomment the line:






This specifies that we’re going to use a different xauth path; we also need to update the /etc/lxdm/LoginReady file with our x11 command, using the updated xauth path.
Put this in /etc/lxdm/LoginReady:



mdm – Mint LMDE
Mint LMDE (Debian edition) doesn’t use the upstart things; instead, put this at the end of /etc/mdm/Init/Default:




Note that this uses the auth path for mdm which is /var/lib/mdm/:0.Xauth