This guide will cover how to setup a basic VNC connection to a Solaris 11 machine. There is also an optional step to allow for persistent VNC connections.
Configure GDM to include ‘[security] DisallowTCP=false’ and ‘[xdmcp] Enable=true’.
$ sudo gedit /etc/gdm/custom.conf
# GDM configuration storage
Configure X-Server to accept remote connections.
$ sudo svccfg -s application/x11/x11-server
svc:/application/x11/x11-server> setprop options/tcp_listen = boolean: true
Configure the VNC service (you could change the ‘-geometry 1280×720’ to whatever resolution you would like).
$ sudo svccfg -s xvnc-inetd
svc:/application/x11/xvnc-inetd> setprop inetd_start/exec = astring: "/usr/bin/Xvnc -geometry 1280x720 -inetd -query localhost -once securitytypes=none"
svc:/application/x11/xvnc-inetd> setprop inetd/wait = boolean: true
** The line highlighted red is optional – only do this if you want your VNC connection to persist (as well as any potential security issues)
Disable and the re-enable the GDM and VNC-inetd services for the changes to take effect.
$ su root
# svcadm disable gdm xvnc-inetd; svcadm enable gdm xvnc-inetd
Point your favourite VNC client at your Solaris server and test if it accepts your VNC connection – you should be presented with a Username/Password login screen.
If you performed the optional step to make your connections persist – close your favourite VNC client and then reconnect – if you remained logged in you have a persistent connections.
Man u so gooood…
After a fresh text install of Solaris-11 (11/11) both xvnc-inetd and gdm are not present. After installing them (# pkg install xvnc-inetd gdm) I can’t get gdm to start:
# svcadm enable gdm
# svcs gdm
offline 10:24:03 svc:/application/graphical-login/gdm:default
isnt it ?
svcadm -r enable gdm
or svcadm enable -r gdm
You are missing some X packages. Do the following:
pkg install slim_install # installs 400+ packages
svcadm enable gdm && exit # gdm now works
pkg uninstall slim_install # uninstalls the installer package
hello … for people who perform a text install…. i am here working in a datacenter Full of SPARC and X86 machines of Oracle-SUN … if you want the GDM and VNC to function properly you can try to install the Solaris Desktop
# pkg install slim_install
# pkg install solaris-desktop
and then the gdm service will be online
setprop inetd/wait = boolean: true
this just seems to cause my xsession to load with an error. after refreshing the gdm service my machine crashes. upon reboot I’m brought to bash prompt.
from there, changing boolean back to false and restarting the gem-inetd service will correct the crash.
however, i am not able to have persistent sessions. any other ideas? thanks a bunch
Thanks. Helped me.
Thanks mate… works perfectly.
I am able to connect to vncserver :1 and higher but when I try connecting to vncserver :0 (the current session on my desktop) I get an error that “no connection could be made because the target machine actively refused it”
I try starting vncserver :0
I get a message that that vnc server is already running.
I have no idea how to get this working. Have tried all different things! :(
Thank You Very Much!!!
I have spent two days searching for a solution to get the VNC server working, but none gave a straight answer as this. Luckily, I stumbled on this article. I followed the instructions and it is working beautifully.