{"id":16,"date":"2024-01-18T18:54:55","date_gmt":"2024-01-18T17:54:55","guid":{"rendered":"https:\/\/v-tailor.hu\/en\/?p=16"},"modified":"2024-01-18T18:54:56","modified_gmt":"2024-01-18T17:54:56","slug":"vra-8-8-2-failed-to-validate-error-after-vcenter-certificate-change","status":"publish","type":"post","link":"https:\/\/v-tailor.hu\/en\/2024\/01\/18\/vra-8-8-2-failed-to-validate-error-after-vcenter-certificate-change\/","title":{"rendered":"vRA 8.8.2 &#8220;Failed to validate&#8221; error after vCenter certificate change"},"content":{"rendered":"\n<p>When a vCenter certificate expired after you have renewed it you need to add this new certificate to the solutions that are linked with the vCenter. Generally it is enough to just re-authenticate with the service user because the vCenter provide the new certificate that can be accepted. But there is a bug in the vRealize Automation and because of this this is not this straightforward. Writing this because the vRA faced with &#8220;Failed to validate&#8221; issue.<\/p>\n\n\n\n<div class=\"wp-block-group\"><div class=\"wp-block-group__inner-container is-layout-constrained wp-block-group-is-layout-constrained\">\n<h2 class=\"wp-block-heading\">Solution<\/h2>\n\n\n\n<p>At the time of troubleshooting and the writing of this article there is no patch provided by VMware so the following steps should be implemented to fix the issue.<\/p>\n\n\n\n<div class=\"wp-block-group\"><div class=\"wp-block-group__inner-container is-layout-constrained wp-block-group-is-layout-constrained\">\n<p style=\"text-decoration:underline\"><strong>Obtain Bearer token<\/strong><\/p>\n\n\n\n<p>Access vRA &#8211; cloud Assembly then go to Infrastructure &gt; Connections &gt; Cloud Account page. Here open the browser&#8217;s <em>Developer Tools<\/em> then select <em>Network<\/em>. If it is required then click to <em>Refresh<\/em> and find <em>access<\/em> then <em>Authorization<\/em> on the right. If possible use <em>Raw<\/em> option because for example the Firefox can use different character set that can cause authentication issues later on.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><a href=\"https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-1.jpg\" target=\"_blank\" rel=\"noreferrer noopener\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"461\" src=\"https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-1-1024x461.jpg\" alt=\"\" class=\"wp-image-18\" srcset=\"https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-1-1024x461.jpg 1024w, https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-1-300x135.jpg 300w, https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-1-768x346.jpg 768w, https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-1.jpg 1429w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/a><\/figure>\n\n\n\n<p><\/p>\n<\/div><\/div>\n\n\n\n<div class=\"wp-block-group\"><div class=\"wp-block-group__inner-container is-layout-constrained wp-block-group-is-layout-constrained\">\n<p style=\"text-decoration:underline\"><strong>Obtain vCenter Cloud Account ID<\/strong><\/p>\n\n\n\n<p>The easiest way to get this ID is from the UI by opening the respective vCenter within the Cloud Accounts page:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><a href=\"https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-2.jpg\" target=\"_blank\" rel=\"noreferrer noopener\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"228\" src=\"https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-2-1024x228.jpg\" alt=\"\" class=\"wp-image-22\" srcset=\"https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-2-1024x228.jpg 1024w, https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-2-300x67.jpg 300w, https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-2-768x171.jpg 768w, https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-2.jpg 1184w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/a><\/figure>\n\n\n\n<p><\/p>\n\n\n\n<p>The alternative way is using Postman. The Postman will be required later on so I recommend you to use this method instead the previous one. For this start the Postman and set as follows:<\/p>\n\n\n\n<ul>\n<li>Authorization: Select Bearer Token and paste the previously obtained token<\/li>\n\n\n\n<li>Headers: add &#8220;api_version&#8221; Key with &#8220;2021-07-15&#8221; Value<\/li>\n<\/ul>\n\n\n\n<p>Then select GET option and enter <em>https:\/\/vRA-FQDN\/iaas\/api\/cloud-accounts\/<\/em> where the vRA-FQDN is your vRA solution&#8217;s VIP or Node IP address. If everything goes well you get &#8220;Status: 200 OK&#8221; and the details of the configured Cloud Account. If you navigate to the vCenter that is afeected you will find the <em>cloudAccountId<\/em>. This and the previous one should be the same:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><a href=\"https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-3.jpg\" target=\"_blank\" rel=\"noreferrer noopener\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"416\" src=\"https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-3-1024x416.jpg\" alt=\"\" class=\"wp-image-23\" srcset=\"https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-3-1024x416.jpg 1024w, https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-3-300x122.jpg 300w, https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-3-768x312.jpg 768w, https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-3.jpg 1064w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/a><\/figure>\n\n\n\n<p><\/p>\n<\/div><\/div>\n\n\n\n<div class=\"wp-block-group\"><div class=\"wp-block-group__inner-container is-layout-constrained wp-block-group-is-layout-constrained\">\n<p style=\"text-decoration:underline\"><strong>Capture the vCenter&#8217;s certificate in PEM format<\/strong><\/p>\n\n\n\n<p>To do this login to the vRA Node with root account and issue the following command, just replace the vCenter_FQDN:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>openssl s_client -connect vCenter_FQDN:443 2> \/dev\/null | openssl x509 | awk 'NF {sub(\/\\r\/, \"\");  printf \"%s\\\\n\",$0;}'<\/code><\/pre>\n\n\n\n<p>Save the full output, including the &#8220;&#8212;&#8211;BEGIN CERTIFICATE&#8212;&#8211;&#8221; and &#8220;&#8212;&#8211;END CERTIFICATE&#8212;&#8211;&#8221; part as well.<\/p>\n<\/div><\/div>\n\n\n\n<div class=\"wp-block-group\"><div class=\"wp-block-group__inner-container is-layout-constrained wp-block-group-is-layout-constrained\">\n<p style=\"text-decoration:underline\"><strong>Using Postman to fix the issue<\/strong><\/p>\n\n\n\n<p>Verify that you have all the necessary information:<\/p>\n\n\n\n<ul>\n<li>Bearer toke &#8211; if it took a long time to get here repeat the steps mentioned above and obtain the token again, maybe it has been expired because timeout<\/li>\n\n\n\n<li>vCenter Cloud Account ID<\/li>\n\n\n\n<li>vCenter certification in PEM format<\/li>\n\n\n\n<li>IP or FQDN of the vCenter &#8211; as it is configured in the Cloud Accounts page<\/li>\n<\/ul>\n\n\n\n<p>Now it is time to create the body for the PATCH call. To do this do not use Notepad but Notepad++, PSPad or Visual Studio Code:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>{\n        \"customProperties\" : {\n            \"certificate\": \"PEM certificate\"\n        },\n        \"endpointProperties\": {\n        \"hostName\": \"vCenter IP or FQDN\",\n        \"certificate\": \"PEM certificate\"\n    }\n}<\/code><\/pre>\n\n\n\n<p>Open the Postman and enter <em>https:\/\/vRA-FQDN\/provisioning\/uerp\/resources\/endpoints\/Cloud Account ID<\/em> to the URL field but change the <em>vRA-FQDN<\/em> and <em>Cloud Account ID<\/em> and also verify\/change the Bearer Token. Furthermore verify on the Headers page that the &#8220;api_version&#8221; key&#8217;s value is <em>2021-01-15<\/em> and the &#8220;Content-Type&#8221; is set to <em>application\/json<\/em>. If any of these values are different fix or add them before continue:<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><a href=\"https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-4.jpg\" target=\"_blank\" rel=\"noreferrer noopener\"><img loading=\"lazy\" decoding=\"async\" width=\"867\" height=\"267\" src=\"https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-4.jpg\" alt=\"\" class=\"wp-image-25\" srcset=\"https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-4.jpg 867w, https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-4-300x92.jpg 300w, https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-4-768x237.jpg 768w\" sizes=\"(max-width: 867px) 100vw, 867px\" \/><\/a><\/figure>\n\n\n\n<p><\/p>\n\n\n\n<p>Click to the Send button and after the successful execution the Postman return &#8220;Status: 200 OK&#8221; message:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><a href=\"https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-5.jpg\" target=\"_blank\" rel=\"noreferrer noopener\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"323\" src=\"https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-5-1024x323.jpg\" alt=\"\" class=\"wp-image-26\" srcset=\"https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-5-1024x323.jpg 1024w, https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-5-300x95.jpg 300w, https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-5-768x242.jpg 768w, https:\/\/v-tailor.hu\/en\/wp-content\/uploads\/sites\/2\/2024\/01\/failedtovalidate-5.jpg 1068w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/a><\/figure>\n\n\n\n<p><\/p>\n\n\n\n<p>When you go back to &#8220;Cloud Accounts&#8221; in the vRA the error message cannot be displayed and you will be able to insert the vCenter service user&#8217;s credentials and after you click to <em>Validate<\/em> , the Save button become active, you can save the configuration and the synchronization is starting.<\/p>\n<\/div><\/div>\n<\/div><\/div>\n","protected":false},"excerpt":{"rendered":"<p>When a vCenter certificate expired after you have renewed it you need to add this new certificate to the solutions that are linked with the vCenter. Generally it is enough to just re-authenticate with the service user because the vCenter provide the new certificate that&#46;&#46;&#46;<\/p>\n","protected":false},"author":1,"featured_media":17,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4],"tags":[5],"_links":{"self":[{"href":"https:\/\/v-tailor.hu\/en\/wp-json\/wp\/v2\/posts\/16"}],"collection":[{"href":"https:\/\/v-tailor.hu\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/v-tailor.hu\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/v-tailor.hu\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/v-tailor.hu\/en\/wp-json\/wp\/v2\/comments?post=16"}],"version-history":[{"count":5,"href":"https:\/\/v-tailor.hu\/en\/wp-json\/wp\/v2\/posts\/16\/revisions"}],"predecessor-version":[{"id":27,"href":"https:\/\/v-tailor.hu\/en\/wp-json\/wp\/v2\/posts\/16\/revisions\/27"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/v-tailor.hu\/en\/wp-json\/wp\/v2\/media\/17"}],"wp:attachment":[{"href":"https:\/\/v-tailor.hu\/en\/wp-json\/wp\/v2\/media?parent=16"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/v-tailor.hu\/en\/wp-json\/wp\/v2\/categories?post=16"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/v-tailor.hu\/en\/wp-json\/wp\/v2\/tags?post=16"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}