"Failed to Start: An error occurred during the initialization" error when trying to access vCloud Director after updating public addresses
search cancel

"Failed to Start: An error occurred during the initialization" error when trying to access vCloud Director after updating public addresses

book

Article ID: 325173

calendar_today

Updated On:

Products

VMware Cloud Director

Issue/Introduction

Symptoms:

  • You noticed the issue after filling out or modifying your Public Addresses settings. 
  • When trying to access your vCloud Director instance at the <IP address>/provider/ or <FQDN>/provider/ it prompts you to login normally, but it then presents you with the following error: 
Failed to Start
"An error occurred during the initialization. Accessing the application through an unsupported public URL or poor connectivity might cause this error." 



Environment

VMware Cloud Director 10.x

Cause

The most common cause for this issue is that there was an uncaught typo in your public addresses resulting in an address that does not match the webapp.allowed.origins properties or any correct/resolvable IP or URL. 

A common typo may be a missing the '.' character in one of the address fields, in which case listing the value for that property may show us that our URL is something like 'https://vcd1vcloud.local' instead of the intended 'https://vcd1.vcloud.local'

Resolution

To resolve this issue we must validate all of the relevant config property values to ensure the addresses are correct, resolvable, and included in the webapp.allowed.origins property as per "Failed Start: An error occurred during initialization" error while accessing the vCloud Director H5 provider and tenant UI (75305).

The relevant property values we should examine are:
  • restapi.baseHttpUri
  • restapi.baseUri
  • ui.baseHttpUri
  • ui.baseUri
  • consoleproxy.external.address
  • webapp.allowed.origins

For vCloud Director versions 10.2.x and earlier:

List values via direct database query
If you are comfortable accessing your associated database we can find those values with the following query: 
select name,value from config where name in ('restapi.baseHttpUri','restapi.baseUri','ui.baseHttpUri','ui.baseUri','consoleproxy.external.address','webapp.allowed.origins');
This will return the values for all of the relevant properties. 


List properties individually via Cell Management Tool
Alternatively, we can view the values for any of those individual properties via the cell management tool with the following command: 
/opt/vmware/vcloud-director/bin]#./cell-management-tool manage-config -n <config-property-name> -l

For example:
/opt/vmware/vcloud-director/bin]#./cell-management-tool manage-config -n ui.baseUri -l
This will return the value for the ui.baseUri property. 

Update and correct config property values
Once we have identified the property that is incorrect we can update it via the cell management tool with the following command:
/opt/vmware/vcloud-director/bin]#./cell-management-tool manage-config -n ui.baseUri -v "<property-value>"

This will update the ui.baseUri property. 


For example: 
/opt/vmware/vcloud-director/bin]#./cell-management-tool manage-config -n ui.baseUri -v "https://vcd1.vcloud.local"

This will update the ui.baseUri property to be "https://vcd1.vcloud.local"

After updating a value, it is a good idea to list the property again to ensure that the change was applied as intended. 


Continue through the list of properties until all properties have been validated and corrected as needed. 
Once this has been done for all of the listed properties you will be able to again login to your vCloud Director instance normally and will have corrected the "Failed to Start" error. 


For vCloud Director versions 10.3 and later :


For vCloud Director 10.3 and later, the cell-management-tool options above do not work. The easiest way to query and modify is by using API Explorer.
 

  • To query current values :

Browse to :
https://<publicURL>/api-explorer/provider#/cors/queryAllowedOrigins

Click "Try it out" , then click on Execute to get the current settings
 
  • To modify :


Browse to :

https://<publicURL>/api-explorer/provider#/cors/setAllowedOrigins

Click "Try it out"

Make any modifications to the values from above query, paste it in the "allowedOrigins" field, then click on Execute

 


Additional Information