Can’t establish connection to the server at 7331

When trying to open the console of a VM using the vSphere Webclient with the  VMware vCenter Server Appliance 5.5, I received the following error: “can’t establish a connection to the server at vcsa.vanzanten.local: 7331″.

vCenter 5.5 can't establish a connection to the server at vcsa 7331

vCenter 5.5 can’t establish a connection to the server at vcsa 7331

It took me some searching through the VMware KB and finally found it. I’m posting it here merely for my self to find it quickly when I need it again. The solution is described in KB2060604 “HTML5 virtual machine console fails to open after restarting vCenter Server Appliance 5.5″. The problem is that an environmental variable is not set correctly. To solve the issue:

  • Setup an SSH session into the vCSA
  • Edit the file: /usr/lib/vmware-vsphere-client/server/wrapper/conf/wrapper.conf
  • Add this line:  set.default.VMWARE_JAVA_HOME=/usr/java/jre-vmware
  • Save the file
  • restart the vSphere Web Client:  /etc/init.d/vsphere-client restart

Now you can login to the vSphere Web Client again and test the console connection. This solved it for me.