Corporate Home Open Source Home
Syndicate content
Eucalyptus

Using VNC to debug an image

Debugging images can be a tricky task when there is no console access. If the NC uses xen as the hypervisor, one could use the xm console command to gain access to the instance console. Another way to achieve console access is to instruct libvirt to configure VNC access to the instance. This document will explain how to achieve that on a specific NC.

Warning: this method is meant to be a debugging aid and not a production setting. The system is not secure since the communication with VNC is not encrypted and there is no password associated with it.

  • Login on the NC you want to use for debugging purpose as root;
  • Locate either gen_libvirt_xml or gen_kvm_libvirt_xml depending on the hypervisor you are using (it's usually in /usr/share/eucalyptus for package installs);
  • Edit the file and find the tag <devices> and before the closing tag </devices> add the following
    <graphics type='vnc' port='-1' autoport='yes'
    keymap='en-us' listen='0.0.0.0'/>
  • Start an instance (be sure it starts on the NC you just modified)
  • On the NC, run this command: virsh vncdisplay <instance id> This will return a VNC display number like ":2". Add 5900 to that number. This number is the VNC port that this instance is listening on.
  • You should now be able to connect to the the instance using something like
    xvncviewer <NC IP>:5902

Once you debugged the instance you can modify your image and upload the fixed version.