vCenter issue: vSphere Client fails with “Invalid URL: The hostname could not parsed.”

//vCenter issue: vSphere Client fails with “Invalid URL: The hostname could not parsed.”

vCenter issue: vSphere Client fails with “Invalid URL: The hostname could not parsed.”

Today when rebooting one of our vCenters 6.0 and try to connect using vSphere Client we get this issue “Invalid URL: The hostname could not be parsed.”

vCenter issue: vSphere Client fails with "Invalid URL: The hostname could not parsed."

The issue itself is described in VMware KB 1033990. Since there were no changes in the URL, was a strange issue.

There are some options to fix the issue. Since changing something in the ADM is not an option for us, need to check the vCenter Advance Settings in VirtualCenter.VimApilurl or VirtualCenter.VimWebServicesUrl to check the error.

Since vSphere Client doesn’t work to check the Advanced Settings, we need to use vSphere Web Client.

  • How to fix

Procedure
In the vSphere Web Client, navigate to the vCenter Server instance.

  1. Select the Manage tab.
  2. Select Advanced Settings.
  3. Click Edit.

vCenter issue: vSphere Client fails with "Invalid URL: The hostname could not parsed."

Then when the Advanced Settings board shows, search(right upper corner) for the word “virtual” and then you will see the VirtualCenter.VimApilurl and VirtualCenter.VimWebServicesUrl options.

As you can see in our case, both options were empty and the VirtualCenter.VimApilurl  has only “https://:443/sdk” when should have “https://vCenterFQDN:443/sdk” and VirtualCenter.VimWebServicesUrl is empty. But VirtualCenter.VimWebServicesUrl is optional.

vCenter issue: vSphere Client fails with "Invalid URL: The hostname could not parsed."

We need to add the vCenter FQDN into VirtualCenter.VimWebServicesUrl (https://vCenterFQDN:443/sdk), and in the VirtualCenter.VimWebServicesUrl (should be added, but not mandatory). After the changes, we were able to login using vSphere Client.

Alternatively, you can do this changes automatically with a PowerCLI command:

PS: In our case, if we reboot the vCenter we have the issue again, still troubleshooting why vCenter loses this entry in the reboot. Will update this post after I find the source of the problem.

UPDATE 20/10/2017: VMware did not provide a solution for this issue. Since vCenter will be EOL will not work on a solution for this issue anymore. The only option is the solution that I added previously in this article.

Hope this information was useful.

Note: Share this article, if you think it is worth sharing.

©2017 ProVirtualzone. All Rights Reserved

By | 2018-09-20T18:50:21+02:00 January 14th, 2017|Virtualization|0 Comments

About the Author:

I am over 20 years’ experience in the IT industry. Working with Virtualization for more than 10 years (mainly VMware). I am an MCP, VCP6.5-DCV, VMware vSAN Specialist, Veeam Vanguard 2018/2019, vExpert vSAN 2018/2019 and vExpert for the last 4 years. Specialties are Virtualization, Storage, and Virtual Backups. I am working for Elits a Swedish consulting company and allocated to a Swedish multinational networking and telecommunications company as a Teach Lead and acting as a Senior ICT Infrastructure Engineer. I am a blogger and owner of the blog ProVirtualzone.com

Leave a Reply

%d bloggers like this: