I have phrased my question very carefully. After much research and trial and error, I am able to have x11vnc start at boot as a system service by using this command line in my service file:
ExecStart=/usr/bin/x11vnc -auth /run/user/121/gdm/Xauthority -forever -loop -noxdamage -repeat -rfbauth /etc/x11vnc.pass -rfbport 5900 -shared
I figured out as many others have that the auth guess
argument doesn't work in 17.10. I also figured out that 121 is the number for the user 'gdm' that owns the greeter X session, and that is where my Xauthority
file resides. Checking xorg processes via ssh:
user@foo:~$ ps -ax |grep xorg
886 tty1 Sl+ 0:00 /usr/lib/xorg/Xorg vt1 -displayfd 3 -auth /run/user/121/gdm/Xauthority -background none -noreset -keeptty -verbose 3
Okay, so I can connect via vnc client and I see the greeter and login, but logging in yields a plain black screen with an active mouse pointer. Looking again at xorg processes:
user@foo:~$ ps -ax |grep xorg
886 tty1 Sl+ 0:00 /usr/lib/xorg/Xorg vt1 -displayfd 3 -auth /run/user/121/gdm/Xauthority -background none -noreset -keeptty -verbose 3
1384 tty2 Sl+ 0:00 /usr/lib/xorg/Xorg vt2 -displayfd 3 -auth /run/user/1000/gdm/Xauthority -background none -noreset -keeptty -verbose 3
I see that there is a new X session owned by the user that logged in (me!), and using the Xauthority
file in that location. The problem seems to be that the VNC client is stuck at the original X session for the greeter owned by 'gdm'. How can I coax the vnc client to follow to the new X session without opening a second instance of the client? Surely it is possible to log in and use the desktop manager graphical interface with x11vnc and a vnc client, no? Thanks very kindly!