How to Set Up VNC
You can set up VNC to provide a domU graphical login.
- Enable sshd tcp port forwarding.
- Install VNC (this example is tightvnc)
- Set up VNC to auto start on boot:
# echo 'vnc 5900/tcp' >>/etc/services
# echo 'vnc stream tcp nowait nobody /opt/vnc/bin/Xvnc-1152' > /tmp/vnc.inetd.conf
# inetconv -i /tmp/vnc.inetd.conf
# svcadm restart inetd
- Create the following executable script file:
# cat /opt/vnc/bin/Xvnc-1152
/opt/vnc/bin/Xvnc -inetd -query localhost -once -localhost -geometry 1152x720 -depth 16
- Turn off Xserver on display 0, enable remote login. Set up gdm/custom.conf as shown in following file.
# cat /etc/X11/gdm/custom.conf
# Note that to disable servers defined in the defaults.conf file (such as
# 0=Standard, you must put a line in this file that says 0=inactive, as
# described in the Configuration section of the GDM documentation.
- Disable CDE/Enable gdm:
# svcadm disable cde-login
# svcadm enable gdm
- Log in to your domU from one shell on a client machine (i.e., the machine with your graphical console):
# ssh -g -L5900:127.0.0.1:5900 <domU ip>
- From another shell on the client machine, type:
# vncviewer 127.0.0.1 :0
- You should now have a Solaris login console. For security reasons, the session is not persistent. If you quit the client, you end the session. If you want a persistent VNC session, you should start a VNC server on a different port (a regular VNC server, not one that uses inetd).
For additional information on VNC (Virtual Network Computing), visit this site.