XenDesktop Error: The hosting infrastructure could not be reached at the specified address

When deploying XenDesktop in a VMware environment, you could run into the following error when trying to connect your XenDesktop host to your VMware vCenter environment: “The hosting infrastructure could not be reached at the specified address”. This is due to the fact that VMware vCenter only allows https connections by default. To make your XenDesktop server use VMware vCenter 5 (or 4.1 and 4.0) as the virtualization platform to deploy the desktop VMs, a change is needed in the proxy.xml file.

In Windows 2008 R2 Server go to C:\ProgramData\VMware\VMware VirtualCenter and make a backup copy of the proxy.xml file and then edit the original proxy.xml.

The location differs per Windows version. Should you use plain Windows 2008 server you can find it here: C:\Users\All Users\VMware\VMware VirtualCenter\proxy.xml. In Windows 2003 server you can find it here: C:\Documents and Settings\All Users\Application Data\VMware\VMware VirtualCenter\proxy.xml.

Search for the <serverNamespace>/</serverNamespace> section. In my current config they look like this:

<e id="0">
  <_type>vim.ProxyService.NamedPipeServiceSpec</_type>
  <accessMode>httpsWithRedirect</accessMode>
  <pipeName>\\.\pipe\vmware-vpxd-webserver-pipe</pipeName>
  <serverNamespace>/</serverNamespace>
</e>

Now change the accessMode section httpsWithRedirect to httpAndHttps:

<e id="0">
  <_type>vim.ProxyService.NamedPipeServiceSpec</_type>
  <accessMode>httpAndHttps</accessMode>
  <pipeName>\\.\pipe\vmware-vpxd-webserver-pipe</pipeName>
  <serverNamespace>/</serverNamespace>
</e>

Next search for <serverNamespace>/sdk</serverNamespace> and again change it:

<e id="9">
  <_type>vim.ProxyService.LocalServiceSpec</_type>
  <accessMode>httpsWithRedirect</accessMode>
  <port>8085</port>
  <serverNamespace>/sdk</serverNamespace>
</e>

Change httpsWithRedirect to httpAndHttps:

<e id="9">
  <_type>vim.ProxyService.LocalServiceSpec</_type>
  <accessMode>httpAndHttps</accessMode>
  <port>8085</port>
  <serverNamespace>/sdk</serverNamespace>
</e>

Now restart the vCenter service and try to connect your XenDesktop server to vCenter. Make sure you use the complete and correct URL including sdk at the end and of course the correct credentials:     http://vCenterServer.domain.local/sdk.

After completing the following screen, you should now see the next screen in the wizard. This proofs that your change was successful.