{"id":387,"date":"2022-10-11T15:20:00","date_gmt":"2022-10-11T13:20:00","guid":{"rendered":"https:\/\/zerobotics.de\/blog\/?p=387"},"modified":"2023-12-22T14:22:08","modified_gmt":"2023-12-22T13:22:08","slug":"replacing-the-vcenter-machine-certificate-and-dont-forget-the-vxrail-manager","status":"publish","type":"post","link":"https:\/\/zerobotics.de\/blog\/en\/replacing-the-vcenter-machine-certificate-and-dont-forget-the-vxrail-manager\/","title":{"rendered":"Replacing the vCenter Machine Certificate &#8230;and don&#8217;t forget the VxRail Manager!"},"content":{"rendered":"<span class=\"span-reading-time rt-reading-time\" style=\"display: block;\"><span class=\"rt-label rt-prefix\">Reading Time<\/span> <span class=\"rt-time\"> 3<\/span> <span class=\"rt-label rt-postfix\">Minutes<\/span><\/span>\n<p>The topic of certificates seems to be haunting me at the moment.<br>Anyway, I want to briefly show here how easy it is nowadays to replace the SSL certificate of the vCenter with an Enterprise CA-signed one.<\/p>\n\n\n\n<p>If you look at the KB article from VMware (<a href=\"https:\/\/kb.vmware.com\/s\/article\/2112277\" target=\"_blank\" rel=\"noopener\">Replacing a vSphere 6.x \/7.x Machine SSL certificate with a Custom Certificate Authority Signed Certificate<\/a>), the &#8222;certificate-manager&#8220; is still quoted here on the command line.<\/p>\n\n\n\n<div style=\"height:58px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<h2 class=\"wp-block-heading\">Create CSR in vSphere Client<\/h2>\n\n\n\n<p>But it is also very easy via the vSphere Client. In my case, there are a couple of VxRail clusters connected to this vCenter, here you also have to do something in the VxRail Manager (in this case still via CLI), but it&#8217;s also easy, see below.<br>To the Demo!<\/p>\n\n\n\n<!--more-->\n\n\n\n<p>Login to vCenter and go to  <code><strong>Administration &gt;&gt; Certificate Management<\/strong><\/code>, then <code><strong>__MACHINE_CERT &gt;&gt; Actions &gt;&gt; Generate Certificate Signing Request<\/strong><\/code>:<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"920\" height=\"653\" src=\"https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik.png\" alt=\"\" class=\"wp-image-389\" srcset=\"https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik.png 920w, https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-300x213.png 300w, https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-768x545.png 768w, https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-624x443.png 624w\" sizes=\"auto, (max-width: 920px) 100vw, 920px\" \/><figcaption class=\"wp-element-caption\">Generate Certificate Signing Request (CSR)<\/figcaption><\/figure>\n\n\n\n<p>Put in all info for the Signing Request:<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"770\" height=\"639\" src=\"https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-1.png\" alt=\"\" class=\"wp-image-390\" srcset=\"https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-1.png 770w, https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-1-300x249.png 300w, https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-1-768x637.png 768w, https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-1-624x518.png 624w\" sizes=\"auto, (max-width: 770px) 100vw, 770px\" \/><figcaption class=\"wp-element-caption\">Enter Infos for the CSR<\/figcaption><\/figure>\n\n\n\n<p>\u2026and either copy or download the CSR:<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"772\" height=\"642\" src=\"https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-2.png\" alt=\"\" class=\"wp-image-391\" srcset=\"https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-2.png 772w, https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-2-300x249.png 300w, https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-2-768x639.png 768w, https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-2-624x519.png 624w\" sizes=\"auto, (max-width: 772px) 100vw, 772px\" \/><figcaption class=\"wp-element-caption\">Copy or Download the CSR<\/figcaption><\/figure>\n\n\n\n<p><\/p>\n\n\n\n<p>Well, that was easy!<br>The <code><strong>something.csr<\/strong><\/code> file is now required by the certificate admin(s), or, if you do this with the Windows CA, there may also be a self-service portal, but this is not the topic here (but it could work as in <a href=\"https:\/\/zerobotics.de\/blog\/en\/vmware-nsx-alb-avi-certificate-signing-request-csr-in-combination-with-microsoft-ca\/\" target=\"_blank\" rel=\"noopener\" title=\"VMware NSX ALB \/ AVI Certificate Signing Request (CSR) with Microsoft CA\">this blog post<\/a>).<\/p>\n\n\n\n<div style=\"height:69px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<h2 class=\"wp-block-heading\">The CSR has been submitted, what&#8217;s next?<\/h2>\n\n\n\n<p>After creating a certificate from the CSR, we should now have a CER file and a certificate chain file, both available from our CA.<\/p>\n\n\n\n<p>Back to vSphere Client, this time <strong><code>Administration &gt;&gt; Certificate Management, <\/code><\/strong>then<strong><code> __MACHINE_CERT &gt;&gt; Actions &gt;&gt; Import and Replace Certificate<\/code><\/strong>:<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"467\" height=\"330\" src=\"https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-3.png\" alt=\"\" class=\"wp-image-392\" srcset=\"https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-3.png 467w, https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-3-300x212.png 300w\" sizes=\"auto, (max-width: 467px) 100vw, 467px\" \/><figcaption class=\"wp-element-caption\">Import and Replace Certificate<\/figcaption><\/figure>\n\n\n\n<p>Then &#8222;Replace with external CA certificate where CSR is generated from vCenter Server&#8220;:<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"1022\" height=\"688\" src=\"https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-4.png\" alt=\"\" class=\"wp-image-393\" srcset=\"https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-4.png 1022w, https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-4-300x202.png 300w, https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-4-768x517.png 768w, https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-4-624x420.png 624w\" sizes=\"auto, (max-width: 1022px) 100vw, 1022px\" \/><figcaption class=\"wp-element-caption\">Replace where CSR was generated on vCenter<\/figcaption><\/figure>\n\n\n\n<p>Hadn&#8217;t mentioned it yet: the advantage of a CSR from the vCenter is that the private key is already &#8222;embedded&#8220;. With a CSR that was not created on the vCenter, it is missing. You would then have to get it additionally and select option 3.<\/p>\n\n\n\n<p>Anyway, with option 2, it then goes on like this:<br>Select a new CER file from the CA (Machine SSL Certificate) and select a chain certificate file from the CA (Chain of trusted root certificates) and click Replace.<br><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-blue-color\">Attention<\/mark>: now the vCenter services restart! This will not take long, but should probably not be done in productive environments without prior consultation.<a href=\"Attention: now the vCenter services restart! This will not take long, but should probably not be done in productive environments without prior consultation.\"><mark style=\"background-color:#e6e6e6\" class=\"has-inline-color has-blue-color\"><\/mark><\/a><\/p>\n\n\n\n<figure class=\"wp-block-image size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"687\" src=\"https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-5-1024x687.png\" alt=\"\" class=\"wp-image-394\" style=\"width:655px;height:439px\" srcset=\"https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-5-1024x687.png 1024w, https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-5-300x201.png 300w, https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-5-768x515.png 768w, https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-5-624x419.png 624w, https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-5.png 1030w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><figcaption class=\"wp-element-caption\">Add CER file and Chain-cert<\/figcaption><\/figure>\n\n\n\n<p>If you are impatient (F5!!! F5!!! F5!!!) and can already log in again, the certificate overview may look a bit strange and also spit out a few errors. Relax and give it a few minutes!<\/p>\n\n\n\n<p><\/p>\n\n\n\n<p>And that&#8217;s it, the vCenter now has a &#8222;Trusted Certificate&#8220; from its own CA and the browser is no longer annoying with security warnings.<\/p>\n\n\n\n<div style=\"height:57px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<h2 class=\"wp-block-heading\">The VxRail Manager also wants to get back on!<\/h2>\n\n\n\n<p>If there are applications that talk to the vCenter ( this can happen), such as vRealize Log Insight, vRealize Automation, vRealize Operations, Skyline Advisor, VxRail Manager,\u2026. then they do not yet know about their luck and should be adjusted (by re-authentication or similar).<\/p>\n\n\n\n<p>IIn my case, there are a few VxRail Managers here that now have no &#8222;trust&#8220; with the vCenter, but this can be fixed with a Python script (available from Dell in the support article <a href=\"https:\/\/www.dell.com\/support\/kbdoc\/de-de\/000077894\/vxrail-how-to-replace-certificate-in-vcenter-for-vxrail-appliance?lang=en\" target=\"_blank\" rel=\"noopener\">VxRail: How to manually import vCenter SSL certificate on VxRail Manager<\/a>). The script is updated from time to time, so always check back first!<br>So:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Load the script onto the VxRail Manager (e.g. via WinSCP).<\/li>\n\n\n\n<li>log in as &#8222;mystic&#8220; via SSH<\/li>\n\n\n\n<li>&#8222;su&#8220; to user &#8222;root&#8220;<\/li>\n\n\n\n<li>execute script: <code>python cert_util.py<\/code><\/li>\n<\/ul>\n\n\n\n<figure class=\"wp-block-image size-full is-resized\"><img loading=\"lazy\" decoding=\"async\" width=\"628\" height=\"682\" src=\"https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-6.png\" alt=\"\" class=\"wp-image-395\" style=\"width:628px;height:682px\" srcset=\"https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-6.png 628w, https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-6-276x300.png 276w, https:\/\/zerobotics.de\/blog\/wp-content\/uploads\/2022\/09\/grafik-6-624x678.png 624w\" sizes=\"auto, (max-width: 628px) 100vw, 628px\" \/><figcaption class=\"wp-element-caption\">VxRail Manager cert_util.py<\/figcaption><\/figure>\n\n\n\n<p>As you can see, the script loads the new CA certificate from vCenter, replaces the existing ones with it and then restarts a few services. Done.<\/p>\n\n\n\n<div style=\"height:46px\" aria-hidden=\"true\" class=\"wp-block-spacer\"><\/div>\n\n\n\n<h2 class=\"wp-block-heading\">Easy!<\/h2>\n\n\n\n<p>In my experience, the use of self-signed certificates is still a rarity, but the effort is small. The CSR is generated in no time and the certificates are quickly exchanged in the vSphere Client.<\/p>\n","protected":false},"excerpt":{"rendered":"<p><span class=\"span-reading-time rt-reading-time\" style=\"display: block;\"><span class=\"rt-label rt-prefix\">Reading Time<\/span> <span class=\"rt-time\"> 3<\/span> <span class=\"rt-label rt-postfix\">Minutes<\/span><\/span>The topic of certificates seems to be haunting me at the moment.Anyway, I want to briefly show here how easy it is nowadays to replace the SSL certificate of the vCenter with an Enterprise CA-signed one. If you look at the KB article from VMware (Replacing a vSphere 6.x \/7.x Machine SSL certificate with a [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[30,84],"tags":[],"class_list":["post-387","post","type-post","status-publish","format-standard","hentry","category-vmware-en","category-vsphere-en"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/zerobotics.de\/blog\/wp-json\/wp\/v2\/posts\/387","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/zerobotics.de\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/zerobotics.de\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/zerobotics.de\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/zerobotics.de\/blog\/wp-json\/wp\/v2\/comments?post=387"}],"version-history":[{"count":16,"href":"https:\/\/zerobotics.de\/blog\/wp-json\/wp\/v2\/posts\/387\/revisions"}],"predecessor-version":[{"id":496,"href":"https:\/\/zerobotics.de\/blog\/wp-json\/wp\/v2\/posts\/387\/revisions\/496"}],"wp:attachment":[{"href":"https:\/\/zerobotics.de\/blog\/wp-json\/wp\/v2\/media?parent=387"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/zerobotics.de\/blog\/wp-json\/wp\/v2\/categories?post=387"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/zerobotics.de\/blog\/wp-json\/wp\/v2\/tags?post=387"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}