Using VNC to connect to Virtual Machines

From Nuclear Physics Group Documentation Pages
Revision as of 17:33, 31 December 2010 by Tbow (talk | contribs) (→‎Setting up VMs for VNC)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search

Setting up VMs for VNC

First add these three lines to the bottom of the .vmx file for that virtual machine:

 RemoteDisplay.vnc.enabled = "TRUE"
 RemoteDisplay.vnc.password = "vncpassword"
 RemoteDisplay.vnc.port = "5900"

Note: The virtual machine must be stopped and then these lines can be add. If you do not do this the lines will be erased upon reset of the virtual machine.

Using VNC with SSH to connect to guest VM

Then ssh to the host machine using this command:

 ssh -L 8080:localhost:5900 hostmachine.unh.edu

Then use any vnc client to connect to localhost:8080 using the password set above.