Wednesday, December 31, 2014

vCenter Appliance 5.5 - HTML5 VM Console - Could not connect to hostname:7331

VMware vCenter Server Appliance 5.5 has a bug where (after a reboot) the vSphere Web Client works but the VM Console connection page returns a "could not connect" error message. The problem is that the VCSA is not setting one of its JRE environment variables during boot. Here's the fix for it:
1. ssh into the vCenter Appliance as root (turn on SSH in the VCSA admin console at https://hostname:5480 if it's not already on)

2. edit this file:
/usr/lib/vmware-vsphere-client/server/wrapper/conf/wrapper.conf

3. add this line anywhere under # Environment Variables:
set.default.VMWARE_JAVA_HOME=/usr/java/jre-vmware

4. restart the vSphere client service with this command:
/etc/init.d/vsphere-client restart

Now, wait a few minutes for vsphere-client to finish initializing (after the command prompt says that it has restarted you still have to wait for it to finish starting up).

That's it! Next time you restart your VCSA, the VM consoles in the vSphere Web Client will work without any intervention.


VMware KB article: http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=2060604

No comments: