<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:blogger='http://schemas.google.com/blogger/2008' xmlns:georss='http://www.georss.org/georss' xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-8658731852844520209</id><updated>2026-09-12T03:17:48.368-04:00</updated><category term="VMWare"/><category term="Microsoft"/><category term="Citrix"/><category term="powershell"/><category term="Script"/><category term="Home Improvement"/><category term="Dell"/><category term="xendesktop"/><category term="powercli"/><category term="DIY"/><category term="Kace"/><category term="Office 2007"/><category term="IT Projects"/><category term="Windows"/><category term="vCenter"/><category term="Toyota Rav4"/><category term="vsphere"/><category term="MDT 2010"/><category term="Upgrade"/><category term="Backup"/><category term="ESXI"/><category term="Subaru STI 2008"/><category term="automation"/><category term="vRealize"/><category term="vRealize Orchestrator"/><category term="SMS"/><category term="SRM"/><category term="Site Recovery Manager"/><category term="VCSA"/><category term="VDP"/><category term="mcafee"/><category term="python"/><category term="terraform"/><category term="API"/><category term="Ansible"/><category term="Blackberry"/><category term="Pointsec"/><category term="Report"/><category term="RightFax"/><category term="vCenter 5.5"/><category term="vSphere Data Protection"/><category term="vSphere Replication"/><category term="vsphere 6"/><category term="Cisco"/><category term="FTP"/><category term="HP ProCurve 1810g"/><category term="IT Tools"/><category term="Linux"/><category term="Log Insight"/><category term="NSX"/><category term="Orchestrator"/><category term="PScribo"/><category term="Registry Tweak"/><category term="Restore"/><category term="SRM 8.1"/><category term="TFTP"/><category term="UCS"/><category term="UltraVNC"/><category term="VB"/><category term="VCSA 5.5"/><category term="VCSA 6.5"/><category term="VCSA-Deploy"/><category term="miscellaneous"/><category term="vCenter v6.0"/><category term="vRA"/><category term="vRO"/><category term="vSphere 6.#"/><category term="workflow"/><category term="4.0"/><category term="5.8.1"/><category term="6.0. 6.1"/><category term="6.5"/><category term="ABR"/><category term="API Explorer"/><category term="Appliance"/><category term="Audit"/><category term="AutoDeploy"/><category term="CLI"/><category term="CMD"/><category term="Centos"/><category term="Certificate"/><category term="Command Line"/><category term="Console"/><category term="DHCP"/><category term="Do-Until Loops"/><category term="Drivers"/><category term="EMC RPA"/><category term="ESXI 6.5"/><category term="ESXi6.5"/><category term="Flask"/><category term="Import-VApp"/><category term="Installation"/><category term="JSON"/><category term="JavaScript"/><category term="Jinja2"/><category term="Kickstart"/><category term="MKS"/><category term="PS Host"/><category term="PXE"/><category term="Patching"/><category term="Permission"/><category term="Posh-SSH"/><category term="REST"/><category term="SMS Imaging"/><category term="SQL"/><category term="SRM 5.8.1"/><category term="SRM 6.1.2"/><category term="SRM 6.5.1"/><category term="Software"/><category term="TFTPBoot"/><category term="Unlock"/><category term="VCSA 6.0"/><category term="VCSA 6.7 Betta"/><category term="VDP 6.1"/><category term="VMRC"/><category term="Vagrant"/><category term="VirtualBox"/><category term="Vmware vSphere Integration Plugin"/><category term="Windows 2012 R2"/><category term="Winexe"/><category term="azure"/><category term="esxi.5.5"/><category term="foreman"/><category term="highlighter"/><category term="issues"/><category term="lacp"/><category term="locked"/><category term="nfs"/><category term="nsx manager"/><category term="password reset"/><category term="pyvmomi"/><category term="sunrpc"/><category term="syntax"/><category term="takeown"/><category term="troubleshooting"/><category term="v6.7"/><category term="vCenter 6.0"/><category term="vCenter 6.5"/><category term="vCenter v6.5"/><category term="vRO 7.2"/><category term="vSphere 6.7"/><category term="vSphere Data Protection 6.1"/><category term="vacuum task"/><category term="vcenter v5.#"/><category term="vcsa6.7"/><category term="virtualenv"/><category term="virtualenvwrapper"/><category term="vm hosted apps"/><category term="vpostgres"/><category term="vrealize automation"/><category term="vscode"/><category term="vyatta"/><category term="workflows"/><category term="wsl2"/><category term="xenapp"/><title type='text'>Fdo&#39;s Workspace</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://fdo-workspace.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default?redirect=false'/><link rel='alternate' type='text/html' href='http://fdo-workspace.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><link rel='next' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default?start-index=26&amp;max-results=25&amp;redirect=false'/><author><name>fdo</name><uri>http://www.blogger.com/profile/16882300714528613456</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhndsbgzepfJ0U5gXwY3zzRcGOqiMcblr09VzwWLCMA_waqC9FUthSCa8n91RwqW_kZXNo2si5UU3N5Ex6UJbYkcUpcJnxOQw6jPOBYuux7fomIpI0UUf8vOXyBT7hyuuE/s113/IMG_5942.jpg'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>239</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-8658731852844520209.post-4820854492889306060</id><published>2021-07-19T13:35:00.001-04:00</published><updated>2021-07-19T13:38:24.738-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="terraform"/><category scheme="http://www.blogger.com/atom/ns#" term="troubleshooting"/><category scheme="http://www.blogger.com/atom/ns#" term="wsl2"/><title type='text'>Terraform Troubleshooting: Server Failed to authenticate the request</title><content type='html'>&lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;This is another one of those odd issues with my Ubuntu Linux Subsystem. Everything was working perfectly fine before I shutdown the laptop for the weekend and then it’s Monday. I would be lying if I say I did not touch laptop over the weekend. The truth is I did not use the Ubuntu Subsystem over the weekend and this morning I keep getting strange Terraform problems when running “terraform apply”. &lt;/p&gt;  &lt;p&gt;Keeps complaining about:&lt;/p&gt;  &lt;p&gt;Error: reading share properties for AzureRM Storage Account “diagstore###”: storage.FileServicesClient#GetServiceProperties: Failure responding to request: Status Code: 403/400 – Original Error: autorest/azure: Service returned an error. Status=400 Code=”AuthenticationFailed” Message=”Server failed to authenticate request. Make sure the value of Authentication header is formedd correctly including the signature.”&lt;/p&gt;  &lt;p&gt;Bellow is a screenshot of the error:&lt;/p&gt; &lt;a href=&quot;https://drive.google.com/uc?id=1J4wYTlBESEr2kWkFZieFQzTFNe3SX4A1&quot;&gt;&lt;img title=&quot;wsl2&quot; style=&quot;display: inline; background-image: none;&quot; border=&quot;0&quot; alt=&quot;wsl2&quot; src=&quot;https://drive.google.com/uc?id=1xKe9YdZIrXd9j50mBFaGmg_k1WMdst5t&quot; width=&quot;945&quot; height=&quot;145&quot; /&gt;&lt;/a&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;Insufficient Priviledges?&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;Like usual did some browsing around these error messages and most of them pointed to insufficient access. To rule that out made myself added myself as contributor to the resource group this storage account was living and tried again. &lt;/p&gt;  &lt;p&gt;&lt;strong&gt;Destroy and Rebuild?&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;Since this was my own dev environment it did not bother me to destroy and start over, but keep running into the same error when it reaches to the point where the storage account is been built&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;Time Drift? Seriously!!&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;I can’t find the post that mentioned this but apparently my Ubuntu subsystem had a huge time drift. I was too focused on fixing the problem and did not grab a screenshot the time drift but the fix was simply issue a&lt;strong&gt; #&amp;gt; wsl –shutdown&lt;/strong&gt; from a PowerShell command prompt and start the subsystem again. After that everything was happy again. &lt;/p&gt;</content><link rel='replies' type='application/atom+xml' href='http://fdo-workspace.blogspot.com/feeds/4820854492889306060/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://fdo-workspace.blogspot.com/2021/07/terraform-troubleshooting-server-failed.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/4820854492889306060'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/4820854492889306060'/><link rel='alternate' type='text/html' href='http://fdo-workspace.blogspot.com/2021/07/terraform-troubleshooting-server-failed.html' title='Terraform Troubleshooting: Server Failed to authenticate the request'/><author><name>fdo</name><uri>http://www.blogger.com/profile/16882300714528613456</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhndsbgzepfJ0U5gXwY3zzRcGOqiMcblr09VzwWLCMA_waqC9FUthSCa8n91RwqW_kZXNo2si5UU3N5Ex6UJbYkcUpcJnxOQw6jPOBYuux7fomIpI0UUf8vOXyBT7hyuuE/s113/IMG_5942.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8658731852844520209.post-8295523412971513729</id><published>2021-07-15T12:07:00.000-04:00</published><updated>2021-07-15T12:07:44.127-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="terraform"/><title type='text'>Troubleshooting Terraform: Not the usual “Failed to query available provider packages” in Ubuntu Windows 10 WSL2</title><content type='html'>&lt;p&gt;I have a Windows 10 laptop with Ubuntu18 WSL2 installed and configured with bunch of tools including Terraform and Ansible. Because Ansible is does not run on Windows and can only manage Windows hosts, we are forced to use Windows System for Linux (&lt;a href=&quot;https://docs.ansible.com/ansible/2.5/user_guide/windows_faq.html&quot; target=&quot;_blank&quot;&gt;Official Doc&lt;/a&gt;). Everything was working perfectly fine and all last week I’ve been working on Terraform in Windows because I did not have any Ansible work to do. Earlier this week I started the Ubuntu system and realized that when I executed “terraform init” I would get the following error:&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;Error: Failed to query available provider packages&lt;/p&gt;    &lt;p&gt;Could not retrieve the list of available versions for provider hashicorp/azurerm: could not query provider registry     &lt;br /&gt; │ for registry.terraform.io/hashicorp/azurerm: the request failed after 2 attempts, please try again later: Get      &lt;br /&gt; │ &amp;quot;&lt;a href=&quot;https://registry.terraform.io/v1/providers/hashicorp/azurerm/versions&amp;quot;:&quot;&gt;https://registry.terraform.io/v1/providers/hashicorp/azurerm/versions&amp;quot;:&lt;/a&gt; net/http: request canceled while waiting for      &lt;br /&gt; │ connection (ssssssssssssssssssssssssssssssssssssssssssssssssss)&lt;/p&gt; &lt;/blockquote&gt; &lt;a href=&quot;https://drive.google.com/uc?id=1Mc4aavt1Zo6omFAu7Z58CwRutNC_Zh_Y&quot;&gt;&lt;img title=&quot;Screenshot 2021-07-15 112720&quot; style=&quot;display: inline; background-image: none;&quot; border=&quot;0&quot; alt=&quot;Screenshot 2021-07-15 112720&quot; src=&quot;https://drive.google.com/uc?id=1H_MTSc9OlFfIodSeW3mnhetJnELOHQ8X&quot; width=&quot;898&quot; height=&quot;198&quot; /&gt;&lt;/a&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;This clearly points to a network related problem but:&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt; I was able to ping 8.8.8.8 perfectly fine&lt;/li&gt;    &lt;li&gt;nslookup 8.8.8.8 &amp;gt; returns dns.google.&lt;/li&gt;    &lt;li&gt;even tried curl &lt;a title=&quot;https://registry.terraform.io/v1/providers/hashicorp/azurerm/versions&quot; href=&quot;https://registry.terraform.io/v1/providers/hashicorp/azurerm/versions&quot;&gt;https://registry.terraform.io/v1/providers/hashicorp/azurerm/versions&lt;/a&gt; &amp;gt; returns all the versions&lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;At this point, I was almost convinced it was not a network problem but there was one more thing I did not try. I connected to the VPN and everything started working again. &lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;h1&gt;So what was the problem????&lt;/h1&gt;  &lt;p&gt;Here is the sequence of events:&lt;/p&gt;  &lt;ol&gt;   &lt;li&gt;For a week I’ve been doing Terraform work from Windows because there was no need Ansible related work.&lt;/li&gt;    &lt;li&gt;I have not been using&amp;#160; VPN because been coding against my dedicated Sandbox.&lt;/li&gt;    &lt;li&gt;This week I had to do some Ansible/Terraform work against my Sandbox and ran into the Terraform problem inside the subsystem.&lt;/li&gt;    &lt;li&gt;After struggling for several days trying to overcome this issue, connected to the VPN and everything started working&lt;/li&gt; &lt;/ol&gt;  &lt;p&gt;This problem normally does not exist on a fresh WSL setup this was 100% caused by myself.&lt;/p&gt;  &lt;p&gt;If you are familiar with the WSL2 network problem when connected to a VPN you will know what this is all about. To overcome the VPN problem inside the subsystem there was couple tweaks I had to make including modifying the DNS inside ubuntu. By default WSL automatically generates the /etc/resolv.conf files every time the subsystem is loaded. I needed a static /etc/resolv.conf because I needs it to resolve using the VPN assigned DNS servers when connected.&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;Default /etc/resolv.conf looks like:&lt;/p&gt;    &lt;pre&gt;&lt;code&gt;# This file was automatically generated by WSL. To stop automatic generation of this file, add the following entry to /etc/wsl.conf:     
# [network]
# generateResolvConf = false&lt;/code&gt;&lt;/pre&gt;
&lt;/blockquote&gt;

&lt;p&gt;After adding those lines into the /etc/wsl.conf updated I was able to customize my /etc/resolv.conf to look like. &lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;nameserver #.#.#.10 &lt;/p&gt;

  &lt;p&gt;nameserver #.#.#.11&lt;/p&gt;

  &lt;p&gt;nameserver 8.8.8.8&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;The first and second row are the DNS assigned by the VPN, you can find this by running ipconfig /all from your Windows CMD prompt. Last line is just google dns which explains why resolution was working. The only hint was the delay during pings and nslookups which I did notice but did not pay close attention.&lt;/p&gt;

&lt;p&gt;After few more test and re-reading the error message it totally makes sense now. &lt;strong&gt;&lt;em&gt;“Client.Timeout exceeded while awaiting headers” &lt;/em&gt;&lt;/strong&gt;Apparently, when “terraform init” is executed it tries to reach out to the provider urls and resolve against DNS1 &amp;gt; DNS2 before it hits DNS3 which is 8.8.8.8 it times out. I disabled DNS1 and DNS2 leaving 8.8.8.8 it was back to normal.&lt;/p&gt;

&lt;h1&gt;How was this fixed?&lt;/h1&gt;

&lt;p&gt;Solution to my problem was straight forward, I moved nameserver 8.8.8.8 to the top. If I have to work while connected to the VPN it will hit the second nameserver and timeout should cover the second try.&lt;/p&gt;

&lt;p&gt;&amp;#160;&lt;/p&gt;

&lt;p&gt;Hope this help someone. This was not the usual “Error: Failed to query available provider packages” error…&lt;/p&gt;</content><link rel='replies' type='application/atom+xml' href='http://fdo-workspace.blogspot.com/feeds/8295523412971513729/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://fdo-workspace.blogspot.com/2021/07/troubleshooting-terraform-not-usual.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/8295523412971513729'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/8295523412971513729'/><link rel='alternate' type='text/html' href='http://fdo-workspace.blogspot.com/2021/07/troubleshooting-terraform-not-usual.html' title='Troubleshooting Terraform: Not the usual “Failed to query available provider packages” in Ubuntu Windows 10 WSL2'/><author><name>fdo</name><uri>http://www.blogger.com/profile/16882300714528613456</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhndsbgzepfJ0U5gXwY3zzRcGOqiMcblr09VzwWLCMA_waqC9FUthSCa8n91RwqW_kZXNo2si5UU3N5Ex6UJbYkcUpcJnxOQw6jPOBYuux7fomIpI0UUf8vOXyBT7hyuuE/s113/IMG_5942.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8658731852844520209.post-928688420193988608</id><published>2021-07-08T12:11:00.000-04:00</published><updated>2021-07-08T12:12:20.913-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Ansible"/><category scheme="http://www.blogger.com/atom/ns#" term="terraform"/><title type='text'>Learning Terraform From Zero</title><content type='html'>&lt;p&gt;This last year been really hectic and like everyone we have to do what we need to stay afloat. I recently started a new position with a new company and of course this is the beginning of a new adventure. If there is anyone following my blog you probably notice a shift in topics covered. &lt;/p&gt;  &lt;p&gt;This article is only to provide some guidance and sharing my personal experience learning Terraform. This is by no mean a tutorial.&lt;/p&gt;  &lt;h1&gt;How hard is Terraform? &lt;/h1&gt;  &lt;p&gt;This depends completely on your background and your willingness to learn new technologies. I am by no means a software developer but I do write my fair share scripts, code and automation tools to perform various tasks. It could be mainly but not limited to PowerShell, Python, Ansible against Windows/Linux vms or VMware infra or Azure Cloud. In the past, I did tinker with Terraform and that was prior to choosing Ansible for a project I was working one. So I spent a good full weekend cranking on PluralSight training and YouTube videos to grab a solid foundation of the basics of Terraform. Learning Terraform was not terribly complicated, just had to be open minded.&lt;/p&gt;  &lt;p&gt;My goal was to familiarize myself with all aspects of managing resources in Azure Cloud with Terraform.&lt;/p&gt;  &lt;h1&gt;Where to start?&lt;/h1&gt;  &lt;p&gt;Read, Learn and Practice.&lt;/p&gt;  &lt;p&gt;You can find a lot of good reading material online. Best place to start is the main HashiCorp Site. Go thru the fundamentals and get an idea of what we dealing with:&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&amp;#160;&lt;a title=&quot;https://learn.hashicorp.com/terraform&quot; href=&quot;https://learn.hashicorp.com/terraform&quot;&gt;https://learn.hashicorp.com/terraform&lt;/a&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;If you have access to online training course or willing to spend some money there are even more options. Fortunately I already had access to PluralSight and Here are couple good ones I used:&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;- Terraform – Getting Started by Ned Bellavance&lt;/p&gt;    &lt;p&gt;- Terraform – Deep Dive by Ned Bellavance&lt;/p&gt;    &lt;p&gt;- Implementing Terraform on Microsoft Azure – by Ned Bellavance&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;Those 3 courses help me setup a good development environment and a foundation. &lt;/p&gt;  &lt;p&gt;There are of course plenty other good training sites like UDemy or even YouTube. Learning from YouTube help better if you are trying to expand on a specific topic. Because there is so much content in YouTube sometimes is hard to keep a good flow.&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;h1&gt;Where to practice?&lt;/h1&gt;  &lt;p&gt;Having a lab and place to get some hands on experience is key to learning. No amount of reading or watching video will give you the real experience. Terraform can be installed on OS X, Linux or Windows and you can manage resources in AWS, Azure, Google Cloud, Docker and etc. Since my goal is to learn how to manage Azure resources there is an option to create a free Azure account with $200 credit – &lt;a href=&quot;https://azure.microsoft.com/en-us/free/&quot; target=&quot;_blank&quot;&gt;link&lt;/a&gt;. I was fortunate enough to get a Visual Studio Subscription and monthly credit for my development projects.&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;h1&gt;Understanding How Terraform Works&lt;/h1&gt;  &lt;h2&gt;Terraform – Infrastructure as Code&lt;/h2&gt;  &lt;p&gt;At first I kept trying to relate Terraform with Ansible which are completely different tools. In some cases you can perform similar task but there are pros and cons of doing it one way or the other.&lt;/p&gt;  &lt;p&gt;In Terraform, you write one .tf file that contain your infrastructure as desired and you can build or destroy those resources by simply running a command. If you need to make some changes simple adjust the content of the .tf and apply again it will automatically update the resources. Depending on the type of changes made it might require deleting and rebuilding the resource.&lt;/p&gt;  &lt;p&gt;In Ansible, you could also achieve the same by writing a playbook to build the resources and another one to destroy. It will require 2 different playbooks. Now the problem start when you need to make changes to the resources. You will have to write playbook to apply the changes, if changes require object deletion you will have to write that into the playbook. &lt;/p&gt;  &lt;p&gt;Note: Terraform focuses on infrastructure automation, which is why it does a much better job a managing the infrastructure. You only have to make sure the tf file contains the resources with the desired configuration and Terraform will take care of building/updating those resources.&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;h2&gt;Where Terraform Don’t Shine&lt;/h2&gt;  &lt;p&gt;Terraform is a great tool and can certainly get the job done but there are times were you need to accept that there are easier ways.&lt;/p&gt;  &lt;p&gt;Say the environment is now deployed, all the resources are deployed in Azure: resource groups, virtual network, load balancers, network security groups, and 100s of Linux and Windows servers. We need to configure all those Linux and Windows servers, they range from application servers, web servers, databases, so forth and so on. &lt;/p&gt;  &lt;p&gt;With Terraform, you could configure servers by using writing long Bash script or PowerShell scripts and using the remote-exec provisioner to kick start the script remotely. Main challenge is Terraform will only be responsible of executing the task and will not be responsible of making sure the script is executed properly or not. It will be entirely reliant upon how well that Bash or PowerShell script is written.&amp;#160; If your next Terraform job is depending on the successful completion of the configuration script, this will already be a big challenge.&lt;/p&gt;  &lt;p&gt;With Ansible instead, you write your playbook or role you want to assign for each type of&amp;#160; server and it will make sure the server is properly configured. You will have to create playbooks to configure web servers, application servers, db servers etc for Linux or Windows.&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;h2&gt;Why not use them together? &lt;/h2&gt;  &lt;p&gt;Using the right tool for the right job will make you life so much easier. Let Terraform handle all infrastructure deployment and Ansible do the configuration.&lt;/p&gt;  &lt;p&gt;I’ve tested this and works harmonically. This is what the flow would look like.&lt;/p&gt;  &lt;ol&gt;   &lt;li&gt;Terraform deploys all the Azure resources&lt;/li&gt;    &lt;li&gt;Terraform builds the Ansible inventory.yml file with the host and credentials or sshkeys&lt;/li&gt;    &lt;li&gt;Terraform executes the Ansible Playbook against the inventory.yml file&lt;/li&gt; &lt;/ol&gt;  &lt;p&gt;This a quick workflow of one of the demo Terraform jobs I’ve been working on but hopefully I will start posting of those stuff very soon.&lt;/p&gt;</content><link rel='replies' type='application/atom+xml' href='http://fdo-workspace.blogspot.com/feeds/928688420193988608/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://fdo-workspace.blogspot.com/2021/07/learning-terraform-from-zero.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/928688420193988608'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/928688420193988608'/><link rel='alternate' type='text/html' href='http://fdo-workspace.blogspot.com/2021/07/learning-terraform-from-zero.html' title='Learning Terraform From Zero'/><author><name>fdo</name><uri>http://www.blogger.com/profile/16882300714528613456</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhndsbgzepfJ0U5gXwY3zzRcGOqiMcblr09VzwWLCMA_waqC9FUthSCa8n91RwqW_kZXNo2si5UU3N5Ex6UJbYkcUpcJnxOQw6jPOBYuux7fomIpI0UUf8vOXyBT7hyuuE/s113/IMG_5942.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8658731852844520209.post-6018148780934417092</id><published>2021-07-08T10:00:00.001-04:00</published><updated>2021-07-08T14:26:06.463-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="azure"/><category scheme="http://www.blogger.com/atom/ns#" term="powershell"/><category scheme="http://www.blogger.com/atom/ns#" term="terraform"/><category scheme="http://www.blogger.com/atom/ns#" term="vscode"/><title type='text'>Visual Studio Code: Working against multiple User Accounts and Azure Subscriptions</title><content type='html'>&lt;p&gt;I started a new job and switched from a MacBook to a Dell Laptop. So I am forced to change my mindset and adjust, process been a bit saddening but I will survive. I use VSCode develop Azure PowerShell, Terraform and Ansible code to perform various task. I have multiple user accounts and even more Azure Subscriptions each for its own purpose. I often switch around depending on the tasks I am performing. The other day something really odd happen and thought I should document this and share. &lt;/p&gt;  &lt;h1&gt;Problem?&lt;/h1&gt;  &lt;p&gt;I was working on a Terraform job to deploy some resources in Azure but it was executing against the wrong subscription and user account. Obviously tried disconnecting all session using Disconnect-AzConnect and even Logout-AzAccount, then use Get-AzContext to make sure it was not returning anything. Used Connect-AzAccount again and Terraform was still deploying resources to the wrong place. I tried restarting computer, clearing browser cache, even searched how to clear Visual Studio Cache and no luck.&lt;/p&gt;  &lt;h1&gt;Cause?&lt;/h1&gt;  &lt;p&gt;What I did not realize was that there was an active Azure CLI (az login) session connected to the Azure Subscription the resources was been deployed to. Ran the “az account show” and it indeed show the subscription Terraform been deploying the to. Used “az logout” clear that. Terraform requires Azure CLI session not the Azure PowerShell session. Duh. This is what happens when you learn something new then shift your focus to work on a complete different project and come back from the holidays…&lt;/p&gt;  &lt;h1&gt;Lesson learned:&lt;/h1&gt;  &lt;blockquote&gt;   &lt;p&gt;Terraform does not care whether you use Azure CLI or Azure PowerShell to establish to establish the Azure session. TF will pickup the active session and try to deploy resources.&lt;/p&gt; &lt;/blockquote&gt;  &lt;h1&gt;Working against Multiple Azure Subscriptions in Visual Studio Code&lt;/h1&gt;  &lt;p&gt;Visual Studio Code is easily became “The Favorite IDE” because of its rich features/capabilities and language supports. But sometimes those rich features can work against you. My Environment have PowerShell Core 7.0 installed as well as the VSCode PowerShell Module that gives you the “PowerShell Integrated Console” terminal.&lt;/p&gt;  &lt;p&gt;VSCode allows you to run multiple PowerShell Terminal Session but only one “PowerShell Integrated Console”. See Picture.&lt;/p&gt;  &lt;p&gt;&lt;a href=&quot;https://drive.google.com/uc?id=1JpmFvpxDqGgpdeU5wQnOLPQ4Rk6g_ebW&quot;&gt;&lt;img title=&quot;Screenshot 2021-07-08 090059&quot; style=&quot;display: inline; background-image: none;&quot; border=&quot;0&quot; alt=&quot;Screenshot 2021-07-08 090059&quot; src=&quot;https://drive.google.com/uc?id=1L-2AFP60nUVz65EksFGuHSYv86CGLICZ&quot; width=&quot;826&quot; height=&quot;117&quot; /&gt;&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;If you have an active Azure connection in any of the three “pwsh” terminals it will persist across the rest of the three “pwsh” shown in picture. So you can definitely start a different session from the PowerShell Integrated Console, if you really need to work with two different active session. I would not suggest doing this because it could do harm if executing wrong code against wrong subscription.&lt;/p&gt;  &lt;p&gt;Note: Have WSL installed you could start another session.&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;h1&gt;Connecting to Azure via PowerShell&lt;/h1&gt;  &lt;p&gt;If using any of the AZ PowerShell modules you would need to connect using the &lt;strong&gt;Connect-AzAccount&lt;/strong&gt; command. Easiest way is to type “Connect-AzAccount” and it will launch the browser asking to login with your account. At this point you can login with the desired account or select from any cached session. You can certainly use additional parameter to specify the tenant and subscription, for that please visit the official &lt;a href=&quot;https://docs.microsoft.com/en-us/powershell/module/az.accounts/Connect-AzAccount?view=azps-6.2.0&quot; target=&quot;_blank&quot;&gt;MS Doc&lt;/a&gt;&lt;/p&gt; &lt;a href=&quot;https://drive.google.com/uc?id=1VPRkh51NcgxAV4T6RRQ8JQM8DDUINEwV&quot;&gt;&lt;img title=&quot;Screenshot 2021-07-08 092246&quot; style=&quot;display: inline; background-image: none;&quot; border=&quot;0&quot; alt=&quot;Screenshot 2021-07-08 092246&quot; src=&quot;https://drive.google.com/uc?id=15BdclxT6f4QRqyjAt-8bXnzgHKFH6iT4&quot; width=&quot;312&quot; height=&quot;312&quot; /&gt;&lt;/a&gt;   &lt;p&gt;To disconnect simple run “&lt;strong&gt;Disconnect-AzAccount&lt;/strong&gt;”.&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;h2&gt;Connecting using Login-AzAccount&lt;/h2&gt; &lt;a href=&quot;https://drive.google.com/uc?id=1h4YA-ZtbQXbar8T6INV4p_IK_xc6tX1q&quot;&gt;&lt;img title=&quot;Screenshot 2021-07-08 093352&quot; style=&quot;display: inline; background-image: none;&quot; border=&quot;0&quot; alt=&quot;Screenshot 2021-07-08 093352&quot; src=&quot;https://drive.google.com/uc?id=1B5w26MVNMzUkA704T6zfJZjmshfnmWR-&quot; width=&quot;571&quot; height=&quot;174&quot; /&gt;&lt;/a&gt;   &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;Alternatively AZ module also have a &lt;strong&gt;Login-AzAccount&lt;/strong&gt; which also allows you to connect to Azure from PowerShell It will also launch the the web browser but might you to copy and paste the Device Code. Once connection is establish you can run the same PS Commands.&lt;/p&gt;  &lt;p&gt;To disconnect run “Logout-AzAccount”&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;h2&gt;Switching Azure Subscriptions with Set-AzContext&lt;/h2&gt;  &lt;p&gt;To select the Azure Subscription you want to work with:&lt;/p&gt;  &lt;p&gt;Set-AzContext -Subscription &amp;quot;xxxx-xxxx-xxxx-xxxx&amp;quot;&lt;/p&gt;  &lt;p&gt;The “Subscription” paramater can be either the Subscription ID or Subscription Name. Use Get-AzContext to verify session&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;h2&gt;Switching Azure Subscriptions with Select-AzContext&lt;/h2&gt;  &lt;p&gt;Another option is to use Select-AzContext which requires the the context name. &lt;/p&gt;  &lt;p&gt;Example:&lt;/p&gt;  &lt;p&gt;Select-AzContext ‘Test Subscripton (xxxxx-xxxx-xxx-xxx-xxx) – xxxxx-xxx-xxxx-xxxxx – &lt;a href=&quot;mailto:test.user@outlook.com&amp;rsquo;&quot;&gt;test.user@outlook.com’&lt;/a&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;Note: If you have an active session, type Select-AzContext and hit TAB to toggle list the context available.&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;h2&gt;Switching Azure Subscription with Select-AzSubscription&lt;/h2&gt;  &lt;p&gt;Select-AzSubscription is probably becoming obsolete soon but it was still an option in the Az Module&lt;/p&gt;  &lt;p&gt;Example:&lt;/p&gt;  &lt;p&gt;Select-AzSubscription –Subscription “Name or ID”&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;h1&gt;Azure CLI&lt;/h1&gt;  &lt;p&gt;From Azure CLI simple use&amp;#160; “az login” command to establish connection it will use web browser and access token:&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;strong&gt;az login&lt;/strong&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;There are are plenty parameters you can use to sign in with different tenants or service principals. If interested refer to official &lt;a href=&quot;https://docs.microsoft.com/en-us/cli/azure/authenticate-azure-cli&quot; target=&quot;_blank&quot;&gt;MSDOC&lt;/a&gt;&lt;/p&gt;    &lt;blockquote&gt;   &lt;p&gt;&lt;strong&gt;&lt;/strong&gt;&lt;/p&gt; &lt;/blockquote&gt;  To show active sessions:    &lt;blockquote&gt;   &lt;p&gt;&lt;strong&gt;az account show&lt;/strong&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;To Switch Subscription:&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;strong&gt;az account set - -subscription “subscription name or ID”&lt;/strong&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;To logout:&lt;strong&gt; &lt;/strong&gt;&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;strong&gt;az logout&lt;/strong&gt;&lt;/p&gt; &lt;/blockquote&gt;  &lt;p&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;This is it for now. I am sure there are plenty other tips and tricks out there but this should cover the basics of connecting to Azure and switching from one Subscription to another.&lt;/p&gt;</content><link rel='replies' type='application/atom+xml' href='http://fdo-workspace.blogspot.com/feeds/6018148780934417092/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://fdo-workspace.blogspot.com/2021/07/visual-studio-code-working-against.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/6018148780934417092'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/6018148780934417092'/><link rel='alternate' type='text/html' href='http://fdo-workspace.blogspot.com/2021/07/visual-studio-code-working-against.html' title='Visual Studio Code: Working against multiple User Accounts and Azure Subscriptions'/><author><name>fdo</name><uri>http://www.blogger.com/profile/16882300714528613456</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhndsbgzepfJ0U5gXwY3zzRcGOqiMcblr09VzwWLCMA_waqC9FUthSCa8n91RwqW_kZXNo2si5UU3N5Ex6UJbYkcUpcJnxOQw6jPOBYuux7fomIpI0UUf8vOXyBT7hyuuE/s113/IMG_5942.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8658731852844520209.post-4997947612885659482</id><published>2020-03-31T15:27:00.000-04:00</published><updated>2020-03-31T15:27:43.927-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="ESXI"/><category scheme="http://www.blogger.com/atom/ns#" term="nfs"/><category scheme="http://www.blogger.com/atom/ns#" term="sunrpc"/><title type='text'>ESXi Trying to access non-existent NFS .sunrpc</title><content type='html'>Network team reached out to me stating that one of the ESXi host been flooding the switches with invalid error trying to hit a RPC or NFS server. From their end all they can see is:&lt;br /&gt;
&lt;blockquote class=&quot;tr_bq&quot;&gt;
&amp;nbsp;esxi_hostip:922   -&amp;gt;  destination_ip_address:111&amp;nbsp;&lt;/blockquote&gt;
&lt;br /&gt;
So tracked down the host in question and it was a ESXi v6.7 host, accessed the ESXi host in via SSH and used tcpdump to see if that was true:&lt;br /&gt;
&lt;br /&gt;
&lt;blockquote class=&quot;tr_bq&quot;&gt;
&quot;tcpdump-uw | grep destination_ip_address&quot;&lt;/blockquote&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgSuRyFJc4Rqf5NaKUxcAunkCeCZfAHXtGUfrZrmqlgrsOiqSRTPbgug0nxZSeK27rmrcixi5nPvDzP2uQWCd0Fl0_BV2HlaxPIOSyhbkIG6io7yo6awj8f9Bxf2fwhDcNR3jKn9pH8B-f0/s1600/Screen+Shot+2020-03-31+at+3.01.01+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;340&quot; data-original-width=&quot;1600&quot; height=&quot;136&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgSuRyFJc4Rqf5NaKUxcAunkCeCZfAHXtGUfrZrmqlgrsOiqSRTPbgug0nxZSeK27rmrcixi5nPvDzP2uQWCd0Fl0_BV2HlaxPIOSyhbkIG6io7yo6awj8f9Bxf2fwhDcNR3jKn9pH8B-f0/s640/Screen+Shot+2020-03-31+at+3.01.01+PM.png&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;blockquote class=&quot;tr_bq&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div style=&quot;text-align: left;&quot;&gt;
19:01:17.575158 IP vm03cl1vc.840 &amp;gt; 10.159.18.20.sunrpc: Flags [S], seq 3024135077, win 65535, options [mss 1460,nop,wscale 9,sackOK,TS val 3512365326 ecr 0], length 0&lt;/div&gt;
&lt;div style=&quot;text-align: left;&quot;&gt;
19:01:18.575482 IP 10.159.18.20.sunrpc &amp;gt; vm03cl1vc.839: Flags [R.], seq 0, ack 4202901431, win 0, length 0&lt;/div&gt;
&lt;/blockquote&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
As you can see from the screenshot it was trying to connect to &quot;destination_i:sunrpc&quot; and is not receiving a valid response. Further digging into .sunrpc port found it was an NFS mount. However the NFS no longer exist in our environment and there was no trace of that NFS server on the host.&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;h3 style=&quot;clear: both; text-align: left;&quot;&gt;
Searching for the NFS Mount:&lt;/h3&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
Here we are looking for anything that will trace back to the destination ip address in question.&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
Using ESXCLI: you can list all nfs storage available and in my case there was no trace of any NFS Datastore with that ip address.&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
Command:&amp;nbsp;&lt;b&gt;esxcli storage nfs list&amp;nbsp;&lt;/b&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
Using ESXCFG-NAS: Similarly you can also use the esxcfg-nas command to list any network attached storage&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
Command: &lt;b&gt;esxcfg-nas -l&lt;/b&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;b&gt;What Other Options:&lt;/b&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
Now that we confirmed that there is really no traces of the NFS, we can dig a bit deeper into the ESXi system configuration. &lt;b&gt;Warning&lt;/b&gt;: Tampering with esx.conf might severely impair your system. Make sure you are careful making changes.&amp;nbsp;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
In my case searched for any reference to the ip address in question inside the &lt;b&gt;/etc/vmware/esx.conf &lt;/b&gt;file.&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
Ran command to display content of esx.conf file and filter out the ip address in question:&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi7Wav3gQ1NAD0E3g_SlQRI3QiwKp_Ad8nQSj-sumMvc4kamnmNlXkVguMz-PVz_J_ACmEj-Suk7_gSutpFeNPyxCosHIybfz_CF4Yy8m8jvGFVuvIj5_vw9J14hh2qzcGQQXQ5jGjJLdfu/s1600/Screen+Shot+2020-03-31+at+3.17.23+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;304&quot; data-original-width=&quot;944&quot; height=&quot;127&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi7Wav3gQ1NAD0E3g_SlQRI3QiwKp_Ad8nQSj-sumMvc4kamnmNlXkVguMz-PVz_J_ACmEj-Suk7_gSutpFeNPyxCosHIybfz_CF4Yy8m8jvGFVuvIj5_vw9J14hh2qzcGQQXQ5jGjJLdfu/s400/Screen+Shot+2020-03-31+at+3.17.23+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
Now, I was able track down references to the non-existent NFS server and apparently it was due to a previous Rubrik setup in our environment. Now all I need to do is remove those entries. But before backup your esx.conf before making any changes. Once you done restart your esxi management agent.&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;span style=&quot;background-color: white; font-family: &amp;quot;metropolisregular&amp;quot;; font-size: 14px;&quot;&gt;Restart the ESXi host daemon and vCenter Agent services using these commands:&lt;/span&gt;&lt;/div&gt;
&lt;br style=&quot;background-color: white; box-sizing: border-box; font-family: MetropolisRegular; font-size: 14px;&quot; /&gt;
&lt;span style=&quot;background-color: white; box-sizing: border-box; font-family: &amp;quot;courier new&amp;quot;; font-size: 14px;&quot;&gt;/etc/init.d/hostd restart&lt;/span&gt;&lt;br /&gt;
&lt;br style=&quot;background-color: white; box-sizing: border-box; font-family: MetropolisRegular; font-size: 14px;&quot; /&gt;
&lt;span style=&quot;background-color: white; box-sizing: border-box; font-family: &amp;quot;courier new&amp;quot;; font-size: 14px;&quot;&gt;/etc/init.d/vpxa restart&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
And that was the solution for my problem.&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://fdo-workspace.blogspot.com/feeds/4997947612885659482/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://fdo-workspace.blogspot.com/2020/03/esxi-trying-to-access-non-existent-nfs.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/4997947612885659482'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/4997947612885659482'/><link rel='alternate' type='text/html' href='http://fdo-workspace.blogspot.com/2020/03/esxi-trying-to-access-non-existent-nfs.html' title='ESXi Trying to access non-existent NFS .sunrpc'/><author><name>fdo</name><uri>http://www.blogger.com/profile/16882300714528613456</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhndsbgzepfJ0U5gXwY3zzRcGOqiMcblr09VzwWLCMA_waqC9FUthSCa8n91RwqW_kZXNo2si5UU3N5Ex6UJbYkcUpcJnxOQw6jPOBYuux7fomIpI0UUf8vOXyBT7hyuuE/s113/IMG_5942.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgSuRyFJc4Rqf5NaKUxcAunkCeCZfAHXtGUfrZrmqlgrsOiqSRTPbgug0nxZSeK27rmrcixi5nPvDzP2uQWCd0Fl0_BV2HlaxPIOSyhbkIG6io7yo6awj8f9Bxf2fwhDcNR3jKn9pH8B-f0/s72-c/Screen+Shot+2020-03-31+at+3.01.01+PM.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8658731852844520209.post-7675207094448128007</id><published>2019-10-04T16:43:00.001-04:00</published><updated>2019-10-04T16:45:34.032-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Backup"/><category scheme="http://www.blogger.com/atom/ns#" term="FTP"/><category scheme="http://www.blogger.com/atom/ns#" term="powershell"/><category scheme="http://www.blogger.com/atom/ns#" term="VCSA 6.5"/><category scheme="http://www.blogger.com/atom/ns#" term="vcsa6.7"/><category scheme="http://www.blogger.com/atom/ns#" term="Windows"/><title type='text'>VCSA v6.5 File Based Backup  to FTP</title><content type='html'>I wrote on my previous post how easy it was to backup VCSA v6.7 to a FTP server the entire process was straight forward and simple. Link to Post &lt;a href=&quot;https://fdo-workspace.blogspot.com/2019/10/building-windows-2016-ftp-server-and.html&quot; target=&quot;_blank&quot;&gt;Building Windows 2016 FTP Server and Configure VCSA v6.7 File-Based Backup&lt;/a&gt;.&amp;nbsp; For VCSA v6.5 all we had was some API to perform the task, which is still better than not having a backup.&lt;br /&gt;
&lt;div&gt;
&lt;br /&gt;
So as promised I will share how we can backup VCSA v6.5.# using the same concept applied on vCenter 6.7. This is handy if you cannot upgrade your vCenter to v6.7 for whatever motive and need to keep vCenter protected. It will require some PowerShell but will get the job done.&lt;/div&gt;
&lt;h2&gt;
Brief Overview&lt;/h2&gt;
&lt;div&gt;
For vCenter v6.5 the file based backup concept was introduced, API released but not incorporated into the UI. But we can still backup the appliance using the Backup-VCSA module and some extra scripts.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;h3&gt;
How will this work??&lt;/h3&gt;
&lt;div&gt;
The Backup-VCSA Module contains a function Backup-VCSAToFile that will take couple parameters:&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
- LocationType =&amp;nbsp;&lt;span class=&quot;pl-s&quot; style=&quot;background-color: white; box-sizing: border-box; color: #032f62; font-family: , &amp;quot;consolas&amp;quot; , &amp;quot;liberation mono&amp;quot; , &amp;quot;menlo&amp;quot; , monospace; font-size: 12px; white-space: pre;&quot;&gt;&lt;span class=&quot;pl-pds&quot; style=&quot;box-sizing: border-box;&quot;&gt;&#39;&lt;/span&gt;FTPS&lt;span class=&quot;pl-pds&quot; style=&quot;box-sizing: border-box;&quot;&gt;&#39;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;pl-k&quot; style=&quot;background-color: white; box-sizing: border-box; color: #d73a49; font-family: , &amp;quot;consolas&amp;quot; , &amp;quot;liberation mono&amp;quot; , &amp;quot;menlo&amp;quot; , monospace; font-size: 12px; white-space: pre;&quot;&gt;,&lt;/span&gt;&lt;span style=&quot;background-color: white; color: #24292e; font-family: , &amp;quot;consolas&amp;quot; , &amp;quot;liberation mono&amp;quot; , &amp;quot;menlo&amp;quot; , monospace; font-size: 12px; white-space: pre;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;pl-s&quot; style=&quot;background-color: white; box-sizing: border-box; color: #032f62; font-family: , &amp;quot;consolas&amp;quot; , &amp;quot;liberation mono&amp;quot; , &amp;quot;menlo&amp;quot; , monospace; font-size: 12px; white-space: pre;&quot;&gt;&lt;span class=&quot;pl-pds&quot; style=&quot;box-sizing: border-box;&quot;&gt;&#39;&lt;/span&gt;HTTP&lt;span class=&quot;pl-pds&quot; style=&quot;box-sizing: border-box;&quot;&gt;&#39;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;pl-k&quot; style=&quot;background-color: white; box-sizing: border-box; color: #d73a49; font-family: , &amp;quot;consolas&amp;quot; , &amp;quot;liberation mono&amp;quot; , &amp;quot;menlo&amp;quot; , monospace; font-size: 12px; white-space: pre;&quot;&gt;,&lt;/span&gt;&lt;span style=&quot;background-color: white; color: #24292e; font-family: , &amp;quot;consolas&amp;quot; , &amp;quot;liberation mono&amp;quot; , &amp;quot;menlo&amp;quot; , monospace; font-size: 12px; white-space: pre;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;pl-s&quot; style=&quot;background-color: white; box-sizing: border-box; color: #032f62; font-family: , &amp;quot;consolas&amp;quot; , &amp;quot;liberation mono&amp;quot; , &amp;quot;menlo&amp;quot; , monospace; font-size: 12px; white-space: pre;&quot;&gt;&lt;span class=&quot;pl-pds&quot; style=&quot;box-sizing: border-box;&quot;&gt;&#39;&lt;/span&gt;SCP&lt;span class=&quot;pl-pds&quot; style=&quot;box-sizing: border-box;&quot;&gt;&#39;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;pl-k&quot; style=&quot;background-color: white; box-sizing: border-box; color: #d73a49; font-family: , &amp;quot;consolas&amp;quot; , &amp;quot;liberation mono&amp;quot; , &amp;quot;menlo&amp;quot; , monospace; font-size: 12px; white-space: pre;&quot;&gt;,&lt;/span&gt;&lt;span style=&quot;background-color: white; color: #24292e; font-family: , &amp;quot;consolas&amp;quot; , &amp;quot;liberation mono&amp;quot; , &amp;quot;menlo&amp;quot; , monospace; font-size: 12px; white-space: pre;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;pl-s&quot; style=&quot;background-color: white; box-sizing: border-box; color: #032f62; font-family: , &amp;quot;consolas&amp;quot; , &amp;quot;liberation mono&amp;quot; , &amp;quot;menlo&amp;quot; , monospace; font-size: 12px; white-space: pre;&quot;&gt;&lt;span class=&quot;pl-pds&quot; style=&quot;box-sizing: border-box;&quot;&gt;&#39;&lt;/span&gt;HTTPS&lt;span class=&quot;pl-pds&quot; style=&quot;box-sizing: border-box;&quot;&gt;&#39;&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;pl-k&quot; style=&quot;background-color: white; box-sizing: border-box; color: #d73a49; font-family: , &amp;quot;consolas&amp;quot; , &amp;quot;liberation mono&amp;quot; , &amp;quot;menlo&amp;quot; , monospace; font-size: 12px; white-space: pre;&quot;&gt;,&lt;/span&gt;&lt;span style=&quot;background-color: white; color: #24292e; font-family: , &amp;quot;consolas&amp;quot; , &amp;quot;liberation mono&amp;quot; , &amp;quot;menlo&amp;quot; , monospace; font-size: 12px; white-space: pre;&quot;&gt; &lt;/span&gt;&lt;span class=&quot;pl-s&quot; style=&quot;background-color: white; box-sizing: border-box; color: #032f62; font-family: , &amp;quot;consolas&amp;quot; , &amp;quot;liberation mono&amp;quot; , &amp;quot;menlo&amp;quot; , monospace; font-size: 12px; white-space: pre;&quot;&gt;&lt;span class=&quot;pl-pds&quot; style=&quot;box-sizing: border-box;&quot;&gt;&#39;&lt;/span&gt;FTP&lt;span class=&quot;pl-pds&quot; style=&quot;box-sizing: border-box;&quot;&gt;&#39;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
- Location = &quot;10.1.1.200/vcsa_backup_folder/&quot;&lt;/div&gt;
&lt;div&gt;
- LocationUser&amp;nbsp; = &#39;&#39;ftp_service_account&#39;&lt;/div&gt;
&lt;div&gt;
- LocationPassword = &quot;ftp_service_account_pwd&quot;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;b&gt;Sample Syntax:&lt;/b&gt;&lt;/div&gt;
&lt;div&gt;
&lt;blockquote class=&quot;tr_bq&quot;&gt;
&lt;span class=&quot;pl-c&quot; style=&quot;background-color: white; box-sizing: border-box; font-family: , &amp;quot;consolas&amp;quot; , &amp;quot;liberation mono&amp;quot; , &amp;quot;menlo&amp;quot; , monospace; font-size: 12px; white-space: pre;&quot;&gt;Backup-VCSAToFile -BackupPassword $BackupPassword  -LocationType $LocationType &lt;/span&gt;&lt;span class=&quot;pl-c&quot; style=&quot;background-color: white; box-sizing: border-box; font-family: , &amp;quot;consolas&amp;quot; , &amp;quot;liberation mono&amp;quot; , &amp;quot;menlo&amp;quot; , monospace; font-size: 12px; white-space: pre;&quot;&gt;-Location $location -LocationUser $LocationUser &lt;/span&gt;&lt;span class=&quot;pl-c&quot; style=&quot;background-color: white; box-sizing: border-box; font-family: , &amp;quot;consolas&amp;quot; , &amp;quot;liberation mono&amp;quot; , &amp;quot;menlo&amp;quot; , monospace; font-size: 12px; white-space: pre;&quot;&gt;-LocationPassword $locationPassword &lt;/span&gt;&lt;span class=&quot;pl-c&quot; style=&quot;background-color: white; box-sizing: border-box; font-family: , &amp;quot;consolas&amp;quot; , &amp;quot;liberation mono&amp;quot; , &amp;quot;menlo&amp;quot; , monospace; font-size: 12px; white-space: pre;&quot;&gt;-Comment &quot;This is a demo&quot; -ShowProgress -FullBackup&lt;/span&gt;&lt;/blockquote&gt;
&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
For full detail refer to the link to source code:&amp;nbsp;&lt;a href=&quot;https://github.com/vmware/PowerCLI-Example-Scripts/tree/master/Modules/Backup-VCSA&quot; target=&quot;_blank&quot;&gt;VMware Github&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;
&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
Next we will be using Windows Task Manager to schedule the job and optionally we can create another script to clean up files older than x amount of days.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;b&gt;Note:&lt;/b&gt; This document will only cover how backup to a ftp server.&lt;br /&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;h2&gt;
Requirement:&lt;/h2&gt;
&lt;div&gt;
- FTP Server / FTP server Account (if you do not have one visit my previous post to build one)&lt;/div&gt;
&lt;div&gt;
- vCenter Server Appliance v6.5.# ready for backup&lt;/div&gt;
&lt;div&gt;
- PowerShell Knowledge&lt;/div&gt;
&lt;div&gt;
- Understanding of Windows Task Scheduler works&lt;/div&gt;
&lt;div&gt;
- Backup-VCSA.psm1 module found at &lt;a href=&quot;https://github.com/vmware/PowerCLI-Example-Scripts/tree/master/Modules/Backup-VCSA&quot; target=&quot;_blank&quot;&gt;VMware Github&lt;/a&gt;&amp;nbsp;wrote by Brian Graf&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;h2&gt;
Building The Backup Script&lt;/h2&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
For this exercise, I will be the Windows 2016 FTP server to store the scripts and run the backup jobs. The script was tested on Windows 2016 - PowerCLI 11.#&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;h3&gt;
Familiarizing yourself with the backup script&lt;/h3&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
Testing the backup script. This script is straight out of the documentation found in the Backup-VCSA module.&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush: ps&quot;&gt;    
[VMware.VimAutomation.Cis.Core.Types.V1.Secret]$BackupPassword = “Passw0rd!”
 
$Comment = “First API Backup”
$LocationType = “FTP”
$location = “10.159.81.171/VC24_21/vcsabackup-$((Get-Date).ToString(‘yyyy-MM-dd-hh-mm’))”
$LocationUser = “ftp_svc1”
[VMware.VimAutomation.Cis.Core.Types.V1.Secret]$locationPassword = “Passw0rd!”


    
$secpasswd = ConvertTo-SecureString &quot;VMware1!&quot; -AsPlainText -Force
$creds = New-Object System.Management.Automation.PSCredential (&quot;administrator@vsphere.local&quot;, $secpasswd)

$vcsa = &quot;10.159.81.206&quot;
$vi = Connect-CisServer $vcsa -Credential $creds


Backup-VCSAToFile -BackupPassword $BackupPassword  -LocationType $LocationType -Location $location -LocationUser $LocationUser -LocationPassword $locationPassword -Comment “This is a demo” -ShowProgress -FullBackup

&lt;/pre&gt;
&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;blockquote class=&quot;tr_bq&quot; style=&quot;background: none rgb(255, 255, 255); border-radius: 0px; border: 0px; bottom: auto; box-sizing: content-box; color: #333333; float: none; font-family: Consolas, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, Courier, monospace; font-size: 14px; height: auto; left: auto; line-height: 20px; margin: 0px; min-height: inherit; outline: 0px; overflow: visible; padding: 0px 1em 0px 0em; position: static; right: auto; top: auto; vertical-align: baseline; white-space: nowrap; width: auto;&quot;&gt;
&lt;code class=&quot;powershell plain&quot; style=&quot;background: none; border-radius: 0px; border: 0px; bottom: auto; box-sizing: content-box; color: rgb(0, 0, 0) !important; float: none; font-family: Consolas, &amp;quot;Bitstream Vera Sans Mono&amp;quot;, &amp;quot;Courier New&amp;quot;, Courier, monospace; height: auto; left: auto; line-height: 20px; margin: 0px; min-height: inherit; outline: 0px; overflow: visible; padding: 0px; position: static; right: auto; top: auto; vertical-align: baseline; width: auto;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;/code&gt;&lt;/blockquote&gt;
&lt;/div&gt;
&lt;div&gt;
If the script was executed properly you should see the job running:&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh3FBkGqD3bYcGPGTZRMpVGUZ27FRcomZyvSrBKETiTmhYroJ8usxLAVKP1LOCC1tba_aIHXjaB1-ahKL5SmHy9YIGfi8AirpS2sSoF2be53j2j9CaZpVrT4h0oTAv_D31_nIimyppyFEOa/s1600/Screen+Shot+2019-10-04+at+3.04.26+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;222&quot; data-original-width=&quot;498&quot; height=&quot;142&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh3FBkGqD3bYcGPGTZRMpVGUZ27FRcomZyvSrBKETiTmhYroJ8usxLAVKP1LOCC1tba_aIHXjaB1-ahKL5SmHy9YIGfi8AirpS2sSoF2be53j2j9CaZpVrT4h0oTAv_D31_nIimyppyFEOa/s320/Screen+Shot+2019-10-04+at+3.04.26+PM.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
And the files should show in the FTP directory specified.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiKmq4Np5nN5wOth8O-C6yRCaSNoGyY3c7vNIFf5rhV-MJPl9oG7dN7JRyx-h_PQ1Qd2LMUCBBqPumHwSn-A31BkClrEGVokPjh0Gq3JrLxXAOE87skq_zrE26bZuxXD5UtONFZFwL8996m/s1600/Screen+Shot+2019-10-04+at+3.05.55+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;234&quot; data-original-width=&quot;488&quot; height=&quot;153&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiKmq4Np5nN5wOth8O-C6yRCaSNoGyY3c7vNIFf5rhV-MJPl9oG7dN7JRyx-h_PQ1Qd2LMUCBBqPumHwSn-A31BkClrEGVokPjh0Gq3JrLxXAOE87skq_zrE26bZuxXD5UtONFZFwL8996m/s320/Screen+Shot+2019-10-04+at+3.05.55+PM.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;
&lt;h3&gt;
PowerShell Script to Kick Start Backup Job&lt;/h3&gt;
&lt;/div&gt;
&lt;div&gt;
Here is a small script I wrote called Run-Backup.ps1 which takes as parameter a configuration file. The configuration file is nothing more than a json file with vCenter information, vCenter Creds, and the FTP parameters required to run the job.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
This is what the Run-Backup.ps1 loos like.&lt;br /&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush: ps&quot;&gt;&amp;lt;# 
    Run-Backup.ps1
    Script to Backup-VCSA 
#&amp;gt;
param (
        [String]$Config,
        [Switch]$Verbose
)

Get-Module -ListAvailable VMware.PowerCLI | Import-Module

$BackupModule = &quot;$CurrDir\Backup-VCSA.psm1&quot;

if (Test-Path $BackupModule){
    Write-Verbose &quot;Backup Module Found&quot;
    Import-Module $BackupModule
}
else{
    Write-Verbose &quot;Backup Module not found&quot;
    Write-Verbose &quot;Exit&quot;
    return 
}

if ($Config){
    Write-Verbose &quot;Loading Config File&quot;
    if (Test-Path $Config){
        $json = Get-Content -Raw $Config | ConvertFrom-Json
    }else{
        Write-Verbose &quot;Failed to Load Config&quot;
    }
}else{
    Write-Verbose &quot;Missing Config File&quot;
    Write-Verbose &quot;Syntax:: RunBackup -Config [config.json]&quot;
    return
}

Write-Verbose &quot;Loading Variables&quot;
$VCSA = $json.VC_IP
$VCName = $json.VC_Name
$VCUser = $json.VC_User
$VCPwd = $json.VC_Password | ConvertTo-SecureString 


$BackupPassword = $VCName
$LocationType = $json.LocationType
$location = &quot;$($json.Location)/$($json.VC_Name)/vcsabackup-$((Get-Date).ToString(‘yyyy-MM-dd-hh-mm’))&quot;
$LocationUser = $json.LocationUser
[VMware.VimAutomation.Cis.Core.Types.V1.Secret]$locationPassword = ([Runtime.InteropServices.Marshal]::PtrToStringAuto([Runtime.InteropServices.Marshal]::SecureStringToBSTR($($json.LocationPassword | ConvertTo-SecureString))))

$comment = &quot;Backup $VCName to $location&quot;

$creds = New-Object System.Management.Automation.PSCredential ($VCUser, $VCPwd)

$ci = Connect-CisServer -Server $VCSA -Credential $creds -Force

Backup-VCSAToFile -LocationType $LocationType -Location $location -LocationUser $LocationUser -LocationPassword $locationPassword -Comment $comment -ShowProgress -FullBackup

Disconnect-CisServer $ci -Force -Confirm:$false&lt;/pre&gt;
&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;
&lt;br /&gt;
As you might have noticed:&lt;br /&gt;
- The vCenter and FTP account password inside the JSON is a SecureString which is why needs to be decrypted before running.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
- I am also adding a password to the backup job to protect the files, you will need this password in order to restore vCenter from these backups. To keep things simple I am using the vCenter name as the backup job password.&lt;br /&gt;
&lt;br /&gt;
This is what the vcenter_config.json looks like:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush: ps&quot;&gt;{
    &quot;VC_IP&quot;:  &quot;10.10.10.207&quot;,
    &quot;VC_Name&quot;:  &quot;vc6_makisan&quot;,
    &quot;VC_User&quot;:  &quot;administrator@vsphere.local&quot;,
    &quot;VC_Password&quot;:  &quot;01000000d08c9ddf0115d1118c7a00c04fc297eb010000002760ab6290f6c749a1d36eb49f730646000000000200000000001066000000010000200000008ab43c2902ee38f81f8477bdf8513754389f1ebc002a3acb8c21e25af58e2d980da6986c70b34000000051bc2e08c3e380c7fd930a9a3917a38b3665f923d0cb763e311ab13df58d88fb17d9da553bd44c1d4391c6b5a1b6d8d87407469958d7acb725b6cdeff481435e&quot;,
    &quot;LocationType&quot;:  &quot;FTP&quot;,
    &quot;Location&quot;:  &quot;10.10.10.171&quot;,
    &quot;LocationUser&quot;:  &quot;ftp_svc1&quot;,
    &quot;LocationPassword&quot;:  &quot;01000000d08c9ddf0115d1118c7a00c04fc297eb010000002760ab6290f6c749a1d36eb49f73064600000000020000000000106600000001000020000000a34e546a76bcc678602303d20a9390cead042371a55acdf68216ad84faad953be2535c9955cda40000000a797810e57b51bad622f50c5bafab281dba3fc62a885c45df1616f889a1bce2b3aa31cdd241ca83c4937792620cc401f0a48eb20b88485d01bdb4653b14158ed&quot;
}

&lt;/pre&gt;
&lt;br /&gt;
To generate your password simply use ConvertTo-SecureString function:&lt;br /&gt;
&lt;blockquote class=&quot;tr_bq&quot;&gt;
&lt;i&gt;&quot;Your Password&quot;| ConvertTo-SecureString -AsPlainText -Force | ConvertFrom-SecureString&lt;/i&gt;&lt;/blockquote&gt;
to make things easier to copy you can try export to file&lt;br /&gt;
&lt;blockquote class=&quot;tr_bq&quot;&gt;
&lt;i&gt;&quot;Your Password&quot; | ConvertTo-SecureString -AsPlainText -Force | ConvertFrom-SecureString &amp;gt; pwfile.txt&lt;/i&gt;&lt;/blockquote&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiSCDbQWQeAJRsdRXjY0m41oJmX4T0iWSMNGLMtNJdnbw1j0y4fELIwxTw0ADH1tr9x1v5r8OQoZpypUOdIZkkqGCMAeXlCM1ervu5z3ofdLBaySBALpYvh9CGua4x65nSuoOO08kKhYeZK/s1600/Screen+Shot+2019-10-04+at+3.36.56+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;136&quot; data-original-width=&quot;842&quot; height=&quot;63&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiSCDbQWQeAJRsdRXjY0m41oJmX4T0iWSMNGLMtNJdnbw1j0y4fELIwxTw0ADH1tr9x1v5r8OQoZpypUOdIZkkqGCMAeXlCM1ervu5z3ofdLBaySBALpYvh9CGua4x65nSuoOO08kKhYeZK/s400/Screen+Shot+2019-10-04+at+3.36.56+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;h3&gt;
Testing new Run-Backup Job&lt;/h3&gt;
&lt;br /&gt;
If your JSON file was configured properly script should simply executing:&lt;br /&gt;
&lt;br /&gt;
.\Run_Backup.ps1 -Config .\config_file.json&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgvvSEyBsusgb8A96PycuaK-kck3Tr1UT4PUOffm5u2Mh0qSr4qR-_xTctCOso2hyphenhypheni8_3T-DoRjJKBll1XxdLx69r_uQHE_XhfpkI6ZFttbDBvOtpfQM7L4brsB1FQ4MEwTvrAyDz3sMCxF/s1600/Screen+Shot+2019-10-04+at+3.43.44+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;606&quot; data-original-width=&quot;1214&quot; height=&quot;198&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgvvSEyBsusgb8A96PycuaK-kck3Tr1UT4PUOffm5u2Mh0qSr4qR-_xTctCOso2hyphenhypheni8_3T-DoRjJKBll1XxdLx69r_uQHE_XhfpkI6ZFttbDBvOtpfQM7L4brsB1FQ4MEwTvrAyDz3sMCxF/s400/Screen+Shot+2019-10-04+at+3.43.44+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
Now that the script works there is one more script we need before creating the Task Job&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;
Creating calljob.bat for Task Scheduler&lt;/h2&gt;
&lt;br /&gt;
I found that Task Scheduler was not running the PS1 script properly for some reason so decided to just create a batch file to trigger the PowerShell script. If you manage to get around feel free to share how you were able to accomplish. In the mean time here is the batch script I used.&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush: ps&quot;&gt;echo off
echo ****************************************************
echo Running batch file to call Run_Backup.ps1 script.
echo Syntax = calljob. [config.json]
echo ****************************************************



if exist %~dp0calljob.bat ( ^
goto :CAllJob) ^
else (goto :NotFound)

:NotFound
echo File not found
goto :EOF

:CallJob
echo Found Script
echo Call script 
REM powershell.exe -command &quot;&amp;amp; &#39;.\VMCLoneJob.ps1&#39; %1&quot;
powershell.exe -command &quot;&amp;amp; &#39;.\Run_Backup.ps1&#39; %1 -Verbose&quot;
&lt;/pre&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;
Creating Windows Task to Initiate Backup&lt;/h2&gt;
&lt;div&gt;
Launch a Task Scheduler : Administrative Tools | Task Scheduler&lt;/div&gt;
&lt;div&gt;
1 - Create a folder to keep all backup task together: This is optional&lt;/div&gt;
&lt;div&gt;
2 - Create a Task | Enter name of your task&lt;/div&gt;
&lt;div&gt;
&amp;nbsp; - - Select - Run whether user is logged on or no - otherwise script willl not run&lt;/div&gt;
&lt;div&gt;
&amp;nbsp; - - Check - Run with highest priviledge&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi_rxnxHN5gmFHBxC7ywGqufhhROibSeCWAbJrT9qmaSoReKP32M2yTx7YwZen7X3PqnW5rs5WCapBr6Ueza1XsFSpqsQ2Dwxx6wtiJ6NqT9KqrfdQhTzAKQZ8UOweWjMBVX0YfoDc48dLD/s1600/Screen+Shot+2019-10-04+at+3.53.56+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;518&quot; data-original-width=&quot;807&quot; height=&quot;256&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi_rxnxHN5gmFHBxC7ywGqufhhROibSeCWAbJrT9qmaSoReKP32M2yTx7YwZen7X3PqnW5rs5WCapBr6Ueza1XsFSpqsQ2Dwxx6wtiJ6NqT9KqrfdQhTzAKQZ8UOweWjMBVX0YfoDc48dLD/s400/Screen+Shot+2019-10-04+at+3.53.56+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
3 - Task Trigger - This till trigger task to run on a schedule defined&lt;/div&gt;
&lt;div&gt;
&amp;nbsp; &amp;nbsp;-&amp;nbsp; - I am running this daily&lt;/div&gt;
&lt;div&gt;
&amp;nbsp; &amp;nbsp;-&amp;nbsp; - You can modify this to run more than once a day. For example you can run this job every 4 hours by checking &quot;Repeat task every: 4hr for duration of 1day&quot;&lt;/div&gt;
&lt;div&gt;
&amp;nbsp; &amp;nbsp;-&amp;nbsp; - Check Enabled&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj7GW5j2nlWwWrSbrCPuBAG1vyPpoACpjYCDdheHhKwDDVFyexGUFGjUpS-wyqDJclkdjm83PBlTg0nenpsFtXvVzz4jupMEfv51xxH8L4tuZP5k7WgM2EwsMxUx4aznlq814RTAmsew2s-/s1600/Screen+Shot+2019-10-04+at+3.55.40+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;633&quot; data-original-width=&quot;865&quot; height=&quot;292&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj7GW5j2nlWwWrSbrCPuBAG1vyPpoACpjYCDdheHhKwDDVFyexGUFGjUpS-wyqDJclkdjm83PBlTg0nenpsFtXvVzz4jupMEfv51xxH8L4tuZP5k7WgM2EwsMxUx4aznlq814RTAmsew2s-/s400/Screen+Shot+2019-10-04+at+3.55.40+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
4 - Action - Is the script that will be triggered&amp;nbsp;&lt;/div&gt;
&lt;div&gt;
&amp;nbsp; &amp;nbsp;- - Action will be Start a program&lt;/div&gt;
&lt;div&gt;
&amp;nbsp; &amp;nbsp;- - Program/script:&amp;nbsp; &amp;nbsp;path to the bat file in my case E:\script\calljob.bat&lt;/div&gt;
&lt;div&gt;
&amp;nbsp; &amp;nbsp;- - Add Arguments:&amp;nbsp; &amp;nbsp; &amp;nbsp; e:\scripts\vcenter_config.json&amp;nbsp;&lt;/div&gt;
&lt;div&gt;
&amp;nbsp; &amp;nbsp;- - Start in:&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; e:\scripts&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjeTk9MKFNkLok30qc3ejTJzUzdET0HyXACsF0caYlc3N-PLS4WnY-vfZHXmhgM5YVKLW0c5Pl6ttAP4FPBia7gV4zeSym4vzP5U9YfP9uskvVaOxDpz7lcumZOeQITAvudZzpTuwq1Wu6A/s1600/Screen+Shot+2019-10-04+at+4.01.50+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;556&quot; data-original-width=&quot;671&quot; height=&quot;331&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjeTk9MKFNkLok30qc3ejTJzUzdET0HyXACsF0caYlc3N-PLS4WnY-vfZHXmhgM5YVKLW0c5Pl6ttAP4FPBia7gV4zeSym4vzP5U9YfP9uskvVaOxDpz7lcumZOeQITAvudZzpTuwq1Wu6A/s400/Screen+Shot+2019-10-04+at+4.01.50+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
5 - Conditions:&lt;br /&gt;
&amp;nbsp;- - I think I left this default&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjr89Pk18uA8KKUvz2BuYY4OfUj8wOdNHtTyKSIKrnRqRQNU_2hySEd7oTtpaWlVrqgRUuGECJ8QVDHSNEnk5p4WBCULjSpRY1aP25g2h_rDn5tLH4fR-GwqzCiSe1YrCHcU6cHISiByFdm/s1600/Screen+Shot+2019-10-04+at+4.02.44+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;481&quot; data-original-width=&quot;633&quot; height=&quot;303&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjr89Pk18uA8KKUvz2BuYY4OfUj8wOdNHtTyKSIKrnRqRQNU_2hySEd7oTtpaWlVrqgRUuGECJ8QVDHSNEnk5p4WBCULjSpRY1aP25g2h_rDn5tLH4fR-GwqzCiSe1YrCHcU6cHISiByFdm/s400/Screen+Shot+2019-10-04+at+4.02.44+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
6 - Settings:&lt;br /&gt;
&amp;nbsp;- - Check - Allow task to be run on demand. This will allow you to test run the job when necessary.&lt;br /&gt;
&amp;nbsp;- - Optionial: I set to stop task if runs longer than 2hrs. Might have to change this depending on the size of your vCenter and network latency between VC and FTP server.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiyeJHAlc824jxfqO6IdZC6wHO_efUfUwS2Cs4sASOLv1U9_1C1JQ1y0z7tAO249rGl4OJkQlbVIwTBo6M1gTtj6B_wHMzZXk1tHbcSHhf3zN_949YXpd8OE393XnQRXsBHExLuGrQLvfGS/s1600/Screen+Shot+2019-10-04+at+4.02.49+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;480&quot; data-original-width=&quot;631&quot; height=&quot;302&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiyeJHAlc824jxfqO6IdZC6wHO_efUfUwS2Cs4sASOLv1U9_1C1JQ1y0z7tAO249rGl4OJkQlbVIwTBo6M1gTtj6B_wHMzZXk1tHbcSHhf3zN_949YXpd8OE393XnQRXsBHExLuGrQLvfGS/s400/Screen+Shot+2019-10-04+at+4.02.49+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
7. Finally save the change and enter your administrator password. If you are having problem with the password go back to the General page and select the correct user or group that will own this job.&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
8. Finally kick start the job by selecting the job and RUN... If everything was configured properly task should run...&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg8Ke0CPWR-brOMMRN0YFlZjBneui2pQCR2vDsjQnqNs-s0xKPK0CdoldxRN9IWK5rKRA3_VnN2I4oCdnhDvpreutj0jA83AF0VjlfkEFUhJg1G8lK7KnLN5h5Y1qzbXcdJk58Ml7bECibi/s1600/Screen+Shot+2019-10-04+at+4.13.03+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;837&quot; data-original-width=&quot;1600&quot; height=&quot;167&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg8Ke0CPWR-brOMMRN0YFlZjBneui2pQCR2vDsjQnqNs-s0xKPK0CdoldxRN9IWK5rKRA3_VnN2I4oCdnhDvpreutj0jA83AF0VjlfkEFUhJg1G8lK7KnLN5h5Y1qzbXcdJk58Ml7bECibi/s320/Screen+Shot+2019-10-04+at+4.13.03+PM.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
And that&#39;s it.. This is a fully automated backup solution for vCenter Appliance v6.5.#. This should keep your vCenter backed up until it is upgraded to v6.7..&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;h2 style=&quot;clear: both; text-align: left;&quot;&gt;
Bonus Script - Deleting old Backups&lt;/h2&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
Here is a script to delete jobs older than 30 days to reclaim some space. I am sure there are much better code but this is what I got:&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
Assuming E:\ftp\vcsa65 is the location directory all your backup jobs is pointing to.&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
Each vCenter_Backup job will have its own folder with the scheduled backup inside. Folder structure should look like:&lt;/div&gt;
&lt;blockquote class=&quot;tr_bq&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;i&gt;E:\ftp\vcsa65\[vcenter_name]\[backup_job_date]&lt;/i&gt;&amp;nbsp;&lt;/blockquote&gt;
&lt;blockquote class=&quot;tr_bq&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;i&gt;E:\ftp\vcsa65\vcenter_1\vcsabackup-date1&lt;br /&gt;E:\ftp\vcsa65\vcenter_1\vcsabackup-date2&lt;br /&gt;E:\ftp\vcsa65\vcenter_1\vcsabackup-date3&lt;br /&gt;E:\ftp\vcsa65\vcenter_2\vcsabackup-date1&lt;br /&gt;E:\ftp\vcsa65\vcenter_2\vcsabackup-date2&lt;br /&gt;E:\ftp\vcsa65\vcenter_2\vcsabackup-date3&lt;br /&gt;. . .&lt;/i&gt;&lt;/blockquote&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
Script should delete [vcsabackup_data] jobs older than 30days by checking creation date. Make sure to test this properly and modify as see fit.&amp;nbsp;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;pre style=&quot;background: rgb(245, 245, 245); border-radius: 3px; border: 1px solid rgb(231, 231, 231); clear: none; line-height: 21px; margin-bottom: 10.5px; overflow: hidden; padding: 10px; word-break: break-word;&quot;&gt;&lt;span class=&quot;p&quot; style=&quot;clear: none; overflow: hidden; white-space: pre-wrap;&quot;&gt;&lt;span style=&quot;color: #4a4a4a; font-family: &amp;quot;menlo&amp;quot; , &amp;quot;monaco&amp;quot; , &amp;quot;courier new&amp;quot; , monospace;&quot;&gt;# Root Directory were all my vCenters are backed up
# structure E:\ftp\vcsa65\[vcenter_name]\backupjob_dates
$backup_path = &quot;E:\ftp\vcsa65&quot;

$vcenters = Get-ChildItem $backup_path

foreach ($vc in $vcenters){

    $backup_list = Get-ChildItem $vc.FullName
    #$backup_list | ? {$_.CreationTime -le (Get-Date).AddDays(-30) }
    foreach ($bk in  $backup_list){
        if ( $bk.CreationTime -le (Get-Date).AddDays(-30)){
            Write-Host &quot;$($bk.FullName) - Over 30 Days Delete&quot;
            Remote-Item $bk -Force -Confirm:$false
        }else{
            Write-Host &quot;$($bk.FullName) - Not Over 30 Days, Skip&quot;
        }

        
    }
}&lt;/span&gt;&lt;/span&gt;&lt;/pre&gt;
&lt;script type=&quot;text/javascript&quot;&gt;
SyntaxHighlighter.highlight();
&lt;/script&gt;
&lt;br /&gt;
&lt;h2&gt;
Final Words:&lt;/h2&gt;
Please make sure you test everything in a DEV environment before actually utilizing this in production. Everything found online must be fully tested.&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://fdo-workspace.blogspot.com/feeds/7675207094448128007/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://fdo-workspace.blogspot.com/2019/10/vcsa-v65-file-based-backup-to-ftp.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/7675207094448128007'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/7675207094448128007'/><link rel='alternate' type='text/html' href='http://fdo-workspace.blogspot.com/2019/10/vcsa-v65-file-based-backup-to-ftp.html' title='VCSA v6.5 File Based Backup  to FTP'/><author><name>fdo</name><uri>http://www.blogger.com/profile/16882300714528613456</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhndsbgzepfJ0U5gXwY3zzRcGOqiMcblr09VzwWLCMA_waqC9FUthSCa8n91RwqW_kZXNo2si5UU3N5Ex6UJbYkcUpcJnxOQw6jPOBYuux7fomIpI0UUf8vOXyBT7hyuuE/s113/IMG_5942.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh3FBkGqD3bYcGPGTZRMpVGUZ27FRcomZyvSrBKETiTmhYroJ8usxLAVKP1LOCC1tba_aIHXjaB1-ahKL5SmHy9YIGfi8AirpS2sSoF2be53j2j9CaZpVrT4h0oTAv_D31_nIimyppyFEOa/s72-c/Screen+Shot+2019-10-04+at+3.04.26+PM.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8658731852844520209.post-4284137353006885109</id><published>2019-10-01T18:23:00.001-04:00</published><updated>2019-10-01T18:23:18.056-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Backup"/><category scheme="http://www.blogger.com/atom/ns#" term="FTP"/><category scheme="http://www.blogger.com/atom/ns#" term="v6.7"/><category scheme="http://www.blogger.com/atom/ns#" term="VCSA"/><title type='text'>Building Windows 2016 FTP Server and configure VCSA v6.7 File-Based Backup </title><content type='html'>As the title says today we will be building a very simple Windows 2016 FTP server to backup vCenters Server Appliance. We will be using the File-Based backup feature that was built into vCenter 6.7.#. I was excited about this news but didn&#39;t have the chance to actually try it until now.&lt;br /&gt;
&lt;br /&gt;
Back on vCenter v6.5 when file based backup was introduced, the only way to initiate the backups was via API.&amp;nbsp;Now is part of the VAMI UI in v6.7.x&amp;nbsp;&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgvHX_LfJcgWja_FFFhkPRLWhKuU6uK9YjAWlcGQKj7fs5bD8un4RPXlQo-vjIqJvuz-K3By3c5RVwQc7m8CYCuyyrRHAqHAjM7mP2HPPmmeSVE1a4SSBytaxzRMgtQbaJzcdl4XyVCF19m/s1600/10_148_71_166_-_fdrdp01_eng.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;597&quot; data-original-width=&quot;1000&quot; height=&quot;238&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgvHX_LfJcgWja_FFFhkPRLWhKuU6uK9YjAWlcGQKj7fs5bD8un4RPXlQo-vjIqJvuz-K3By3c5RVwQc7m8CYCuyyrRHAqHAjM7mP2HPPmmeSVE1a4SSBytaxzRMgtQbaJzcdl4XyVCF19m/s400/10_148_71_166_-_fdrdp01_eng.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
BTW, depending on the version the following backup target are supported&lt;br /&gt;
&lt;br /&gt;
vCenter v6.5.x -&amp;nbsp;&lt;span style=&quot;background-color: #fafafa; color: #212529; font-family: Metropolis, &amp;quot;Avenir Next&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Arial, sans-serif; font-size: 14px;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;span style=&quot;background-color: #fafafa; color: #212529; font-family: Metropolis, &amp;quot;Avenir Next&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Arial, sans-serif; font-size: 14px;&quot;&gt;FTP, FTPS, HTTP, HTTPS, or SCP&lt;/span&gt;&lt;br /&gt;
vCenter v6.7,x -&amp;nbsp;&lt;span style=&quot;background-color: #fafafa; color: #212529; font-family: Metropolis, &amp;quot;Avenir Next&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Arial, sans-serif; font-size: 14px;&quot;&gt;FTP, FTPS, HTTP, HTTPS, NFS, SCP or SMB&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: #fafafa; color: #212529; font-family: Metropolis, &amp;quot;Avenir Next&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Arial, sans-serif; font-size: 14px;&quot;&gt;&lt;br /&gt;&lt;/span&gt;
&lt;br /&gt;
&lt;b&gt;Requirement:&lt;/b&gt;&lt;br /&gt;
- Basic Windows 2016 skills&lt;br /&gt;
- Windows 2016 Server Deployed and configured - VCSA should be able to reach this server.&lt;br /&gt;
- VCSA v6.7.x waiting for backups.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;h3&gt;
Installing FTP Server Role&lt;/h3&gt;
From the Windows Server:&lt;br /&gt;
- Launch Server Manager&lt;br /&gt;
- Click - Add Role and Features&lt;br /&gt;
- Select Web Server (IIS)&lt;br /&gt;
- Role Features&lt;br /&gt;
- Select FTP Server&lt;br /&gt;
- Check FTP Services and FTP Extensibility&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjwG_31TZWLfcH0_zD7juSzA-hafgMGZvSbVg8q5FDaCI1gXMB6F9AUvvL7k1A0XSSJP89JzrSfn2fHSdPVa_-D81lKHCHDOFUZtH8YfRYxfi5Iqdr55jiRmNbXCV3NEEihPfDZnNWP6QZ-/s1600/Screen+Shot+2019-10-01+at+5.50.26+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;404&quot; data-original-width=&quot;569&quot; height=&quot;283&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjwG_31TZWLfcH0_zD7juSzA-hafgMGZvSbVg8q5FDaCI1gXMB6F9AUvvL7k1A0XSSJP89JzrSfn2fHSdPVa_-D81lKHCHDOFUZtH8YfRYxfi5Iqdr55jiRmNbXCV3NEEihPfDZnNWP6QZ-/s400/Screen+Shot+2019-10-01+at+5.50.26+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
- Click Next to review confirmation and Finish to Install&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;h3 style=&quot;clear: both; text-align: left;&quot;&gt;
Create the FTP Service Account&lt;/h3&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
From Server Manager |&amp;nbsp; Tools | Computer Management&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
- Local User and Groups&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
- Right Click on Users and create your user&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
- For example:&lt;b&gt; ftp_svc&lt;/b&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiFR3k1yHZj6q74momhtL7ZQxTQPinWBvmBZvOxJx4CQZn_ColR8uWWeNYeGITtoMB5tZq2RNa8E2TkxNEVs0HVHrCxKfxHOCiPTKrhmq6lwzm7o-JI6N1wcr8_abIjGrKzchfTTLZ2yaFs/s1600/Screen+Shot+2019-10-01+at+5.56.26+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;339&quot; data-original-width=&quot;794&quot; height=&quot;170&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiFR3k1yHZj6q74momhtL7ZQxTQPinWBvmBZvOxJx4CQZn_ColR8uWWeNYeGITtoMB5tZq2RNa8E2TkxNEVs0HVHrCxKfxHOCiPTKrhmq6lwzm7o-JI6N1wcr8_abIjGrKzchfTTLZ2yaFs/s400/Screen+Shot+2019-10-01+at+5.56.26+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;h3&gt;
Creating the FTP Web Site&lt;/h3&gt;
&lt;br /&gt;
Go to Server Manager:&lt;br /&gt;
- Tools&lt;br /&gt;
- Internet Information Services (IIS) Manager&lt;br /&gt;
- Drill down to Sites and Right Click on Sites&lt;br /&gt;
- Select Add FTP Site&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiEWULCoAmq3ObhQ29fOIJ9Mu-7XpqFUzVgZAxE91c-N44BZJPro8Ee7OumpZxe7E_NjPSAvo4OezAQrwfolW9NAjNSUhADkt5gKo6AuaXvFB9gxVUEOLmmTB-mHEUpR2yN9DmM-9yKmx3B/s1600/Screen+Shot+2019-10-01+at+6.11.11+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;319&quot; data-original-width=&quot;427&quot; height=&quot;239&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiEWULCoAmq3ObhQ29fOIJ9Mu-7XpqFUzVgZAxE91c-N44BZJPro8Ee7OumpZxe7E_NjPSAvo4OezAQrwfolW9NAjNSUhADkt5gKo6AuaXvFB9gxVUEOLmmTB-mHEUpR2yN9DmM-9yKmx3B/s320/Screen+Shot+2019-10-01+at+6.11.11+PM.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
- Name your site and point to directory to be used as ftp_root directory (this is where files will be uploaded)&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgW6liFcq1VFGz5NqRd1oO84THRmaNSsmMPXUtkLg_CI1d0y-Uggk2l1Z4YgvfkyOiSiYjLFTHZnG6TjeJ3Pq6ocKZCexQOuQlOauc59J5vWPWOq2Bolan6Ynsu7fDvkdXGRiuuECYKs77o/s1600/Screen+Shot+2019-10-01+at+5.59.22+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;549&quot; data-original-width=&quot;721&quot; height=&quot;243&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgW6liFcq1VFGz5NqRd1oO84THRmaNSsmMPXUtkLg_CI1d0y-Uggk2l1Z4YgvfkyOiSiYjLFTHZnG6TjeJ3Pq6ocKZCexQOuQlOauc59J5vWPWOq2Bolan6Ynsu7fDvkdXGRiuuECYKs77o/s320/Screen+Shot+2019-10-01+at+5.59.22+PM.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
- Next to Binding and SSL Settings&lt;br /&gt;
- select no SSL and click next&lt;br /&gt;
- Next to Authentication and Authorization&lt;br /&gt;
- Authentication will be Basic&lt;br /&gt;
- Allow access to specified user and enter the service account created&lt;br /&gt;
- Check read and write permission&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;h3&gt;
Test the FTP Site&lt;/h3&gt;
&lt;br /&gt;
Launch Internet Explorer and access ftp://localhost or ip address&lt;br /&gt;
- If everything was configured properly it should prompt for credentials&lt;br /&gt;
- Enter the service account user name and password&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjBLciRgaPcx-1Bg-E8m7esvfXwHvgJvxsLLCkdxF-hLxTiZD5I83HowxujbTSBPhfBV2UHsbjCDa4XZEN7p3C6xpMiNIJ2VPVXMbOZT0b9KmGOY6CQvV-wbuTIgE6oXRZJGr5mnyDMDIRW/s1600/Screen+Shot+2019-10-01+at+6.04.20+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;336&quot; data-original-width=&quot;717&quot; height=&quot;149&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjBLciRgaPcx-1Bg-E8m7esvfXwHvgJvxsLLCkdxF-hLxTiZD5I83HowxujbTSBPhfBV2UHsbjCDa4XZEN7p3C6xpMiNIJ2VPVXMbOZT0b9KmGOY6CQvV-wbuTIgE6oXRZJGr5mnyDMDIRW/s320/Screen+Shot+2019-10-01+at+6.04.20+PM.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
- You should be able to log into the root of the ftp site&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiHbXK8-YO70IuvC7xhU434YNIobhTOzs7mwambB012fEdCBGxYh59Uxj-8jFjGFb7HFwNUjyvCyY4FKHYrkFp5a5K9ENo65AfkkMW6BtuXOzOkQHeGf5c8M-MTL1fR4Q5QWSeY0pUOoLb9/s1600/Screen+Shot+2019-10-01+at+6.05.40+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;296&quot; data-original-width=&quot;772&quot; height=&quot;122&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiHbXK8-YO70IuvC7xhU434YNIobhTOzs7mwambB012fEdCBGxYh59Uxj-8jFjGFb7HFwNUjyvCyY4FKHYrkFp5a5K9ENo65AfkkMW6BtuXOzOkQHeGf5c8M-MTL1fR4Q5QWSeY0pUOoLb9/s320/Screen+Shot+2019-10-01+at+6.05.40+PM.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;h3&gt;
Configure VCSA Backup&amp;nbsp;&lt;/h3&gt;
&lt;div&gt;
Log into your VCSA Appliance Management UI https://vcsa_ip:5480 and click Backup&lt;/div&gt;
&lt;div&gt;
- Click Configure&amp;nbsp;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEimE2LQO0BWUE72wOdAltTuWFTgUlB7H4rqMeXeiPySIzqm48osnJv6GNZYhU-A3QV9I_Dkif0qELzQzIiKoskzRMe9WZXokn37hKxeSPh27y9pUwou5B3DeLl-h5-qwLMr_rm4CNgXMnGk/s1600/10_148_71_166_-_fdrdp01_eng.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;597&quot; data-original-width=&quot;1000&quot; height=&quot;191&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEimE2LQO0BWUE72wOdAltTuWFTgUlB7H4rqMeXeiPySIzqm48osnJv6GNZYhU-A3QV9I_Dkif0qELzQzIiKoskzRMe9WZXokn37hKxeSPh27y9pUwou5B3DeLl-h5-qwLMr_rm4CNgXMnGk/s320/10_148_71_166_-_fdrdp01_eng.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;
- Create Backup Schedule&lt;/div&gt;
&lt;div&gt;
- Backup location&lt;/div&gt;
&lt;div&gt;
- Backup server credentials&lt;/div&gt;
&lt;div&gt;
- Schedule: Daily, Monthly or Custom&lt;/div&gt;
&lt;div&gt;
- Encrypt backup password&lt;/div&gt;
&lt;div&gt;
- Number of backup to retain (this is cool to conserve and clean up old backups)&lt;/div&gt;
&lt;div&gt;
- Data check to retain Stats.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEguowYqtV4h77tpMzCKsoVjgPlgcmBwalqIVDK9HDjHaviVctVubPY671pBYDEX3CdtF7lTh7vUUFHJzokQ-ytc2GAkwf-23RtJMXIMpumLCkcJh2GWBrkih8KdbGCWWeTBFDwNEihR-HTA/s1600/Screen+Shot+2019-10-01+at+6.17.02+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;713&quot; data-original-width=&quot;845&quot; height=&quot;270&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEguowYqtV4h77tpMzCKsoVjgPlgcmBwalqIVDK9HDjHaviVctVubPY671pBYDEX3CdtF7lTh7vUUFHJzokQ-ytc2GAkwf-23RtJMXIMpumLCkcJh2GWBrkih8KdbGCWWeTBFDwNEihR-HTA/s320/Screen+Shot+2019-10-01+at+6.17.02+PM.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;
Once this is done you can click Backup Now to test and make sure everything is working&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
- Click Backup Now&amp;nbsp;&lt;/div&gt;
&lt;div&gt;
- Enter the ftp_service account password and &#39;START&#39;&lt;/div&gt;
&lt;div&gt;
- if everything is configured properly you should see files been copied to the FTP site&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh5RYgQVN3rt3EEa3ThzfI6JL1wixXco6RoNYusNR0ts0Xgu9Q8WOSCjuoHS3jOelqnl72LZnkc7-lyvgLFwJs6IGA19TxJXWrcfdtLJ32A8BR8aEiIdNZaw5ylkATFbMDKYAT2gBkF1eEy/s1600/Screen+Shot+2019-10-01+at+6.19.33+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;270&quot; data-original-width=&quot;765&quot; height=&quot;112&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh5RYgQVN3rt3EEa3ThzfI6JL1wixXco6RoNYusNR0ts0Xgu9Q8WOSCjuoHS3jOelqnl72LZnkc7-lyvgLFwJs6IGA19TxJXWrcfdtLJ32A8BR8aEiIdNZaw5ylkATFbMDKYAT2gBkF1eEy/s320/Screen+Shot+2019-10-01+at+6.19.33+PM.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
This is the easiest and cheapest solution to backup your vCenter Appliance.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://fdo-workspace.blogspot.com/feeds/4284137353006885109/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://fdo-workspace.blogspot.com/2019/10/building-windows-2016-ftp-server-and.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/4284137353006885109'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/4284137353006885109'/><link rel='alternate' type='text/html' href='http://fdo-workspace.blogspot.com/2019/10/building-windows-2016-ftp-server-and.html' title='Building Windows 2016 FTP Server and configure VCSA v6.7 File-Based Backup '/><author><name>fdo</name><uri>http://www.blogger.com/profile/16882300714528613456</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhndsbgzepfJ0U5gXwY3zzRcGOqiMcblr09VzwWLCMA_waqC9FUthSCa8n91RwqW_kZXNo2si5UU3N5Ex6UJbYkcUpcJnxOQw6jPOBYuux7fomIpI0UUf8vOXyBT7hyuuE/s113/IMG_5942.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgvHX_LfJcgWja_FFFhkPRLWhKuU6uK9YjAWlcGQKj7fs5bD8un4RPXlQo-vjIqJvuz-K3By3c5RVwQc7m8CYCuyyrRHAqHAjM7mP2HPPmmeSVE1a4SSBytaxzRMgtQbaJzcdl4XyVCF19m/s72-c/10_148_71_166_-_fdrdp01_eng.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8658731852844520209.post-999156646462238328</id><published>2019-07-28T11:47:00.001-04:00</published><updated>2019-07-28T11:47:28.459-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="python"/><category scheme="http://www.blogger.com/atom/ns#" term="virtualenv"/><category scheme="http://www.blogger.com/atom/ns#" term="virtualenvwrapper"/><title type='text'>Fix for Python not working in VirtualEnv -  Reason: image not found.</title><content type='html'>&lt;div class=&quot;tr_bq&quot;&gt;
I&#39;ve become a big fan of &quot;virtualenvwrapper&quot; because it makes managing multiple virtual environment super easy and it takes you to the root of the project folder you which to work on.&lt;/div&gt;
&lt;br /&gt;
Few commands:&lt;br /&gt;
&lt;i&gt;- mkproject &quot;project_name&quot;:&amp;nbsp; will create virtualenv and project folder&lt;/i&gt;&lt;br /&gt;
&lt;i&gt;- workon : will list all the virtualenv&amp;nbsp;&lt;/i&gt;&lt;br /&gt;
&lt;i&gt;- workon project_name: will activate the virtuelenv and cd to the project folder&lt;/i&gt;&lt;br /&gt;
There are still lot of tips and tricks in the main website&amp;nbsp;&lt;a href=&quot;https://virtualenvwrapper.readthedocs.io/en/latest/&quot;&gt;https://virtualenvwrapper.readthedocs.io/en/latest/&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
Lately been dealing with an odd issue where I can load the virtualenv but python is not working. When I try to launch python I get error:&lt;br /&gt;
&lt;blockquote class=&quot;tr_bq&quot;&gt;
&lt;i&gt;$ python --version&lt;br /&gt;dyld: Library not loaded: @executable_path/../.Python&lt;br /&gt;&amp;nbsp; Referenced from: /Users/maki/.virtualenvs/rest_foreman/bin/python&lt;br /&gt;&amp;nbsp; Reason: image not found&lt;br /&gt;Abort trap: 6&lt;/i&gt;&lt;/blockquote&gt;
&amp;nbsp;Originally I would delete the virtualenv, create a new, but it will not change directory. Apparently deleting the virtualenv does not remove the project folder and there seems to be a bug where it doesn&#39;t register existing project folders. Only way to get around this and keeping the same project name as well as fixing change directory option was to rename the bad project folder. Do mkproject and move the file content to the new location. However it happened keep happening for some reason and I had to find a better solution.&lt;br /&gt;
&lt;br /&gt;
&lt;h3&gt;
What was the problem??&lt;/h3&gt;
&lt;br /&gt;
I browse to the &lt;i&gt;.virtualenv/project/bin/ f&lt;/i&gt;older and notice the symlinks were messed up.&lt;br /&gt;
&lt;br /&gt;
&lt;blockquote class=&quot;tr_bq&quot;&gt;
&lt;i&gt;&amp;nbsp;0 lrwxr-xr-x&amp;nbsp; &amp;nbsp;1 maki&amp;nbsp; &amp;nbsp;staff&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;9 Jun 21 13:31 python -&amp;gt; python3.7&lt;/i&gt;&lt;i&gt;&amp;nbsp;8 -rwxr-xr-x&amp;nbsp; &amp;nbsp;1 maki&amp;nbsp;&amp;nbsp;&amp;nbsp;staff&amp;nbsp; &amp;nbsp;2362 Jun 21 13:31 python-config&lt;/i&gt;&lt;i&gt;&amp;nbsp;0 lrwxr-xr-x&amp;nbsp; &amp;nbsp;1 maki&amp;nbsp;&amp;nbsp;&amp;nbsp;staff&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;9 Jun 21 13:31 python3 -&amp;gt; python3.7&lt;/i&gt;&lt;i&gt;32 -rwxr-xr-x&amp;nbsp; 1 maki&amp;nbsp;&amp;nbsp;&amp;nbsp;staff 12552 Jun 21 13:31 python3.7&lt;/i&gt;&lt;i&gt;&amp;nbsp;8 -rwxr-xr-x&amp;nbsp; &amp;nbsp;1 maki&amp;nbsp;&amp;nbsp;&amp;nbsp;staff&amp;nbsp; &amp;nbsp; &amp;nbsp;253 Jun 21 13:31 wheel&lt;/i&gt;&lt;/blockquote&gt;
Tried calling any of the 3 python# from the folder will give me same error message. Notice is a symlink to python3.7. Seems like a ENV variable missing. I am not sure why it stopped working but I know it was after rebooting my MAC and I don&#39;t reboot the MAC often.&lt;br /&gt;
&lt;h3&gt;
&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;b&gt;Fixing the broken symlink:&lt;/b&gt;&lt;/h3&gt;
&lt;br /&gt;
From inside the virtualenv find your bin folder:&lt;br /&gt;
&lt;blockquote class=&quot;tr_bq&quot;&gt;
&lt;i&gt;&lt;b&gt;- $ workon project&lt;br /&gt;- $ which python&lt;br /&gt;output:&lt;br /&gt;/Users/maki/.virtualenvs/rest_foreman/bin/python&lt;/b&gt;&lt;/i&gt;&lt;/blockquote&gt;
Using another terminal session:&lt;br /&gt;
&lt;br /&gt;
&lt;blockquote&gt;
&lt;i&gt;&lt;b&gt;- $ cd to the bin folder&lt;br /&gt;- $ which python3.7 (I only use python3 find location of your python3.7)&amp;nbsp;&lt;/b&gt;&lt;/i&gt;&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;i&gt;&lt;b&gt;output:&lt;br /&gt;/usr/local/bin/python3.7&amp;nbsp;&lt;/b&gt;&lt;/i&gt;&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;i&gt;&lt;b&gt;# Run following command in the bin folder to replace broken links&lt;br /&gt;- $ ln -s -f /usr/local/bin/python3.7 python&lt;br /&gt;- $ ln -s -f /usr/local/bin/python3.7 python3.7&lt;br /&gt;- $ ln -s -f /usr/local/bin/python3.7 python3&amp;nbsp;&lt;/b&gt;&lt;/i&gt;&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;i&gt;&lt;b&gt;# Should look like this:&lt;br /&gt;0 lrwxr-xr-x&amp;nbsp; 1 maki&amp;nbsp; staff&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;24 Jul 28 11:42 python -&amp;gt; /usr/local/bin/python3.7&lt;br /&gt;8 -rwxr-xr-x&amp;nbsp; 1 maki&amp;nbsp; staff&amp;nbsp; 2362 May 10 16:28 python-config&lt;br /&gt;0 lrwxr-xr-x&amp;nbsp; 1 maki&amp;nbsp; staff&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 9 May 10 16:28 python3 -&amp;gt; python3.7&lt;br /&gt;0 lrwxr-xr-x&amp;nbsp; 1 maki&amp;nbsp; staff&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;24 Jul 28 11:00 python3.7 -&amp;gt; /usr/local/bin/python3.7&lt;/b&gt;&lt;/i&gt;&lt;/blockquote&gt;
Now it should work again. you can test by running &lt;b&gt;python --version&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Not sure if there is a better fix but if you do have one please share.. Thanks..&lt;br /&gt;
&lt;br /&gt;</content><link rel='replies' type='application/atom+xml' href='http://fdo-workspace.blogspot.com/feeds/999156646462238328/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://fdo-workspace.blogspot.com/2019/07/fix-for-python-not-working-in.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/999156646462238328'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/999156646462238328'/><link rel='alternate' type='text/html' href='http://fdo-workspace.blogspot.com/2019/07/fix-for-python-not-working-in.html' title='Fix for Python not working in VirtualEnv -  Reason: image not found.'/><author><name>fdo</name><uri>http://www.blogger.com/profile/16882300714528613456</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhndsbgzepfJ0U5gXwY3zzRcGOqiMcblr09VzwWLCMA_waqC9FUthSCa8n91RwqW_kZXNo2si5UU3N5Ex6UJbYkcUpcJnxOQw6jPOBYuux7fomIpI0UUf8vOXyBT7hyuuE/s113/IMG_5942.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8658731852844520209.post-7857716817946589502</id><published>2019-07-19T11:32:00.000-04:00</published><updated>2019-07-19T12:42:41.580-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="issues"/><category scheme="http://www.blogger.com/atom/ns#" term="powershell"/><category scheme="http://www.blogger.com/atom/ns#" term="python"/><category scheme="http://www.blogger.com/atom/ns#" term="vCenter"/><title type='text'>vCenter AD authentication taking over 60second???</title><content type='html'>A very odd issue got escalated to me this week. Some of our in house tools&amp;nbsp;will take forever to run and will time out. These tools uses AD service account to authenticate and &lt;span style=&quot;background-color: yellow;&quot;&gt;issue is also encountered when login into&lt;/span&gt;&amp;nbsp;vSphere Web Client. Browser will sit in login screen for a minute. BTW this particular environment was running v6.5.&lt;br /&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
I started by investigating the in-house application one of which I developed. Application will consistently timeout. Reported this issue and basic checks were performed on the vCenter. vCenter services, cpu/mem resources, disk space and all the usual stuff but everything seem fine.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
In order to better understand the situation, created a very simply Python script to measure amount time time taken to connect to this vCenter. On every&amp;nbsp;vCenter it will take ~0.15sec to establish connection. But this affected one was taking up to ~60sec consistently.&amp;nbsp;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhX5TIsGyCxARuTb7I7oHz2fGAyPSQ6X8kLEIJ2UNiC5kSE_TbK2Yzc_4FLJ7fnDBg1GNKv4w21gfw1c25cWr1JHIocwY58VJOQwlAhtc-Y7NweyAd_i8vxzlywAlUqiMqrVagbaPD8PeMS/s1600/test_connect_vc_py_%25E2%2580%2594_powershell__Workspace_.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;136&quot; data-original-width=&quot;376&quot; height=&quot;115&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhX5TIsGyCxARuTb7I7oHz2fGAyPSQ6X8kLEIJ2UNiC5kSE_TbK2Yzc_4FLJ7fnDBg1GNKv4w21gfw1c25cWr1JHIocwY58VJOQwlAhtc-Y7NweyAd_i8vxzlywAlUqiMqrVagbaPD8PeMS/s320/test_connect_vc_py_%25E2%2580%2594_powershell__Workspace_.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
Once the account is authenticated everything worked fine, but waiting 60sec was unacceptable.&amp;nbsp; Opened case with VMware, went thru whole process and the engineer finally pointed out&amp;nbsp;&lt;i&gt;/var/log/vmware/sso/vmware-sts-idmd.log&lt;/i&gt; error message complaining about cannot bind connection with ldap.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjXz9deSOE8vclUJ0piO7WxOfLMXGr8ccfBSMbSnnwzab1E7H5ty9ZL3TAVc6ckY6IAUhiS44i_CB3A5V3BXrWAhRgEnmc5ziICKkvX40dIWVwVSGBhrb_ixLpUTyX_KkpjDKr66jwYOOHQ/s1600/Screen_Shot_2019-07-18_at_1_44_27_PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;85&quot; data-original-width=&quot;1324&quot; height=&quot;40&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjXz9deSOE8vclUJ0piO7WxOfLMXGr8ccfBSMbSnnwzab1E7H5ty9ZL3TAVc6ckY6IAUhiS44i_CB3A5V3BXrWAhRgEnmc5ziICKkvX40dIWVwVSGBhrb_ixLpUTyX_KkpjDKr66jwYOOHQ/s640/Screen_Shot_2019-07-18_at_1_44_27_PM.png&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;blockquote class=&quot;tr_bq&quot;&gt;
&lt;i&gt;[ServerUtils] cannot bind connection: [ldap://ipaddres_of_primary_ad:389 , domain\userid]&amp;nbsp;&lt;/i&gt;&lt;/blockquote&gt;
&lt;blockquote class=&quot;tr_bq&quot;&gt;
&lt;i&gt;[ServerUtils] Error received by LDAP client: com.vmware.identiry.interop.ldap.OpenLdapClientLibrary, error code: -1&lt;/i&gt;&lt;/blockquote&gt;
&lt;br /&gt;
Next step was to identify issue: Started with basic checking to make sure port were open between vCenter and AD server. &quot;curl -v ad_server_ip:389&quot; and of course it was failing. When it comes to production our role and access is very compartmentalized and reaching out to the appropriate team is required. Networking team verified ports were open and AD team verified no firewall rules were applied.&lt;br /&gt;
&lt;br /&gt;
I tried several things to verify each side&#39;s statement. Since AD server and vCenter were in different network I wanted to make sure ports were not blocked. Wrote very simple Python script to listen to port 389, on the same network AD server was residing and tested port connection VC. It worked!! this rule out &quot;network issue&quot;. Spent so much time looking at this problem that left something out.. We have a primary and a secondary AD server. Went back to the VC and tested port connecting against the secondary AD server and it worked!!! Well which perfectly explain the ~60sec delay before switching to the good AD.. Which also explain why the logs are flooded with error related to primary AD and no messages from the secondary.&lt;br /&gt;
&lt;br /&gt;
Reported back to AD team and they had to schedule the reboot. Since we can&#39;t wait any longer easiest solution was to swap the identity sources used in vCenter.&amp;nbsp; To do so:&lt;br /&gt;
&lt;br /&gt;
-- Administration | Single Sign - On | Configuration | Identity Sources&lt;br /&gt;
-- Select your Domain | Edit | Swap your primary and secondary AD source&lt;br /&gt;
-- Save changes..&lt;br /&gt;
&lt;br /&gt;
Tested and this fixed the problem for me...&lt;br /&gt;
&lt;br /&gt;
&lt;h3&gt;
Bonus Scripts used to troubleshoot this issue:&lt;/h3&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
Test Python script to measure duration:&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div style=&quot;background-color: #1e1e1e; line-height: 18px;&quot;&gt;
&lt;br /&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
&lt;span style=&quot;color: #c586c0;&quot;&gt;import&lt;/span&gt; atexit&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
&lt;span style=&quot;color: #c586c0;&quot;&gt;from&lt;/span&gt; pyVim.connect &lt;span style=&quot;color: #c586c0;&quot;&gt;import&lt;/span&gt; SmartConnectNoSSL, Disconnect&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
&lt;span style=&quot;color: #c586c0;&quot;&gt;import&lt;/span&gt; requests&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
&lt;span style=&quot;color: #c586c0;&quot;&gt;import&lt;/span&gt; json&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
&lt;span style=&quot;color: #c586c0;&quot;&gt;from&lt;/span&gt; requests.auth &lt;span style=&quot;color: #c586c0;&quot;&gt;import&lt;/span&gt; HTTPBasicAuth&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
&lt;span style=&quot;color: #c586c0;&quot;&gt;import&lt;/span&gt; ssl&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
&lt;span style=&quot;color: #c586c0;&quot;&gt;import&lt;/span&gt; time&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
start_time = time.time()&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
vcenter=&lt;span style=&quot;color: #ce9178;&quot;&gt;&#39;vcenter_ip_address&#39;&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
user=&lt;span style=&quot;color: #ce9178;&quot;&gt;&#39;username@domain.com&#39;&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
password=&lt;span style=&quot;color: #ce9178;&quot;&gt;&#39;secret_password&#39;&lt;/span&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
&lt;span style=&quot;color: #c586c0;&quot;&gt;try&lt;/span&gt;:&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
&lt;span style=&quot;color: #569cd6;&quot;&gt;print&lt;/span&gt;(&lt;span style=&quot;color: #ce9178;&quot;&gt;&quot;Trying to connecto to &quot;&lt;/span&gt;, vcenter)&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
service_instance = SmartConnectNoSSL(&lt;span style=&quot;color: #9cdcfe;&quot;&gt;host&lt;/span&gt;=vcenter, &lt;span style=&quot;color: #9cdcfe;&quot;&gt;user&lt;/span&gt;=user, &lt;span style=&quot;color: #9cdcfe;&quot;&gt;pwd&lt;/span&gt;=password)&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
&lt;span style=&quot;color: #6a9955;&quot;&gt;# doing this means you don&#39;t need to remember to disconnect your script/objects&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
atexit.register(Disconnect, service_instance)&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
&lt;span style=&quot;color: #c586c0;&quot;&gt;except&lt;/span&gt; requests.exceptions.SSLError &lt;span style=&quot;color: #569cd6;&quot;&gt;as&lt;/span&gt; e:&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
context = ssl.SSLContext(ssl.PROTOCOL_TLSv1)&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
context.verify_mode = ssl.CERT_NONE&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
trying&lt;/div&gt;
&lt;br /&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
service_instance = SmartConnectNoSSL(&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
&lt;span style=&quot;color: #9cdcfe;&quot;&gt;host&lt;/span&gt;=vcenter, &lt;span style=&quot;color: #9cdcfe;&quot;&gt;user&lt;/span&gt;=user, &lt;span style=&quot;color: #9cdcfe;&quot;&gt;pwd&lt;/span&gt;=password, &lt;span style=&quot;color: #9cdcfe;&quot;&gt;sslContext&lt;/span&gt;=context)&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
&lt;span style=&quot;color: #6a9955;&quot;&gt;# doing this means you don&#39;t need to remember to disconnect your script/objects&lt;/span&gt;&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
atexit.register(Disconnect, service_instance)&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
&lt;span style=&quot;color: #c586c0;&quot;&gt;except&lt;/span&gt; vim.fault.InvalidLogin:&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
&lt;span style=&quot;color: #569cd6;&quot;&gt;print&lt;/span&gt;(&lt;span style=&quot;color: #ce9178;&quot;&gt;&quot;Invalid Login - username or password.&quot;&lt;/span&gt;)&lt;/div&gt;
&lt;br /&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
&lt;span style=&quot;color: #569cd6;&quot;&gt;print&lt;/span&gt;(&lt;span style=&quot;color: #ce9178;&quot;&gt;&#39;Script ended - trying to connect to VC -&#39;&lt;/span&gt;, vcenter)&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
&lt;span style=&quot;color: #569cd6;&quot;&gt;print&lt;/span&gt;(service_instance)&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
&lt;div style=&quot;line-height: 18px;&quot;&gt;
&lt;div&gt;
&lt;/div&gt;
&lt;div&gt;
&lt;span style=&quot;color: #569cd6;&quot;&gt;print&lt;/span&gt;(&lt;span style=&quot;color: #ce9178;&quot;&gt;&quot;--- %s seconds ---&quot;&lt;/span&gt; % (time.time() - start_time))&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div style=&quot;color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; white-space: pre;&quot;&gt;
Output&lt;/div&gt;
&lt;div&gt;
&lt;span style=&quot;color: #d4d4d4; font-family: &amp;quot;menlo&amp;quot; , &amp;quot;monaco&amp;quot; , &amp;quot;courier new&amp;quot; , monospace;&quot;&gt;&lt;span style=&quot;font-size: 12px; white-space: pre;&quot;&gt;Trying to connecto to  10.10.10.10
Script ended - trying to connect to VC - 10.10.10.10
&#39;vim.ServiceInstance:ServiceInstance&#39;
--- 0.15743589401245117 seconds ---&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
Port Listener Script - Credit to GeekFlare for creating this.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;div style=&quot;background-color: #1e1e1e; color: #d4d4d4; font-family: Menlo, Monaco, &amp;quot;Courier New&amp;quot;, monospace; font-size: 12px; line-height: 18px; white-space: pre;&quot;&gt;
&lt;div&gt;
&lt;span style=&quot;color: #ce9178;&quot;&gt;&#39;&#39;&#39;    Simple socket server using threads&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style=&quot;color: #ce9178;&quot;&gt;&#39;&#39;&#39;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style=&quot;color: #c586c0;&quot;&gt;import&lt;/span&gt; socket&lt;/div&gt;
&lt;div&gt;
&lt;span style=&quot;color: #c586c0;&quot;&gt;import&lt;/span&gt; sys&lt;/div&gt;
&lt;div&gt;
HOST = &lt;span style=&quot;color: #ce9178;&quot;&gt;&#39;&#39;&lt;/span&gt;   &lt;span style=&quot;color: #6a9955;&quot;&gt;# Symbolic name, meaning all available interfaces&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
PORT = &lt;span style=&quot;color: #b5cea8;&quot;&gt;389&lt;/span&gt; &lt;span style=&quot;color: #6a9955;&quot;&gt;# Arbitrary non-privileged port&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)&lt;/div&gt;
&lt;div&gt;
&lt;span style=&quot;color: #569cd6;&quot;&gt;print&lt;/span&gt;( &lt;span style=&quot;color: #ce9178;&quot;&gt;&#39;Socket created&#39;&lt;/span&gt;)&lt;/div&gt;
&lt;div&gt;
&lt;span style=&quot;color: #6a9955;&quot;&gt;#Bind socket to local host and port&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style=&quot;color: #c586c0;&quot;&gt;try&lt;/span&gt;:&lt;/div&gt;
&lt;div&gt;
s.bind((HOST, PORT))&lt;/div&gt;
&lt;div&gt;
&lt;span style=&quot;color: #c586c0;&quot;&gt;except&lt;/span&gt; socket.error &lt;span style=&quot;color: #569cd6;&quot;&gt;as&lt;/span&gt; msg:&lt;/div&gt;
&lt;div&gt;
&lt;span style=&quot;color: #569cd6;&quot;&gt;print&lt;/span&gt;(&lt;span style=&quot;color: #ce9178;&quot;&gt;&#39;Bind failed. Error Code : &#39;&lt;/span&gt; + &lt;span style=&quot;color: #4ec9b0;&quot;&gt;str&lt;/span&gt;(msg[&lt;span style=&quot;color: #b5cea8;&quot;&gt;0&lt;/span&gt;]) + &lt;span style=&quot;color: #ce9178;&quot;&gt;&#39; Message &#39;&lt;/span&gt; + msg[&lt;span style=&quot;color: #b5cea8;&quot;&gt;1&lt;/span&gt;] )&lt;/div&gt;
&lt;div&gt;
sys.exit()&lt;/div&gt;
&lt;div&gt;
&lt;span style=&quot;color: #569cd6;&quot;&gt;print&lt;/span&gt;( &lt;span style=&quot;color: #ce9178;&quot;&gt;&#39;Socket bind complete&#39;&lt;/span&gt;)&lt;/div&gt;
&lt;div&gt;
&lt;span style=&quot;color: #6a9955;&quot;&gt;#Start listening on socket&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
s.listen(&lt;span style=&quot;color: #b5cea8;&quot;&gt;10&lt;/span&gt;)&lt;/div&gt;
&lt;div&gt;
&lt;span style=&quot;color: #569cd6;&quot;&gt;print&lt;/span&gt;( &lt;span style=&quot;color: #ce9178;&quot;&gt;&#39;Socket now listening&#39;&lt;/span&gt;)&lt;/div&gt;
&lt;div&gt;
&lt;span style=&quot;color: #6a9955;&quot;&gt;#now keep talking with the client&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style=&quot;color: #c586c0;&quot;&gt;while&lt;/span&gt; &lt;span style=&quot;color: #b5cea8;&quot;&gt;1&lt;/span&gt;:&lt;/div&gt;
&lt;div&gt;
&lt;span style=&quot;color: #6a9955;&quot;&gt;#wait to accept a connection - blocking call&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
conn, addr = s.accept()&lt;/div&gt;
&lt;div&gt;
&lt;span style=&quot;color: #569cd6;&quot;&gt;print&lt;/span&gt; (&lt;span style=&quot;color: #ce9178;&quot;&gt;&#39;Connected with &#39;&lt;/span&gt; + addr[&lt;span style=&quot;color: #b5cea8;&quot;&gt;0&lt;/span&gt;] + &lt;span style=&quot;color: #ce9178;&quot;&gt;&#39;:&#39;&lt;/span&gt; + &lt;span style=&quot;color: #4ec9b0;&quot;&gt;str&lt;/span&gt;(addr[&lt;span style=&quot;color: #b5cea8;&quot;&gt;1&lt;/span&gt;]))&lt;/div&gt;
&lt;div&gt;
s.close()&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;</content><link rel='replies' type='application/atom+xml' href='http://fdo-workspace.blogspot.com/feeds/7857716817946589502/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://fdo-workspace.blogspot.com/2019/07/vcenter-ad-authentication-taking-over.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/7857716817946589502'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/7857716817946589502'/><link rel='alternate' type='text/html' href='http://fdo-workspace.blogspot.com/2019/07/vcenter-ad-authentication-taking-over.html' title='vCenter AD authentication taking over 60second???'/><author><name>fdo</name><uri>http://www.blogger.com/profile/16882300714528613456</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhndsbgzepfJ0U5gXwY3zzRcGOqiMcblr09VzwWLCMA_waqC9FUthSCa8n91RwqW_kZXNo2si5UU3N5Ex6UJbYkcUpcJnxOQw6jPOBYuux7fomIpI0UUf8vOXyBT7hyuuE/s113/IMG_5942.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhX5TIsGyCxARuTb7I7oHz2fGAyPSQ6X8kLEIJ2UNiC5kSE_TbK2Yzc_4FLJ7fnDBg1GNKv4w21gfw1c25cWr1JHIocwY58VJOQwlAhtc-Y7NweyAd_i8vxzlywAlUqiMqrVagbaPD8PeMS/s72-c/test_connect_vc_py_%25E2%2580%2594_powershell__Workspace_.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8658731852844520209.post-6583841691075110550</id><published>2019-06-28T16:25:00.001-04:00</published><updated>2019-06-28T16:25:24.893-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Flask"/><category scheme="http://www.blogger.com/atom/ns#" term="Jinja2"/><category scheme="http://www.blogger.com/atom/ns#" term="python"/><title type='text'>Learning Flask and Jinja2 - Manipulating Data</title><content type='html'>Lately I&#39;ve been learning Flask to write tools that queries vCenter and this article very brief article that will show how to data generated in form of&amp;nbsp; List or JSON in a Jinja2 template table.&lt;br /&gt;
&lt;br /&gt;
&lt;h3&gt;
Jinja2 - Dividing a List into columns using Batch&lt;/h3&gt;
&lt;div&gt;
When you have a long list of data, instead of displaying a long list, you can plus the data into columns. Easiest way to do this is using the batch filter.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
Following example will take a list of letter and divide into a table with 3 columns evenly distributed&lt;/div&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush: py&quot;&gt;import json
from jinja2 import Template
list_str = [&#39;a&#39;,&#39;b&#39;,&#39;c&#39;,&#39;d&#39;,&#39;e&#39;,&#39;f&#39;,&#39;g&#39;,&#39;h&#39;,&#39;i&#39;,&#39;j&#39;,&#39;k&#39;,&#39;l&#39;,&#39;m&#39;]
list_str
tmpl = Template(&#39;&#39;&#39;
&amp;lt;table&amp;gt;
{%- for row in data|batch(3, &#39;&amp;amp;nbsp;&#39;) %}
  &amp;lt;tr&amp;gt;
  {%- for column in row %}
    &amp;lt;td&amp;gt;{{ column }}&amp;lt;/td&amp;gt;
  {%- endfor %}
  &amp;lt;/tr&amp;gt;
{%- endfor %}
&amp;lt;/table&amp;gt;
&#39;&#39;&#39;)
print(tmpl.render(data = list_str))
 

## Output

&amp;lt;table&amp;gt;
  &amp;lt;tr&amp;gt;
    &amp;lt;td&amp;gt;a&amp;lt;/td&amp;gt;
    &amp;lt;td&amp;gt;b&amp;lt;/td&amp;gt;
    &amp;lt;td&amp;gt;c&amp;lt;/td&amp;gt;
  &amp;lt;/tr&amp;gt;
  &amp;lt;tr&amp;gt;
    &amp;lt;td&amp;gt;d&amp;lt;/td&amp;gt;
    &amp;lt;td&amp;gt;e&amp;lt;/td&amp;gt;
    &amp;lt;td&amp;gt;f&amp;lt;/td&amp;gt;
  &amp;lt;/tr&amp;gt;
  &amp;lt;tr&amp;gt;
    &amp;lt;td&amp;gt;g&amp;lt;/td&amp;gt;
    &amp;lt;td&amp;gt;h&amp;lt;/td&amp;gt;
    &amp;lt;td&amp;gt;i&amp;lt;/td&amp;gt;
  &amp;lt;/tr&amp;gt;
  &amp;lt;tr&amp;gt;
    &amp;lt;td&amp;gt;j&amp;lt;/td&amp;gt;
    &amp;lt;td&amp;gt;k&amp;lt;/td&amp;gt;
    &amp;lt;td&amp;gt;l&amp;lt;/td&amp;gt;
  &amp;lt;/tr&amp;gt;
  &amp;lt;tr&amp;gt;
    &amp;lt;td&amp;gt;m&amp;lt;/td&amp;gt;
    &amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;
    &amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;
  &amp;lt;/tr&amp;gt;
&amp;lt;/table&amp;gt;
&lt;/pre&gt;
&lt;script type=&quot;text/javascript&quot;&gt;
SyntaxHighlighter.highlight();
&lt;/script&gt;


&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;h3&gt;
Jinja2 - JSON to Table - Static&lt;/h3&gt;
&lt;br /&gt;
Data in JSON is the most common format but depending on how is displayed on your page it can be hard to read. Even when displaying into pretty JSON format often times is not good enough. Here is a quick example on how to turn a JSON output into 3 column table. This following example will export the data. Each row contains 3 fields: name, moid and guestfullname the Jinja loop will take loop thru each item into columns and rows.&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush: py&quot;&gt;import json
from jinja2 import Template

json_str = &#39;&#39;&#39;[{&quot;name&quot;: &quot;name&quot;, &quot;moId&quot;: &quot;moId&quot;, &quot;guestFullName&quot;: &quot;guestFullName&quot;}, 
    {&quot;name&quot;: &quot;dummyvm023&quot;, &quot;moId&quot;: &quot;vm-2409&quot;, &quot;guestFullName&quot;: &quot;SUSE Linux Enterprise 11 (64-bit)&quot;}, 
    {&quot;name&quot;: &quot;dummyvm034&quot;, &quot;moId&quot;: &quot;vm-9152&quot;, &quot;guestFullName&quot;: &quot;Red Hat Enterprise Linux 6 (64-bit)&quot;}]&#39;&#39;&#39;


vm_list = json.loads(json_str)

tmpl1 = Template(&#39;&#39;&#39;
&amp;lt;table&amp;gt;
   {% for vm in vm_list %}
   &amp;lt;tr&amp;gt;&lt;/pre&gt;
&lt;pre class=&quot;brush: py&quot;&gt;       &amp;lt;td&amp;gt;{{ vm[&#39;name&#39;] }}&amp;lt;/td&amp;gt; &lt;/pre&gt;
&lt;pre class=&quot;brush: py&quot;&gt;       &amp;lt;td&amp;gt;{{ vm[&#39;moId&#39;] }}&amp;lt;/td&amp;gt;&lt;/pre&gt;
&lt;pre class=&quot;brush: py&quot;&gt;       &amp;lt;td&amp;gt;{{ vm[&#39;guestFullName&#39;] }}&amp;lt;/td&amp;gt;&lt;/pre&gt;
&lt;pre class=&quot;brush: py&quot;&gt;   &amp;lt;/tr&amp;gt;
   {% endfor %}
&amp;lt;/table&amp;gt;
&#39;&#39;&#39;)

# Sample Output
&amp;lt;table&amp;gt;
  &amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;name&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;moId&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;guestFullName&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;
  &amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;dummyvm023&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;vm-2409&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;SUSE Linux Enterprise 11 (64-bit)&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;
  &amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;dummyvm034&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;vm-9152&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;Red Hat Enterprise Linux 6 (64-bit)&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;
&amp;lt;/table&amp;gt;
&lt;/pre&gt;
&lt;script type=&quot;text/javascript&quot;&gt;
SyntaxHighlighter.highlight();
&lt;/script&gt;



&lt;br /&gt;
&lt;br /&gt;
&lt;h3&gt;
Jinja2 - JSON to Table - Dynamic&lt;/h3&gt;
&lt;div&gt;
Previous method is okay when the JSON data only have few fields/columns, but when dealing with large JSON files with lots of columns it becomes hard to code each field into the Jinja template. In the next example we will use keys and values to iterate thru the data and generate the table dynamically.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;pre class=&quot;brush: py&quot;&gt;import json
from jinja2 import Template

json_str = &#39;&#39;&#39;[{&quot;name&quot;: &quot;name&quot;, &quot;moId&quot;: &quot;moId&quot;, &quot;guestFullName&quot;: &quot;guestFullName&quot;}, 
    {&quot;name&quot;: &quot;dummyvm023&quot;, &quot;moId&quot;: &quot;vm-2409&quot;, &quot;guestFullName&quot;: &quot;SUSE Linux Enterprise 11 (64-bit)&quot;}, 
    {&quot;name&quot;: &quot;dummyvm034&quot;, &quot;moId&quot;: &quot;vm-9152&quot;, &quot;guestFullName&quot;: &quot;Red Hat Enterprise Linux 6 (64-bit)&quot;}]&#39;&#39;&#39;

tmpl2 = Template(&#39;&#39;&#39;
&amp;lt;table&amp;gt;
   {% for vm in vmList %}
        &amp;lt;tr&amp;gt;
        {% for key, value in vm.items() %}
            &amp;lt;td&amp;gt;{{value}}&amp;lt;/td&amp;gt;
        {% endfor %}
        &amp;lt;/tr&amp;gt;
    {% endfor %}
&amp;lt;/table&amp;gt;
&#39;&#39;&#39;)
print(tmpl1.render(vmList = vmList))

## Sample Output

&amp;lt;table&amp;gt;
        &amp;lt;tr&amp;gt;
            &amp;lt;td&amp;gt;name&amp;lt;/td&amp;gt;
            &amp;lt;td&amp;gt;moId&amp;lt;/td&amp;gt;
            &amp;lt;td&amp;gt;guestFullName&amp;lt;/td&amp;gt;
        &amp;lt;/tr&amp;gt;
        &amp;lt;tr&amp;gt;
            &amp;lt;td&amp;gt;dummyvm023&amp;lt;/td&amp;gt;
            &amp;lt;td&amp;gt;vm-2409&amp;lt;/td&amp;gt;
            &amp;lt;td&amp;gt;SUSE Linux Enterprise 11 (64-bit)&amp;lt;/td&amp;gt;
        &amp;lt;/tr&amp;gt;
        &amp;lt;tr&amp;gt;
            &amp;lt;td&amp;gt;dummyvm034&amp;lt;/td&amp;gt;
            &amp;lt;td&amp;gt;vm-9152&amp;lt;/td&amp;gt;
            &amp;lt;td&amp;gt;Red Hat Enterprise Linux 6 (64-bit)&amp;lt;/td&amp;gt;   
        &amp;lt;/tr&amp;gt;
&amp;lt;/table&amp;gt;

&lt;/pre&gt;
&lt;script type=&quot;text/javascript&quot;&gt;
SyntaxHighlighter.highlight();
&lt;/script&gt;



&lt;br /&gt;
Here is a quick example of what it would look like on a real scenario. Here is a little tool I wrote where user can select the from a list of options they want in their report and sorted into 4 columns.&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi5NlsZzSuJdgZk9WNWgCOXqbx4pOBNPsI4JN73oolch_SHkxmi4T8jHBYrHWI8wDBjrWQRndxrwpI2ximSdCKc7jcFhyX-fSmLlkm0qBU3D1-5giCZ1YhXzwHOyhrE6i5cu1b7YX1WTwg9/s1600/Welcome_to_Console_Launch_Site.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;553&quot; data-original-width=&quot;817&quot; height=&quot;216&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi5NlsZzSuJdgZk9WNWgCOXqbx4pOBNPsI4JN73oolch_SHkxmi4T8jHBYrHWI8wDBjrWQRndxrwpI2ximSdCKc7jcFhyX-fSmLlkm0qBU3D1-5giCZ1YhXzwHOyhrE6i5cu1b7YX1WTwg9/s320/Welcome_to_Console_Launch_Site.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
And here is the report generated:&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiQG0qmWxH9lgDI4MgYPI2MdS7-i9VOQYn9kqphguKPf_CIovtleg2MyxG4ny-CpCSvnUjX46qr7L3YLKhAeowaTuVO63uhDnqTEufrrU3OQa07lrEnIqzFsC1IDPvVIPx9jeNhnuIqJAKJ/s1600/Welcome_to_Console_Launch_Site.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;837&quot; data-original-width=&quot;1063&quot; height=&quot;251&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiQG0qmWxH9lgDI4MgYPI2MdS7-i9VOQYn9kqphguKPf_CIovtleg2MyxG4ny-CpCSvnUjX46qr7L3YLKhAeowaTuVO63uhDnqTEufrrU3OQa07lrEnIqzFsC1IDPvVIPx9jeNhnuIqJAKJ/s320/Welcome_to_Console_Launch_Site.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
Thats it...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;</content><link rel='replies' type='application/atom+xml' href='http://fdo-workspace.blogspot.com/feeds/6583841691075110550/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://fdo-workspace.blogspot.com/2019/06/learning-flask-and-jinja2-manipulating.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/6583841691075110550'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/6583841691075110550'/><link rel='alternate' type='text/html' href='http://fdo-workspace.blogspot.com/2019/06/learning-flask-and-jinja2-manipulating.html' title='Learning Flask and Jinja2 - Manipulating Data'/><author><name>fdo</name><uri>http://www.blogger.com/profile/16882300714528613456</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhndsbgzepfJ0U5gXwY3zzRcGOqiMcblr09VzwWLCMA_waqC9FUthSCa8n91RwqW_kZXNo2si5UU3N5Ex6UJbYkcUpcJnxOQw6jPOBYuux7fomIpI0UUf8vOXyBT7hyuuE/s113/IMG_5942.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi5NlsZzSuJdgZk9WNWgCOXqbx4pOBNPsI4JN73oolch_SHkxmi4T8jHBYrHWI8wDBjrWQRndxrwpI2ximSdCKc7jcFhyX-fSmLlkm0qBU3D1-5giCZ1YhXzwHOyhrE6i5cu1b7YX1WTwg9/s72-c/Welcome_to_Console_Launch_Site.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8658731852844520209.post-5785309342843900885</id><published>2019-06-14T11:42:00.001-04:00</published><updated>2019-06-14T11:45:01.590-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="foreman"/><title type='text'>Getting Started with Foreman 101 - Vagrant CentOS7</title><content type='html'>&lt;div style=&quot;-en-clipboard: true;&quot;&gt;
&lt;span style=&quot;color: black; font-family: &amp;quot;times&amp;quot;; font-size: small; letter-spacing: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;&quot;&gt;One of the items I’ve been wanting to add to my toolbox was a bare metal solution. Goal here was to come up with solution to make the life of fellow colleagues easier. Previously, I built a PXE tool that will deploy ESXi VM and thought about extending this to deploy physical servers. Yeah I know we have AutoDeploy but it has its limitations. AutoDeploy doesn’t work for greenfields environments. It might work for capacity add’s but what if I manage many vCenters in different networks? We don&#39;t want to enable AutoDeploy everywhere you can imaging what would happen.&amp;nbsp;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style=&quot;color: black; font-family: &amp;quot;times&amp;quot;; font-size: small; letter-spacing: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div&gt;
&lt;span style=&quot;color: black; font-family: &amp;quot;times&amp;quot;; font-size: small; letter-spacing: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;&quot;&gt;We also use Nested Datacenter for development work and I was able to accomplish this using vRO, PowerShell and my TFTP/PXE solution. Thought about extending my tool to do bare metal but didn’t take long to conclude this was a bad idea so started researching for tools online. So spent next few weeks researching and narrowed down to potential candidates. The time I spent evaluating each solution, &amp;nbsp;I started to compile a list of nice to have:&lt;/span&gt;&lt;/div&gt;
&lt;ul&gt;
&lt;li&gt;&lt;div&gt;
&lt;span style=&quot;color: black; font-family: &amp;quot;times&amp;quot;; font-size: small; letter-spacing: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;&quot;&gt;easy to deploy and configure&lt;/span&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;&lt;div&gt;
&lt;span style=&quot;color: black; font-family: &amp;quot;times&amp;quot;; font-size: small; letter-spacing: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;&quot;&gt;rich in Rest API for integration purposes&lt;/span&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;&lt;div&gt;
&lt;span style=&quot;color: black; font-family: &amp;quot;times&amp;quot;; font-size: small; letter-spacing: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;&quot;&gt;plugins with third party tools is a big plus&lt;/span&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;&lt;div&gt;
&lt;span style=&quot;color: black; font-family: &amp;quot;times&amp;quot;; font-size: small; letter-spacing: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;&quot;&gt;UI would be nice&lt;/span&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;&lt;div&gt;
&lt;span style=&quot;color: black; font-family: &amp;quot;times&amp;quot;; font-size: small; letter-spacing: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;&quot;&gt;capable of provisioning Linux, Windows, ESXi&lt;/span&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;&lt;div&gt;
&lt;span style=&quot;--inversion-type-color: simple; caret-color: rgb(255, 255, 255); color: black; font-family: &amp;quot;times&amp;quot;;&quot;&gt;free, OpenSource&lt;/span&gt;&lt;span style=&quot;--inversion-type-color: simple; color: black; font-family: &amp;quot;times&amp;quot;;&quot;&gt;&amp;nbsp;is big plus&lt;/span&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li&gt;&lt;span style=&quot;--inversion-type-color: simple; color: black; font-family: &amp;quot;times&amp;quot;;&quot;&gt;can deploy to vCenter plus&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;div&gt;
&lt;span style=&quot;--inversion-type-color: simple; caret-color: rgb(255, 255, 255); color: black; font-family: &amp;quot;times&amp;quot;;&quot;&gt;etc...&lt;/span&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
So far the big runner up was Foreman.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;!--?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?--&gt;

&lt;br /&gt;
&lt;div&gt;
What is Foreman? “Foreman is a complete lifecycle management tool for physical and virtual servers. We give system administrators the power to easily automate repetitive tasks, quickly deploy applications, and proactively manage servers, on-premise or in the cloud.”&amp;nbsp;&lt;a href=&quot;https://www.theforeman.org/&quot;&gt;https://www.theforeman.org/&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgScffEsEsw-TyhgWJhosK8hLSYP7wlnngn6BoPH4RPFLLvku1XU2vpl9VQlqRZe0pkqqZkrWWMScdO02MLocOVUVmA32kJTOXj7Wil4m9vV-wxnMAyfpYml7P39PwNyxG2lIxJ33Wv0Yr3/s1600/Screen+Shot+2019-06-14+at+11.08.13+AM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;544&quot; data-original-width=&quot;1127&quot; height=&quot;154&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgScffEsEsw-TyhgWJhosK8hLSYP7wlnngn6BoPH4RPFLLvku1XU2vpl9VQlqRZe0pkqqZkrWWMScdO02MLocOVUVmA32kJTOXj7Wil4m9vV-wxnMAyfpYml7P39PwNyxG2lIxJ33Wv0Yr3/s320/Screen+Shot+2019-06-14+at+11.08.13+AM.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;div style=&quot;-en-clipboard: true;&quot;&gt;
&lt;b&gt;Initial Thought&lt;/b&gt; - After evaluating different solutions one thing I found extremely annoying was lack of documentation how simple installer do not work as advertised. I was actually impressed with the completeness of Foreman documentation and initial install. The Quickstart process was no joke, I literally got started in less than 15 mins on my first try, compared to this other XXXX solution where I was stuck for 4 days troubleshooting their automated install. My colleague figured out after getting help from the community but I was already turned off by the product. When I found Foreman was capable of provisioning to vCenter that was awesome. Didn&#39;t take me long to get addicted.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
My POC is MacBook with Vagrant and Virtual Box. Choice of OS platform is CentOS 7, but Foreman supports a wide variety of operating system. So far tested Centos and Ubuntu and they were both painless.
&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
If you don’t are not using Vagrant that is not an issue can just deploy your basic CentOS 7 VM and run the install.
&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
Let&#39;s Dive right into the setup process.
&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;!--?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?--&gt;

&lt;br /&gt;
&lt;h2&gt;
Deploying Vagrant/CentOS 7 with Foreman 1.22.0&lt;/h2&gt;
1.22.0 - latest version at day of this post&lt;br /&gt;
&lt;br /&gt;
&lt;!--?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?--&gt;

&lt;br /&gt;
&lt;div&gt;
Here is the config I added to my vagrantfile. Following code will deploy CentosVM and install Foreman with default configuration. Feel free to adjust the script, variables to meet your needs. Script_foreman is simply the yum update and the 5 commands to install Foreman. The rest is vagrant configuration. Note that hostname is a FQDN, which is required for Foreman install. Then update the IP address to match your network setting.&amp;nbsp;&lt;/div&gt;
&lt;br /&gt;
Vagrant Configuration File:&lt;br /&gt;
&lt;pre class=&quot;brush: py&quot;&gt;    $script_foreman = &amp;lt;&amp;lt;-SCRIPT
    sudo yum update -y
    sudo yum -y install https://yum.puppet.com/puppet6-release-el-7.noarch.rpm
    sudo yum -y install http://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
    sudo yum -y install https://yum.theforeman.org/releases/1.22/el7/x86_64/foreman-release.rpm
    sudo yum -y install foreman-installer
    sudo foreman-installer
    SCRIPT
    config.vm.define &quot;foreman&quot; do |fore|
        fore.vm.box = &quot;centos/7&quot;
        fore.vm.hostname = &quot;foreman.maki.com&quot;
        fore.vm.network  &quot;private_network&quot;, ip: &quot;192.168.57.70&quot;
        fore.vm.provider &quot;virtualbox&quot; do |vb|
            vb.memory= 4096
            vb.cpus = 4
        end
        fore.vm.provision &quot;shell&quot;, inline: $script_foreman
    end&lt;/pre&gt;
&lt;br /&gt;
Once ready &quot;vagrant up foreman&quot; and within minutes your server should be up and running.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgc3vRwtW7mdq4YWNghKXOkOkSCXU6YOVTQCsLAr_8eFHMsHcqE_7AaIePV1pB40gRy34UjDVfycXvwEI-DFt8deIblBSn43skrJr1GZkKpBPR-gSDS3kWCnyS1M0v6GqWkLePxMvz8YZse/s1600/Screen+Shot+2019-06-14+at+9.59.58+AM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;176&quot; data-original-width=&quot;579&quot; height=&quot;97&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgc3vRwtW7mdq4YWNghKXOkOkSCXU6YOVTQCsLAr_8eFHMsHcqE_7AaIePV1pB40gRy34UjDVfycXvwEI-DFt8deIblBSn43skrJr1GZkKpBPR-gSDS3kWCnyS1M0v6GqWkLePxMvz8YZse/s320/Screen+Shot+2019-06-14+at+9.59.58+AM.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;h3 style=&quot;clear: both; text-align: left;&quot;&gt;
Installing Foreman on any CentOS 7 Server&lt;/h3&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
This steps were straight from the Foreman website:&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;quickstart_os quickstart_os_rhel7 quickstart_os_el7&quot; style=&quot;background-color: white; box-sizing: border-box; color: #333333; font-family: &amp;quot;Open Sans&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 14px;&quot;&gt;
&lt;div style=&quot;box-sizing: border-box; margin-bottom: 10px;&quot;&gt;
From the clean Centos7 Server runn the following commands:&lt;/div&gt;
&lt;br /&gt;
&lt;figure class=&quot;highlight&quot; style=&quot;background-attachment: initial; background-clip: initial; background-image: initial; background-origin: initial; background-position: initial; background-repeat: initial; background-size: initial; box-sizing: border-box; margin: 0px;&quot;&gt;&lt;pre style=&quot;background-color: #2f2f2f; border-radius: 4px; border: 1px solid rgb(204, 204, 204); box-sizing: border-box; color: white; display: inline-block; font-family: FreeMono, monospace; height: auto; line-height: 14px; margin-bottom: 10px; max-width: 850px; overflow-wrap: break-word; overflow: auto; padding: 10px; position: relative; word-break: break-all;&quot;&gt;&lt;code class=&quot;language-bash&quot; data-lang=&quot;bash&quot; style=&quot;border-radius: 0px; box-sizing: border-box; color: inherit; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: inherit; padding: 0px; white-space: pre-wrap;&quot;&gt;&lt;span class=&quot;nb&quot; style=&quot;box-sizing: border-box; color: #71ff3d;&quot;&gt;sudo &lt;/span&gt;yum &lt;span class=&quot;nt&quot; style=&quot;box-sizing: border-box; color: #c6a4ff;&quot;&gt;-y&lt;/span&gt; install https://yum.puppetlabs.com/puppet5/puppet5-release-el-7.noarch.rpm&lt;/code&gt;&lt;/pre&gt;
&lt;/figure&gt;&lt;/div&gt;
&lt;div class=&quot;quickstart_os quickstart_os_el7&quot; style=&quot;background-color: white; box-sizing: border-box; color: #333333; font-family: &amp;quot;Open Sans&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 14px;&quot;&gt;
&lt;div style=&quot;box-sizing: border-box; margin-bottom: 10px;&quot;&gt;
Enable the EPEL (Extra Packages for Enterprise Linux) and the Foreman repos:&lt;/div&gt;
&lt;br /&gt;
&lt;figure class=&quot;highlight&quot; style=&quot;background-attachment: initial; background-clip: initial; background-image: initial; background-origin: initial; background-position: initial; background-repeat: initial; background-size: initial; box-sizing: border-box; margin: 0px;&quot;&gt;&lt;pre style=&quot;background-color: #2f2f2f; border-radius: 4px; border: 1px solid rgb(204, 204, 204); box-sizing: border-box; color: white; display: inline-block; font-family: FreeMono, monospace; height: auto; line-height: 14px; margin-bottom: 10px; max-width: 850px; overflow-wrap: break-word; overflow: auto; padding: 10px; position: relative; word-break: break-all;&quot;&gt;&lt;code class=&quot;language-bash&quot; data-lang=&quot;bash&quot; style=&quot;border-radius: 0px; box-sizing: border-box; color: inherit; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: inherit; padding: 0px; white-space: pre-wrap;&quot;&gt;&lt;span class=&quot;nb&quot; style=&quot;box-sizing: border-box; color: #71ff3d;&quot;&gt;sudo &lt;/span&gt;yum &lt;span class=&quot;nt&quot; style=&quot;box-sizing: border-box; color: #c6a4ff;&quot;&gt;-y&lt;/span&gt; install http://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
&lt;span class=&quot;nb&quot; style=&quot;box-sizing: border-box; color: #71ff3d;&quot;&gt;sudo &lt;/span&gt;yum &lt;span class=&quot;nt&quot; style=&quot;box-sizing: border-box; color: #c6a4ff;&quot;&gt;-y&lt;/span&gt; install https://yum.theforeman.org/releases/1.20/el7/x86_64/foreman-release.rpm&lt;/code&gt;&lt;/pre&gt;
&lt;/figure&gt;&lt;/div&gt;
&lt;h4 id=&quot;downloading-the-installer&quot; style=&quot;background-color: white; box-sizing: border-box; color: #333333; font-family: &amp;quot;Open Sans&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 18px; font-weight: 500; line-height: 1.1; margin-bottom: 10px; margin-top: 10px;&quot;&gt;
Downloading the installer&lt;/h4&gt;
&lt;div class=&quot;quickstart_os quickstart_os_rhel7 quickstart_os_el7&quot; style=&quot;background-color: white; box-sizing: border-box; color: #333333; font-family: &amp;quot;Open Sans&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 14px;&quot;&gt;
&lt;br /&gt;
&lt;figure class=&quot;highlight&quot; style=&quot;background-attachment: initial; background-clip: initial; background-image: initial; background-origin: initial; background-position: initial; background-repeat: initial; background-size: initial; box-sizing: border-box; margin: 0px;&quot;&gt;&lt;pre style=&quot;background-color: #2f2f2f; border-radius: 4px; border: 1px solid rgb(204, 204, 204); box-sizing: border-box; color: white; display: inline-block; font-family: FreeMono, monospace; height: auto; line-height: 14px; margin-bottom: 10px; max-width: 850px; overflow-wrap: break-word; overflow: auto; padding: 10px; position: relative; word-break: break-all;&quot;&gt;&lt;code class=&quot;language-bash&quot; data-lang=&quot;bash&quot; style=&quot;border-radius: 0px; box-sizing: border-box; color: inherit; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: inherit; padding: 0px; white-space: pre-wrap;&quot;&gt;&lt;span class=&quot;nb&quot; style=&quot;box-sizing: border-box; color: #71ff3d;&quot;&gt;sudo &lt;/span&gt;yum &lt;span class=&quot;nt&quot; style=&quot;box-sizing: border-box; color: #c6a4ff;&quot;&gt;-y&lt;/span&gt; install foreman-installer&lt;/code&gt;&lt;/pre&gt;
&lt;/figure&gt;&lt;/div&gt;
&lt;h4 id=&quot;running-the-installer&quot; style=&quot;background-color: white; box-sizing: border-box; color: #333333; font-family: &amp;quot;Open Sans&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 18px; font-weight: 500; line-height: 1.1; margin-bottom: 10px; margin-top: 10px;&quot;&gt;
Running the installer&lt;/h4&gt;
&lt;div style=&quot;background-color: white; box-sizing: border-box; color: #333333; font-family: &amp;quot;Open Sans&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 14px; margin-bottom: 10px;&quot;&gt;
The installation run is non-interactive, but the configuration can be customized by supplying any of the options listed in&amp;nbsp;&lt;code class=&quot;highlighter-rouge&quot; style=&quot;border-radius: 4px; box-sizing: border-box; color: black; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; padding: 2px 4px;&quot;&gt;foreman-installer --help&lt;/code&gt;, or by running&amp;nbsp;&lt;code class=&quot;highlighter-rouge&quot; style=&quot;border-radius: 4px; box-sizing: border-box; color: black; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; padding: 2px 4px;&quot;&gt;foreman-installer -i&lt;/code&gt;&amp;nbsp;for interactive mode. More examples are given in the&amp;nbsp;&lt;a href=&quot;https://www.theforeman.org/manuals/1.20/index.html#3.2.2InstallerOptions&quot; style=&quot;background: 0px 0px; box-sizing: border-box; color: #107fc9; text-decoration-line: none;&quot;&gt;Installation Options&lt;/a&gt;&amp;nbsp;section. Adding&amp;nbsp;&lt;code class=&quot;highlighter-rouge&quot; style=&quot;border-radius: 4px; box-sizing: border-box; color: black; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; padding: 2px 4px;&quot;&gt;-v&lt;/code&gt;&amp;nbsp;will disable the progress bar and display all changes. To run the installer, execute:&lt;/div&gt;
&lt;div class=&quot;quickstart_os quickstart_os_none quickstart_os_el7 quickstart_os_rhel7 quickstart_os_debian9 quickstart_os_ubuntu1804 quickstart_os_ubuntu1604&quot; style=&quot;background-color: white; box-sizing: border-box; color: #333333; font-family: &amp;quot;Open Sans&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Helvetica, Arial, sans-serif; font-size: 14px;&quot;&gt;
&lt;br /&gt;
&lt;figure class=&quot;highlight&quot; style=&quot;background-attachment: initial; background-clip: initial; background-image: initial; background-origin: initial; background-position: initial; background-repeat: initial; background-size: initial; box-sizing: border-box; margin: 0px;&quot;&gt;&lt;pre style=&quot;background-color: #2f2f2f; border-radius: 4px; border: 1px solid rgb(204, 204, 204); box-sizing: border-box; color: white; display: inline-block; font-family: FreeMono, monospace; height: auto; line-height: 14px; margin-bottom: 10px; max-width: 850px; overflow-wrap: break-word; overflow: auto; padding: 10px; position: relative; word-break: break-all;&quot;&gt;&lt;code class=&quot;language-bash&quot; data-lang=&quot;bash&quot; style=&quot;border-radius: 0px; box-sizing: border-box; color: inherit; font-family: Menlo, Monaco, Consolas, &amp;quot;Courier New&amp;quot;, monospace; font-size: inherit; padding: 0px; white-space: pre-wrap;&quot;&gt;&lt;span class=&quot;nb&quot; style=&quot;box-sizing: border-box; color: #71ff3d;&quot;&gt;sudo &lt;/span&gt;foreman-installer&lt;/code&gt;&lt;/pre&gt;
&lt;/figure&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
Reference Links:&amp;nbsp;&lt;a href=&quot;https://www.theforeman.org/manuals/1.20/quickstart_guide.html#QuickstartGuide&quot;&gt;https://www.theforeman.org/manuals/1.20/quickstart_guide.html#QuickstartGuide&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
Access Foreman from web browser. You can either add the FQDN to your hosts file or simply use the IP address.&lt;/div&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjfYh58Arrzoa2M9EEef1xJ1JnCJxGHjrLbmB88WCYqcSfG402WgFF87en7gohPDrYhY_ST9un6VFxv7Q2Zu60ulYdxsGwrthcBaM-niWHBvM7xtJUF04dwexAwGVg8_2MsPuSOdMj4504U/s1600/Screen+Shot+2019-06-14+at+10.06.28+AM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;392&quot; data-original-width=&quot;766&quot; height=&quot;163&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjfYh58Arrzoa2M9EEef1xJ1JnCJxGHjrLbmB88WCYqcSfG402WgFF87en7gohPDrYhY_ST9un6VFxv7Q2Zu60ulYdxsGwrthcBaM-niWHBvM7xtJUF04dwexAwGVg8_2MsPuSOdMj4504U/s320/Screen+Shot+2019-06-14+at+10.06.28+AM.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
Login using Credential...&lt;/div&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi86cvgD4XhHoppMemx9r2G9s6hnjFuDnveOqPZK1SwJhueBh6cwF3yUr0Y6ja_EK3yVwRnIHKWmfj6BDcDxxlaWK6hm2dXxgKsdOyETqJUSxspxTJq1u1qscQbNHumwpeBKXPNzEDO_7CP/s1600/Screen+Shot+2019-06-14+at+10.07.24+AM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;889&quot; data-original-width=&quot;1187&quot; height=&quot;239&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi86cvgD4XhHoppMemx9r2G9s6hnjFuDnveOqPZK1SwJhueBh6cwF3yUr0Y6ja_EK3yVwRnIHKWmfj6BDcDxxlaWK6hm2dXxgKsdOyETqJUSxspxTJq1u1qscQbNHumwpeBKXPNzEDO_7CP/s320/Screen+Shot+2019-06-14+at+10.07.24+AM.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
And that is for Foreman Installation.&lt;br /&gt;
&lt;br /&gt;
I am still learning the product and there is a long list of things I want to test so will be updating as I go. Most of my experiment will be against vCenter, once I get my hands on some physical gear will also test that.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;h3&gt;
Additional Info:&lt;/h3&gt;
&lt;div&gt;
Documentation:&amp;nbsp;&lt;a href=&quot;https://www.theforeman.org/documentation.html&quot;&gt;https://www.theforeman.org/documentation.html&lt;/a&gt;&amp;nbsp;Lot of good information. The community is extremely helpful and good place if you get stuck. Most of the answers can be found in Manual or Community old posts.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
Deploying ESXi with Foreman:&amp;nbsp;&lt;a href=&quot;https://theforeman.org/2018/08/deploying-esxi-through-foreman.html&quot;&gt;https://theforeman.org/2018/08/deploying-esxi-through-foreman.html&lt;/a&gt;. This was actually really cool project. Was one of the very first thing I did with Foreman.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;</content><link rel='replies' type='application/atom+xml' href='http://fdo-workspace.blogspot.com/feeds/5785309342843900885/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://fdo-workspace.blogspot.com/2019/06/getting-started-with-foreman-101.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/5785309342843900885'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/5785309342843900885'/><link rel='alternate' type='text/html' href='http://fdo-workspace.blogspot.com/2019/06/getting-started-with-foreman-101.html' title='Getting Started with Foreman 101 - Vagrant CentOS7'/><author><name>fdo</name><uri>http://www.blogger.com/profile/16882300714528613456</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhndsbgzepfJ0U5gXwY3zzRcGOqiMcblr09VzwWLCMA_waqC9FUthSCa8n91RwqW_kZXNo2si5UU3N5Ex6UJbYkcUpcJnxOQw6jPOBYuux7fomIpI0UUf8vOXyBT7hyuuE/s113/IMG_5942.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgScffEsEsw-TyhgWJhosK8hLSYP7wlnngn6BoPH4RPFLLvku1XU2vpl9VQlqRZe0pkqqZkrWWMScdO02MLocOVUVmA32kJTOXj7Wil4m9vV-wxnMAyfpYml7P39PwNyxG2lIxJ33Wv0Yr3/s72-c/Screen+Shot+2019-06-14+at+11.08.13+AM.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8658731852844520209.post-4385680885495013130</id><published>2019-03-29T11:26:00.000-04:00</published><updated>2019-03-29T11:40:37.749-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="vCenter"/><category scheme="http://www.blogger.com/atom/ns#" term="vRA"/><category scheme="http://www.blogger.com/atom/ns#" term="vrealize automation"/><title type='text'>vRealize Automation 7.5 - Dealing with Issues - Part 2</title><content type='html'>This actually a continuation of my previous post:&amp;nbsp;&lt;a href=&quot;https://fdo-workspace.blogspot.com/2019/03/vrealize-automation-75-dealing-with.html&quot; target=&quot;_blank&quot;&gt;vRealize Automation 7.5 - Dealing with Issues Deploying vRA, IaaS and SQL&lt;/a&gt;&amp;nbsp;I was finally able to complete a couple trainings on vRA 7.x. Now I have my instance of vRA 7.5 fully configured and deployed with some sample catalog items to Centos and Windows 2012R2 VMs. The Pluralsight training &quot;Getting Started with vRealize Automation 7&quot; is definitely a good start if you never had any exposure to vRA or want a refresher. Presenter does a good job covering most of the key points. However during the training I ran into some technical issues. Troubleshooting those issues definitely contributed in helping me understand the product better. Now I am looking for some more advanced tutorials or training materials to dive deeper into vRA.&lt;br /&gt;
&lt;br /&gt;
Back to topic of the post which is about couple more issues I encountered through out my vRA learning process:&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;
&lt;b&gt;AD User Account not showing&lt;/b&gt;&lt;/h2&gt;
&lt;br /&gt;
After your domain is added as a &quot;Directory&quot; under &lt;i&gt;Administration | Directory Management | Directories&lt;/i&gt; and synced, total number of domain users are shown under Synced Users. These domain user accounts should be consumable by vRA. It allow you to add any domain\user into Custom Groups or Business Groups, permissions, etc.&lt;br /&gt;
&lt;br /&gt;
In my screenshot I have the default local domain and the second domain with 241 users synched.&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhdiqNL5VRns42QaXV6qaZVTE3EKX00A8DcoYdCcubvSUHLte7WasmWA4ZJtHY8bkXS1Z8z1wD1sEyf8zt0z9a_of-A4zn5PTsopMV-U5EmbH1PwhgKeavfV2p_1qvxdKeISuO5tlv0m8pH/s1600/Screen+Shot+2019-03-29+at+10.26.12+AM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;292&quot; data-original-width=&quot;1338&quot; height=&quot;86&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhdiqNL5VRns42QaXV6qaZVTE3EKX00A8DcoYdCcubvSUHLte7WasmWA4ZJtHY8bkXS1Z8z1wD1sEyf8zt0z9a_of-A4zn5PTsopMV-U5EmbH1PwhgKeavfV2p_1qvxdKeISuO5tlv0m8pH/s400/Screen+Shot+2019-03-29+at+10.26.12+AM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
During this exercise, I was trying to a new AD user to a Business Group and the account was not found because of the two following reasons:&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;h3 style=&quot;clear: both; text-align: left;&quot;&gt;
New Account was created an AD and vRA is not aware of it&lt;/h3&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
If you created a new user account is created in your AD, vRA is not aware of it unless is synced. Directory synch can be performed manually by click on &quot;&lt;b&gt;Sync Now&lt;/b&gt;&quot; or wait until the next scheduled synch if configured.&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;h3 style=&quot;clear: both; text-align: left;&quot;&gt;
Account is not new but still not showing in vRA&lt;/h3&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
The other common scenario is when a vRA cannot find a user account, you are sure that the user exist in AD and is not a new account. This is usually because during vRA Directory configuration the user CNs configured does not include the user you are looking for.&amp;nbsp;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
Simple example is during initial configuration you decided to configure vRA to sync with&amp;nbsp; &lt;b&gt;CN=users,DC=example,DC=com&lt;/b&gt;&amp;nbsp; but the user you looking for is part of &lt;b&gt;CD=admins,DC=example,DC=com.&amp;nbsp;&lt;/b&gt;&amp;nbsp;Solution is just to specify/add another DNs.&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
Under: Administration | Directories | click on directory name you wish to reconfigure&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
- Click Sync Settings&amp;nbsp;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
- Click Users&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
- Here you add other CNs,&amp;nbsp; once done simply Save and Sync.&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;b&gt;Notice&lt;/b&gt; in my example: I originally had &lt;i&gt;CN=users,DC=domain,DC=com&lt;/i&gt;. Then I added the &lt;i&gt;DC=domain,DC=com&lt;/i&gt;, this will scan your entire AD for users. This is an extremely lazy way to do things and is not really recommended in production. I have a CN with a &lt;b&gt;&lt;i&gt;blank space&lt;/i&gt;&lt;/b&gt; in the name and couldn&#39;t figure out how add it to the list. Will update once I figure out.&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi_YihjZ1Tjr11rAtHMdsjcu4Jr7N3M19RyVeNn1UJGWP303zUykbobeb3e9W56-seWut-Eh8oKWW9halGUWB2QTsDxN7N5tUa6f_KTcIh_vhD5OQ2u3NGzUTGC5XTvjSo_TKfQ03IJTgCB/s1600/Screen+Shot+2019-03-29+at+10.39.49+AM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;373&quot; data-original-width=&quot;1340&quot; height=&quot;111&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi_YihjZ1Tjr11rAtHMdsjcu4Jr7N3M19RyVeNn1UJGWP303zUykbobeb3e9W56-seWut-Eh8oKWW9halGUWB2QTsDxN7N5tUa6f_KTcIh_vhD5OQ2u3NGzUTGC5XTvjSo_TKfQ03IJTgCB/s400/Screen+Shot+2019-03-29+at+10.39.49+AM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;h2 style=&quot;clear: both; text-align: left;&quot;&gt;
VM templates not showing when designing blueprints&lt;/h2&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
Another common mistake is when creating VM clone Blueprints the template you wish to use is not shown in the Template list. If you are stuck in this scenario make sure you check the following few items:&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjq2j0bVHRdJwzd58nOFQO5nG_zEVDxc567cSj2fgeIUdxle_8hXx3HUAGiZ5qmqQ4Kv21qPZmpr0sT8CC6fcOrq1RdXVKpLWpoB5U3qexTxUw-wpA7Phy7tx248p9BEvL5R_6RjKSLVagu/s1600/Screen+Shot+2019-03-29+at+10.48.00+AM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;752&quot; data-original-width=&quot;1185&quot; height=&quot;203&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjq2j0bVHRdJwzd58nOFQO5nG_zEVDxc567cSj2fgeIUdxle_8hXx3HUAGiZ5qmqQ4Kv21qPZmpr0sT8CC6fcOrq1RdXVKpLWpoB5U3qexTxUw-wpA7Phy7tx248p9BEvL5R_6RjKSLVagu/s320/Screen+Shot+2019-03-29+at+10.48.00+AM.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
1 - &lt;b&gt;Make sure the vm you are using as a template was converted to VM Template&lt;/b&gt;. In my environment, vm template is just a regular virtual machine to clone from and is not usually converted to a VM Template. Since vRA requires the images to be a template, right click on your target vm, from the menu select Template | Clone or Convert to Template&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgAMkePe1KxXyQRdzT4C71BDN6yBzAgOsP_u97O1ZEJoL1RhNiQmSr8CjvLhERDVT5jmxat4XEVoOH9Qg8Hb6NToAbKz4DS18I3m_zrRyX8n6lg6z4uuKwuxPZz-9EaLwk0qj9Ktd8PIAD0/s1600/Screen+Shot+2019-03-29+at+10.53.35+AM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;86&quot; data-original-width=&quot;452&quot; height=&quot;75&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgAMkePe1KxXyQRdzT4C71BDN6yBzAgOsP_u97O1ZEJoL1RhNiQmSr8CjvLhERDVT5jmxat4XEVoOH9Qg8Hb6NToAbKz4DS18I3m_zrRyX8n6lg6z4uuKwuxPZz-9EaLwk0qj9Ktd8PIAD0/s400/Screen+Shot+2019-03-29+at+10.53.35+AM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
2 - &lt;b&gt;Make sure the Template is in the right cluster / endpoint.&lt;/b&gt; If your vCenter has multiple clusters and during configuration you selected specific cluster for vRA consumption make sure your template is places there. To double check go to Fabric Group:&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;b&gt;&lt;i&gt;Infrastructure | Endpoints | Fabric Groups&lt;/i&gt;&lt;/b&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;b&gt;&lt;i&gt;&lt;br /&gt;&lt;/i&gt;&lt;/b&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
In my example I had configured 2 different vCenters as endpoints, one of my vCenters have multiple clusters. I had to move the template to the selected cluster.&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj9Zw9bhxisZK-QYIeNM6kZe8usPPFAqsbZLXEy4bKqrnMSnjUrAzGPaGbv24_v1-bLohP8i6-gzj-BItx1rbtctRTfwrucDRNkFkMTS4gd9ctiEAouP4wsE78-Mk7J_Zt5vabtKtasRgzB/s1600/Screen+Shot+2019-03-29+at+11.01.33+AM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;738&quot; data-original-width=&quot;1092&quot; height=&quot;270&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj9Zw9bhxisZK-QYIeNM6kZe8usPPFAqsbZLXEy4bKqrnMSnjUrAzGPaGbv24_v1-bLohP8i6-gzj-BItx1rbtctRTfwrucDRNkFkMTS4gd9ctiEAouP4wsE78-Mk7J_Zt5vabtKtasRgzB/s400/Screen+Shot+2019-03-29+at+11.01.33+AM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
3 - &lt;b&gt;Finally Sync the resources&lt;/b&gt;, vRA will sync vCenter object on its own schedule. If you need it immediately must manually recollect data. To do so go to:&lt;b&gt; Infrastructure | Compute Resources | Compute Resources&lt;/b&gt; | right click on the cluster your template resides and click &quot;&lt;b&gt;Data Collection&lt;/b&gt;&quot;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhOrgFVv9YPvUdXt-51qGMZATUZ7h5mVGHxFQsscwKvEUwuFoXyVs4cXDs3El09TxdlrPbUEAfN1UWUNzgkVPIf_0ObMW-6U1mO1aImdILcYYKegltrqGyXNraJPpWtzW1egLa1Vy1Tr4bE/s1600/Screen+Shot+2019-03-29+at+11.07.51+AM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;464&quot; data-original-width=&quot;949&quot; height=&quot;195&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhOrgFVv9YPvUdXt-51qGMZATUZ7h5mVGHxFQsscwKvEUwuFoXyVs4cXDs3El09TxdlrPbUEAfN1UWUNzgkVPIf_0ObMW-6U1mO1aImdILcYYKegltrqGyXNraJPpWtzW1egLa1Vy1Tr4bE/s400/Screen+Shot+2019-03-29+at+11.07.51+AM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
Once the&lt;b&gt; Data Collection&lt;/b&gt; window launches click &lt;b&gt;&quot;Request Now&quot;&lt;/b&gt; under Inventory to initiate manual sync. Once completed you can double check again to see if template shows in your blueprint.&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhZRsskpyYD8F2iSqnqsmmacXRxH9xiPbLdYCtqZIJEMLjhIbiPDd-_kMiYB9vUwmoBQ3Dzh5tabFmLMiITh8zvqVivhC3XtH8ukEaB9o52AS-5yOnrkQjRJxEHnW4cbWF-AlApszkJXaWg/s1600/Screen+Shot+2019-03-29+at+11.21.52+AM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;737&quot; data-original-width=&quot;827&quot; height=&quot;285&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhZRsskpyYD8F2iSqnqsmmacXRxH9xiPbLdYCtqZIJEMLjhIbiPDd-_kMiYB9vUwmoBQ3Dzh5tabFmLMiITh8zvqVivhC3XtH8ukEaB9o52AS-5yOnrkQjRJxEHnW4cbWF-AlApszkJXaWg/s320/Screen+Shot+2019-03-29+at+11.21.52+AM.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
This is all I got for now.&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
I am hoping dive deeper into vRA as time permits and start designing some more advanced Blueprints. If any one have have pointers to advance vRA tutorials feel to share in the comments section.&amp;nbsp;&lt;/div&gt;
&lt;br /&gt;</content><link rel='replies' type='application/atom+xml' href='http://fdo-workspace.blogspot.com/feeds/4385680885495013130/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://fdo-workspace.blogspot.com/2019/03/vrealize-automation-75-dealing-with_29.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/4385680885495013130'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/4385680885495013130'/><link rel='alternate' type='text/html' href='http://fdo-workspace.blogspot.com/2019/03/vrealize-automation-75-dealing-with_29.html' title='vRealize Automation 7.5 - Dealing with Issues - Part 2'/><author><name>fdo</name><uri>http://www.blogger.com/profile/16882300714528613456</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhndsbgzepfJ0U5gXwY3zzRcGOqiMcblr09VzwWLCMA_waqC9FUthSCa8n91RwqW_kZXNo2si5UU3N5Ex6UJbYkcUpcJnxOQw6jPOBYuux7fomIpI0UUf8vOXyBT7hyuuE/s113/IMG_5942.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhdiqNL5VRns42QaXV6qaZVTE3EKX00A8DcoYdCcubvSUHLte7WasmWA4ZJtHY8bkXS1Z8z1wD1sEyf8zt0z9a_of-A4zn5PTsopMV-U5EmbH1PwhgKeavfV2p_1qvxdKeISuO5tlv0m8pH/s72-c/Screen+Shot+2019-03-29+at+10.26.12+AM.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8658731852844520209.post-6204390143429707360</id><published>2019-03-22T17:18:00.002-04:00</published><updated>2019-03-22T21:17:33.570-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Installation"/><category scheme="http://www.blogger.com/atom/ns#" term="SQL"/><category scheme="http://www.blogger.com/atom/ns#" term="vRA"/><title type='text'>vRealize Automation 7.5 - Dealing with Issues Deploying vRA, IaaS and SQL</title><content type='html'>vRealize Automation 7.5 is like a hot topic now. There is all sort of exciting news about it, all kinda of cool things it can do so couldn&#39;t help but check it out. Last year after VMworld 2018, I did attempt deploying the vRA 7.x but didn&#39;t get to far with the project. I have no experience with vRA but I am comfortable with vRealize Orchestrator (vRO).&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Where to start? &lt;/b&gt;Well if you are vExpert, you should have a 1 year of free PluralSight Access. There is a good &quot;Getting Started with vRealize Automation 7&quot; which is bit old but concept is the same. I am using the training as my guide. Otherwise, there are plenty online tutorials on how to install vRA 7.x there are also YouTube videos.&lt;br /&gt;
&lt;br /&gt;
I have been stuck in the first Chapter 1- Module: &quot;A Simple Installation&quot; which is 15min long for 3 days now. BTW, I have real work to do and vRA is only in my spare time. The goal of this post is not to show step by step how to do click thru the installation wizard but to deal with some the issues I came across.&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;
&lt;b&gt;vRA Appliance Root Account Lockout&lt;/b&gt;&lt;/h2&gt;
I am a fast typer and not always accurate so 3 times before locking out is not good enough. Since this appliance is for learning purposes, disabling root account lockout is a must. Once you are locked out, only options are to wait for it to auto unlock, deploy a new one or log into single user mode and reset. To prevent this issue once and for all disable the lockout policy.&lt;br /&gt;
&lt;br /&gt;
&lt;h3&gt;
Boot into Single User Mode&lt;/h3&gt;
Reboot your vRA appliance and console to it. Once you see the boot screen select the second option and enter &#39;e&#39; to edit.&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh3iTcvAOUSEoOxH0Ej467uAfMmTORF0rZif0pRSrEEtObcYziDLGV73CWa1n8I5LinPn1pv7Sn6VpJLR7ScKru_wDMyguEggw5Bdg1WDtyhN1tyfQ2dTF1_SaTIIXl6DrtjWGjcxDSzUQ2/s1600/Screen+Shot+2019-03-22+at+3.37.35+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;640&quot; data-original-width=&quot;1095&quot; height=&quot;233&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh3iTcvAOUSEoOxH0Ej467uAfMmTORF0rZif0pRSrEEtObcYziDLGV73CWa1n8I5LinPn1pv7Sn6VpJLR7ScKru_wDMyguEggw5Bdg1WDtyhN1tyfQ2dTF1_SaTIIXl6DrtjWGjcxDSzUQ2/s400/Screen+Shot+2019-03-22+at+3.37.35+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
Scroll to the end of the line and append:&amp;nbsp; &amp;nbsp;&lt;b&gt;rw init=/bin/bash&lt;/b&gt;&lt;br /&gt;
&lt;b&gt;&lt;br /&gt;&lt;/b&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgK8umz5uqttn1LlK5MKqTAQsZWV-2Yub073OF5HgankCC8-8m4UNWK4rWg2Kevew7oGcDB41LolyzHBWmsXHuNBk5S32aygA5TUsJEx8Xyx9gVSemc8WLJfy3XbZ0DwelQ4Oj8ye4E8_wS/s1600/Screen+Shot+2019-03-22+at+3.39.02+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;300&quot; data-original-width=&quot;1106&quot; height=&quot;107&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgK8umz5uqttn1LlK5MKqTAQsZWV-2Yub073OF5HgankCC8-8m4UNWK4rWg2Kevew7oGcDB41LolyzHBWmsXHuNBk5S32aygA5TUsJEx8Xyx9gVSemc8WLJfy3XbZ0DwelQ4Oj8ye4E8_wS/s400/Screen+Shot+2019-03-22+at+3.39.02+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
Once done &lt;b&gt;ESC &lt;/b&gt;to go back to menu and &lt;b&gt;&#39;b&#39; &lt;/b&gt;to boot&lt;br /&gt;
&lt;br /&gt;
&lt;h3&gt;
Unlocking Root Account&lt;/h3&gt;
&lt;br /&gt;
To check if account is locked:&lt;br /&gt;
&lt;blockquote class=&quot;tr_bq&quot;&gt;
# pam_tally2 --user root&lt;/blockquote&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgZQiUhjBpm8pQqGPlzj6vImim5Pzr4hjaYI1QjoJF8_kOy2tXozyawsQroYh7NxiGeKDAxdm5MsVq5jbiqYA_Yyoz3Ti7N_98hT9C4VRgJN-w454pKBzwvbXp6lTXFhboYzg5FDFnwqgmO/s1600/Screen+Shot+2019-03-22+at+3.40.53+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;336&quot; data-original-width=&quot;1025&quot; height=&quot;130&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgZQiUhjBpm8pQqGPlzj6vImim5Pzr4hjaYI1QjoJF8_kOy2tXozyawsQroYh7NxiGeKDAxdm5MsVq5jbiqYA_Yyoz3Ti7N_98hT9C4VRgJN-w454pKBzwvbXp6lTXFhboYzg5FDFnwqgmO/s400/Screen+Shot+2019-03-22+at+3.40.53+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
To reset&lt;br /&gt;
&lt;blockquote class=&quot;tr_bq&quot;&gt;
#pam_tally2 --user root --reset&lt;/blockquote&gt;
&lt;h3&gt;
Disabling Root Account Lockout&lt;/h3&gt;
While you are here resetting the root account might as well disable the lockout policy. (This is only for your Dev/Testing purposes)&lt;br /&gt;
&lt;br /&gt;
Use vi to edit /etc/pam.d/common-auth&lt;br /&gt;
&lt;blockquote class=&quot;tr_bq&quot;&gt;
&lt;br /&gt;
# vi /etc/pam.d/common-auth&lt;/blockquote&gt;
Enter &#39;&lt;b&gt;i&lt;/b&gt;&#39; to enter edit mode, once you comment out the line with &quot;&lt;b&gt;pam_tally.2.so deny=3...&lt;/b&gt;&quot;&lt;br /&gt;
Hit &lt;b&gt;ESC&lt;/b&gt;&amp;nbsp; type &quot;&lt;b&gt;:wq!&lt;/b&gt;&quot; to save&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiX7k4g6zVd_Y5mn8BLhhoKXT6fUMRYbwwY9dY3tOFEhcpgbzItFg6Gex7aCtJUPUrMZ-s7yh4jtVNlNhs7iBu1jcRqt9YUP2D1lUb769cmHI-8CUNBh2n5hwOFAe-G9OBf4_-F5dKN3MYY/s1600/Screen+Shot+2019-03-22+at+3.46.37+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;529&quot; data-original-width=&quot;1137&quot; height=&quot;185&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiX7k4g6zVd_Y5mn8BLhhoKXT6fUMRYbwwY9dY3tOFEhcpgbzItFg6Gex7aCtJUPUrMZ-s7yh4jtVNlNhs7iBu1jcRqt9YUP2D1lUb769cmHI-8CUNBh2n5hwOFAe-G9OBf4_-F5dKN3MYY/s400/Screen+Shot+2019-03-22+at+3.46.37+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
Now you reboot the appliance.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;
Reset the vRA Installation Wizard&amp;nbsp;&lt;/h2&gt;
If for whatever reason you made a mistake, browser closed or something else when wrong and when you go back to your https://vra_appliance_ip:5480 the installation wizard is not there. Fortunately deploying new OVA is not the only option. There is a way to bring that wizard back. I learned about this while dealing with the screen below.&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj7jHP5lLoXUK8-S1fdGbDnbhNVqunQBnJ8l-L67-G7leANDqT00E7tfrxk70MjiU9tVInBcaaQfZENCoSFAglOlR2oJL6Ji2sEUEfoWwVmovD2wSWHSCbsp6oLkm5h6RzsCb2EO3CqlZ8a/s1600/Screen+Shot+2019-03-22+at+3.49.01+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;693&quot; data-original-width=&quot;1101&quot; height=&quot;201&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj7jHP5lLoXUK8-S1fdGbDnbhNVqunQBnJ8l-L67-G7leANDqT00E7tfrxk70MjiU9tVInBcaaQfZENCoSFAglOlR2oJL6Ji2sEUEfoWwVmovD2wSWHSCbsp6oLkm5h6RzsCb2EO3CqlZ8a/s320/Screen+Shot+2019-03-22+at+3.49.01+PM.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;h3&gt;
Bring Back vRA Installation Wizard - Method 1&lt;/h3&gt;
Once you are logged into your vRA appliance via SSH or console edit the &quot;/etc/vcac/vami.ini&quot;&lt;br /&gt;
&lt;blockquote class=&quot;tr_bq&quot;&gt;
Change the &quot;start_wizard&quot; from false to true&lt;/blockquote&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiYAgMpkwc0zL4_ZrbpG2UFQNgWYfhQ5nfRRAzABGqHsdrMLsPJonA_aOiiHwaha8MP3U2qYiL-fmIYrDBf9eggeIT6u_brV1iL57A6eaFeJ-6gdQxWYdVuQzV9zM-w7c2382DPMuQra6-H/s1600/Screen+Shot+2019-03-22+at+3.58.48+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;257&quot; data-original-width=&quot;815&quot; height=&quot;100&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiYAgMpkwc0zL4_ZrbpG2UFQNgWYfhQ5nfRRAzABGqHsdrMLsPJonA_aOiiHwaha8MP3U2qYiL-fmIYrDBf9eggeIT6u_brV1iL57A6eaFeJ-6gdQxWYdVuQzV9zM-w7c2382DPMuQra6-H/s320/Screen+Shot+2019-03-22+at+3.58.48+PM.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;
Restart vami-lighttp service&lt;/div&gt;
&lt;blockquote class=&quot;tr_bq&quot;&gt;
# service-lighttp restart command&lt;/blockquote&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgCf4wzo0CbpaFAJBb-IVbYXA0Un6UI2IVfpXMV7muiZsuJDhXEpVo9LMe5V-U1y9Oj97fOnjhl5kRrg7T_LfPUQWvn7lII3-8jW2eyM3fTt5D2Ilw7YcHa1LSLxtZ-TyQ4gOmgkhK2M7Iq/s1600/Screen+Shot+2019-03-22+at+3.59.58+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;166&quot; data-original-width=&quot;898&quot; height=&quot;59&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgCf4wzo0CbpaFAJBb-IVbYXA0Un6UI2IVfpXMV7muiZsuJDhXEpVo9LMe5V-U1y9Oj97fOnjhl5kRrg7T_LfPUQWvn7lII3-8jW2eyM3fTt5D2Ilw7YcHa1LSLxtZ-TyQ4gOmgkhK2M7Iq/s320/Screen+Shot+2019-03-22+at+3.59.58+PM.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
Now you should see the wizard if you log back into https://vra_appliance_ip:5480&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;h3&gt;
Bring Back vRA Installation Wizard - Method 2&amp;nbsp;&lt;/h3&gt;
&lt;div&gt;
Use the&amp;nbsp;&lt;b&gt;vcac-vami &lt;/b&gt;command to reset:&lt;/div&gt;
&lt;blockquote class=&quot;tr_bq&quot;&gt;
# /usr/sbin/vcac-vami installation-wizard activate&lt;br /&gt;
yes --&amp;gt; Confirm&lt;/blockquote&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjpkZHudbnZSV5IsNaD1EDk9Xg9m2J89oY0T3LEQTBgQl3GW76KR15YGRICjHR3lS36eOdAVPfACO2Dgl3yQkfC768TcMC5k16wRyIHLEttFgWAD0gxrJN4ZcWOzStv_CyEWw5bc83mug0N/s1600/Screen+Shot+2019-03-22+at+4.02.32+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;461&quot; data-original-width=&quot;857&quot; height=&quot;172&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjpkZHudbnZSV5IsNaD1EDk9Xg9m2J89oY0T3LEQTBgQl3GW76KR15YGRICjHR3lS36eOdAVPfACO2Dgl3yQkfC768TcMC5k16wRyIHLEttFgWAD0gxrJN4ZcWOzStv_CyEWw5bc83mug0N/s320/Screen+Shot+2019-03-22+at+4.02.32+PM.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;
Log back into https://vra_appliance_ip:5480 and try again.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;h2&gt;
&lt;br /&gt;Addressing Single Sign-On Page Issue&lt;/h2&gt;
&lt;div class=&quot;&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
Unfortunately there is no easy way for this one. I was stuck here for sometime. The install process does have an option to not build the IAAS (Infrastructure as a Service) server but I think skipping that is also a factor to this problem. So I do recommend building the IAAS server. After that try again. Make sure you go back to the wizard and check the box to install IAAS server.&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgX8XPKDDdxJcCJ6manlsMgSAhQL8wgnvK28_R2Wy5wgii4KyiGmZFsVeFBd7wRZgcQxMHhoQ5lv6EVgX1O5Un1LPKxmzp3nCyaKRYbso1y9GKrFiW6xe_LRk1-_PrzXmGshBziwofDeS7N/s1600/Screen+Shot+2019-03-22+at+3.49.01+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;693&quot; data-original-width=&quot;1101&quot; height=&quot;201&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgX8XPKDDdxJcCJ6manlsMgSAhQL8wgnvK28_R2Wy5wgii4KyiGmZFsVeFBd7wRZgcQxMHhoQ5lv6EVgX1O5Un1LPKxmzp3nCyaKRYbso1y9GKrFiW6xe_LRk1-_PrzXmGshBziwofDeS7N/s320/Screen+Shot+2019-03-22+at+3.49.01+PM.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: justify;&quot;&gt;
&lt;b&gt;Error Message&lt;/b&gt;:&amp;nbsp;&lt;span style=&quot;background-color: white; color: #666666; font-family: proxima-nova, Arial, sans-serif; font-size: 14px;&quot;&gt;PreparedStatementCallback; SQL [INSTER INTO installation_wizard_params (node, page, role, instance, param, value, sequence) values (?, ?, ?, ?, ?, ?, ?)]; ERROR: insert or update on table &quot;installation_wizard_params&quot; violates foreign key constraint &quot;installation wizard params pk&quot; Detail: Kye (node)=(cafe.node.128400245.15991) is not present in table &quot;cluster_nodes&quot;.; nested exception is org.postgresql.util.PSQLException: ERROR: insert or update on table &quot;installation_wizard_params&quot; violates foreign key constraints &quot;installation_wizard_params_pk&quot; Detail: Key (node)=(cafe.node.128400245.15991) is not present in table &quot;cluster_nodes&quot;.&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;b&gt;Things to Try:&lt;/b&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;
&lt;/div&gt;
&lt;ul&gt;
&lt;li&gt;Deploy the IAAS server, I deployed a Windows 2012R2&lt;/li&gt;
&lt;ul&gt;
&lt;li&gt;Joined server to the Domain&lt;/li&gt;
&lt;li&gt;Made sure DNS is fully working forward and reverse resolution from and to vRA&lt;/li&gt;
&lt;li&gt;Time must be correct even thought the wizard will check for you&lt;/li&gt;
&lt;li&gt;Install the Management Agent installer from the Wizard, if done properly your IAAS server will be discovered by the wizard.&lt;/li&gt;
&lt;/ul&gt;
&lt;li&gt;Make sure the password is good, something like &quot;VMware123!&quot; which works for me.&lt;/li&gt;
&lt;li&gt;If you did all that and the problem is still there you are out of luck, that happened to me.&lt;/li&gt;
&lt;li&gt;Delete the vRA appliance and deploy fresh new one&lt;/li&gt;
&lt;li&gt;Re-Install the Management Agent installer on the IAAS&lt;/li&gt;
&lt;ul&gt;
&lt;li&gt;Uninstall the agent - still pointing to old vRA&lt;/li&gt;
&lt;li&gt;Revert Snapshot if you have one&lt;/li&gt;
&lt;li&gt;Re-Install the Agent and point to new vRA&lt;/li&gt;
&lt;/ul&gt;
&lt;/ul&gt;
&lt;br /&gt;
&lt;div&gt;
Almost positive this should fix the problem.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;h2&gt;
Microsoft SQL Server ISSUE&lt;/h2&gt;
&lt;div&gt;
I wasn&#39;t sure if I was getting tired of vRA or the training video, this time I was stuck at the SQL Server screen. I failed the validation miserably, according to the error message it needs a SQL Server. I was under the impression it would at least load the SQL Express version for me. Sight... Video guy could have at least said something. Just kidding... Took a break from this, got fresh cup of coffee to refresh my mind and body. Several hours later...&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhGw6hOIPiFeDlIMF7h7-3pT3mAj-kfCpMcMXhrdUz7nmTbfYHPKa581V17FtelEKQj45s8LShsJi8hHRs7cWyWdCOSigD7cfTyRIL3HJi2KY9uyWRa0oIcgyfMULbvaNPXfdepxiVvNsIa/s1600/Screen+Shot+2019-03-22+at+4.19.08+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;637&quot; data-original-width=&quot;1087&quot; height=&quot;233&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhGw6hOIPiFeDlIMF7h7-3pT3mAj-kfCpMcMXhrdUz7nmTbfYHPKa581V17FtelEKQj45s8LShsJi8hHRs7cWyWdCOSigD7cfTyRIL3HJi2KY9uyWRa0oIcgyfMULbvaNPXfdepxiVvNsIa/s400/Screen+Shot+2019-03-22+at+4.19.08+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
Did browsing and found the &lt;a href=&quot;https://docs.vmware.com/en/vRealize-Automation/7.5/vrealize-automation-75-installation-and-configuration.pdf&quot; target=&quot;_blank&quot;&gt;vRA 7.5 Installation Guide&lt;/a&gt;&amp;nbsp;- Requirement are in page 28. Following section is copied some info from the guide.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
IaaS SQL Server Host
A Windows server that hosts the IaaS SQL database must meet certain requirements.&amp;nbsp;&lt;/div&gt;
&lt;div&gt;
&lt;ul&gt;
&lt;li&gt;Your SQL Server can reside on one of your IaaS Windows servers, or on a separate host.&amp;nbsp;&lt;/li&gt;
&lt;li&gt;When hosted
together with IaaS components, these requirements are in addition to those for all IaaS Windows servers.&amp;nbsp;&lt;/li&gt;
&lt;li&gt;This release of vRealize Automation does not support the default SQL Server 2016 130 compatibility
mode. If you separately create an empty SQL Server 2016 database for use with IaaS, use 100 or
120 compatibility mode.
If you create the database through the vRealize Automation installer, compatibility is already
configured.&amp;nbsp;&lt;/li&gt;
&lt;li&gt;When hosted together with IaaS components, configure Java.&lt;/li&gt;
&lt;ul&gt;
&lt;li&gt;Install 64-bit Java 1.8 update 181 or later. Do not use 32-bit.
The JRE is enough.&amp;nbsp;&lt;/li&gt;
&lt;li&gt;You do not need the full JDK.
n Set the JAVA_HOME environment variable to the Java installation folder.
n Verify that %JAVA_HOME%\bin\java.exe is available.&amp;nbsp;&lt;/li&gt;
&lt;/ul&gt;
&lt;li&gt;Enable TCP/IP protocol for SQL Server.&lt;/li&gt;
&lt;li&gt;&amp;nbsp;SQL Server includes a model database that is the template for all databases created on the SQL
instance.&amp;nbsp;&lt;/li&gt;
&lt;li&gt;For IaaS to install correctly, do not change the model database size.&lt;/li&gt;
&lt;li&gt;Usually, the server needs more hardware than the minimums described in IaaS Windows Servers.&amp;nbsp;&lt;/li&gt;
&lt;/ul&gt;
&lt;/div&gt;
&lt;h3&gt;
Installing/Configuring your SQL Server&lt;/h3&gt;
&lt;div&gt;
I am installing SQL Server Express on my IAAS server, but you can certainly build a separate server.&lt;/div&gt;
&lt;div&gt;
&lt;ul&gt;
&lt;li&gt;Download SQL Server Express 2017 which is the latest version available for download on day of this article &lt;a href=&quot;https://www.microsoft.com/en-us/sql-server/sql-server-downloads&quot; target=&quot;_blank&quot;&gt;LINK&lt;/a&gt;&amp;nbsp;. Whatever version you pick make sure is compatible with vRA.&lt;/li&gt;
&lt;li&gt;Download SQL Server Management Studio Express &lt;a href=&quot;https://docs.microsoft.com/en-us/sql/ssms/download-sql-server-management-studio-ssms?view=sql-server-2017&quot; target=&quot;_blank&quot;&gt;LINK&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;Download install JAVA 64-bit JRE. I am a big fan of &lt;a href=&quot;https://chocolatey.org/&quot; target=&quot;_blank&quot;&gt;Chocolatey&lt;/a&gt;. Loaded my JRE and tools from via command line.&lt;/li&gt;
&lt;/ul&gt;
&lt;h4&gt;
Install SQL Server Express 2017, SQL Management Studio and JAVA&lt;/h4&gt;
&lt;/div&gt;
&lt;div&gt;
Click on the SQL Express 2017 binary to start installation. Make sure you choose Custom, I did Basic and left out bunch of required components.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgcLqBbnwmUDp1t9o_KRNW_agQr-Wm1xC3q3AoMd-tLRle-0hRbFjrJumnj-OI3RmYjMeNJdOHWnRqddqv3p_gDTTe5CgexGEAnHrn9mhFrEnrlS0Bx37UkM6zUqxswsjCZFi70Jdur1oZ6/s1600/Screen+Shot+2019-03-22+at+4.42.18+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;627&quot; data-original-width=&quot;789&quot; height=&quot;317&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgcLqBbnwmUDp1t9o_KRNW_agQr-Wm1xC3q3AoMd-tLRle-0hRbFjrJumnj-OI3RmYjMeNJdOHWnRqddqv3p_gDTTe5CgexGEAnHrn9mhFrEnrlS0Bx37UkM6zUqxswsjCZFi70Jdur1oZ6/s400/Screen+Shot+2019-03-22+at+4.42.18+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
I left everything default up till the Feature Selection Page:&lt;/div&gt;
&lt;div&gt;
&lt;ul&gt;
&lt;li&gt;Database Engine Services&lt;/li&gt;
&lt;ul&gt;
&lt;li&gt;Sql Server Replication&lt;/li&gt;
&lt;li&gt;Machine Learning Services&lt;/li&gt;
&lt;/ul&gt;
&lt;li&gt;Shared Features&lt;/li&gt;
&lt;ul&gt;
&lt;li&gt;Client Tools Connectivity&lt;/li&gt;
&lt;/ul&gt;
&lt;/ul&gt;
&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjmaqZnbjmcnNcZHlJSW_Sm4bpS5bUcO92aNWFglhi_aG52hjjBhI4k0wi_6ftaTWZe9mjtTgMcfZVVLNtz6UJMPu7TVSKHspYkXDdmKnDUJC7WZhkz_Vu7cbUc-bpjPCL0gcP4ZmENHH4e/s1600/Screen+Shot+2019-03-22+at+4.44.58+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;590&quot; data-original-width=&quot;799&quot; height=&quot;295&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjmaqZnbjmcnNcZHlJSW_Sm4bpS5bUcO92aNWFglhi_aG52hjjBhI4k0wi_6ftaTWZe9mjtTgMcfZVVLNtz6UJMPu7TVSKHspYkXDdmKnDUJC7WZhkz_Vu7cbUc-bpjPCL0gcP4ZmENHH4e/s400/Screen+Shot+2019-03-22+at+4.44.58+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;
Left everything else default.&amp;nbsp;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
Install SQL Server Management Studio and JAVA&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;h3&gt;
Additional Configuration on your SQL Server&lt;/h3&gt;
&lt;div&gt;
There are few other thing you must enable to fully pass validation&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;ul&gt;
&lt;li&gt;Launch SQL Server Configuration Manager&lt;/li&gt;
&lt;ul&gt;
&lt;li&gt;Set SQL Server Services | SQL Server Browser to start/automatic&lt;/li&gt;
&lt;li&gt;Enable all Named Pipes and TCP/IP&amp;nbsp;&lt;/li&gt;
&lt;/ul&gt;
&lt;/ul&gt;
&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEix1JlKXj4PbrzQ6n7R0WRGaI7PzHBPri1Oxakqt8ENzit3385n4dl6pLXzsaMFkaNzxLqYeaAy8T0jKGzBhbhnHu2megiSI3A3k3zqhk0e3ufGzbHO7PYrxB3_8wDADm3rB4jHu4fs1zQz/s1600/Screen+Shot+2019-03-22+at+4.52.47+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;221&quot; data-original-width=&quot;650&quot; height=&quot;108&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEix1JlKXj4PbrzQ6n7R0WRGaI7PzHBPri1Oxakqt8ENzit3385n4dl6pLXzsaMFkaNzxLqYeaAy8T0jKGzBhbhnHu2megiSI3A3k3zqhk0e3ufGzbHO7PYrxB3_8wDADm3rB4jHu4fs1zQz/s320/Screen+Shot+2019-03-22+at+4.52.47+PM.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;/div&gt;
&lt;ul&gt;
&lt;li style=&quot;text-align: left;&quot;&gt;Launch SQL Server Management Studio&lt;/li&gt;
&lt;ul&gt;
&lt;li style=&quot;text-align: left;&quot;&gt;Login using Windows Authentication&lt;/li&gt;
&lt;li style=&quot;text-align: left;&quot;&gt;It will show your server as Localhost\SQLExpress&lt;/li&gt;
&lt;li style=&quot;text-align: left;&quot;&gt;Browse Security | Logins&lt;/li&gt;
&lt;li style=&quot;text-align: left;&quot;&gt;Create new login and find the domain user account you using to login and make this account sysadmin. It will be needed for DB creation process. Wizard will ask for this user account. I used the same domain account for vRA installation.&lt;/li&gt;
&lt;/ul&gt;
&lt;/ul&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj7_CDEt8qvIrebHg1Tv4_O8h-7Wh20uYUIwczwIC6AMuTUaBO0LOjzZwdOFdo0EdXh5LpdNg8qk0RA1tA36ZGJ6MYthvDJceMDNpjvhI3WBUAQIg04zLmda9BQcxJMWaTE-JzbmBJC_Lhyphenhyphen/s1600/Screen+Shot+2019-03-22+at+4.56.10+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;896&quot; data-original-width=&quot;800&quot; height=&quot;320&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj7_CDEt8qvIrebHg1Tv4_O8h-7Wh20uYUIwczwIC6AMuTUaBO0LOjzZwdOFdo0EdXh5LpdNg8qk0RA1tA36ZGJ6MYthvDJceMDNpjvhI3WBUAQIg04zLmda9BQcxJMWaTE-JzbmBJC_Lhyphenhyphen/s320/Screen+Shot+2019-03-22+at+4.56.10+PM.png&quot; width=&quot;285&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div style=&quot;text-align: left;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;b&gt;TRY AGAIN!&lt;/b&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
Go back to the &lt;i&gt;vRA Installation Wizzard&lt;/i&gt; | &lt;i&gt;Microsoft SQL Server&lt;/i&gt; screen&amp;nbsp; and make sure you enter your hostname\[SQL INSTANCE] or it will fail again and again.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjwmlzFuXjdfR8UWdahGzkIitBerlafZ4HsnCQgeDdlzC6cq9BRmjeesPJbHj7-tgz5KIujdH5a3ClBvkPbeSXcOLNiYuSgr2u2ySDEgKm58UjLJNGsX2K6ip4w4h-mieUwT446ZoxvebeF/s1600/Screen+Shot+2019-03-22+at+5.02.53+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;631&quot; data-original-width=&quot;1006&quot; height=&quot;250&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjwmlzFuXjdfR8UWdahGzkIitBerlafZ4HsnCQgeDdlzC6cq9BRmjeesPJbHj7-tgz5KIujdH5a3ClBvkPbeSXcOLNiYuSgr2u2ySDEgKm58UjLJNGsX2K6ip4w4h-mieUwT446ZoxvebeF/s400/Screen+Shot+2019-03-22+at+5.02.53+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
If everything went find it should pass the Microsoft SQL Server screen. During one my attempts I failed the final Validation process because the domain account I was using to did not have sufficient permission. So adding it as a&amp;nbsp; &quot;sysadmin&quot; should fix the problem. Otherwise expand to check the actual error message.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEipEGatu3IYv9MQQ7CLRU2lAcXk4rAk_p14UUbTVi9iIOUHDEZbHaZeLkCNrK5HCyBqwAup_bcO01zezo98naQAudDu4Ro2FP_-Q1gCt6j_y_fjlu3d2TUV2uvVR4KTMUcjUA6R_KjEnlpB/s1600/Screen+Shot+2019-03-22+at+5.05.23+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;591&quot; data-original-width=&quot;1170&quot; height=&quot;201&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEipEGatu3IYv9MQQ7CLRU2lAcXk4rAk_p14UUbTVi9iIOUHDEZbHaZeLkCNrK5HCyBqwAup_bcO01zezo98naQAudDu4Ro2FP_-Q1gCt6j_y_fjlu3d2TUV2uvVR4KTMUcjUA6R_KjEnlpB/s400/Screen+Shot+2019-03-22+at+5.05.23+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
On my last attempt passed validation successfully and started the installation.&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjX1YfmyvogiI6S_M3VBc51txSk8nxTJemLC-zPGG6fG7kjMaCaAzl2BPOw1-p8LVYhL2IruY5DigIdbxviJiQjVfQFftBNHwsHIghZMj7ntrEgqDgChOJpk9lqxUt4JGfxzFiiOFaL_0nV/s1600/Screen+Shot+2019-03-22+at+5.09.52+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;797&quot; data-original-width=&quot;1159&quot; height=&quot;273&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjX1YfmyvogiI6S_M3VBc51txSk8nxTJemLC-zPGG6fG7kjMaCaAzl2BPOw1-p8LVYhL2IruY5DigIdbxviJiQjVfQFftBNHwsHIghZMj7ntrEgqDgChOJpk9lqxUt4JGfxzFiiOFaL_0nV/s400/Screen+Shot+2019-03-22+at+5.09.52+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
While I was posting this Installation completed successfully.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiBvhUmeZ0cIQIq_OR_Z6zEm0PswRyZPVgCVXjeM1Duf5Sbog9vU_btNTAKS1UdNiu3u6moKLeHf0LmOm86vWAGybz1K53zXC9IUmTXY8dCGsmUhzojuvE0BUXMIOBmF_MkrXziWwBnKOnt/s1600/Screen+Shot+2019-03-22+at+5.08.31+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;855&quot; data-original-width=&quot;1212&quot; height=&quot;281&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiBvhUmeZ0cIQIq_OR_Z6zEm0PswRyZPVgCVXjeM1Duf5Sbog9vU_btNTAKS1UdNiu3u6moKLeHf0LmOm86vWAGybz1K53zXC9IUmTXY8dCGsmUhzojuvE0BUXMIOBmF_MkrXziWwBnKOnt/s400/Screen+Shot+2019-03-22+at+5.08.31+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
Now I can finally move on to the chapter 2 of my vRealize Automation 7.x Training&lt;/div&gt;
&lt;div&gt;
&lt;b&gt;&lt;br /&gt;&lt;/b&gt;&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://fdo-workspace.blogspot.com/feeds/6204390143429707360/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://fdo-workspace.blogspot.com/2019/03/vrealize-automation-75-dealing-with.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/6204390143429707360'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/6204390143429707360'/><link rel='alternate' type='text/html' href='http://fdo-workspace.blogspot.com/2019/03/vrealize-automation-75-dealing-with.html' title='vRealize Automation 7.5 - Dealing with Issues Deploying vRA, IaaS and SQL'/><author><name>fdo</name><uri>http://www.blogger.com/profile/16882300714528613456</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhndsbgzepfJ0U5gXwY3zzRcGOqiMcblr09VzwWLCMA_waqC9FUthSCa8n91RwqW_kZXNo2si5UU3N5Ex6UJbYkcUpcJnxOQw6jPOBYuux7fomIpI0UUf8vOXyBT7hyuuE/s113/IMG_5942.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh3iTcvAOUSEoOxH0Ej467uAfMmTORF0rZif0pRSrEEtObcYziDLGV73CWa1n8I5LinPn1pv7Sn6VpJLR7ScKru_wDMyguEggw5Bdg1WDtyhN1tyfQ2dTF1_SaTIIXl6DrtjWGjcxDSzUQ2/s72-c/Screen+Shot+2019-03-22+at+3.37.35+PM.png" height="72" width="72"/><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8658731852844520209.post-1705399061031105941</id><published>2019-03-20T20:19:00.002-04:00</published><updated>2019-03-20T20:19:56.325-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="powercli"/><category scheme="http://www.blogger.com/atom/ns#" term="powershell"/><category scheme="http://www.blogger.com/atom/ns#" term="PScribo"/><title type='text'>PowerShell: Generating PScribo Report for DiskIOPs</title><content type='html'>I&#39;ve been VMUG member for sometime and never thought I would actually stand in front of a crowd and speak. My team had the opportunity to speak at DC VMUG in Reston,VA - &quot;&lt;span style=&quot;background-color: white; box-sizing: border-box; color: #464646; font-family: &amp;quot;helvetica neue&amp;quot; , &amp;quot;helvetica&amp;quot; , &amp;quot;arial&amp;quot; , sans-serif; font-size: 14px;&quot;&gt;&lt;em style=&quot;box-sizing: border-box; font-weight: bold;&quot;&gt;Mitigating Noisy Neighbor disk i/o situations&quot; &lt;/em&gt;&lt;span style=&quot;box-sizing: border-box;&quot;&gt;on March 14, 2019. It was my very first time ever speaking in front of a crowd and being nervous was an understatement.&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; box-sizing: border-box; color: #464646; font-family: &amp;quot;helvetica neue&amp;quot; , &amp;quot;helvetica&amp;quot; , &amp;quot;arial&amp;quot; , sans-serif; font-size: 14px;&quot;&gt;&lt;span style=&quot;box-sizing: border-box;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span style=&quot;background-color: white; box-sizing: border-box; color: #464646; font-family: &amp;quot;helvetica neue&amp;quot; , &amp;quot;helvetica&amp;quot; , &amp;quot;arial&amp;quot; , sans-serif; font-size: 14px;&quot;&gt;&lt;span style=&quot;box-sizing: border-box;&quot;&gt;So during the presentation I shared briefly a script to generate a Disk IOPs Report per VM per VMDK.&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; box-sizing: border-box; color: #464646; font-family: &amp;quot;helvetica neue&amp;quot; , &amp;quot;helvetica&amp;quot; , &amp;quot;arial&amp;quot; , sans-serif; font-size: 14px;&quot;&gt;&lt;span style=&quot;box-sizing: border-box;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;background-color: white; box-sizing: border-box; color: #464646; font-family: &amp;quot;helvetica neue&amp;quot; , &amp;quot;helvetica&amp;quot; , &amp;quot;arial&amp;quot; , sans-serif; font-size: 14px;&quot;&gt;&lt;span style=&quot;box-sizing: border-box;&quot;&gt;Following script will get all vms inside a &quot;vmug-test&quot;&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;background-color: white; color: #464646; font-family: &amp;quot;helvetica neue&amp;quot; , &amp;quot;helvetica&amp;quot; , &amp;quot;arial&amp;quot; , sans-serif; font-size: 14px;&quot;&gt;&amp;nbsp;folder and generate a report with the storage IO allocation limit.&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;background-color: white; box-sizing: border-box; color: #464646; font-family: &amp;quot;helvetica neue&amp;quot; , &amp;quot;helvetica&amp;quot; , &amp;quot;arial&amp;quot; , sans-serif; font-size: 14px;&quot;&gt;&lt;span style=&quot;box-sizing: border-box;&quot;&gt;&lt;br /&gt;&lt;/span&gt;&lt;/span&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:ps&quot;&gt;$vmlist = get-vm -location vmug-test
$rpt = @()

foreach ($vm in $vmlist){
    $disklist = $vm | Get-HardDisk
    foreach ($disk in $disklist){
        $tmp = $vm | select Name, HardDisk, SizeGB, IOPsLimit
        $tmp.Name = $vm.Name
        $tmp.HardDisk = $disk.Name
        $tmp.SizeGB = $disk.CapacityGB
        $tmp.IOPsLimit = $disk.ExtensionData.StorageIOAllocation.Limit
        $rpt += $tmp
    }
}
$rpt | Sort-Object Name
#To Generate CSV
$rpt | Sort-Object Name, HardDisk, SizeGB, IOPsLimit | Export-Csv -NoTypeInformation &quot;.\IOPsRPT.csv&quot;

######  Section Uses PS Scribo to Turn table in to HTML, TXT, DOC
$document = Document &#39;Report&#39; -Verbose {
    #TOC -Name &#39;Table of Contents&#39;;
    #PageBreak;
    
    &amp;lt;# WARNING: 
        Microsoft Word will include paragraphs styled with &#39;Heading*&#39; style names to the TOC. 
        To avoid this, define an identical style with a name not beginning with &#39;Heading&#39;! 
    #&amp;gt;
    
    Paragraph -Style Heading1 &#39;Disk IOPS Report&#39;
    Section -Style Heading2 &quot;Sample Report Sorted by VM name&quot; {
            #Paragraph -Style Heading3 &#39;Example of an autofit table width, autofit contents and no cell highlighting.&#39;
            #Paragraph &quot;Services ($($services.Count) Services found):&quot;
            $rpt | Table -Columns Name,HardDisk,SizeGB,IOPsLimit -Headers Name,HardDisk,SizeGB,IOPsLimitcd -Width 0
    }
}
$document | Export-Document -Path .\ -Format Word,Html,Text -Verbose
&lt;/pre&gt;
&lt;br /&gt;
&lt;span style=&quot;font-weight: normal;&quot;&gt;Here is the sample output:&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-weight: normal;&quot;&gt;&lt;br /&gt;&lt;/span&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhtGwfbvV9kP7R1a_5TGGGBBf0zGTA-8IsEy_C6vPWi3c-z2pQBKd5xiSvVFUkeh0fVXYOCJSnIzAnpIMXXIkiRLsYBg93eP6DyeQAmOQHNR8gPkGFg6ihR7FydyVBf0jT_6_aFh6IylYqX/s1600/Screen+Shot+2019-03-20+at+8.10.55+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;323&quot; data-original-width=&quot;824&quot; height=&quot;250&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhtGwfbvV9kP7R1a_5TGGGBBf0zGTA-8IsEy_C6vPWi3c-z2pQBKd5xiSvVFUkeh0fVXYOCJSnIzAnpIMXXIkiRLsYBg93eP6DyeQAmOQHNR8gPkGFg6ihR7FydyVBf0jT_6_aFh6IylYqX/s640/Screen+Shot+2019-03-20+at+8.10.55+PM.png&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
Sample script can be downloaded from &lt;a href=&quot;https://github.com/fdo7-ng/Reports_IOPs&quot; target=&quot;_blank&quot;&gt;GitHub&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://fdo-workspace.blogspot.com/feeds/1705399061031105941/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://fdo-workspace.blogspot.com/2019/03/powershell-generating-pscribo-report.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/1705399061031105941'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/1705399061031105941'/><link rel='alternate' type='text/html' href='http://fdo-workspace.blogspot.com/2019/03/powershell-generating-pscribo-report.html' title='PowerShell: Generating PScribo Report for DiskIOPs'/><author><name>fdo</name><uri>http://www.blogger.com/profile/16882300714528613456</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhndsbgzepfJ0U5gXwY3zzRcGOqiMcblr09VzwWLCMA_waqC9FUthSCa8n91RwqW_kZXNo2si5UU3N5Ex6UJbYkcUpcJnxOQw6jPOBYuux7fomIpI0UUf8vOXyBT7hyuuE/s113/IMG_5942.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhtGwfbvV9kP7R1a_5TGGGBBf0zGTA-8IsEy_C6vPWi3c-z2pQBKd5xiSvVFUkeh0fVXYOCJSnIzAnpIMXXIkiRLsYBg93eP6DyeQAmOQHNR8gPkGFg6ihR7FydyVBf0jT_6_aFh6IylYqX/s72-c/Screen+Shot+2019-03-20+at+8.10.55+PM.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8658731852844520209.post-3349897856821174977</id><published>2019-03-20T15:23:00.001-04:00</published><updated>2019-03-20T18:30:28.847-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="highlighter"/><category scheme="http://www.blogger.com/atom/ns#" term="powershell"/><category scheme="http://www.blogger.com/atom/ns#" term="Script"/><category scheme="http://www.blogger.com/atom/ns#" term="syntax"/><title type='text'>Installing Syntax Highlighter on Blogger</title><content type='html'>&lt;div dir=&quot;auto&quot;&gt;
Today I am scratching one more task off my list: &lt;strike&gt;Adding Syntax Highlighter to my blog&lt;/strike&gt;. Like everyone else I got nothing but excuses. Well today I spent few hours adding this feature into my blog. As usual ran into few issues/fixes which I shared as well.&lt;/div&gt;
&lt;h3&gt;
First, what is &lt;b&gt;Syntax Highlighter&lt;/b&gt; and why do we need this?&lt;/h3&gt;
In simple word, is basically a tool that reformat blocks of code/scripts into a nicely colored pretty looking code block within your blog. I did some digging and decided to go with one written by Alex Gorbatchev, latest version as of today is 3.0.83.&amp;nbsp;&lt;a href=&quot;http://alexgorbatchev.com/SyntaxHighlighter&quot;&gt;http://alexgorbatchev.com/SyntaxHighlighter&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhD58pbVZxkJWpB2OShP0BZTGERliiRMR3yTd6QcG2jeVSp6Lanc-qxRwrM2_A_qzdJr7ls89AotEgMBtHmm2JsayWm6FlPkAg0heR7nwxUlSgsWLwZlXa9DkXH0Qy3VWnCgLRZjA0oUJUt/s1600/Screen+Shot+2019-03-20+at+3.26.15+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;457&quot; data-original-width=&quot;1114&quot; height=&quot;163&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhD58pbVZxkJWpB2OShP0BZTGERliiRMR3yTd6QcG2jeVSp6Lanc-qxRwrM2_A_qzdJr7ls89AotEgMBtHmm2JsayWm6FlPkAg0heR7nwxUlSgsWLwZlXa9DkXH0Qy3VWnCgLRZjA0oUJUt/s400/Screen+Shot+2019-03-20+at+3.26.15+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
I opened this account Blogger.com so long ago and didn&#39;t bother switching to another service yet. Of course it has it’s pros and cons but that is a different topic.&lt;br /&gt;
&lt;h4&gt;
Let’s get started.&lt;/h4&gt;
Log into your &lt;b&gt;Blogger.com &lt;/b&gt;account:&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;Click on Theme:&lt;/li&gt;
&lt;li&gt;Before you do ANYTHING!! Please backup your theme. I found it a lot easier to download the team and make changes offline than directly on the browser. So many thing can go wrong.&lt;/li&gt;
&lt;li&gt;Click on the Backup/Restore button&lt;/li&gt;
&lt;/ul&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhYY1FFi0obxeTNRIyQwttlxOBVwpfVxKr5z913d_zT3fDIX_xIunueXw_6P7Dx3zLffBaPqYWzvj9FEQkLdS0dj9g_4EMGI8YSWSqWMBt1vgbrcO4Rzk4GtzPSC_7YUJUkdyvALc6xtF98/s1600/Screen+Shot+2019-03-20+at+3.26.23+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;542&quot; data-original-width=&quot;1052&quot; height=&quot;205&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhYY1FFi0obxeTNRIyQwttlxOBVwpfVxKr5z913d_zT3fDIX_xIunueXw_6P7Dx3zLffBaPqYWzvj9FEQkLdS0dj9g_4EMGI8YSWSqWMBt1vgbrcO4Rzk4GtzPSC_7YUJUkdyvALc6xtF98/s400/Screen+Shot+2019-03-20+at+3.26.23+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
From the Theme &amp;gt; Backup / Restore window | Download the theme:&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgky5gIC1LNBNzpH-IvdR3LTqP268eENxZzPfqtRCOtoXmpiBpxJQQ3-5VaZfOp4jGsYFQGmQ5wmUqYsJo9_MiFILBGEZxP3wCDkZ3GwMqxOpWfUZ6d8g9xfnpu2XiTgANgs5TF3L0Okgnh/s1600/Screen+Shot+2019-03-20+at+3.26.33+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;346&quot; data-original-width=&quot;608&quot; height=&quot;182&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgky5gIC1LNBNzpH-IvdR3LTqP268eENxZzPfqtRCOtoXmpiBpxJQQ3-5VaZfOp4jGsYFQGmQ5wmUqYsJo9_MiFILBGEZxP3wCDkZ3GwMqxOpWfUZ6d8g9xfnpu2XiTgANgs5TF3L0Okgnh/s320/Screen+Shot+2019-03-20+at+3.26.33+PM.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
Side Note: I am sure, I am not the only one getting this annoying warning: “&lt;i&gt;&lt;span style=&quot;color: red;&quot;&gt;Custom themes that mix HTTP and HTTPS may affect the security and user experience of your blog when it is viewed over HTTPS.&amp;nbsp;&lt;a href=&quot;https://www.blogger.com/go/mixedcontent&quot; target=&quot;_blank&quot;&gt;Learn more&lt;/a&gt;.&lt;/span&gt;&lt;/i&gt;”. Which is another reason why downloading the theme and modifying it offline then uploading it is the best way to get around this. Once file is saved Close this window.&lt;br /&gt;
&lt;br /&gt;
&lt;h3&gt;
Attempt to fix the mixd http issue (optional skip to next section)&lt;/h3&gt;
Once to the back to the main Theme, click Edit HTML button. Notice you see that same warning “&lt;i&gt;Editing your theme so it mixes HTTP and HTTPS may affect the security and user experience of your blog when it is viewed over HTTPS.&amp;nbsp;&lt;a href=&quot;https://www.blogger.com/go/mixedcontent&quot; target=&quot;_blank&quot;&gt;Learn more&lt;/a&gt;.&amp;nbsp;&lt;a href=&quot;https://www.blogger.com/blogger.g?blogID=8658731852844520209#&quot;&gt;Hide warning&lt;/a&gt;&lt;/i&gt;”&amp;nbsp;. If you are lucky you should be able to edit and paste the piece of code to enable Syntax Highlighter right from this window. In my case, I tried to fix all the http URLs by searching the entire code for http links and searching for a https version. The only ones I couldn’t able to replace were those on the top.&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEidIA2186IiSKi-J_L7OsUpF1RyIDFTwKLX4TtfcJ4p3cbrSsGYOGaTnaPars8MCkVK_KaNvQWaNNSzrcdK_EkcoQC95cR9NHDLjrDsS_IG0iBE7ELT18L1MOyruuRqMr8ahJp07jZqRHrU/s1600/Screen+Shot+2019-03-20+at+3.26.44+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;401&quot; data-original-width=&quot;804&quot; height=&quot;199&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEidIA2186IiSKi-J_L7OsUpF1RyIDFTwKLX4TtfcJ4p3cbrSsGYOGaTnaPars8MCkVK_KaNvQWaNNSzrcdK_EkcoQC95cR9NHDLjrDsS_IG0iBE7ELT18L1MOyruuRqMr8ahJp07jZqRHrU/s400/Screen+Shot+2019-03-20+at+3.26.44+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
Here is the xmlns section causing those mixed http warning if anyone figure this one out please let me know.&lt;br /&gt;
&lt;br /&gt;
&lt;blockquote class=&quot;tr_bq&quot;&gt;
&lt;i&gt;&amp;lt;html b:dynamicViews=&#39;true&#39; b:version=&#39;2&#39; class=&#39;v2&#39; expr:dir=&#39;data:blog.languageDirection&#39; expr:lang=&#39;data:blog.locale&#39; xmlns=&#39;http://www.w3.org/1999/xhtml&#39; xmlns:b=&#39;http://www.google.com/2005/gml/b&#39; xmlns:data=&#39;http://www.google.com/2005/gml/data&#39; xmlns:expr=&#39;http://www.google.com/2005/gml/expr&#39;&amp;gt;
&lt;/i&gt;&lt;/blockquote&gt;
&lt;b&gt;Note:&lt;/b&gt; The only way to get around changes not saving is to download and modify offline&lt;br /&gt;
&lt;br /&gt;
I clicked on the feedback button to report this problem. Let see what support comes back with.&lt;br /&gt;
&lt;h3&gt;
Code to Install Syntax HighLighter&lt;/h3&gt;
Here is the code you need to insert right above the &amp;lt;/head&amp;gt; to enable Syntax Highlighter. This include all the different brushes provided. One thing I did do was find all the https links to the scripts.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush: html&quot;&gt;&amp;lt;link href=&quot;http://alexgorbatchev.com/pub/sh/current/styles/shCore.css&quot; rel=&quot;stylesheet&quot; type=&quot;text/css&quot;&amp;gt;
&amp;lt;link href=&quot;http://alexgorbatchev.com/pub/sh/current/styles/shThemeDefault.css&quot; rel=&quot;stylesheet&quot; type=&quot;text/css&quot;&amp;gt;
&amp;lt;script src=&quot;https://agorbatchev.typepad.com/pub/sh/3_0_83/scripts/shCore.js&quot; type=&quot;text/javascript&quot;&amp;gt;
&amp;lt;script src=&#39;https://agorbatchev.typepad.com/pub/sh/3_0_83/scripts/shBrushCpp.js&#39; type=&#39;text/javascript&#39;/&amp;gt;
&amp;lt;script src=&#39;https://agorbatchev.typepad.com/pub/sh/3_0_83/scripts/shBrushCSharp.js&#39; type=&#39;text/javascript&#39;/&amp;gt;
&amp;lt;script src=&#39;https://agorbatchev.typepad.com/pub/sh/3_0_83/scripts/shBrushCss.js&#39; type=&#39;text/javascript&#39;/&amp;gt;
&amp;lt;script src=&#39;https://agorbatchev.typepad.com/pub/sh/3_0_83/scripts/shBrushJava.js&#39; type=&#39;text/javascript&#39;/&amp;gt;
&amp;lt;script src=&#39;https://agorbatchev.typepad.com/pub/sh/3_0_83/scripts/shBrushJScript.js&#39; type=&#39;text/javascript&#39;/&amp;gt;
&amp;lt;script src=&#39;https://agorbatchev.typepad.com/pub/sh/3_0_83/scripts/shBrushPhp.js&#39; type=&#39;text/javascript&#39;/&amp;gt;
&amp;lt;script src=&#39;https://agorbatchev.typepad.com/pub/sh/3_0_83/scripts/shBrushPython.js&#39; type=&#39;text/javascript&#39;/&amp;gt;
&amp;lt;script src=&#39;https://agorbatchev.typepad.com/pub/sh/3_0_83/scripts/shBrushRuby.js&#39; type=&#39;text/javascript&#39;/&amp;gt;
&amp;lt;script src=&#39;https://agorbatchev.typepad.com/pub/sh/3_0_83/scripts/shBrushSql.js&#39; type=&#39;text/javascript&#39;/&amp;gt;
&amp;lt;script src=&#39;https://agorbatchev.typepad.com/pub/sh/3_0_83/scripts/shBrushVb.js&#39; type=&#39;text/javascript&#39;/&amp;gt;
&amp;lt;script src=&#39;https://agorbatchev.typepad.com/pub/sh/3_0_83/scripts/shBrushXml.js&#39; type=&#39;text/javascript&#39;/&amp;gt;
&amp;lt;script src=&#39;https://agorbatchev.typepad.com/pub/sh/3_0_83/scripts/shBrushPerl.js&#39; type=&#39;text/javascript&#39;/&amp;gt;
&amp;lt;script language=&#39;javascript&#39;&amp;gt;
SyntaxHighlighter.config.bloggerMode = true;
SyntaxHighlighter.all();
&amp;lt;/script&amp;gt;
&lt;script type=&quot;text/javascript&quot;&gt;
SyntaxHighlighter.highlight();
&lt;/script&gt;
&lt;/pre&gt;
&lt;br /&gt;
&lt;h3&gt;
Installing from Browser&lt;/h3&gt;
Find &amp;lt;/head&amp;gt;, from a MAC use command+F, Windows CTRL+F.&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjlZR0Ho0o0M0K0JtbWHx0__PK2oNZjoYgqkxvELsZoQ5X05c3t6KbTTkaQsjsjx2JsmkeH8ohdQnqw5GPBmqHtLmEnJX3BTNppvdKigKBhqPGvgVhOWEzagDN0w6CuHrOPrbMpjnTUQY0_/s1600/Screen+Shot+2019-03-20+at+3.26.53+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;439&quot; data-original-width=&quot;816&quot; height=&quot;215&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjlZR0Ho0o0M0K0JtbWHx0__PK2oNZjoYgqkxvELsZoQ5X05c3t6KbTTkaQsjsjx2JsmkeH8ohdQnqw5GPBmqHtLmEnJX3BTNppvdKigKBhqPGvgVhOWEzagDN0w6CuHrOPrbMpjnTUQY0_/s400/Screen+Shot+2019-03-20+at+3.26.53+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
After it is installed:&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgy6Qxgu-q1zPa-zkCtD0Uo9H0NlIRbwGVzU3FHczfcYqiUiQajdEsT9RXC75XK2n7y8HC_7QCZMnt0Xg8sWdWaT760h27XJwLLKh_mlTrl4sKacHRWcEHSGsCOLOr4YVnaZglnNCM5Dj5e/s1600/Screen+Shot+2019-03-20+at+3.27.01+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;359&quot; data-original-width=&quot;805&quot; height=&quot;177&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgy6Qxgu-q1zPa-zkCtD0Uo9H0NlIRbwGVzU3FHczfcYqiUiQajdEsT9RXC75XK2n7y8HC_7QCZMnt0Xg8sWdWaT760h27XJwLLKh_mlTrl4sKacHRWcEHSGsCOLOr4YVnaZglnNCM5Dj5e/s400/Screen+Shot+2019-03-20+at+3.27.01+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
Now all Save theme and you all set with installation.&lt;br /&gt;
&lt;br /&gt;
&lt;h3&gt;
Editing Theme Offline&lt;/h3&gt;
Use your favorite text editor, in my case Atom. Search for the XML file which is the theme downloaded on the previous step. Search for &amp;lt;/head&amp;gt; and paste script provided.&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh7CPEDF_roORb7TrxL1A2BCQFXT5k4pZjU3efCgfx3dniULijZljCER2LiFtJL_Ay2KbMdkVZoNlP77LWtt_a_KzeE7gA5-OB4B1PZa5fghgYA7NL80MFRU8Zs2aat6BwPqMqF6HTOLdeR/s1600/Screen+Shot+2019-03-20+at+3.27.11+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;755&quot; data-original-width=&quot;1084&quot; height=&quot;277&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh7CPEDF_roORb7TrxL1A2BCQFXT5k4pZjU3efCgfx3dniULijZljCER2LiFtJL_Ay2KbMdkVZoNlP77LWtt_a_KzeE7gA5-OB4B1PZa5fghgYA7NL80MFRU8Zs2aat6BwPqMqF6HTOLdeR/s400/Screen+Shot+2019-03-20+at+3.27.11+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
Once ready upload the new theme to your blog using the Chose File.. and upload button.&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh_gf4FVFtgWvrzEcdBdZu1BBST-FgRCoxV8ugdxFXhcudOrZEwvQ1tppk-eQ13jSct3fLQDN_6XZIsvS7PV85hjcYE6JUIXLO5cuLWQicc96xEkAvpeKAIto4Tiz2GvSertFHMsBU4XCdF/s1600/Screen+Shot+2019-03-20+at+3.27.19+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;342&quot; data-original-width=&quot;606&quot; height=&quot;180&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh_gf4FVFtgWvrzEcdBdZu1BBST-FgRCoxV8ugdxFXhcudOrZEwvQ1tppk-eQ13jSct3fLQDN_6XZIsvS7PV85hjcYE6JUIXLO5cuLWQicc96xEkAvpeKAIto4Tiz2GvSertFHMsBU4XCdF/s320/Screen+Shot+2019-03-20+at+3.27.19+PM.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
Once done that’s it you are all set. Ready to test!&lt;br /&gt;
&lt;br /&gt;
&lt;h3&gt;
Using Syntax Highlighter&lt;/h3&gt;
Now to use the SyntaxHighlighter place your code between the &amp;lt;pre /&amp;gt; tags and define your code type by setting the brush value.&lt;br /&gt;
&lt;br /&gt;
&lt;code&gt;&amp;lt;pre class=&quot;brush: Brush_Alias&quot;&amp;gt;&lt;/code&gt;&lt;br /&gt;
SCRIPT HERE &lt;code&gt;&lt;/code&gt;&lt;br /&gt;
&lt;code&gt;&amp;lt;/pre&amp;gt;&lt;/code&gt;&lt;br /&gt;
&lt;br /&gt;
For full list of supported Brush aliases check for manual for brushes&amp;nbsp;&lt;a href=&quot;http://alexgorbatchev.com/SyntaxHighlighter/manual/brushes/&quot;&gt;http://alexgorbatchev.com/SyntaxHighlighter/manual/brushes/&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjGayFf1H67NWd7N2G7FjtGZp5YQGW93YaWOxbM04c9KydqYdWvYcUzMpLbC7A1MMc7zDrzJo-1evYhiZVqa2XG1MhEIj_Lt5uX7PqeT9ZIa_sAiUOvvFX2D4IJC74SOWzXQ1scwDonV5e1/s1600/Screen+Shot+2019-03-20+at+3.27.32+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;775&quot; data-original-width=&quot;859&quot; height=&quot;360&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjGayFf1H67NWd7N2G7FjtGZp5YQGW93YaWOxbM04c9KydqYdWvYcUzMpLbC7A1MMc7zDrzJo-1evYhiZVqa2XG1MhEIj_Lt5uX7PqeT9ZIa_sAiUOvvFX2D4IJC74SOWzXQ1scwDonV5e1/s400/Screen+Shot+2019-03-20+at+3.27.32+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Sample: To make PowerShell code block look like this:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush: ps&quot;&gt;    # Power Shell Script
    Write-Host &quot;Simple script to get Windows Process&quot;
    $process = Get-Process
    $process | Select-Object ProcessName, Id, CPU&lt;/pre&gt;
&lt;br /&gt;
Use this - brush type is ps or powershell&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush: plain&quot;&gt;&amp;lt;pre class=&quot;brush: ps&quot;&amp;gt;
    # Power Shell Script
    Write-Host &quot;Simple script to get Windows Process&quot;
    $process = Get-Process
    $process | Select-Object ProcessName, Id, CPU
&amp;lt;/pre&amp;gt;
&lt;/pre&gt;
&lt;br /&gt;
&lt;br /&gt;
If you are using Dynamic themes in your blog, you are not done. It will require adding additional lines of code to make it work. &lt;b&gt;What are Dynamic View Themes?&lt;/b&gt;&amp;nbsp;If you go under “Themes”, scrolld to the middle you can see Dynamic Views section:&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhAIFnrC7feXGQ7zjZg8fsddeZEx5S-RnpKfujIKWqfR_Y8YKIbDG2LepwCJR1Aoqti3yLOkjmlVtykRrgwK4fPP7Ko9rmgo3SnksJ16MmS7ZjKQyUiVSbK3-KL2D6gzWfFt5KK1D8ctFWM/s1600/Screen+Shot+2019-03-20+at+3.27.42+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;471&quot; data-original-width=&quot;954&quot; height=&quot;196&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhAIFnrC7feXGQ7zjZg8fsddeZEx5S-RnpKfujIKWqfR_Y8YKIbDG2LepwCJR1Aoqti3yLOkjmlVtykRrgwK4fPP7Ko9rmgo3SnksJ16MmS7ZjKQyUiVSbK3-KL2D6gzWfFt5KK1D8ctFWM/s400/Screen+Shot+2019-03-20+at+3.27.42+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Work around&lt;/b&gt; is to add the extra piece of code inside the right before closing&amp;nbsp; &amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;blockquote class=&quot;tr_bq&quot;&gt;
&amp;lt;script type=&quot;text/javascript&quot;&amp;gt;&lt;br /&gt;SyntaxHighlighter.highlight();&lt;br /&gt;&amp;lt;/script&amp;gt;&lt;/blockquote&gt;
&lt;br /&gt;
So, for” Dynamic View” users, use the following format&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush: plain&quot;&gt;&amp;lt;pre class=&quot;brush: ps&quot;&amp;gt;
    # Power Shell Script
    Write-Host &quot;Simple script to get Windows Process&quot;
    $process = Get-Process
    $process | Select-Object ProcessName, Id, CPU
    &amp;lt;script type=&quot;text/javascript&quot;&amp;gt;
    SyntaxHighlighter.highlight();
    &amp;lt;/script&amp;gt;
&amp;lt;/pre&amp;gt;
&lt;script type=&quot;text/javascript&quot;&gt;
SyntaxHighlighter.highlight();
&lt;/script&gt;
&lt;/pre&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
This should wrap up the Syntax Highlighter setup for you Blogger.com blog. To sum this up:&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;Intro to Syntax Highlighter 3.0.83 - latest version day blog was posted.&lt;/li&gt;
&lt;li&gt;Backup/Restore Theme&lt;/li&gt;
&lt;li&gt;Install System Highlighter into theme&lt;/li&gt;
&lt;li&gt;How to use the Syntax Highlighter for those using Simple and Dynamic View themes.&lt;/li&gt;
&lt;/ul&gt;
&lt;br /&gt;
Next I will try to figure out how to host the on my own share drive like: DropBox, OneDrive, Google Drive or anything down those lines.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;</content><link rel='replies' type='application/atom+xml' href='http://fdo-workspace.blogspot.com/feeds/3349897856821174977/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://fdo-workspace.blogspot.com/2019/03/installing-syntax-highlighter-on-blogger.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/3349897856821174977'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/3349897856821174977'/><link rel='alternate' type='text/html' href='http://fdo-workspace.blogspot.com/2019/03/installing-syntax-highlighter-on-blogger.html' title='Installing Syntax Highlighter on Blogger'/><author><name>fdo</name><uri>http://www.blogger.com/profile/16882300714528613456</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhndsbgzepfJ0U5gXwY3zzRcGOqiMcblr09VzwWLCMA_waqC9FUthSCa8n91RwqW_kZXNo2si5UU3N5Ex6UJbYkcUpcJnxOQw6jPOBYuux7fomIpI0UUf8vOXyBT7hyuuE/s113/IMG_5942.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhD58pbVZxkJWpB2OShP0BZTGERliiRMR3yTd6QcG2jeVSp6Lanc-qxRwrM2_A_qzdJr7ls89AotEgMBtHmm2JsayWm6FlPkAg0heR7nwxUlSgsWLwZlXa9DkXH0Qy3VWnCgLRZjA0oUJUt/s72-c/Screen+Shot+2019-03-20+at+3.26.15+PM.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8658731852844520209.post-5425027725773952612</id><published>2019-03-19T17:45:00.000-04:00</published><updated>2019-03-19T21:17:35.382-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="automation"/><category scheme="http://www.blogger.com/atom/ns#" term="CLI"/><category scheme="http://www.blogger.com/atom/ns#" term="Script"/><category scheme="http://www.blogger.com/atom/ns#" term="VCSA"/><category scheme="http://www.blogger.com/atom/ns#" term="VCSA-Deploy"/><category scheme="http://www.blogger.com/atom/ns#" term="vSphere 6.7"/><title type='text'>VCSA 6.7 CLI Deployment issue with Target | Datacenter Parameter</title><content type='html'>&lt;style type=&quot;text/css&quot;&gt;
p.p1 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Helvetica}
p.p2 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Helvetica; min-height: 14.0px}
&lt;/style&gt;


&lt;br /&gt;
&lt;div class=&quot;p1&quot;&gt;
VCSA CLI deployment tools is one of the best way to automate the deployment of vCenter. Part of my role is to maintain a library of scripts to automate various task within vCenter as well as deploy and configure vCenter itself. Another really awesome use case is for vCenter Backup/Restore purposes. Say you backup your VCSA to FTP server, you could use this tool to deploy a VC then restore configuration from VCSA. When things go wrong is a lot easier to just destroy everything and start fresh.&amp;nbsp;&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
vCenter Appliance v6.7 has been out for some time and I still haven’t found time to poke at it. Well today I finally had a reason to build a full v6.7 environment and ran into this annoying issue the parameters in the JSON file. Ran into this same issue during early days of VCSA v6.5 but somehow I did not document the fix and now I am scratching my head over this issue once again.&amp;nbsp;&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
For those who are not sure what I am talking about. Inside the VCSA iso file there is folder with an executable vcsa-deploy that helps provision vCenters. In fact the VCSA UI deployment options facilitate json creation and then invokes that vcsa-deploy executable. The VCSA JSON Templates are located under following location:&amp;nbsp; &amp;nbsp;&lt;i&gt;VMware-VCSA-all-6.7.0-8217866\vcsa-cli-installer\templates. &lt;/i&gt;&amp;nbsp;I am looking under the install folder for new VCSA deployment. As you can see from the picture, there are two flavor of each VCSA or PSC type: on ESXi or on VC. You can deploy the appliance directly to a ESXi host or to a VC.&amp;nbsp;&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEibfH7MMFR74D-2m1g3Bg9fMGvdpt3bFH7tW0fK6rXax5OUVgORHG5XyvylphOXBva1vPz8WQ1nVgYHW4SFnubUfJOJCRm8zkoZ3RwE4GkEMqBd0R2RHfCBrmHMoU2XzwebB8CgQcJEBYY4/s1600/Screen+Shot+2019-03-19+at+6.29.14+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;560&quot; data-original-width=&quot;920&quot; height=&quot;242&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEibfH7MMFR74D-2m1g3Bg9fMGvdpt3bFH7tW0fK6rXax5OUVgORHG5XyvylphOXBva1vPz8WQ1nVgYHW4SFnubUfJOJCRm8zkoZ3RwE4GkEMqBd0R2RHfCBrmHMoU2XzwebB8CgQcJEBYY4/s400/Screen+Shot+2019-03-19+at+6.29.14+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;h3&gt;
Purpose of this article is to address the &quot;target&quot; and &quot;datacenter&quot; parameter in the json file to deploy &lt;b&gt;VCSA_on_VC&lt;/b&gt;&lt;/h3&gt;
&lt;div class=&quot;p1&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
In this case, I wanted to use embedded_vCSA_on_VC.json template json. Populated all parameters according to the &lt;a href=&quot;https://docs.vmware.com/en/VMware-vSphere/6.7/com.vmware.vcenter.install.doc/GUID-457EAE1F-B08A-4E64-8506-8A3FA84A0446.html&quot; target=&quot;_blank&quot;&gt;VMWare Deployment Configuration Parameters&lt;/a&gt;&amp;nbsp;and I got the following error message.&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgAbDsN2qt9oDnoyJEJC94c88U2KUozPZYJtoWSsYcAIXMhxAIEpagnx8tqfuQ0TpHzujyKbym6BkOnFBrdOveGAU1UjFOYispxTa_9_Kb6te996KQQe1D9sp-Aa5FksvTjJW1I-YUybJ9i/s1600/Screen+Shot+2019-03-19+at+6.43.31+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;482&quot; data-original-width=&quot;1522&quot; height=&quot;126&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgAbDsN2qt9oDnoyJEJC94c88U2KUozPZYJtoWSsYcAIXMhxAIEpagnx8tqfuQ0TpHzujyKbym6BkOnFBrdOveGAU1UjFOYispxTa_9_Kb6te996KQQe1D9sp-Aa5FksvTjJW1I-YUybJ9i/s400/Screen+Shot+2019-03-19+at+6.43.31+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;blockquote class=&quot;tr_bq&quot;&gt;
================ [FAILED] Task: PrecheckTask: Running prechecks. execution&lt;br /&gt;
failed at 20:29:19 ================&lt;br /&gt;
Task &#39;PrecheckTask: Running prechecks.&#39; execution failed because&lt;br /&gt;
[com.vmware.vcsa.installer.prechecks.host_configs: The path provided in the&lt;br /&gt;
target setting in section new_vcsa, subsection vc does not exist. Check the&lt;br /&gt;
value of the target setting in the JSON file provided to the installer.&amp;nbsp; ],&lt;br /&gt;
possible resolution is []&amp;nbsp;&lt;/blockquote&gt;
&lt;div class=&quot;p1&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
VCSA-Deploy basically complaining about the &quot;target&quot; parameter: new_vcsa.vc.target. The same issue applies to the datacenter parameter.&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
Following section is extracted directly from the vCenter 6.7 | Deployment Configuration Parameters Documentation:&amp;nbsp;&lt;a href=&quot;https://docs.vmware.com/en/VMware-vSphere/6.7/com.vmware.vcenter.install.doc/GUID-457EAE1F-B08A-4E64-8506-8A3FA84A0446.html&quot; target=&quot;_blank&quot;&gt;VMWare Deployment Configuration Parameters&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;p&quot; id=&quot;GUID-457EAE1F-B08A-4E64-8506-8A3FA84A0446__p_83C65C3081D34549B24F638FD7F6081B&quot; style=&quot;box-sizing: border-box; caret-color: rgb(86, 86, 86); color: #565656; font-family: Metropolis, &amp;quot;Avenir Next&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Arial, sans-serif; font-size: 13px; text-size-adjust: auto;&quot;&gt;
The target&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;span class=&quot;ph productname&quot; id=&quot;GUID-457EAE1F-B08A-4E64-8506-8A3FA84A0446__PRODUCTNAME_151DEB637A324DC9B6DDD7091D718B38&quot; style=&quot;box-sizing: border-box;&quot;&gt;ESXi&lt;/span&gt;&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;host or DRS cluster on which you want to deploy the appliance.&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;
&lt;div class=&quot;note note important&quot; id=&quot;GUID-457EAE1F-B08A-4E64-8506-8A3FA84A0446__p_F63A9D6E33CB44FB93EA7D5106335B1C&quot; style=&quot;border-bottom: 2px solid rgb(209, 210, 211); border-top: 2px solid rgb(209, 210, 211); box-sizing: border-box; caret-color: rgb(86, 86, 86); color: #565656; font-family: Metropolis, &amp;quot;Avenir Next&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Arial, sans-serif; font-size: 13px; margin-bottom: 1em; margin-top: 1em; padding: 15px 0px; text-size-adjust: auto;&quot;&gt;
&lt;span class=&quot;note__title&quot; style=&quot;box-sizing: border-box; font-weight: 700;&quot;&gt;Important:&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;p&quot; id=&quot;GUID-457EAE1F-B08A-4E64-8506-8A3FA84A0446__d42t737&quot; style=&quot;box-sizing: border-box;&quot;&gt;
You must provide the name that is displayed in the&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;span class=&quot;ph productname&quot; id=&quot;GUID-457EAE1F-B08A-4E64-8506-8A3FA84A0446__PRODUCTNAME_36A67B5996CE47209B6ACC1FB2332B47&quot; style=&quot;box-sizing: border-box;&quot;&gt;vCenter Server&lt;/span&gt;&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;inventory. For example, if the name of the target&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;span class=&quot;ph productname&quot; id=&quot;GUID-457EAE1F-B08A-4E64-8506-8A3FA84A0446__PRODUCTNAME_151DEB637A324DC9B6DDD7091D718B38&quot; style=&quot;box-sizing: border-box;&quot;&gt;ESXi&lt;/span&gt;&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;host is an IP address in the&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;span class=&quot;ph productname&quot; id=&quot;GUID-457EAE1F-B08A-4E64-8506-8A3FA84A0446__PRODUCTNAME_36A67B5996CE47209B6ACC1FB2332B47&quot; style=&quot;box-sizing: border-box;&quot;&gt;vCenter Server&lt;/span&gt;&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;inventory, you cannot provide an FQDN.&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&quot;p&quot; id=&quot;GUID-457EAE1F-B08A-4E64-8506-8A3FA84A0446__p_201B94559A9742EF8A4D1F4F0B016B26&quot; style=&quot;box-sizing: border-box; caret-color: rgb(86, 86, 86); color: #565656; font-family: Metropolis, &amp;quot;Avenir Next&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Arial, sans-serif; font-size: 13px; text-size-adjust: auto;&quot;&gt;
If the target&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;span class=&quot;ph productname&quot; id=&quot;GUID-457EAE1F-B08A-4E64-8506-8A3FA84A0446__PRODUCTNAME_151DEB637A324DC9B6DDD7091D718B38&quot; style=&quot;box-sizing: border-box;&quot;&gt;ESXi&lt;/span&gt;&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;host or DRS cluster is located in a folder or a structure of folders, the value must be a comma-separated list of strings or a comma-separated list as a single string. For example,&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;
&lt;pre class=&quot;pre codeblock vm-code-block prettyprint&quot; id=&quot;GUID-457EAE1F-B08A-4E64-8506-8A3FA84A0446__codeblock_83F1CFAEF5A743A99D2AFD4A87C35785&quot; style=&quot;background-color: whitesmoke; border-radius: 4px; border: 1px solid rgb(204, 204, 204); box-shadow: none; box-sizing: border-box; color: #333333; font-size: 13px; line-height: 1.42857; margin-bottom: 10px; overflow-wrap: break-word; overflow: auto; padding: 7px; position: relative; text-size-adjust: auto; word-break: break-all;&quot;&gt;&lt;div class=&quot;copy-code-icon btnCopyCode mb-3&quot; style=&quot;box-sizing: border-box; margin-bottom: 1rem !important; overflow: hidden; white-space: normal;&quot;&gt;
&lt;div class=&quot;copy-code-container float-right&quot; data-original-title=&quot;Click to Copy&quot; style=&quot;box-sizing: border-box; color: #565656; cursor: pointer; fill: currentcolor; float: right !important; height: 20px; width: 20px;&quot; title=&quot;&quot;&gt;
&lt;svg height=&quot;36&quot; preserveaspectratio=&quot;xMidYMid meet&quot; version=&quot;1.1&quot; viewbox=&quot;0 0 36 36&quot; width=&quot;36&quot; xmlns:xlink=&quot;http://www.w3.org/1999/xlink&quot; xmlns=&quot;http://www.w3.org/2000/svg&quot;&gt;&lt;path class=&quot;clr-i-outline clr-i-outline-path-1&quot; d=&quot;M29.5,7h-19A1.5,1.5,0,0,0,9,8.5v24A1.5,1.5,0,0,0,10.5,34h19A1.5,1.5,0,0,0,31,32.5V8.5A1.5,1.5,0,0,0,29.5,7ZM29,32H11V9H29Z&quot;&gt;&lt;/path&gt;&lt;path class=&quot;clr-i-outline clr-i-outline-path-2&quot; d=&quot;M26,3.5A1.5,1.5,0,0,0,24.5,2H5.5A1.5,1.5,0,0,0,4,3.5v24A1.5,1.5,0,0,0,5.5,29H6V4H26Z&quot;&gt;&lt;/path&gt;&lt;rect fill-opacity=&quot;0&quot; height=&quot;36&quot; width=&quot;36&quot; x=&quot;0&quot; y=&quot;0&quot;&gt;&lt;/rect&gt;&lt;/svg&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;div style=&quot;box-sizing: border-box;&quot;&gt;
[&quot;parent_folder&quot;, &quot;child_folder&quot;, &quot;esxi-host.domain.com&quot;]&lt;/div&gt;
&lt;/pre&gt;
&lt;div class=&quot;p&quot; id=&quot;GUID-457EAE1F-B08A-4E64-8506-8A3FA84A0446__d42t755&quot; style=&quot;box-sizing: border-box; caret-color: rgb(86, 86, 86); color: #565656; font-family: Metropolis, &amp;quot;Avenir Next&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Arial, sans-serif; font-size: 13px; text-size-adjust: auto;&quot;&gt;
or&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;
&lt;pre class=&quot;pre codeblock vm-code-block prettyprint&quot; id=&quot;GUID-457EAE1F-B08A-4E64-8506-8A3FA84A0446__codeblock_836385A26F86469C9DBABBF5BA6432D9&quot; style=&quot;background-color: whitesmoke; border-radius: 4px; border: 1px solid rgb(204, 204, 204); box-shadow: none; box-sizing: border-box; color: #333333; font-size: 13px; line-height: 1.42857; margin-bottom: 10px; overflow-wrap: break-word; overflow: auto; padding: 7px; position: relative; text-size-adjust: auto; word-break: break-all;&quot;&gt;&lt;div class=&quot;copy-code-icon btnCopyCode mb-3&quot; style=&quot;box-sizing: border-box; margin-bottom: 1rem !important; overflow: hidden; white-space: normal;&quot;&gt;
&lt;div class=&quot;copy-code-container float-right&quot; data-original-title=&quot;Click to Copy&quot; style=&quot;box-sizing: border-box; color: #565656; cursor: pointer; fill: currentcolor; float: right !important; height: 20px; width: 20px;&quot; title=&quot;&quot;&gt;
&lt;svg height=&quot;36&quot; preserveaspectratio=&quot;xMidYMid meet&quot; version=&quot;1.1&quot; viewbox=&quot;0 0 36 36&quot; width=&quot;36&quot; xmlns:xlink=&quot;http://www.w3.org/1999/xlink&quot; xmlns=&quot;http://www.w3.org/2000/svg&quot;&gt;&lt;path class=&quot;clr-i-outline clr-i-outline-path-1&quot; d=&quot;M29.5,7h-19A1.5,1.5,0,0,0,9,8.5v24A1.5,1.5,0,0,0,10.5,34h19A1.5,1.5,0,0,0,31,32.5V8.5A1.5,1.5,0,0,0,29.5,7ZM29,32H11V9H29Z&quot;&gt;&lt;/path&gt;&lt;path class=&quot;clr-i-outline clr-i-outline-path-2&quot; d=&quot;M26,3.5A1.5,1.5,0,0,0,24.5,2H5.5A1.5,1.5,0,0,0,4,3.5v24A1.5,1.5,0,0,0,5.5,29H6V4H26Z&quot;&gt;&lt;/path&gt;&lt;rect fill-opacity=&quot;0&quot; height=&quot;36&quot; width=&quot;36&quot; x=&quot;0&quot; y=&quot;0&quot;&gt;&lt;/rect&gt;&lt;/svg&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;div style=&quot;box-sizing: border-box;&quot;&gt;
&quot;parent_folder, child_folder, esxi-host.domain.com&quot;&lt;/div&gt;
&lt;/pre&gt;
&lt;div class=&quot;p&quot; id=&quot;GUID-457EAE1F-B08A-4E64-8506-8A3FA84A0446__d42t758&quot; style=&quot;box-sizing: border-box; caret-color: rgb(86, 86, 86); color: #565656; font-family: Metropolis, &amp;quot;Avenir Next&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Arial, sans-serif; font-size: 13px; text-size-adjust: auto;&quot;&gt;
&lt;/div&gt;
&lt;div class=&quot;p&quot; id=&quot;GUID-457EAE1F-B08A-4E64-8506-8A3FA84A0446__p_1511FF6E281B461191EF353CBCA0F17E&quot; style=&quot;box-sizing: border-box; caret-color: rgb(86, 86, 86); color: #565656; font-family: Metropolis, &amp;quot;Avenir Next&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Arial, sans-serif; font-size: 13px; text-size-adjust: auto;&quot;&gt;
If the target&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;span class=&quot;ph productname&quot; id=&quot;GUID-457EAE1F-B08A-4E64-8506-8A3FA84A0446__PRODUCTNAME_151DEB637A324DC9B6DDD7091D718B38&quot; style=&quot;box-sizing: border-box;&quot;&gt;ESXi&lt;/span&gt;&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;host is part of a cluster, use a comma-separated list of strings or a comma-separated list as a single string to provide the path. For example,&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;
&lt;pre class=&quot;pre codeblock vm-code-block prettyprint&quot; id=&quot;GUID-457EAE1F-B08A-4E64-8506-8A3FA84A0446__codeblock_2BF91858C0684EFAA0C7F8FA36C1772A&quot; style=&quot;background-color: whitesmoke; border-radius: 4px; border: 1px solid rgb(204, 204, 204); box-shadow: none; box-sizing: border-box; color: #333333; font-size: 13px; line-height: 1.42857; margin-bottom: 10px; overflow-wrap: break-word; overflow: auto; padding: 7px; position: relative; text-size-adjust: auto; word-break: break-all;&quot;&gt;&lt;div class=&quot;copy-code-icon btnCopyCode mb-3&quot; style=&quot;box-sizing: border-box; margin-bottom: 1rem !important; overflow: hidden; white-space: normal;&quot;&gt;
&lt;div class=&quot;copy-code-container float-right&quot; data-original-title=&quot;Click to Copy&quot; style=&quot;box-sizing: border-box; color: #565656; cursor: pointer; fill: currentcolor; float: right !important; height: 20px; width: 20px;&quot; title=&quot;&quot;&gt;
&lt;svg height=&quot;36&quot; preserveaspectratio=&quot;xMidYMid meet&quot; version=&quot;1.1&quot; viewbox=&quot;0 0 36 36&quot; width=&quot;36&quot; xmlns:xlink=&quot;http://www.w3.org/1999/xlink&quot; xmlns=&quot;http://www.w3.org/2000/svg&quot;&gt;&lt;path class=&quot;clr-i-outline clr-i-outline-path-1&quot; d=&quot;M29.5,7h-19A1.5,1.5,0,0,0,9,8.5v24A1.5,1.5,0,0,0,10.5,34h19A1.5,1.5,0,0,0,31,32.5V8.5A1.5,1.5,0,0,0,29.5,7ZM29,32H11V9H29Z&quot;&gt;&lt;/path&gt;&lt;path class=&quot;clr-i-outline clr-i-outline-path-2&quot; d=&quot;M26,3.5A1.5,1.5,0,0,0,24.5,2H5.5A1.5,1.5,0,0,0,4,3.5v24A1.5,1.5,0,0,0,5.5,29H6V4H26Z&quot;&gt;&lt;/path&gt;&lt;rect fill-opacity=&quot;0&quot; height=&quot;36&quot; width=&quot;36&quot; x=&quot;0&quot; y=&quot;0&quot;&gt;&lt;/rect&gt;&lt;/svg&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;div style=&quot;box-sizing: border-box;&quot;&gt;
[&quot;cluster_name&quot;, &quot;esxi-host.domain.com&quot;] 
      &lt;/div&gt;
&lt;/pre&gt;
&lt;div class=&quot;p&quot; id=&quot;GUID-457EAE1F-B08A-4E64-8506-8A3FA84A0446__d42t767&quot; style=&quot;box-sizing: border-box; caret-color: rgb(86, 86, 86); color: #565656; font-family: Metropolis, &amp;quot;Avenir Next&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Arial, sans-serif; font-size: 13px; text-size-adjust: auto;&quot;&gt;
or&lt;span class=&quot;Apple-converted-space&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;
&lt;pre class=&quot;pre codeblock vm-code-block prettyprint&quot; id=&quot;GUID-457EAE1F-B08A-4E64-8506-8A3FA84A0446__codeblock_B380028AB1B84E1088D8425F34105F8E&quot; style=&quot;background-color: whitesmoke; border-radius: 4px; border: 1px solid rgb(204, 204, 204); box-shadow: none; box-sizing: border-box; color: #333333; font-size: 13px; line-height: 1.42857; margin-bottom: 10px; overflow-wrap: break-word; overflow: auto; padding: 7px; position: relative; text-size-adjust: auto; word-break: break-all;&quot;&gt;&lt;div class=&quot;copy-code-icon btnCopyCode mb-3&quot; style=&quot;box-sizing: border-box; margin-bottom: 1rem !important; overflow: hidden; white-space: normal;&quot;&gt;
&lt;div class=&quot;copy-code-container float-right&quot; data-original-title=&quot;Click to Copy&quot; style=&quot;box-sizing: border-box; color: #565656; cursor: pointer; fill: currentcolor; float: right !important; height: 20px; width: 20px;&quot; title=&quot;&quot;&gt;
&lt;svg height=&quot;36&quot; preserveaspectratio=&quot;xMidYMid meet&quot; version=&quot;1.1&quot; viewbox=&quot;0 0 36 36&quot; width=&quot;36&quot; xmlns:xlink=&quot;http://www.w3.org/1999/xlink&quot; xmlns=&quot;http://www.w3.org/2000/svg&quot;&gt;&lt;path class=&quot;clr-i-outline clr-i-outline-path-1&quot; d=&quot;M29.5,7h-19A1.5,1.5,0,0,0,9,8.5v24A1.5,1.5,0,0,0,10.5,34h19A1.5,1.5,0,0,0,31,32.5V8.5A1.5,1.5,0,0,0,29.5,7ZM29,32H11V9H29Z&quot;&gt;&lt;/path&gt;&lt;path class=&quot;clr-i-outline clr-i-outline-path-2&quot; d=&quot;M26,3.5A1.5,1.5,0,0,0,24.5,2H5.5A1.5,1.5,0,0,0,4,3.5v24A1.5,1.5,0,0,0,5.5,29H6V4H26Z&quot;&gt;&lt;/path&gt;&lt;rect fill-opacity=&quot;0&quot; height=&quot;36&quot; width=&quot;36&quot; x=&quot;0&quot; y=&quot;0&quot;&gt;&lt;/rect&gt;&lt;/svg&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;div style=&quot;box-sizing: border-box;&quot;&gt;
&quot;cluster_name, esxi-host.domain.com&quot;&lt;/div&gt;
&lt;/pre&gt;
&lt;div class=&quot;p&quot; id=&quot;GUID-457EAE1F-B08A-4E64-8506-8A3FA84A0446__d42t770&quot; style=&quot;box-sizing: border-box; caret-color: rgb(86, 86, 86); color: #565656; font-family: Metropolis, &amp;quot;Avenir Next&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Arial, sans-serif; font-size: 13px; text-size-adjust: auto;&quot;&gt;
&lt;/div&gt;
&lt;div class=&quot;note&quot; id=&quot;GUID-457EAE1F-B08A-4E64-8506-8A3FA84A0446__p_85DE897E25F24720917AF1F08DA5BF1F&quot; style=&quot;border-bottom: 2px solid rgb(209, 210, 211); border-top: 2px solid rgb(209, 210, 211); box-sizing: border-box; caret-color: rgb(86, 86, 86); color: #565656; font-family: Metropolis, &amp;quot;Avenir Next&amp;quot;, &amp;quot;Helvetica Neue&amp;quot;, Arial, sans-serif; font-size: 13px; margin-bottom: 1em; margin-top: 1em; padding: 15px 0px; text-size-adjust: auto;&quot;&gt;
&lt;span class=&quot;note__title&quot; style=&quot;box-sizing: border-box; font-weight: 700;&quot;&gt;Note:&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;p&quot; id=&quot;GUID-457EAE1F-B08A-4E64-8506-8A3FA84A0446__d42t773&quot; style=&quot;box-sizing: border-box;&quot;&gt;
The value is case-sensitive&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
For some reason i tried all those different combinations listed in the KB and did not work. Two important fact about this parameter is that it can be a &lt;b&gt;string&lt;/b&gt; or array and is &lt;b&gt;case sensitive&lt;/b&gt;. Using the &lt;b&gt;cluster_name&lt;/b&gt; only worked. This is thanks to one of VirtuallyGhettos scripts.&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
Here is sample section that works:&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&amp;nbsp; &amp;nbsp; &quot;new_vcsa&quot;: {&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &quot;vc&quot;: {&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &quot;hostname&quot;: &quot;10.10.10.10&quot;,&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &quot;username&quot;: &quot;administrator@vsphere.local&quot;,&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &quot;password&quot;: &quot;Passw0rd!&quot;,&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &quot;deployment_network&quot;: &quot;Test-VL47&quot;,&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &quot;datacenter&quot;: &quot;MakiDC&quot;,&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &quot;datastore&quot;: &quot;Maki-Datastore02&quot;,&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &quot;target&quot;: &quot;Maki-Cluster&quot;&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; },&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
where:&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
- &lt;b&gt;datacenter&lt;/b&gt; is the datacenter name&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
- &lt;b&gt;target &lt;/b&gt;is the cluster name&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
Reference links:&lt;br /&gt;
&lt;a href=&quot;https://docs.vmware.com/en/VMware-vSphere/6.7/com.vmware.vcenter.install.doc/GUID-457EAE1F-B08A-4E64-8506-8A3FA84A0446.html&quot; target=&quot;_blank&quot;&gt;JSON Templates for CLI Deplyment of the vCenter Server Appliance and Platform Services Controller Appliance&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;p1&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;br /&gt;</content><link rel='replies' type='application/atom+xml' href='http://fdo-workspace.blogspot.com/feeds/5425027725773952612/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://fdo-workspace.blogspot.com/2019/03/vcsa-67-cli-deployment.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/5425027725773952612'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/5425027725773952612'/><link rel='alternate' type='text/html' href='http://fdo-workspace.blogspot.com/2019/03/vcsa-67-cli-deployment.html' title='VCSA 6.7 CLI Deployment issue with Target | Datacenter Parameter'/><author><name>fdo</name><uri>http://www.blogger.com/profile/16882300714528613456</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhndsbgzepfJ0U5gXwY3zzRcGOqiMcblr09VzwWLCMA_waqC9FUthSCa8n91RwqW_kZXNo2si5UU3N5Ex6UJbYkcUpcJnxOQw6jPOBYuux7fomIpI0UUf8vOXyBT7hyuuE/s113/IMG_5942.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEibfH7MMFR74D-2m1g3Bg9fMGvdpt3bFH7tW0fK6rXax5OUVgORHG5XyvylphOXBva1vPz8WQ1nVgYHW4SFnubUfJOJCRm8zkoZ3RwE4GkEMqBd0R2RHfCBrmHMoU2XzwebB8CgQcJEBYY4/s72-c/Screen+Shot+2019-03-19+at+6.29.14+PM.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8658731852844520209.post-7460676242485811719</id><published>2019-02-24T15:25:00.000-05:00</published><updated>2019-02-24T16:30:15.244-05:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Audit"/><category scheme="http://www.blogger.com/atom/ns#" term="powercli"/><category scheme="http://www.blogger.com/atom/ns#" term="powershell"/><category scheme="http://www.blogger.com/atom/ns#" term="Report"/><category scheme="http://www.blogger.com/atom/ns#" term="VMWare"/><title type='text'>PowerCLI: Getting List of VMs Created in vCenter</title><content type='html'>&lt;div dir=&quot;auto&quot;&gt;
On my previous post, I was wrote about auditing reconfiguration task on specific VMs. But this time I simply wanted to get a full list of VMs created in vCenter. For this task I used a script from a website you probably already know &quot;Virtu-Al.net&quot;:&lt;/div&gt;
&lt;blockquote&gt;
Get-VIEvent&amp;nbsp;-maxsamples&amp;nbsp;10000&amp;nbsp;|where&amp;nbsp;{$_.Gettype().Name-eq&quot;VmCreatedEvent&quot;&amp;nbsp;-or&amp;nbsp;$_.Gettype().Name-eq&amp;nbsp;&quot;VmBeingClonedEvent&quot;&amp;nbsp;-or&amp;nbsp;$_.Gettype().Name-eq&amp;nbsp;&quot;VmBeingDeployedEvent&quot;} |SortCreatedTime&amp;nbsp;-Descending&amp;nbsp;|Select&amp;nbsp;CreatedTime, UserName,FullformattedMessage&amp;nbsp;-First&amp;nbsp;10&lt;/blockquote&gt;
&lt;div dir=&quot;ltr&quot;&gt;
As you can see the script pulls max sample of 10K objects, what happen when I run this in my vCenter. Two things normally happens:&lt;/div&gt;
&lt;div dir=&quot;ltr&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div dir=&quot;ltr&quot;&gt;
- You get couple or no VMs  when you know that is not true.&lt;i&gt; &lt;/i&gt;Then you try to increasing max sample to retrieve more events and you run into an issue.&lt;/div&gt;
&lt;div dir=&quot;ltr&quot;&gt;
&lt;i&gt;&lt;br /&gt;&lt;/i&gt;&lt;/div&gt;
&lt;div dir=&quot;ltr&quot;&gt;
- You get the deserializing error message when increasing the max sample number. Sometimes it will happen at 10k if not it will definitely occur if you increase that number to 100k:&lt;/div&gt;
&lt;blockquote class=&quot;tr_bq&quot;&gt;
&lt;i&gt;Get-VIEvent: Error in deserializing body of reply message for operation  &#39;ReadPreviousEvents&#39;.&lt;/i&gt; &lt;/blockquote&gt;
&lt;div dir=&quot;ltr&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh0h-9UrBvV1A4v8mmWgWjUeNcjbX4GXAp1nJlXk_bl9DvixaFfY-94tNWVYE74ZLZuntLuq4n0e1cuwYzHvetcNlwTb9M9TL-bJGbliXGDud300vxfO9W99U9AI2o7vpcX4aRrdHz6O4xw/s1600/Screen+Shot+2019-02-24+at+3.24.34+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;194&quot; data-original-width=&quot;1600&quot; height=&quot;47&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh0h-9UrBvV1A4v8mmWgWjUeNcjbX4GXAp1nJlXk_bl9DvixaFfY-94tNWVYE74ZLZuntLuq4n0e1cuwYzHvetcNlwTb9M9TL-bJGbliXGDud300vxfO9W99U9AI2o7vpcX4aRrdHz6O4xw/s400/Screen+Shot+2019-02-24+at+3.24.34+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;centered-image&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div dir=&quot;ltr&quot;&gt;
&lt;br /&gt;
Well that is because you are using old version of PowerCLI. This occurred to me on a system running PowerCLI 6.5.x, and according to few articles and KB doc VMware was aware of this and was going to fix.&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgFLpOdRcyrBPgmGpZlyrNBZ23wceIdQRLaSyHZ76WffQNiSvOhUyRS1dXQn3FZiib8-6CcPcuCisUOFzA_8om4G363maKQB6Ua20BTNn4jJ2X0RBlpmpYDmSWl8QeCLfgL_8IAGaIhU8Hh/s1600/Screen+Shot+2019-02-24+at+3.33.44+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;324&quot; data-original-width=&quot;1168&quot; height=&quot;110&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgFLpOdRcyrBPgmGpZlyrNBZ23wceIdQRLaSyHZ76WffQNiSvOhUyRS1dXQn3FZiib8-6CcPcuCisUOFzA_8om4G363maKQB6Ua20BTNn4jJ2X0RBlpmpYDmSWl8QeCLfgL_8IAGaIhU8Hh/s400/Screen+Shot+2019-02-24+at+3.33.44+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;centered-image&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;&quot; dir=&quot;ltr&quot;&gt;
&lt;br /&gt;
Well VMware did kept their promise. Tested the same script with PowerCLI 11.0# and issue was gone. Increased the max sample up to 300K and no error. &lt;/div&gt;
&lt;div class=&quot;centered-image&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh-46UoOnaiEhBw6oDI7Y8GzSjzLwW5PtR-56oKaVrPwV3ihNcViHBDtHOyvirLR-PmO8E56feOVFUIWoiqBs_VY4LVwcndJq_rHrmeF0fFJDDZnEXVpRD42w3dltTka8dTLYomcB_Hmlu2/s1600/Screen+Shot+2019-02-24+at+3.36.47+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;349&quot; data-original-width=&quot;1600&quot; height=&quot;86&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh-46UoOnaiEhBw6oDI7Y8GzSjzLwW5PtR-56oKaVrPwV3ihNcViHBDtHOyvirLR-PmO8E56feOVFUIWoiqBs_VY4LVwcndJq_rHrmeF0fFJDDZnEXVpRD42w3dltTka8dTLYomcB_Hmlu2/s400/Screen+Shot+2019-02-24+at+3.36.47+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;centered-image&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;&quot; dir=&quot;ltr&quot;&gt;
&lt;br /&gt;
Keep in mind that the larger the number of samples you are trying to collect the longer it will take. In the next exercise, I will pull max sample of 400K and use the &quot;measure-command&quot; to measure how long this script took to complete.&lt;/div&gt;
&lt;div class=&quot;&quot; dir=&quot;ltr&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;&quot; dir=&quot;ltr&quot;&gt;
If you are not familiar with the &quot;Measure-Command&quot; command-let you might want to check it out. Simple to use simply put in between the bracket code wish to execute. In this case, I want run Get-ViEvent and 400K max samples. As you see in the screenshot it took about 5mins to complete(not as bad as I thought) and I got 321800. This mean it only had 320K events.&amp;nbsp;&lt;/div&gt;
&lt;div class=&quot;&quot; dir=&quot;ltr&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiMJoPPVjUebTywuQ2R9ST-dr5Ooiv-NwMb6fzCXbL39zZkRPRyQhsz-CILkNwAnJ87MzyiZpNlMBRfJkrwqsPra1Yi5Sh_9KWCoIf21FvV99XNMdBMOfMIEgfPJjTLb2-qBX9yke7eYDCR/s1600/Screen+Shot+2019-02-24+at+3.57.20+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;534&quot; data-original-width=&quot;1118&quot; height=&quot;152&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiMJoPPVjUebTywuQ2R9ST-dr5Ooiv-NwMb6fzCXbL39zZkRPRyQhsz-CILkNwAnJ87MzyiZpNlMBRfJkrwqsPra1Yi5Sh_9KWCoIf21FvV99XNMdBMOfMIEgfPJjTLb2-qBX9yke7eYDCR/s320/Screen+Shot+2019-02-24+at+3.57.20+PM.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;&quot; dir=&quot;ltr&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;&quot; dir=&quot;ltr&quot;&gt;
If want to find out how far back you went simply subtract the &quot;CreatedTime&quot; from the last event from today&#39;s date. In my case it was about 30 days 17 hrs. So my vCenter currently retaining about 30days of data. To get more than that might require adjusting event retention on vCenter, this will cause your vCenter to eat up more disk space.&lt;/div&gt;
&lt;div class=&quot;&quot; dir=&quot;ltr&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgh9aoUYbE-ReK3W_B0L-FYl_cSlKy84RkUR9tMMFXusplQCM8Re80Xt-MkpBK0KfoXqlMUZsOy1NILHlMOZJbKiRQksi7pCRQaLBVgfnR0TnVUJoGnKrAwle-oVBcrvVWJfZvr3KMVRw6j/s1600/Screen+Shot+2019-02-24+at+4.02.36+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;388&quot; data-original-width=&quot;866&quot; height=&quot;143&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgh9aoUYbE-ReK3W_B0L-FYl_cSlKy84RkUR9tMMFXusplQCM8Re80Xt-MkpBK0KfoXqlMUZsOy1NILHlMOZJbKiRQksi7pCRQaLBVgfnR0TnVUJoGnKrAwle-oVBcrvVWJfZvr3KMVRw6j/s320/Screen+Shot+2019-02-24+at+4.02.36+PM.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;&quot; dir=&quot;ltr&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;&quot; dir=&quot;ltr&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;&quot; dir=&quot;ltr&quot;&gt;
But let&#39;s work with what we got, I like doing break my scripts in sections. Notice I stored results of the &quot;&lt;b&gt;Get-ViEvent -MaxSample 400000&lt;/b&gt;&quot; into $evt variable without using any filters. This way I can recycle the data,&amp;nbsp; know how many events was collected in case, and how many of those events are actually relevant.&lt;/div&gt;
&lt;div class=&quot;&quot; dir=&quot;ltr&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;&quot; dir=&quot;ltr&quot;&gt;
Now we can apply all filters, script takes lot less time to run:&lt;/div&gt;
&lt;blockquote class=&quot;tr_bq&quot;&gt;
&lt;i&gt;$created = $evt | where {$_.Gettype().Name-eq &quot;VmCreatedEvent&quot; -or $_.Gettype().Name-eq &quot;VmBeingClonedEvent&quot; -or $_.Gettype().Name-eq &quot;VmBeingDeployedEvent&quot;}&amp;nbsp;&lt;/i&gt;&lt;/blockquote&gt;
After applying filters to get VMs created/cloned/deployed got 17 items.&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgd7i2F9EOLKvJOI-q96wANCkk0t3N9LVanzWKcH3uxxXvnrz96f8TKlZCemI6m3Ob-s1cmyZmJzhkP8xK10OMC_jq2ZFEBtwfoRMu9wwQ38ZyLeXkbTQO8VDWd6OiU155uAJnBpWy29Yva/s1600/Screen+Shot+2019-02-24+at+4.18.08+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;110&quot; data-original-width=&quot;1600&quot; height=&quot;27&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgd7i2F9EOLKvJOI-q96wANCkk0t3N9LVanzWKcH3uxxXvnrz96f8TKlZCemI6m3Ob-s1cmyZmJzhkP8xK10OMC_jq2ZFEBtwfoRMu9wwQ38ZyLeXkbTQO8VDWd6OiU155uAJnBpWy29Yva/s400/Screen+Shot+2019-02-24+at+4.18.08+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
To view these items in pretty formatted view apply another filter and sort by date.&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjWth3T0Kn3KTQdRnIdWXcCzaRZHAfgGOT1J2C2vazx_iSNZPFvcEcI3tO2EvklVpqrpt6udStBym-3vlBB8gYW9USVXqty4nEZcyShZz5tTvgC9X6lHWLNwrLlqkCIzaOknKIRmMFYQfwu/s1600/Screen+Shot+2019-02-24+at+4.16.45+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;560&quot; data-original-width=&quot;1582&quot; height=&quot;141&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjWth3T0Kn3KTQdRnIdWXcCzaRZHAfgGOT1J2C2vazx_iSNZPFvcEcI3tO2EvklVpqrpt6udStBym-3vlBB8gYW9USVXqty4nEZcyShZz5tTvgC9X6lHWLNwrLlqkCIzaOknKIRmMFYQfwu/s400/Screen+Shot+2019-02-24+at+4.16.45+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;&quot; dir=&quot;ltr&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;&quot; dir=&quot;ltr&quot;&gt;
Hopes this help understand when pulling &quot;Get-VIEvents&quot; from vCenter. If you need to pull other reports that might be stored in that $evt variable this might be the time to do them...&lt;/div&gt;
&lt;div class=&quot;&quot; dir=&quot;ltr&quot;&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://fdo-workspace.blogspot.com/feeds/7460676242485811719/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://fdo-workspace.blogspot.com/2019/02/powercli-getting-list-of-vms-created-in.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/7460676242485811719'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/7460676242485811719'/><link rel='alternate' type='text/html' href='http://fdo-workspace.blogspot.com/2019/02/powercli-getting-list-of-vms-created-in.html' title='PowerCLI: Getting List of VMs Created in vCenter'/><author><name>fdo</name><uri>http://www.blogger.com/profile/16882300714528613456</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhndsbgzepfJ0U5gXwY3zzRcGOqiMcblr09VzwWLCMA_waqC9FUthSCa8n91RwqW_kZXNo2si5UU3N5Ex6UJbYkcUpcJnxOQw6jPOBYuux7fomIpI0UUf8vOXyBT7hyuuE/s113/IMG_5942.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh0h-9UrBvV1A4v8mmWgWjUeNcjbX4GXAp1nJlXk_bl9DvixaFfY-94tNWVYE74ZLZuntLuq4n0e1cuwYzHvetcNlwTb9M9TL-bJGbliXGDud300vxfO9W99U9AI2o7vpcX4aRrdHz6O4xw/s72-c/Screen+Shot+2019-02-24+at+3.24.34+PM.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8658731852844520209.post-4662225989131909823</id><published>2019-01-23T17:04:00.000-05:00</published><updated>2019-01-23T18:07:40.739-05:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="powercli"/><category scheme="http://www.blogger.com/atom/ns#" term="powershell"/><category scheme="http://www.blogger.com/atom/ns#" term="Report"/><category scheme="http://www.blogger.com/atom/ns#" term="vCenter"/><category scheme="http://www.blogger.com/atom/ns#" term="VMWare"/><category scheme="http://www.blogger.com/atom/ns#" term="vsphere"/><title type='text'>Simple PowerCLI Script to Audit a VM Task and Events - Reconfiguration Changes</title><content type='html'>&lt;div dir=&quot;auto&quot;&gt;
Purpose of this article is to show how generate a quick report to audit tasks and events on a target VM. The events in this report will be similar to what we see in vCenter VM Task/Events. If the events you are looking for are too old it might not show. However, this report will provide you with a more in depth detail of each task. This is useful when tracking specific tasks such as what reconfiguration was made, changes by who, relocated from to where to where, etc.&amp;nbsp;&lt;/div&gt;
&lt;div dir=&quot;auto&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
For this exercise, I deployed a test vm using one my scripts. Script will clone vm from template and perform a series of tasks. Next, we will be using the report to check what happened during the process. BTW, PowerShell v5.1 and PowerCli v10.1 was used to run the commands. Environment is running on a vCenter v6.0xx, but anything done in this exercise should work on any versions of vCenter.&lt;br /&gt;
&lt;br /&gt;
Once the VM deployment was completed. Here list of Task shown in vSphere Web Client.&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjWc5BtQLOYxnqbX3rkNuX9Hc2vgFgRXK8V_pTY7iEiGfPBDRrtItmEsmWqehmAPRxHF49HoFi4EeRPDB9cOYCGogwcYMFs8yklQGxL9yIQgs8_X_VFmYf0nVo_lNKPETQq8oAYDM_y_Ggo/s1600/Screen+Shot+2019-01-23+at+4.41.02+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;308&quot; data-original-width=&quot;890&quot; height=&quot;217&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjWc5BtQLOYxnqbX3rkNuX9Hc2vgFgRXK8V_pTY7iEiGfPBDRrtItmEsmWqehmAPRxHF49HoFi4EeRPDB9cOYCGogwcYMFs8yklQGxL9yIQgs8_X_VFmYf0nVo_lNKPETQq8oAYDM_y_Ggo/s640/Screen+Shot+2019-01-23+at+4.41.02+PM.png&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
Here is the list of Events &lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg6Xcr2UqTkJCNqKZQS8wr0BiQtA85l5ghJkNjKqfdyt0PccN5ziT_dwkKfREeNyvzPeEx8btjb0MVkfKoXKXSKhSIa_HBQKqnjZ6k4RmKncBfOIqk_kQb2wyjHKTTemq-5_sLdGcPJ_UdD/s1600/Screen+Shot+2019-01-23+at+4.46.33+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;466&quot; data-original-width=&quot;818&quot; height=&quot;363&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg6Xcr2UqTkJCNqKZQS8wr0BiQtA85l5ghJkNjKqfdyt0PccN5ziT_dwkKfREeNyvzPeEx8btjb0MVkfKoXKXSKhSIa_HBQKqnjZ6k4RmKncBfOIqk_kQb2wyjHKTTemq-5_sLdGcPJ_UdD/s640/Screen+Shot+2019-01-23+at+4.46.33+PM.png&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
Now lets run the script to get all events using &lt;strong&gt;Get-VIEvent&lt;/strong&gt;:&lt;br /&gt;
&lt;blockquote&gt;
$vmname = “testdp-1&quot;&lt;br /&gt;
$vm = get-vm $vmname &lt;br /&gt;
$evt = $vm | Get-VIEvent &lt;br /&gt;
#or if you prefer a one liner &lt;br /&gt;
get-vm “tested-1” |&amp;nbsp;Get-VIEvent &lt;/blockquote&gt;
You should see the following output &lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEihgb66flwrJv4hlOyEwB-53TCo5x_HdQBwtmhzwOChvSlWrOT-taM-IG6SBYy_ybOCw2V0pmfUln4Mipu_TAV4s4enXo_2mgorhxmvGWSYUaesFJkmo73BxHV65WzhwwnkrP4d8F1x5JTA/s1600/Screen+Shot+2019-01-23+at+4.48.21+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;434&quot; data-original-width=&quot;630&quot; height=&quot;440&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEihgb66flwrJv4hlOyEwB-53TCo5x_HdQBwtmhzwOChvSlWrOT-taM-IG6SBYy_ybOCw2V0pmfUln4Mipu_TAV4s4enXo_2mgorhxmvGWSYUaesFJkmo73BxHV65WzhwwnkrP4d8F1x5JTA/s640/Screen+Shot+2019-01-23+at+4.48.21+PM.png&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
Script returned a long list of events. To make this data bit easier to read we can grab CreatedDate and FullFormatedMessage field, format as table and sort it by date.&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjDIEozENRokN2CBJkj9ExxnbJEmLqX8GhpSewPPqkH9j5QmYg5HgsNRFX_E919lSPHgToZNr-0DKJSxSurfUSt6aJKUKHhvIqdFvDMn04lpZwNsyKiF0KDcdxE_j531Pv1KUcKMS749k3N/s1600/Screen+Shot+2019-01-23+at+4.50.49+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;313&quot; data-original-width=&quot;1087&quot; height=&quot;184&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjDIEozENRokN2CBJkj9ExxnbJEmLqX8GhpSewPPqkH9j5QmYg5HgsNRFX_E919lSPHgToZNr-0DKJSxSurfUSt6aJKUKHhvIqdFvDMn04lpZwNsyKiF0KDcdxE_j531Pv1KUcKMS749k3N/s640/Screen+Shot+2019-01-23+at+4.50.49+PM.png&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
From this list we can see the following:&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;Date and Time where VM was created &lt;/li&gt;
&lt;li&gt;Name of the VM it was cloned from &lt;/li&gt;
&lt;li&gt;VM was Reconfigured several times &lt;/li&gt;
&lt;li&gt;VM hardware compatibility was upgraded &lt;/li&gt;
&lt;li&gt;VM hardware compatibility upgrade failed &lt;/li&gt;
&lt;li&gt;VM was powered on and relocated &lt;/li&gt;
&lt;li&gt;Started OS Customization &lt;/li&gt;
&lt;li&gt;OS Customization succeed &lt;/li&gt;
&lt;li&gt;VMWare Tools upgrade was initiated.&lt;/li&gt;
&lt;/ul&gt;
&lt;br /&gt;
Now, lets try digging deeper into reconfiguration tasks. First, grab only task contains reconfigure. Here is a table format view to make sure the filter is working.&lt;br /&gt;
And here is list view of the same list of reconfigure events. Notice is the one that “Task: Reconfigure virtual machine” contains information regarding the reconfigure task, server name, event chain id of actual reconfigure task. Those starting with &quot;Reconfigured.” are the one that contains the ConfigSpec details.&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjgv48TV8ZlrBJNTFqfvUiRJ8IppIjd7XL78KlDZ1f9r-egAS2jYduNVAWIb_Fflriw7nGWrj3rrRWqEoI3U-Vf3nnHX2Gx-Vb8b5WNFxK6zY-QXBojgsSFxFAai7nQWWVCjWrJD45HVzv5/s1600/Screen+Shot+2019-01-23+at+4.52.55+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;406&quot; data-original-width=&quot;589&quot; height=&quot;275&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjgv48TV8ZlrBJNTFqfvUiRJ8IppIjd7XL78KlDZ1f9r-egAS2jYduNVAWIb_Fflriw7nGWrj3rrRWqEoI3U-Vf3nnHX2Gx-Vb8b5WNFxK6zY-QXBojgsSFxFAai7nQWWVCjWrJD45HVzv5/s400/Screen+Shot+2019-01-23+at+4.52.55+PM.png&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
Lets take a closer look to the content of the task with ConfigSpec. You could do this couple different ways. By accessing the task and open the ConfigSpec parameter or export output into a JSON file.&lt;br /&gt;
&lt;strong&gt;Method 1 - $event[index].ConfigSpec &lt;/strong&gt;&lt;br /&gt;
- This task was changing CPU and Memory&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiESIJbQ9fFVw5GvdV2EiMrZqhifgGttBg5aKv9FJgOS2IL7QEIAOpHg2vyJTZ_xtCQ4UIoDKreY_WUVwFGPCWcOWx7XUMZ1V2gGZtIWxOArV8E7NVG0mvlMACTiD1JsfPULvjFQXDv2x9C/s1600/Screen+Shot+2019-01-23+at+4.53.35+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;475&quot; data-original-width=&quot;469&quot; height=&quot;400&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiESIJbQ9fFVw5GvdV2EiMrZqhifgGttBg5aKv9FJgOS2IL7QEIAOpHg2vyJTZ_xtCQ4UIoDKreY_WUVwFGPCWcOWx7XUMZ1V2gGZtIWxOArV8E7NVG0mvlMACTiD1JsfPULvjFQXDv2x9C/s400/Screen+Shot+2019-01-23+at+4.53.35+PM.png&quot; width=&quot;393&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;strong&gt;Method 2 - Export everything to a json file &lt;/strong&gt;&lt;br /&gt;
&lt;blockquote&gt;
$vmname = “testdp-1*&quot;&lt;br /&gt;
$vm = get-vm $vmname &lt;br /&gt;
$evt = $vm | Get-VIEvent &lt;br /&gt;
$file = &quot;.\&quot; + $vmname.Replace(&quot;*&quot;,&quot;&quot;)+&quot;.json&quot;&lt;br /&gt;
$evt | ConvertTo-Json -Depth 10 | Out-File $file &lt;/blockquote&gt;
Sample output and checking out the ConfigSpec&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh1iIzYePUJrBZNtKMJsHYWfpMUQgGQouCFOnqvWy9L0_GRCjW-THhfixjiWgWGCuHEVU_QoWZA_FY_UzdJ-EGZr1x3NyG7ht_ZjTmcrlTqTaoSS-aeJFTzvLv7f_8RfKazOjnlOA8WURk0/s1600/Screen+Shot+2019-01-23+at+4.55.05+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;748&quot; data-original-width=&quot;1135&quot; height=&quot;419&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh1iIzYePUJrBZNtKMJsHYWfpMUQgGQouCFOnqvWy9L0_GRCjW-THhfixjiWgWGCuHEVU_QoWZA_FY_UzdJ-EGZr1x3NyG7ht_ZjTmcrlTqTaoSS-aeJFTzvLv7f_8RfKazOjnlOA8WURk0/s640/Screen+Shot+2019-01-23+at+4.55.05+PM.png&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
Following Reconfigure.ConfigSpec was to change CPU, Memory settings.&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjl4LmzRdMWX0zk7GohPTDMCLdhtmhkXZ8PxldcycXtZFVluJO2AtBRnB22xaifWNaAX8YcAnHgNwBM3mWYM8MjydW2pByd5YJAz3iJvA7vBleajnmO6Y1Ef1yful-1w1GLji4PUcNzRmiC/s1600/Screen+Shot+2019-01-23+at+4.55.40+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;760&quot; data-original-width=&quot;1361&quot; height=&quot;355&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjl4LmzRdMWX0zk7GohPTDMCLdhtmhkXZ8PxldcycXtZFVluJO2AtBRnB22xaifWNaAX8YcAnHgNwBM3mWYM8MjydW2pByd5YJAz3iJvA7vBleajnmO6Y1Ef1yful-1w1GLji4PUcNzRmiC/s640/Screen+Shot+2019-01-23+at+4.55.40+PM.png&quot; width=&quot;640&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;br /&gt;
Here another Reconfigure Task ConfigSpec that modified the VM NIC Mapping&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
As promised in the title this is a very &lt;strong&gt;simple&lt;/strong&gt; script that can generate powerful report. This same report can be formated and ouput to a CSV file or even a HTML or Word document using PSCribo.</content><link rel='replies' type='application/atom+xml' href='http://fdo-workspace.blogspot.com/feeds/4662225989131909823/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://fdo-workspace.blogspot.com/2019/01/simple-powercli-script-to-audit-vm-task.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/4662225989131909823'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/4662225989131909823'/><link rel='alternate' type='text/html' href='http://fdo-workspace.blogspot.com/2019/01/simple-powercli-script-to-audit-vm-task.html' title='Simple PowerCLI Script to Audit a VM Task and Events - Reconfiguration Changes'/><author><name>fdo</name><uri>http://www.blogger.com/profile/16882300714528613456</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhndsbgzepfJ0U5gXwY3zzRcGOqiMcblr09VzwWLCMA_waqC9FUthSCa8n91RwqW_kZXNo2si5UU3N5Ex6UJbYkcUpcJnxOQw6jPOBYuux7fomIpI0UUf8vOXyBT7hyuuE/s113/IMG_5942.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjWc5BtQLOYxnqbX3rkNuX9Hc2vgFgRXK8V_pTY7iEiGfPBDRrtItmEsmWqehmAPRxHF49HoFi4EeRPDB9cOYCGogwcYMFs8yklQGxL9yIQgs8_X_VFmYf0nVo_lNKPETQq8oAYDM_y_Ggo/s72-c/Screen+Shot+2019-01-23+at+4.41.02+PM.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8658731852844520209.post-1288907120896635285</id><published>2019-01-04T10:13:00.001-05:00</published><updated>2019-01-04T10:13:51.738-05:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Cisco"/><category scheme="http://www.blogger.com/atom/ns#" term="ESXI 6.5"/><category scheme="http://www.blogger.com/atom/ns#" term="UCS"/><category scheme="http://www.blogger.com/atom/ns#" term="VMWare"/><title type='text'>Cisco UCS-C220-M5 with ESXi v6.5x not Detecting 1GB X550-T2 NIC</title><content type='html'>&lt;p dir=&quot;auto&quot;&gt;Today got reached out to deal with an issue 1GB NIC was not showing up on a bunch of Cisco UCSC-C220-M5##. Immediately suspected it was a missing driver issue on the original ESXi v6.5u2x. First thing first access the CIMC of the CISCO UCS host and checked Invenotry / Network Adapters and the Cisco LOM X550-T2 was showing fine.&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgKCIPcP1hfvifG5AsoVn6sG7bB92BaOAhr8euFrAfS-hRTFTdzASbMho9fa4yBfntd7BVHjqa_JNuBlbyJMiT5vs4bKRgEvlmB2OftZa2bp4M0gpW_MztUkDSriH6yeLUl_aRcminTv8Ft/s9999/Screen-Shot-2019-01-04-at-9.33.39-AM.png&quot; width=&quot;722&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;&lt;p dir=&quot;auto&quot;&gt;The only to manage the host was using CIMC KVM/virtual console. Ran “&lt;em&gt;&lt;strong&gt;esxcli software vib list&lt;/strong&gt;&lt;/em&gt;” command and found ixgben v1.4.1.x and based on the VMware Compatibility Guide it should have worked.&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjH1fYvbcqO0b2_5MiyTIN1MLaVzzdYf3IHEM5jIzhkfVtcnCnvg8Nq8fuel1jWzd6XfjGcdkpJ630foCGHDf4qdx2M0MK_Tsa9eKLv19tw9-GQ4ZJ2Yx_3lb8Rr5hpTppGC_kjEmB9Rkmp/s9999/Screen-Shot-2019-01-04-at-9.26.56-AM.png&quot; width=&quot;1040&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;p dir=&quot;ltr&quot;&gt;If you track down the VMware ESXi 6.0 ixgben 1.4.1 driver notes it clearly states is compatible with ESXi6.5 and x550. For some reason the 10G device which uses the same driver is fine.&lt;br&gt;&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh2X-cuFSvddg-S6uvvi6QUnjKylBTvk6UR_m9uquWoERYV1h0zdwC3CGBgSYyiybDT9ZpDhVezKfPR-WB-B8lCt9NXF9RHfcKqVkswYmWglyVY6nbqO5f8SnT4VJ7GZRc1PdBRmP_SVMQn/s9999/Screen-Shot-2019-01-04-at-9.37.55-AM.png&quot; width=&quot;1035&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;p dir=&quot;ltr&quot;&gt;Anyway, on an quick attempt to fix issue this downloaded the latest &lt;em&gt;&lt;strong&gt;ixgben version 1.7.10&lt;/strong&gt;&lt;/em&gt;, created an iso, mount to host via CIMC virtual console, rebooted and still wouldn’t work. At the point the solution is to use the Cisco Custom Image for ESXi 6.5u2 GA ISO from the VMware Website.&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj-0tKuSNSNpmBY6WtqlEAEJgaILzr1LXAQPB8qY6lFPA24CW7KI7mAZDIieTtHscrl0MunE5ZnegDEmBC6byWZLV3uGEm1UB0Jgxz5jxegLd0JcxPsmJ8IV5Tpw958mWEVsk5RjXB6HocT/s9999/Screen-Shot-2019-01-04-at-9.28.55-AM.png&quot; width=&quot;1066&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;p dir=&quot;ltr&quot;&gt;This issue can be resolved by simply re-installing ESXi using the Cisco Custom Image for ESXi 6.5U2 GA Install CD ISO, but for learning purpose will be using the offline bundle zip file instead. Because we do not have network/ssh access, the only way present these files is via ISO and is already a build-in utility under Virtual Media to Create Image.&lt;/p&gt;&lt;h3&gt;Creating ISO with Virtual Media / Create Image&lt;/h3&gt;&lt;p dir=&quot;ltr&quot;&gt;Process is straight forward, simply click Create Image &lt;br&gt;&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhDxbHswvxuL4nluUVGm2gynYBOwnw1bq9L7ohwRT6omMHAQZBbwaMAWzrp8dnp0VBOPc4dIPJ8iBAZ1v0uu9lJsYWXu8I-aEB5aAo6RgxfdHIiehDus6xZy6A2nnJ0YN_yjH705oxOTZ67/s9999/Screen-Shot-2019-01-04-at-9.44.27-AM.png&quot; width=&quot;513&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;p dir=&quot;ltr&quot;&gt;&lt;br&gt;Drop the zip file to create image&lt;br&gt;&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhWamBRvD9eFvx3byEwTEbfd715PAogSvOoOOnsPCftTZxPtRpxrYPPNMzMRnn6fGLLoXL4ctk9orpl67Fae9VMl7cVlujduDPAcXbL4UuBc4HiKQGhl_rh0qQa1zCG16CNJ3kcmzlcgrGm/s9999/Screen-Shot-2019-01-04-at-9.47.00-AM.png&quot; width=&quot;633&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;p dir=&quot;ltr&quot;&gt;&lt;br&gt;Download the ISO&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgVt2sG70erC_MJztRnn6uWe-5MsQ9A9ompj9Vox9Bqz2p_FM88V3auk7fttAITNMTQETU3ifNidSBrN8QTs8eYevvb0utyuE_vH6buoNTlp8V_tYsz5Pow7Um3OUqi_Ybag2zkCNO3pVUI/s9999/Screen-Shot-2019-01-04-at-9.48.03-AM.png&quot; width=&quot;631&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;p dir=&quot;ltr&quot;&gt;&lt;br&gt;Then, activate Virtual Devices and Map the ISO we just created.&lt;/p&gt;&lt;h3&gt;Mounting the CD-ROM in ESXi using vsish&lt;/h3&gt;&lt;p dir=&quot;ltr&quot;&gt;Once the ISO is mounted via CIMC / Virtual Device access your ESXi via shell and issue the following commands:&lt;/p&gt;&lt;blockquote&gt;&lt;p dir=&quot;ltr&quot;&gt;#start the cdrom module&lt;br&gt;vmkload_mod iso9660&lt;/p&gt;&lt;p dir=&quot;ltr&quot;&gt;# locate CD path&lt;/p&gt;&lt;p dir=&quot;ltr&quot;&gt;esxcfg-mpath -b | grep “CD-ROM&quot;&lt;/p&gt;&lt;p dir=&quot;ltr&quot;&gt;#mount the device&lt;/p&gt;&lt;p dir=&quot;ltr&quot;&gt;vsish -e set /vmkModules/iso9660/mount mpx.vmhba##.C0:T0:L0&lt;/p&gt;&lt;p dir=&quot;ltr&quot;&gt;#access mounted device under /vmfs/volumes/&lt;br&gt;#in my case there was folder called mpx.vmhba33.C0:T0:L0&lt;/p&gt;&lt;/blockquote&gt;&lt;p dir=&quot;ltr&quot;&gt;Now that CD-Drive is mounted and you can see the Custom Cisco Offline Bundle we can proceed with installation of vib file.&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj1RZIBrZGxMHYFKms7gj58BX4A-r9fIoEKz_trH5kcTK9pTn3OeEGFjm-iqQb82NezDT6eRd5Flb6VNn1KT0hDnOjypB52d62uvkiUq-E9k7MqTRg7GSi_lHrvVbXKQOvvaeqe8_bEP6ip/s9999/image2019-1-2_15-0-18.png&quot; width=&quot;942&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;p dir=&quot;ltr&quot;&gt;Note: Notice after issuing the esxcfg-mpath command it listed multiple paths (L0,L3,L5 and L6). I am not 100% why there are 4 different paths but mounting the one with L0 worked for me. I am assuming it can support mapping 4 iso files, or it might have detected the physical CD/DVD drive.&lt;/p&gt;&lt;h3&gt;Installing ESXi Patch / VIB Drivers using ESXCLI&lt;/h3&gt;&lt;p dir=&quot;ltr&quot;&gt;To install the patch use “&lt;strong&gt;esxcli software vib install -d “full path to zip file&lt;/strong&gt;&quot;&lt;/p&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjuxHbY2gOA7YjdZU5j7ATmkhwBQXhdB-J71wspTmI6Xw3edo7iDSTcwpZJrxWcDYRPo7p8-4I1sKNGfuXCgv_dA8H-qVsfYfUb6zNX8eGqaSS9UBca58doIjIGPFNxjZAWedp3RHt3GCUF/s9999/image2019-1-2_14-37-24.png&quot; width=&quot;1119&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;p dir=&quot;ltr&quot;&gt;Once installed perform a final reboot and check to make sure the X550 device is now showing.&lt;br&gt;&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhA1vjOPsH6_9uFC39Tn1jQBslgBEw62f-GZwf8P8-B2y5l2WF7dXtzlu-nnSNmk3cNN_q1EO6T_BX0feVJ2DRJXYSC-51ex8PP5XXo4x7F6SHdCWLtOfG355fS0f3IeueIh7FIUDw8kJ9q/s9999/image2019-1-2_15-17-21_png.jpg&quot; width=&quot;660&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fdo-workspace.blogspot.com/feeds/1288907120896635285/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://fdo-workspace.blogspot.com/2019/01/cisco-ucs-c220-m5-with-esxi-v65x-not.html#comment-form' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/1288907120896635285'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/1288907120896635285'/><link rel='alternate' type='text/html' href='http://fdo-workspace.blogspot.com/2019/01/cisco-ucs-c220-m5-with-esxi-v65x-not.html' title='Cisco UCS-C220-M5 with ESXi v6.5x not Detecting 1GB X550-T2 NIC'/><author><name>fdo</name><uri>http://www.blogger.com/profile/16882300714528613456</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhndsbgzepfJ0U5gXwY3zzRcGOqiMcblr09VzwWLCMA_waqC9FUthSCa8n91RwqW_kZXNo2si5UU3N5Ex6UJbYkcUpcJnxOQw6jPOBYuux7fomIpI0UUf8vOXyBT7hyuuE/s113/IMG_5942.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgKCIPcP1hfvifG5AsoVn6sG7bB92BaOAhr8euFrAfS-hRTFTdzASbMho9fa4yBfntd7BVHjqa_JNuBlbyJMiT5vs4bKRgEvlmB2OftZa2bp4M0gpW_MztUkDSriH6yeLUl_aRcminTv8Ft/s72-c/Screen-Shot-2019-01-04-at-9.33.39-AM.png" height="72" width="72"/><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8658731852844520209.post-5160047523133230226</id><published>2018-11-05T16:34:00.007-05:00</published><updated>2018-11-06T09:29:49.476-05:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="API"/><category scheme="http://www.blogger.com/atom/ns#" term="NSX"/><category scheme="http://www.blogger.com/atom/ns#" term="nsx manager"/><category scheme="http://www.blogger.com/atom/ns#" term="vCenter"/><title type='text'>NSX v6.2-v6.3 - Adding CLI user to NSX Manager GUI via PowerShell</title><content type='html'>&lt;p dir=&quot;auto&quot;&gt;This is actually an extention of my previous post &quot;&lt;a href=&quot;http://fdo-workspace.blogspot.com/2018/11/nsx-62x-63x-api-against-nsx-manager-403.html&quot; target=&quot;_blank&quot;&gt;NSX 6.2.x-6.3.x  - API against NSX Manager - 403 Forbidden&lt;/a&gt;”. On the post I used the curl command to add the cli user account into NSX Manager. Unfortunately the server where the command had to be run was a Windows machine so the only way around this was using PowerShell Invoke-WebRequest command.&lt;/p&gt;&lt;p dir=&quot;auto&quot;&gt;&lt;strong&gt;Note:&lt;/strong&gt; First part which is creating the CLI user account still needs to be done from the NSX Manager Console or SSH.&lt;/p&gt;&lt;p dir=&quot;auto&quot;&gt;Here are the examples provided by KB 2150736:&lt;/p&gt;&lt;p dir=&quot;auto&quot;&gt;&lt;strong&gt;Example 1:&lt;/strong&gt;&lt;br&gt;&lt;/p&gt;&lt;blockquote&gt;POST https://&amp;lt;NSXMGR_IP&amp;gt;/api/2.0/services/usermgmt/role/api_username?isCli=true &lt;br&gt;&amp;lt;accessControlEntry&amp;gt;&lt;br&gt;&amp;lt;role&amp;gt;auditor&amp;lt;/role&amp;gt;&lt;br&gt;&amp;lt;resource&amp;gt;&lt;br&gt;&amp;lt;resourceId&amp;gt;globalroot-0&amp;lt;/resourceId&amp;gt;&lt;br&gt;&amp;lt;/resource&amp;gt;&lt;br&gt;&amp;lt;/accessControlEntry&amp;gt;&lt;/blockquote&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;&lt;p&gt;&lt;strong&gt;Example 2:&lt;/strong&gt;&lt;/p&gt;&lt;p&gt;Continuing with the previous example from step 1, here is what the command would look like for curl:&lt;/p&gt;&lt;blockquote&gt;curl -v -H &quot;Content-Type:application/xml&quot; -k -u admin -X POST -d &quot;&amp;lt;accessControlEntry&amp;gt;&amp;lt;role&amp;gt;auditor&amp;lt;/role&amp;gt;&amp;lt;resource&amp;gt;&amp;lt;resourceId&amp;gt;globalroot-0&amp;lt;/resourceId&amp;gt;&amp;lt;/resource&amp;gt;&amp;lt;/accessControlEntry&amp;gt;&quot; https://&amp;lt;NSXMGR_IP&amp;gt;/api/2.0/services/usermgmt/role/api_username?isCli=true&lt;/blockquote&gt;&lt;p dir=&quot;ltr&quot;&gt;Using both example as reference created a PowerShell script that will do the job:&lt;/p&gt;&lt;p dir=&quot;ltr&quot;&gt;&lt;strong&gt;PowerCLI Script:&lt;/strong&gt;&lt;/p&gt;&lt;blockquote&gt;&lt;p dir=&quot;ltr&quot;&gt;#NSX Info&lt;br&gt;$nsx_admin = &quot;admin&quot;&lt;br&gt;$nsx_pwd = “adminPwd123!&quot;     &lt;br&gt;$nsx_mgr_ip= “nsxmgr_ip&quot;&lt;br&gt;#NewCLIAccount&lt;br&gt;$nsx_user = &quot;api_user&quot;&lt;/p&gt;&lt;p&gt;####### No changes below this line - Will add user as an &quot;Auditor&quot;&lt;/p&gt;&lt;p&gt;$BasicAuth =  $([Convert]::ToBase64String([Text.Encoding]::ASCII.GetBytes(&quot;$($nsx_admin):$($nsx_pwd)&quot;)))&lt;br&gt;$Authorization = &#39;Basic {0}&#39; -f $BasicAuth&lt;br&gt;$wrequest = &quot;https://&quot;+$nsx_mgr_ip+&quot;/api/2.0/services/usermgmt/role/&quot;+$nsx_user+&quot;?isCli=true&quot;&lt;/p&gt;&lt;p&gt;$body = @&quot;&lt;br&gt;&amp;lt;accessControlEntry&amp;gt;&lt;br&gt;&amp;lt;role&amp;gt;auditor&amp;lt;/role&amp;gt;&lt;br&gt;&amp;lt;resource&amp;gt;  &lt;br&gt;&amp;lt;resourceId&amp;gt;globalroot-0&amp;lt;/resourceId&amp;gt;&lt;br&gt;&amp;lt;/resource&amp;gt;&lt;br&gt;&amp;lt;/accessControlEntry&amp;gt;&lt;br&gt;&quot;@&lt;/p&gt;&lt;p&gt;$headers = @{&#39;Authorization&#39; = $Authorization}&lt;br&gt;Invoke-WebRequest -Uri $wrequest -Method POST -ContentType &quot;application/xml&quot; -Body $body -Headers $headers&lt;/p&gt;&lt;/blockquote&gt;&lt;p dir=&quot;ltr&quot;&gt;&lt;br&gt;&lt;strong&gt;Updates: &lt;/strong&gt;&lt;/p&gt;&lt;p dir=&quot;ltr&quot;&gt;If you are getting “The underlying connection was closed: Could not establish trust relationship for the SSL/TLS secure channel”. Add the following code before the Invoke-WebRequest and it should work.&lt;/p&gt;&lt;blockquote&gt;# Disable SSL/TLS Certificate Verification (for non-publically accessible servers)&lt;br&gt;add-type @&quot;&lt;br&gt;    using System.Net;&lt;br&gt;    using System.Security.Cryptography.X509Certificates;&lt;br&gt;    public class TrustAllCertsPolicy : ICertificatePolicy {&lt;br&gt;        public bool CheckValidationResult(&lt;br&gt;            ServicePoint srvPoint, X509Certificate certificate,&lt;br&gt;            WebRequest request, int certificateProblem) {&lt;br&gt;            return true;&lt;br&gt;        }&lt;br&gt;    }&lt;br&gt;&quot;@&lt;br&gt;[System.Net.ServicePointManager]::CertificatePolicy = New-Object TrustAllCertsPolicy&lt;/blockquote&gt;&lt;p dir=&quot;ltr&quot;&gt;&lt;br&gt;Here is what final script should look like:&lt;/p&gt;&lt;blockquote&gt;&lt;p dir=&quot;ltr&quot;&gt;#NSX Info&lt;br&gt;$nsx_admin = &quot;admin&quot;&lt;br&gt;$nsx_pwd = &quot;enter nsx admin password&quot;&lt;br&gt;$nsx_mgr_ip= &quot;#Nsx Manager Ip&quot;&lt;br&gt;#NewCLIAccount&lt;br&gt;$nsx_user = &quot;api_user&quot;&lt;/p&gt;&lt;p&gt;&lt;br&gt;####### No changes below this line - Will add user as an &quot;Auditor&quot;&lt;/p&gt;&lt;p&gt;&lt;br&gt;$BasicAuth =  $([Convert]::ToBase64String([Text.Encoding]::ASCII.GetBytes(&quot;$($nsx_admin):$($nsx_pwd)&quot;)))&lt;br&gt;$Authorization = &#39;Basic {0}&#39; -f $BasicAuth&lt;br&gt;$wrequest = &quot;https://&quot;+$nsx_mgr_ip+&quot;/api/2.0/services/usermgmt/role/&quot;+$nsx_user+&quot;?isCli=true&quot;&lt;/p&gt;&lt;p&gt;&lt;br&gt;# Disable SSL/TLS Certificate Verification (for non-publically accessible servers)&lt;br&gt;add-type @&quot;&lt;br&gt;    using System.Net;&lt;br&gt;    using System.Security.Cryptography.X509Certificates;&lt;br&gt;    public class TrustAllCertsPolicy : ICertificatePolicy {&lt;br&gt;        public bool CheckValidationResult(&lt;br&gt;            ServicePoint srvPoint, X509Certificate certificate,&lt;br&gt;            WebRequest request, int certificateProblem) {&lt;br&gt;            return true;&lt;br&gt;        }&lt;br&gt;    }&lt;br&gt;&quot;@&lt;br&gt;[System.Net.ServicePointManager]::CertificatePolicy = New-Object TrustAllCertsPolicy&lt;/p&gt;&lt;p&gt;&lt;br&gt;$body = @&quot;&lt;br&gt;&amp;lt;accessControlEntry&amp;gt;&lt;br&gt;&amp;lt;role&amp;gt;auditor&amp;lt;/role&amp;gt;&lt;br&gt;&amp;lt;resource&amp;gt;&lt;br&gt;&amp;lt;resourceId&amp;gt;globalroot-0&amp;lt;/resourceId&amp;gt;&lt;br&gt;&amp;lt;/resource&amp;gt;&lt;br&gt;&amp;lt;/accessControlEntry&amp;gt;&lt;br&gt;&quot;@&lt;/p&gt;&lt;p&gt;$headers = @{&#39;Authorization&#39; = $Authorization}&lt;br&gt;Invoke-WebRequest -Uri $wrequest -Method POST -ContentType &quot;application/xml&quot; -Body $body -Headers $headers&lt;/p&gt;&lt;/blockquote&gt;</content><link rel='replies' type='application/atom+xml' href='http://fdo-workspace.blogspot.com/feeds/5160047523133230226/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://fdo-workspace.blogspot.com/2018/11/nsx-v62-v63-adding-cli-user-to-nsx.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/5160047523133230226'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/5160047523133230226'/><link rel='alternate' type='text/html' href='http://fdo-workspace.blogspot.com/2018/11/nsx-v62-v63-adding-cli-user-to-nsx.html' title='NSX v6.2-v6.3 - Adding CLI user to NSX Manager GUI via PowerShell'/><author><name>fdo</name><uri>http://www.blogger.com/profile/16882300714528613456</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhndsbgzepfJ0U5gXwY3zzRcGOqiMcblr09VzwWLCMA_waqC9FUthSCa8n91RwqW_kZXNo2si5UU3N5Ex6UJbYkcUpcJnxOQw6jPOBYuux7fomIpI0UUf8vOXyBT7hyuuE/s113/IMG_5942.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8658731852844520209.post-8613692339862788120</id><published>2018-11-02T11:50:00.000-04:00</published><updated>2018-11-02T11:50:17.681-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="API"/><category scheme="http://www.blogger.com/atom/ns#" term="NSX"/><category scheme="http://www.blogger.com/atom/ns#" term="powershell"/><title type='text'>NSX 6.2.x-6.3.x  - API against NSX Manager - 403 Forbidden</title><content type='html'>&lt;p dir=&quot;auto&quot;&gt;I&#39;ve started looking into all PowerShell Modules available to extract information from NSX. The environments I am working with runs NSX v6.2.x-v6.3.x. Started with Rest API commands and got stuck with the 403 Forbidden error message. I made sure it was not permission issue so elevated my test account to Enterprise Administrator.  Also made sure it wasn&#39;t a port issue between the server and the NSX manager.  Check here for &lt;a href=&quot;https://docs.vmware.com/en/VMware-NSX-for-vSphere/6.3/com.vmware.nsx.upgrade.doc/GUID-E7C4E61C-1F36-457C-ACC5-EAF955C46E8B.html&quot; target=&quot;_blank&quot;&gt;Ports and Protocols Required by NSX&lt;/a&gt;.&lt;/p&gt;&lt;p dir=&quot;auto&quot;&gt;Then decided to try PowerNSX from the PowerShell Gallery and was still getting the same error message:&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiTPqpEgWvU56dXwAd7V9J1IiTfx5Yj-gcy1MNaTNRXXVGegA1JA2lfNk0ztrSySm-VzhGBR3hDg6lQi6bR0fMX1dUTozwpeDd-wPDrQGZFkSyUTXCXKt9-ycsLck9rU4M6vw10wPZRN1iT/s9999/10_159_81_166_-_2012_FDTRM1e3.jpg&quot; width=&quot;837&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;p&gt;&lt;br&gt;After poking around noticed several thing:&lt;br&gt;- vSphere local admin account (&lt;a href=&quot;mailto:administrator@vsphere.local&quot; target=&quot;_blank&quot;&gt;administrator@vsphere.local&lt;/a&gt; has no issues connecting to the NSX Manager and the account is an “Enterprise Administrator”, and so is my test account.&lt;br&gt;- There is an &lt;strong&gt;admin&lt;/strong&gt; account in v6.3.x is also able to connect using PowerNSX.&lt;br&gt;- Between NSX Manager 6.2.x and 6.3.x. In v6.3.x there is a Role called &quot;NSX CLI User&quot; which only the “admin” user has.&lt;br&gt;- Conclusion: Only the &lt;a href=&quot;http://administrator@vsphere.local/&quot; target=&quot;_blank&quot;&gt;administrator@vsphere.local&lt;/a&gt; and NSX Cli User are allowed to run APIs.&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg9nI3N654NgcSNFfwU0pbpLfKC4HUXjHGJ_3HLRLTmTdb2oARM-XvDS9QgPj8kPoX1bVgEYfvZnSs-potftBW75IM8T84xxWdc8mPeIVYRhH4-K4gIpqY9OCNKKt6y2IFzrGzDFG36INtq/s9999/Screen-Shot-2018-11-02-at-11.06.08-AM_1.png&quot; width=&quot;527&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;p dir=&quot;ltr&quot;&gt;And there is no way to assing the NSX CLI user role from the web client:&lt;br&gt;&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgxtK9bsRCpksGZCqkOwSllBed6akK431YRXjWKFi0PWnGblkTD5Cq2LYto2T1m1y1siM8pZwDGoHVTn5lDAPlQ69EUFvAu69dd0joXRr8jRBUfEgSDTyzaeCD2lJXMEWjms19SgLT9uSvK/s9999/Screen-Shot-2018-11-02-at-11.07.09-AM_1.png&quot; width=&quot;701&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;&lt;p&gt;Only way around is to Create a CLI USER.&lt;/p&gt;&lt;h3&gt;Step 1 - Creating the API/CLI user account in NSX Manager&lt;/h3&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;&lt;p&gt;SSH or Console into your NSX Manager with admin account&lt;/p&gt;&lt;blockquote&gt;&lt;p dir=&quot;ltr&quot;&gt;&lt;br&gt;## From nsx manager commandline enter command:&lt;br&gt;enter&lt;br&gt;configure terminal&lt;/p&gt;&lt;p dir=&quot;ltr&quot;&gt;nsxmgr(config)#&lt;br&gt;nsxmgr(config)# user &lt;strong&gt; api_user&lt;/strong&gt; password plaintext &lt;strong&gt;Password123!&lt;/strong&gt;&lt;br&gt;nsxmgr(config)#&lt;br&gt;nsxmgr(config)# user &lt;strong&gt; api_user&lt;/strong&gt; privilege web-interface &lt;br&gt;nsxmgr(config)# exit &lt;br&gt;nsxmgr#&lt;br&gt;nsxmgr# write memory&lt;/p&gt;&lt;p&gt;&lt;br&gt;## To verify account was created&lt;br&gt;show running-config&lt;br&gt;&lt;/p&gt;&lt;/blockquote&gt;&lt;h3&gt;Step 2 - Enable the new API/CLI account for web client use&lt;/h3&gt;&lt;p dir=&quot;ltr&quot;&gt;Next is to create the same user via API to make it appear in the web client. This can be perform via PostMan, RestClient or curl. Since I am using a Mac will be using curl.&lt;/p&gt;&lt;blockquote&gt;# Replace the NSXMGR_IP and the api_user&lt;br&gt;curl -v -H &quot;Content-Type:application/xml&quot; -k -u admin -X POST -d &quot;&amp;lt;accessControlEntry&amp;gt;&amp;lt;role&amp;gt;auditor&amp;lt;/role&amp;gt;&amp;lt;resource&amp;gt;&amp;lt;resourceId&amp;gt;globalroot-0&amp;lt;/resourceId&amp;gt;&amp;lt;/resource&amp;gt;&amp;lt;/accessControlEntry&amp;gt;&quot; https://&amp;lt;&lt;strong&gt;NSXMGR_IP&lt;/strong&gt;&amp;gt;/api/2.0/services/usermgmt/role/&lt;strong&gt;api_user&lt;/strong&gt;?isCli=true&lt;/blockquote&gt;&lt;p dir=&quot;ltr&quot;&gt;This command will add the &lt;strong&gt;api_user&lt;/strong&gt; account to webclient and assign &lt;strong&gt;Auditor&lt;/strong&gt; role. Log into webclient and make sure account was created. Change the role if desired.&lt;/p&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjuh_NBqofqehZx73K8_FO6YolpNSrC2bctUbDTH2DPa0nkFyBkxfTaop_v3mGCl8IvR4meQWxSqHWeohYHZ35skdXAG-5AAuY6KQfSfMVa3-tK5awbruAa9JVfDXS_bFz-wIJz43s7S6C7/s9999/Screen-Shot-2018-11-02-at-11.19.39-AM_1.png&quot; width=&quot;684&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;p dir=&quot;ltr&quot;&gt;&lt;br&gt;Link to VMware KB Doc:  &lt;a href=&quot;https://kb.vmware.com/s/article/2150736&quot; target=&quot;_blank&quot;&gt;Creating a User for NSX CLI and assigning API roles/permissions (2150736)&lt;/a&gt;&lt;/p&gt;&lt;p dir=&quot;ltr&quot;&gt;Now you should be able to connect using Connect-NSXServer command let. It will first ask for the NSX User credentials and next you will need to enter the vCenter credentials. If you API User account have enought right you can enter the credentials again. Mine is an “Auditor” so entering different vCenter credentials.&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjXn_ZEGS5qTclL9qOZMEvckJWQUKq7VwTmCpZBzUvowCFP6GdAKJ_VIX_qjbJVSsIhcjgctIrQEczVEYrkWVF7pJn02dzf_6jGNypjkFqeVYE1hVlcNVhIx4AjSnZ1l0ZmsykUWlY_40wS/s9999/10_159_81_166_-_2012_FDTRM1_11.jpg&quot; width=&quot;805&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;p dir=&quot;ltr&quot;&gt;You can also pass the vCenter Credentials using the -VIUsername and VIPassword. To get help on this command simple run &lt;strong&gt;Get-Help | Connect-NSXServer&lt;/strong&gt;&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjbYnhyU8mW2l2jkxQPPasOXCXYbpEy8rAiK0VEADt-mLSDZcCfW3FvaTuRgZJyAvKQ713RSLo6_Uw_wtZpf0ipY39WQS08rd8a1sBX5nFgSS7C_mYVN2V39oC7PXu8_18HambxGfS2afBz/s9999/Screen-Shot-2018-11-02-at-11.46.35-AM.png&quot; width=&quot;836&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/8613692339862788120'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/8613692339862788120'/><link rel='alternate' type='text/html' href='http://fdo-workspace.blogspot.com/2018/11/nsx-62x-63x-api-against-nsx-manager-403.html' title='NSX 6.2.x-6.3.x  - API against NSX Manager - 403 Forbidden'/><author><name>fdo</name><uri>http://www.blogger.com/profile/16882300714528613456</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhndsbgzepfJ0U5gXwY3zzRcGOqiMcblr09VzwWLCMA_waqC9FUthSCa8n91RwqW_kZXNo2si5UU3N5Ex6UJbYkcUpcJnxOQw6jPOBYuux7fomIpI0UUf8vOXyBT7hyuuE/s113/IMG_5942.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiTPqpEgWvU56dXwAd7V9J1IiTfx5Yj-gcy1MNaTNRXXVGegA1JA2lfNk0ztrSySm-VzhGBR3hDg6lQi6bR0fMX1dUTozwpeDd-wPDrQGZFkSyUTXCXKt9-ycsLck9rU4M6vw10wPZRN1iT/s72-c/10_159_81_166_-_2012_FDTRM1e3.jpg" height="72" width="72"/></entry><entry><id>tag:blogger.com,1999:blog-8658731852844520209.post-986475727592404026</id><published>2018-10-26T12:28:00.002-04:00</published><updated>2018-10-27T15:36:36.267-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="powercli"/><category scheme="http://www.blogger.com/atom/ns#" term="powershell"/><category scheme="http://www.blogger.com/atom/ns#" term="Script"/><category scheme="http://www.blogger.com/atom/ns#" term="vCenter"/><category scheme="http://www.blogger.com/atom/ns#" term="vsphere"/><title type='text'>PowerCLI - Create vCenter Nested Folder Structure from File</title><content type='html'>&lt;div dir=&quot;auto&quot;&gt;
I was in the process of migrating everything off my old lab into a new one. Already had script to rebuild all the datastores, vdswitches, port groups, etc but not the VM folders. Found the Get-FolderPath script created by LucD the does the hard work. BTW, attended couple of LucD&#39;s session in VMworld and it was awesome. He was in the documenting virtual environment with PowerShell session if I am not mistaken.&lt;/div&gt;
&lt;div dir=&quot;auto&quot;&gt;
Lets get right into it.&lt;/div&gt;
&lt;div dir=&quot;auto&quot;&gt;
&lt;strong&gt;Script syntax:&lt;/strong&gt;&lt;br /&gt;Get-FolderPath -Folder (Get-Folder -Name “FolderName&quot;)&lt;/div&gt;
&lt;br /&gt;
&lt;h3&gt;
Extracting Folder Structure from Source vCenter&lt;/h3&gt;
&lt;br /&gt;
&lt;div dir=&quot;auto&quot;&gt;
Now to here is a simple script to get a list all folders in your source datacenter. Must connect to your source vCenter first.&lt;/div&gt;
&lt;blockquote&gt;
&lt;div dir=&quot;auto&quot;&gt;
# Define dcname for VC with multiple datacenter&lt;/div&gt;
&lt;div dir=&quot;auto&quot;&gt;
$dcname = &quot;Maki-DC&quot;&lt;br /&gt;# Get list of VM folders only&lt;br /&gt;$folder_list = Get-Datacenter $dcname | Get-Folder -Type VM&lt;/div&gt;
# Loop Through list and get the folder path&lt;br /&gt;$folder_paths = $folders | % {(Get-FolderPath -folder $_).Path }&lt;br /&gt;# Export into a txt file&lt;br /&gt;$folder_paths | Out-File .\vm_folder_list.txt&lt;/blockquote&gt;
&lt;div dir=&quot;ltr&quot;&gt;
Once script is completed it should generate the following text file:&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEij0rKW7sNvXZsoIwNjli2DNjckWzhZj7dQryqsDBXg03_5ieZuqr9k5R28Q4HDUzHos8iNChhLKFkbnYZzpdedd1Sq_xlJVJBMpFrdaOjIJ-V4rXRfLerniD2n4IONsjI3mQ0JRUQC3s_S/s9999/Screen-Shot-2018-10-26-at-11.57.47-AM.png&quot; style=&quot;max-width: 100%;&quot; width=&quot;785&quot; /&gt;&lt;/div&gt;
&lt;div dir=&quot;ltr&quot;&gt;
Disconnect from source vCenter.&lt;/div&gt;
&lt;h3&gt;
Create Folder Structure in Destination vCenter&lt;/h3&gt;
&lt;div dir=&quot;ltr&quot;&gt;
Now here is the script to create the folder structure using text file generated.&lt;/div&gt;
&lt;blockquote&gt;
&lt;div dir=&quot;ltr&quot;&gt;
$folder_list = get-content .\vm_folder_list.txt&lt;br /&gt;$dcname = &quot;Maki-DC&quot;&lt;br /&gt;$datacenter = Get-Datacenter -Name $dcname&lt;/div&gt;
# Define VM root folder&lt;br /&gt;$rootFolder = $datacenter | Get-Folder -Name vm -Type VM&lt;br /&gt;Foreach ($folderpath in $folder_list){&lt;br /&gt;    $fullpath = $folderpath&lt;br /&gt;
# Split fullpath into individual folder names&lt;br /&gt;    $directorylist = $fullpath.split(&#39;\&#39;)&lt;br /&gt;    # Skip datacenter folder name &lt;br /&gt;    $directorylist = $directorylist | Where {$_ -ne $dcname}&lt;br /&gt;    $parentfolder = $rootFolder&lt;br /&gt;
# Loop throught the list of directories and create them if not found.&lt;br /&gt;    # Folder are created row by row, from left to right&lt;br /&gt;    # Datacenter Root \ Subfolder1 \ Subfolder2 \ Subfolder3 &lt;br /&gt;    # Once the folder is created it becomes the parent for subfolder.&lt;br /&gt;    Foreach ($directory in $directorylist){&lt;br /&gt;        $current = Get-Folder -name $directory -ErrorAction SilentlyContinue&lt;br /&gt;        if ($current -eq $null){&lt;br /&gt;            Write-Host &quot;Creating new folder $directory&quot; -ForegroundColor Green &lt;br /&gt;            $parentfolder = New-Folder -Name $directory -Location $parentfolder&lt;br /&gt;        }else{&lt;br /&gt;            Write-host &quot;Skip - Found folder $directory&quot; -ForegroundColor Yellow&lt;br /&gt;            $parentfolder = $current&lt;br /&gt;        }&lt;br /&gt;
}&lt;br /&gt;}&lt;/blockquote&gt;
&lt;br /&gt;
&lt;strong&gt;Note: &lt;/strong&gt;Before running the create folder structure script need to disconnect from your source vCenter and connect to the destination vCenter. It will cause issues if you are connected to both vCenter and both datacenter using same name.&lt;br /&gt;
&lt;div dir=&quot;ltr&quot;&gt;
This is what it looks like when script is running:&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEizKf3C_sIWInNNg8tXiI-kXqkrNpd3WfsvqeOSL_djRFJHiGSGCj6vOzOwAZJhyphenhyphenTf5zX1T97cZAKGZzlFuBJZNy_jRkNK1RtH5drHUogMiGx9VopBlHXn7FlMOTauaFc8rCiU9RvRO59zn/s9999/Screen-Shot-2018-10-26-at-12.20.02-PM.png&quot; style=&quot;max-width: 100%;&quot; width=&quot;479&quot; /&gt;&lt;/div&gt;
&lt;div dir=&quot;ltr&quot;&gt;
&lt;br /&gt;What the script is doing:&lt;/div&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhAwZH1F1SHWX40VYu3k79GSJVa1gkgaRye8ygR8-F0bLc3uLu3sxHJW_6rOB444fD18SbLZuspjbsBmL9CuuaKq65BJrIlAfXsh1WTsnrdfUtSSgDP5Z8KQnKWA_Q2JG4l-0tYIGjieRAo/s9999/10_159_81_166_-_2012_FDTRM1_9.jpg&quot; style=&quot;max-width: 100%;&quot; width=&quot;1015&quot; /&gt;&lt;/div&gt;
&lt;div dir=&quot;ltr&quot;&gt;
Once is done:&lt;/div&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi5nOknEsxrPHnWWZu3HE__QAUriJxAo86iEI8gBvzxs1p5aZsVgQU-DhA454JhZv8CyxKrwLb1PHveXfuVXWijG3YWFucpeQFXV7gnbDTzdt5J5E60xYo_ul-KPGRvkypjo3K7EiNpuabe/s9999/Screen-Shot-2018-10-26-at-12.26.57-PM.png&quot; style=&quot;max-width: 100%;&quot; width=&quot;383&quot; /&gt;&lt;/div&gt;
&lt;br /&gt;
&lt;br /&gt;
This was tested on vSphere v6.0 and v6.5...&lt;br /&gt;
&lt;br /&gt;</content><link rel='replies' type='application/atom+xml' href='http://fdo-workspace.blogspot.com/feeds/986475727592404026/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://fdo-workspace.blogspot.com/2018/10/powercli-create-nested-folder-structure.html#comment-form' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/986475727592404026'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/986475727592404026'/><link rel='alternate' type='text/html' href='http://fdo-workspace.blogspot.com/2018/10/powercli-create-nested-folder-structure.html' title='PowerCLI - Create vCenter Nested Folder Structure from File'/><author><name>fdo</name><uri>http://www.blogger.com/profile/16882300714528613456</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhndsbgzepfJ0U5gXwY3zzRcGOqiMcblr09VzwWLCMA_waqC9FUthSCa8n91RwqW_kZXNo2si5UU3N5Ex6UJbYkcUpcJnxOQw6jPOBYuux7fomIpI0UUf8vOXyBT7hyuuE/s113/IMG_5942.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEij0rKW7sNvXZsoIwNjli2DNjckWzhZj7dQryqsDBXg03_5ieZuqr9k5R28Q4HDUzHos8iNChhLKFkbnYZzpdedd1Sq_xlJVJBMpFrdaOjIJ-V4rXRfLerniD2n4IONsjI3mQ0JRUQC3s_S/s72-c/Screen-Shot-2018-10-26-at-11.57.47-AM.png" height="72" width="72"/><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8658731852844520209.post-9220581176409533029</id><published>2018-10-25T20:42:00.000-04:00</published><updated>2018-10-25T20:42:37.858-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="powershell"/><category scheme="http://www.blogger.com/atom/ns#" term="PScribo"/><category scheme="http://www.blogger.com/atom/ns#" term="Report"/><category scheme="http://www.blogger.com/atom/ns#" term="VMWare"/><title type='text'>PowerShell: Using PScribo to Generate Report</title><content type='html'>&lt;p dir=&quot;auto&quot;&gt;I was doing on some data analysis against a CSV. Then I started using PowerShell to manipulate the data and do some calculation. Next to take it a step further thought about generating a pretty report in HTML format. Thought this might be a great opportinity to learn how to use PScribo. The very first time I heard about PScribo was in one of the VMworld sessions I think it was about documenting your virtual environment using PowerShell. &lt;/p&gt;&lt;p dir=&quot;auto&quot;&gt;Downloaded the PScribo module from the PowerShell Gallery and downloaded the sample script provided by the creator (Github:iainbrighton\PScribo). &lt;/p&gt;&lt;p dir=&quot;auto&quot;&gt;Now lets start by taking a look at the CSV data. CSV file contains nothing more than host information, cluster, cpu, memory and ESX version. From this information I want to process and get the amount of free memory and cpu. &lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgurHYiJaBjqNsFPR_Xbl7CBEiLD1cGpQUHklM7kl6jbdxb4GT_cl9qG_8fKvydd9LDuV-VQBZqU5fgNUMgfO56aCp1SAHq3nUc0kS-EEPUfHfB9odiTmbsrOKmxkNIcl0vhdn-qhO1ERn2/s9999/Screen-Shot-2018-10-25-at-7.56.56-PM.png&quot;  width=&quot;1494&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;p dir=&quot;ltr&quot;&gt;Created a script that will process the CSV data, masage it, sort it and perform some simply calculation. Once the done here is the output on screen. &lt;strong&gt;Note:&lt;/strong&gt; Didn’t cover how I processed the data. Might do that on a separate post.&lt;br&gt;&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhcX0i35j2LdUuX-t7fZxjOEtALQToTem9nnU4Sbds-skZE3h51A7lk9uqvTjZgasgWTmdpc18qsHM8plK0UJnuLiwTpLs9l1PVeasXYDVxXOgtLqQLZy9OR_KO4bKT7p1CuxI7jxqKLfDV/s9999/Screen-Shot-2018-10-25-at-8.00.26-PM.png&quot;  width=&quot;2012&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;p dir=&quot;ltr&quot;&gt;There is no easy way to produce a nicely formated output into a document without without some tools. After few mins looking into the PSscribo sample I was able to produce a HTML and nicely formated text file.&lt;/p&gt;&lt;p dir=&quot;ltr&quot;&gt;Created Summary of all locations and highlighted location without enough resources to handle host a host failure.&lt;br&gt;&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg_pM_aaUN1s3NSYy95XVCJ48I7hfX6IxGg6l-VVOQzUisynEdOZ6KrmY5wv0tUYOyw3uYjGAyyK-aqzV8LA_oIbd-t0fpqXrTl1nZ4qaKl9QpG26vOCaCj2eReYNvmzCxqo7JwJKYT_933/s9999/Screen-Shot-2018-10-25-at-8.10.15-PM.png&quot;  width=&quot;1144&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;p dir=&quot;ltr&quot;&gt;Next section is break down of each location and individual host resource break down.&lt;br&gt;&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjdLUl76IYKz_TyP5JkaHC6AatZWfZkVSEKYhyphenhyphenyYhy9T9jTScl_kMHjxhU6InEEnqv8533MYDZnHYfYcTxKzwjjfjsY0Kk8c2Nk9GXmoxfriyiBzNOM2slzh_LNYkmlsOEq1epPDryTeHTe/s9999/Screen-Shot-2018-10-25-at-8.09.52-PM.png&quot;  width=&quot;1392&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;p dir=&quot;ltr&quot;&gt;Here is the same output generated into a text file.&lt;br&gt;&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhI3Jk4Cv07Ch0DzJjxP_Qh9LEzw-5xVF9cdoGHdLh7IS8yzDRT7JagIvKN-KSgtS24XNG2NBTxgMz5TncGnbpagGZimzCav3yALSLL9TuEbaDregQIyKpZ1aFMq8xW1sdG6MzFooLJTKrp/s9999/Screen-Shot-2018-10-25-at-8.14.12-PM.png&quot;  width=&quot;1352&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi8IvSB04TDXR6mYJH46NDKfGCi9I_QtSEQ4rZUuVYODytG9alNVWQCp2O7DsECvxKH6XEHez8RpHm_ueBphHfNtWoJJiqg_dHyk05jZKgvqrJ1mr-qX7s8R81gas56woHTiXFhzUBUkoUz/s9999/Screen-Shot-2018-10-25-at-8.14.26-PM.png&quot;  width=&quot;1958&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;p dir=&quot;ltr&quot;&gt;How this is done??&lt;/p&gt;&lt;p dir=&quot;ltr&quot;&gt;Once you have your data from the CSV file processed into tables or PSobject variables all you need to do process it using PScribo. Refer to the example provided by the creater is extremely easy to follow. I used sample to generate this output.&lt;/p&gt;&lt;blockquote&gt;&lt;p dir=&quot;ltr&quot;&gt;######  Section Uses PS Scribo to Turn table in to HTML, TXT, DOC&lt;br&gt;$document = Document &#39;ReportDoc&#39; -Verbose {&lt;br&gt;&lt;/p&gt;&lt;p&gt;   # Section 1&lt;br&gt;    Style -Name &#39;HighUsage&#39; -Color White -BackgroundColor Firebrick -Bold&lt;br&gt;    Paragraph -Style Heading1 &#39;Summary Host Usage Report for All Locations&#39;&lt;br&gt;    Paragraph -Style Heading3 &#39;Cell marked red means that there is not enough resource to handle a host failure&#39;&lt;br&gt;    Section -Style Heading2 &quot;Host Usage for GEO&quot; {&lt;br&gt;        $reportclone = $report.Clone()&lt;br&gt;        $reportclone | ? { ($_.MemFree) -lt ($_.HostMemSize) } | Set-Style -Property &#39;MemFree&#39; -Style HighUsage &lt;br&gt;        $reportclone | Table -Columns Datacenter,Cluster,NumHost,NumVCPU,CPUFree,MemoryMB,MemFree -Headers Datacenter,Cluster,NumHost,NumVCPU,CPUFree,MemoryMB,MemFreeMB  -Width 0&lt;br&gt;    }&lt;br&gt;    PageBreak;&lt;br&gt;   # Section 2&lt;br&gt;    Paragraph -Style Heading1 &#39;Detailed Host Usage Report Each Location&#39;&lt;br&gt;    Paragraph -Style Heading3 &#39;Cell marked red means that memory usage is over 90%&#39;&lt;/p&gt;&lt;p&gt;    Foreach ($dc in $datacenters){&lt;br&gt;        $dc_data = $csv_data | where {$_.Datacenter -eq $dc}&lt;br&gt;        Section -Style Heading2 &quot;Datastore Usage for $dc&quot; {&lt;br&gt;            $highusagetable = $dc_data.Clone()&lt;br&gt;            $highusagetable | ? {$_.&#39;Memory Usage %&#39; -gt 90} | Set-Style -Property &#39;Memory Usage %&#39; -Style HighUsage &lt;br&gt;            $highusagetable | Table -Columns Host,DataCenter,Cluster, &#39;# vCPUs&#39;, &#39;CPU usage %&#39;, &#39;# Memory&#39;,&#39;Memory usage %&#39;, &#39;ESX Version&#39; -Headers Host,DataCenter,Cluster, &#39;# vCPUs&#39;,&#39;CPU usage %&#39;, &#39;# Memory&#39;, &#39;Memory usage %&#39;, &#39;ESX Version&#39; -Width 0&lt;/p&gt;&lt;p&gt;        }&lt;br&gt;      }&lt;br&gt;}&lt;br&gt;$document | Export-Document -Path .\ -Format Word,Html,Text -Verbose;&lt;/p&gt;&lt;/blockquote&gt;&lt;p dir=&quot;ltr&quot;&gt;The script will generate a Word,Html and Text file. Simple notes:&lt;br&gt;- Paragraph is to define text there are different styles, heading format and colors you can use.&lt;br&gt;- Set-Style is to define styles. I used this to highlight values were needs attention.&lt;br&gt;- Table output: you can select the columns you want to output and even adjust the column name, width etc.&lt;/p&gt;&lt;p dir=&quot;ltr&quot;&gt;The second section will loop thru each location and list out host information. Each location with its respective host information.&lt;/p&gt;&lt;p dir=&quot;ltr&quot;&gt;This was the first time using PScribo and it was fairly user friendly. I attempted using vCheck to generate HTML files but requires a lot more work. This is a perfect solution for quick an easy documentation. Thumbs up to the creator!&lt;/p&gt;</content><link rel='replies' type='application/atom+xml' href='http://fdo-workspace.blogspot.com/feeds/9220581176409533029/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://fdo-workspace.blogspot.com/2018/10/powershell-using-pscribo-to-generate.html#comment-form' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/9220581176409533029'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/9220581176409533029'/><link rel='alternate' type='text/html' href='http://fdo-workspace.blogspot.com/2018/10/powershell-using-pscribo-to-generate.html' title='PowerShell: Using PScribo to Generate Report'/><author><name>fdo</name><uri>http://www.blogger.com/profile/16882300714528613456</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhndsbgzepfJ0U5gXwY3zzRcGOqiMcblr09VzwWLCMA_waqC9FUthSCa8n91RwqW_kZXNo2si5UU3N5Ex6UJbYkcUpcJnxOQw6jPOBYuux7fomIpI0UUf8vOXyBT7hyuuE/s113/IMG_5942.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgurHYiJaBjqNsFPR_Xbl7CBEiLD1cGpQUHklM7kl6jbdxb4GT_cl9qG_8fKvydd9LDuV-VQBZqU5fgNUMgfO56aCp1SAHq3nUc0kS-EEPUfHfB9odiTmbsrOKmxkNIcl0vhdn-qhO1ERn2/s72-c/Screen-Shot-2018-10-25-at-7.56.56-PM.png" height="72" width="72"/><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8658731852844520209.post-2808151412224814091</id><published>2018-10-13T11:19:00.001-04:00</published><updated>2018-10-13T11:39:23.018-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="API"/><category scheme="http://www.blogger.com/atom/ns#" term="API Explorer"/><category scheme="http://www.blogger.com/atom/ns#" term="powershell"/><category scheme="http://www.blogger.com/atom/ns#" term="REST"/><category scheme="http://www.blogger.com/atom/ns#" term="vCenter v6.5"/><title type='text'>vCenter 6.5 Health Rest API</title><content type='html'>&lt;p dir=&quot;auto&quot;&gt;Exploring the vSphere v6.5 Rest API has been in my todo list since it was released. I’ve been pretty busy with support and engineering work as well as up keeping my existing code library with PowerCLI, Python (PyvMomi), VMware Orchestrator and even Ansible code. And of course I can only use personal time to blog. I have all these script languages why vCenter REST API now? If you take a closer look, there are plenty code on how to configure and create in almost anything in vCenter but nothing to monitor vCenter. So the piece that caught my attention was the vCenter Appliance Health API only available in REST.&lt;/p&gt;&lt;p dir=&quot;auto&quot;&gt;So in this article we will be explore was is the Health API all about.&lt;/p&gt;&lt;p dir=&quot;auto&quot;&gt;To get started we will be taking a quick look at the available APIs by access a vCenter v6.5.# landing page and click on the Browse vSphere REST API link.&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh4lRmsSMsGqDSshf-fd4_g5V6aIqXvl9aJJbWSWBprZdaUWNkbHb2hz-nVOMQFHmSUaUXTiLPCqJq2nnT0_v0h1FKf-tqTX7QhsMvbllcQP2mjtpbHv3aQjEOgPk18YNN9T-54kakhseQj/s9999/10_159_81_166_-_2012_FDTRM1_8.jpg&quot; width=&quot;1136&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;p dir=&quot;ltr&quot;&gt;Once inside the API Explorer main page, you can select the API from the drop down: appliance, cis, content, vapi and vcenter. For this exercise we will only be looking at the &lt;strong&gt;appliance&lt;/strong&gt;.&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjDmHZx2Gqjc823NtMRQZaQ0AFEQBPOwtPgLF5Iz3h8_Ay0USL_bkSiB6Yne3ufnVuWCCh0NyuWRh_SyhsMXYdYiHpkznLJj-mtMvEOxvu7zh947d27BxcKPQUnf1UFJr9OqiQsbj-YJ6SK/s9999/Screen-Shot-2018-10-13-at-9.49.49-AM.png&quot; width=&quot;1136&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;p dir=&quot;ltr&quot;&gt;To be even more specific we want to look at all the items listed under health: &lt;br&gt;- application management services&lt;br&gt;- database storage health&lt;br&gt;- load health&lt;br&gt;- memory health&lt;br&gt;- software packages - provides information on VUM repo packages.&lt;br&gt;	- red: indicate security packages available&lt;br&gt;	- orange: non security packages available&lt;br&gt;	- green: no updates available&lt;br&gt;	- gray: error retrieveing updates&lt;br&gt;&lt;/p&gt;&lt;p dir=&quot;ltr&quot;&gt;- storage health&lt;br&gt;- swap health&lt;br&gt;- system health&lt;br&gt;- last health check time stamp&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgYJCy6QyK2wWAGGGcHwZwleNB_SSelzr2wDXxBIXm06SMpV08KBLRMMExy3fMGXJBjghdbZYyvVtlSvBdLJuWo1OOVgjS1Fs2xwAVMKk6RhVGY3AEhz6Tmz2llYHaqzpoxmbd7ay4CwfyE/s9999/10_159_81_166_-_2012_FDTRM1_7.jpg&quot; width=&quot;1097&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;&lt;h3&gt;Part 1 -&amp;nbsp;Using the vCenter API Explorer&lt;/h3&gt;&lt;p dir=&quot;ltr&quot;&gt;Lets try &lt;strong&gt;health/applmgmt&lt;/strong&gt; - expand to see the API, read through the content and click “TRY IT OUT!”.&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgrg2V5xiTHJT5xJggwxLmhEPp7vjEor4e9erBsas4k_xRW42qT9f04M1zmG1wOnahHdt81yOzhrlPxVyGwf-ohuxANHu0Zpcu_JMlGB19yPE-91eFLcMWNifrr9DqBNF33_XIZJ_EpLmVi/s9999/Screen-Shot-2018-10-13-at-10.11.03-AM.png&quot; width=&quot;1133&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;p dir=&quot;ltr&quot;&gt;&lt;br&gt;It will show the full curl command, request URL, response body, reponse code and response header basically everything you would normally expect from this command. What do we get from this &lt;strong&gt;health/applmgnt&lt;/strong&gt; API? From the response we get “green” meaning services all services are good and code 200 meaning request was successful.&lt;/p&gt;&lt;p dir=&quot;ltr&quot;&gt;It would be nice that in future releases they break down the status of each service. Perhaps green when everything is healthy, when orange or red pointing out which service is down.&lt;br&gt;&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhqcOGJ72vGzHEwJ38WtYVBHj-LweCrzImHx9UjFeItNIkKRLmuN90s5d1wRNOEqs4Eq-a30tD_ByLz3zCoUU0YEbMeCQRP6isvTq69ox6_GYiBUbL_vK3Z9uqJ1iopEm4D03ygZe0V09eq/s9999/10_159_81_166_-_20122_FDTRM1.jpg&quot; width=&quot;1124&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;p dir=&quot;ltr&quot;&gt;&lt;br&gt;Before I jump into PowerShell mode, I want to take a look at one more API. Check out the &lt;strong&gt;health/databasestorage&lt;/strong&gt; API. Example value when “orange” when status 200 and sample response message when code 400. OK.&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhblkBKwENoQJofzoL0cj5SdXEszCbthHPWxnV7huxLenOVBkBB4Rrff_Va-4dDTY5BfiYnw6bUllZ07AvA36fR6En_GxZOV-RUPmLNYIPPLYWpNVhYrh4YLOa6C-MQnMicmLNvX8SiSm-C/s9999/Screen-Shot-2018-10-13-at-10.30.59-AM.png&quot; width=&quot;1130&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;p dir=&quot;ltr&quot;&gt;&lt;br&gt;Now lets try out this &lt;strong&gt;health/databasestorage&lt;/strong&gt; API. CLICK. Notice that we are getting a &lt;strong&gt;com.vmware.vapi.std.errors.unauthenticated&lt;/strong&gt; in the response body and response code &lt;strong&gt;401&lt;/strong&gt;. This mean it failed to get a response and requires authentication in order to perform this request.&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEihukn4pgBzC06nktJN-lS8J0Pikio98CHQ40dJI_ii_ubrLt3hJ-v8h4syeIaj-MQUpUtOA_-PCVfDTzt0qhRe47b3m98yYnv_oX93wzjgE55_cVHo7SC7aC4y0PAGPJtADEaa-VY5npGP/s9999/10_159_81_166_-_2012_FDTRM1_6.jpg&quot; width=&quot;1127&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;p dir=&quot;ltr&quot;&gt;To get pass the authentication error click Login in the top right corner, enter your credentials and try again. This time you should see your vCenter’s database storage health and the response code 200.&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhVqZ9XRWCmWycAilf7XWzo2-YCaZEHPrwRtKZqEgeYoY7CQfwJBDKGIOz8VhzHea2CCAcxbCl3TkXA-4pecIZM1WNLYeSTuhxljpZnIdgZ5MrimHKufN1IFIOlxWd8J33GIQwGVuCJnHKk/s9999/10_159_81_166_-_2012_FDTRM13.jpg&quot; width=&quot;1194&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;&lt;h3&gt;Part 2 - Writing PS Scripts to get vCenter Health&lt;/h3&gt;&lt;p dir=&quot;ltr&quot;&gt;This next section will translate everything we did in API Explorer to PowerShell.&lt;/p&gt;&lt;p dir=&quot;ltr&quot;&gt;Let’s use health/database-storage API for this exercise. From the API explorer we can obtain the Curl example, and the Request URL:&lt;/p&gt;&lt;p dir=&quot;ltr&quot;&gt;Curl:&lt;br&gt;&lt;/p&gt;&lt;blockquote&gt;curl -X GET —header &#39;Accept: application/json&#39; --header &#39;vmware-api-session-id: 2b66ca49e7dc2e105d69bf52a4a75f77&#39; &#39;https://vcenter_ip/rest/appliance/health/database-storage&#39;&lt;/blockquote&gt;&lt;p dir=&quot;ltr&quot;&gt;Request URL:&lt;br&gt;&lt;/p&gt;&lt;blockquote&gt;https://vcenter_ip/rest/appliance/health/database-storage&lt;/blockquote&gt;&lt;p dir=&quot;ltr&quot;&gt;&lt;br&gt;To satisfy the request we must obtain the “api-session-id”  which will be used as an authentication token.&lt;br&gt;Following code will perfom the following task:&lt;br&gt;- Define target vCenter IP or FQDN&lt;br&gt;- Get Credentials to access vCenter&lt;br&gt;- Request session id from vCenter using Invoke-WebRequest&lt;br&gt;- Session ID will be used repeatedly throughout the rest of the script to perfom calls against the health API.&lt;/p&gt;&lt;blockquote&gt;$vcenteraddr = &quot;vCenter_IP_or_FQDN&quot;&lt;br&gt;$credential = Get-Credential&lt;br&gt;$authentication = [System.Convert]::ToBase64String([System.Text.Encoding]::UTF8.GetBytes($Credential.UserName+&#39;:&#39;+$Credential.GetNetworkCredential().Password))&lt;br&gt;$header = @{&lt;br&gt;  &#39;Authorization&#39; = &quot;Basic $authentication&quot;&lt;br&gt;}&lt;br&gt;[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12&lt;br&gt;# Request a token from cis, using vCenter Credentials&lt;br&gt;$response = Invoke-WebRequest -Uri https://$vcenteraddr/rest/com/vmware/cis/session -Method Post -Headers $header&lt;br&gt;$sessionid = (ConvertFrom-Json $response.Content).value&lt;br&gt;# this authentication header will be used for all future request&lt;br&gt;$header = @{&#39;vmware-api-session-id&#39; = $sessionid}&lt;/blockquote&gt;&lt;p dir=&quot;ltr&quot;&gt;Once the session-id is stored in our new header we can proceed bu using the Invoke-RestMethod.&lt;/p&gt;&lt;blockquote&gt;# Get database storage health status&lt;br&gt;$request_url = &quot;https://$vcenteraddr/rest/appliance/health/database-storage&quot;&lt;br&gt;$response = Invoke-RestMethod -Uri $request_url -Headers $header&lt;br&gt;Write-Host &quot;Health status of database storage: $($response.value)&quot;&lt;/blockquote&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;&lt;p dir=&quot;ltr&quot;&gt;Executing the code will give out following output:&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEji4Pdz8QmAfqTMByma27jBO-Q15_LtXcoOk6-OuwyVrVA6I3NUTIZ8EuENvG6iTfcxPCsZFSjX3GGFyuyiMlZfgvKVMVNFOe8Xmw98XtwcbMU4MbRiSiHHOaD2jhgBUQdvPjTueY5hLLQG/s9999/Screen-Shot-2018-10-13-at-11.12.47-AM.png&quot; width=&quot;701&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;&lt;p dir=&quot;ltr&quot;&gt;&lt;br&gt;That is how simple it is… Now we can finally add some health monitoring screen into our code library. With this you can certainly go as creative you want. Below I’ve included the rest of the code I am testing with.&lt;/p&gt;&lt;blockquote&gt;&lt;p dir=&quot;ltr&quot;&gt;$vcenteraddr = &quot;vCenter_IP_or_FQDN&quot;&lt;br&gt;$credential = Get-Credential&lt;br&gt;$authentication = [System.Convert]::ToBase64String([System.Text.Encoding]::UTF8.GetBytes($Credential.UserName+&#39;:&#39;+$Credential.GetNetworkCredential().Password))&lt;br&gt;$header = @{&lt;br&gt;  &#39;Authorization&#39; = &quot;Basic $authentication&quot;&lt;br&gt;}&lt;/p&gt;&lt;p&gt;[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12&lt;br&gt;$response = Invoke-WebRequest -Uri https://$vcenteraddr/rest/com/vmware/cis/session -Method Post -Headers $header&lt;br&gt;$sessionid = (ConvertFrom-Json $response.Content).value&lt;br&gt;$header = @{&#39;vmware-api-session-id&#39; = $sessionid}&lt;/p&gt;&lt;p&gt;# Get health status of applmgmt services&lt;br&gt;$request_url = &quot;https://$vcenteraddr/rest/appliance/health/applmgmt&quot;&lt;br&gt;$response = Invoke-RestMethod -Uri $request_url -Headers $header&lt;br&gt;Write-Host &quot;Health status of applemgmt service: $($response.value)&quot;&lt;/p&gt;&lt;p&gt;&lt;br&gt;# Get database storage health status&lt;br&gt;$request_url = &quot;https://$vcenteraddr/rest/appliance/health/database-storage&quot;&lt;br&gt;$response = Invoke-RestMethod -Uri $request_url -Headers $header&lt;br&gt;Write-Host &quot;Health status of database storage: $($response.value)&quot;&lt;/p&gt;&lt;p&gt;&lt;br&gt;# Get appliance health load&lt;br&gt;$request_url = &quot;https://$vcenteraddr/rest/appliance/health/load&quot;&lt;br&gt;$response = Invoke-RestMethod -Uri $request_url -Headers $header&lt;br&gt;Write-Host &quot;VCSA load health: $($response.value)&quot;&lt;/p&gt;&lt;p&gt;# Get appliance memory health&lt;br&gt;$request_url = &quot;https://$vcenteraddr/rest/appliance/health/mem&quot;&lt;br&gt;$response = Invoke-RestMethod -Uri $request_url -Headers $header&lt;br&gt;Write-Host &quot;Health memory health: $($response.value)&quot;&lt;/p&gt;&lt;p&gt;# Get appliance storage&lt;br&gt;$request_url = &quot;https://$vcenteraddr/rest/appliance/health/storage&quot;&lt;br&gt;$response = Invoke-RestMethod -Uri $request_url -Headers $header&lt;br&gt;Write-Host &quot;Health storage health: $($response.value)&quot;&lt;/p&gt;&lt;p&gt;# Get appliance swap&lt;br&gt;$request_url = &quot;https://$vcenteraddr/rest/appliance/health/swap&quot;&lt;br&gt;$response = Invoke-RestMethod -Uri $request_url -Headers $header&lt;br&gt;Write-Host &quot;Health swap health: $($response.value)&quot;&lt;/p&gt;&lt;p&gt;# Get Appliance system &lt;br&gt;$get_command = &quot;https://$vcenteraddr/rest/appliance/health/system&quot;&lt;br&gt;$response = Invoke-RestMethod -Uri $get_command -Headers $header&lt;br&gt;Write-Host &quot;Health system health: $($response.value)&quot;&lt;/p&gt;&lt;/blockquote&gt;&lt;p dir=&quot;ltr&quot;&gt;Here is my vCenter’s Health:&lt;br&gt;&lt;/p&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjEhqU2PwFOyHuhe8z1vbxrTLJhI-CNiUmGfeykkoqJ8v4FJmve8foXVgPvFFxx9nQ3U9i1iiiyV6q9W8-JZA520XIWynNSqJvzWen7w9sKQG32CGuk1hAnQb9MnC1dtmZc3hId_aDQHX5h/s9999/Screen-Shot-2018-10-13-at-11.22.21-AM.png&quot;  width=&quot;417&quot; style=&quot;max-width: 100%;&quot;&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://fdo-workspace.blogspot.com/feeds/2808151412224814091/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://fdo-workspace.blogspot.com/2018/10/vcenter-65-health-rest-api.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/2808151412224814091'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/2808151412224814091'/><link rel='alternate' type='text/html' href='http://fdo-workspace.blogspot.com/2018/10/vcenter-65-health-rest-api.html' title='vCenter 6.5 Health Rest API'/><author><name>fdo</name><uri>http://www.blogger.com/profile/16882300714528613456</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhndsbgzepfJ0U5gXwY3zzRcGOqiMcblr09VzwWLCMA_waqC9FUthSCa8n91RwqW_kZXNo2si5UU3N5Ex6UJbYkcUpcJnxOQw6jPOBYuux7fomIpI0UUf8vOXyBT7hyuuE/s113/IMG_5942.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh4lRmsSMsGqDSshf-fd4_g5V6aIqXvl9aJJbWSWBprZdaUWNkbHb2hz-nVOMQFHmSUaUXTiLPCqJq2nnT0_v0h1FKf-tqTX7QhsMvbllcQP2mjtpbHv3aQjEOgPk18YNN9T-54kakhseQj/s72-c/10_159_81_166_-_2012_FDTRM1_8.jpg" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8658731852844520209.post-1297897797642416697</id><published>2018-09-10T18:05:00.001-04:00</published><updated>2018-10-13T09:24:41.655-04:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Cisco"/><category scheme="http://www.blogger.com/atom/ns#" term="ESXI"/><category scheme="http://www.blogger.com/atom/ns#" term="UCS"/><title type='text'>ESXi Management Network Down After Host Upgrade</title><content type='html'>&lt;div dir=&quot;auto&quot;&gt;
Today was just one of those day. It all started with a simple ESXi host upgrade from v5.5u2 to v6.0u3x, in the process decided to do firmware upgrade. This was a Cisco UCS C-series host running CIMC v2.0 and couldn’t be happier updating it to the new v3.0x UI. While looking for the firmware saw 4.0(1a) was released, so decided to go with 4.0 instead. Few hours later, ESXi v6.0u3x was loaded and CIMC firmware 4.0 was loaded as well. From vCenter, noticed the host was still showing disconnected so launched the KVM Console and everything looked normal. Management network and everything was configured properly but couldn’t ping gateway or anything. I thought it could have been something related to the 4.0 firmware. Never had this issue during my previous firmware upgrades to v3.0. Spend the next hours or so doing all sort of things just to find out that the solution was as simple as two mouse clicks.&lt;/div&gt;
&lt;div dir=&quot;ltr&quot;&gt;
&lt;strong&gt;So what did I do?&lt;/strong&gt;&lt;br /&gt;After the Cisco UCS firmware was upgraded to 4.0(1a) I thought it might have been a driver issue. Went to the Cisco Hardware and Software Compatibility page, enter my Server Type, Model, OS Version, etc and a Driver ISO was available.&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgZSiExINTF3L7nCPsuAyo1VFJMAQJ0SaNCjMevEPyF3LA2p3GDkmWduBnDiYhDT7jpu6ok6VyGKcduCbVXiXJqt2Io86RKLT5MikM4Guc_w8mz8Xj1uvw677N_IkvLs5YX4i8H_BKnwE4H/s9999/Screen-Shot-2018-09-10-at-5.19.47-PM.png&quot; style=&quot;max-width: 100%;&quot; width=&quot;1964&quot; /&gt;&lt;/div&gt;
&lt;div dir=&quot;ltr&quot;&gt;
&lt;br /&gt;Downloaded the Driver ISO and decided to mount via Virtual Devices in the CIMC. Next thing I did was figure out how to mount the CDRom from inside the ESXi. Came accross vGhetto’s &lt;strong&gt;How to mount cdrom using vshish &lt;/strong&gt;(&lt;a href=&quot;https://www.virtuallyghetto.com/2011/04/how-to-mount-cdrom-using-vsish-on-esxi.html&quot; target=&quot;_blank&quot;&gt;https://www.virtuallyghetto.com/2011/04/how-to-mount-cdrom-using-vsish-on-esxi.html&lt;/a&gt;). Straight foward and simple instructions. Mounted the CDRROM, browsed all the way the the network driver folder just to find a html file. The hmtl files had a link to the Vmware website where driver could be downloaded.&lt;/div&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh0pU2YhIP24VXCwSDMAko0LKe0Tuezyy5w_Q9WT4mSffCc5eg4JE8mA9JRjTLXwSfwsni6emoiXhvhc18YWm4_ecymCF3FBbasaFHMHC7PLLdAwRxMafGr5IZC4aSviXA_B3rbIrmaCcbF/s9999/Screen-Shot-2018-09-10-at-5.25.27-PM.png&quot; style=&quot;max-width: 100%;&quot; width=&quot;1652&quot; /&gt;&lt;/div&gt;
&lt;div dir=&quot;ltr&quot;&gt;
Browsed to the link and downloaded the driver. Access the host via CIMC KVM Console, ran few commands and noticed the driver for the NIC was newer than the one listed in the VMware site.&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhhHAdt48ew5u_INH7dekKd0pmicg86MsJlmCpaxYccyN49kpITkkXjmZkhkMjFFBBOzhWesrWiIJbKprDJsTFE9VI848U-l9uJTHZZsFSitWltHN_cd0gG3E65IObPJGudAyLxL6QCURT9/s9999/Screen-Shot-2018-09-10-at-6.01.43-PM.png&quot; style=&quot;max-width: 100%;&quot; width=&quot;940&quot; /&gt;&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiH1muhbhyphenhyphenB-6S0aX4LPbwhvgS46oUjviLiBxakLcJcHvxUZjDL0TVNtW8Jo26Bzj4Fk_PO-48gSSbamlIZd3VnN2thYVZlzK3YlopyoKykgTjyqYWqaAAM_XFH99RLqFZx5bU1XAVVEvE0/s9999/Screen-Shot-2018-09-10-at-5.26.21-PM.png&quot; style=&quot;max-width: 100%;&quot; width=&quot;1778&quot; /&gt;&lt;/div&gt;
&lt;div dir=&quot;ltr&quot;&gt;
The driver downloaded was in form of a ZIP file and the only way to make this available to the ESXi host was mounting ISO through the KVM. Searched online to found a utility to create and ISO and found (ISO Creator) free utility to convert a folder to ISO.&lt;br /&gt;- Mounted the ISO to the active KVM Session &lt;br /&gt;- Run few command to mount CDROM using vshish inside the host &lt;br /&gt;- Browsed to the CD&lt;/div&gt;
&lt;div dir=&quot;ltr&quot;&gt;
Noticed that from the host, the content of the CD was weird. Tried to generate new ISO and same result. From windows, the CD content looked fine it had the vib and the zip file, but from the ESXi host it was just showing the partial file name with no extension.&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgFXPPrgRO4DSes7XHJLs4Ub1ktVJMmV_DYnVH5aFV8N_Wi0n9pqqY4lgZ9pyFl5qPHv92qsdjERNt6arpbqO2223lg5Y7bBbhn6EksfGZTNrlUGgKrd9bD_TPxzEPXORYbUA1Nk2uG6mF_/s9999/Screen-Shot-2018-09-10-at-5.29.11-PM.png&quot; style=&quot;max-width: 100%;&quot; width=&quot;1392&quot; /&gt;&lt;/div&gt;
&lt;div dir=&quot;ltr&quot;&gt;
&lt;br /&gt;Decided to run the installation commands against the IGB file anyway. Loaded the driver using the &lt;a href=&quot;http://%20https//www.cisco.com/c/en/us/support/docs/servers-unified-computing/ucs-manager/116349-technote-product-00.html&quot; target=&quot;_blank&quot;&gt;Cisco Driver Installation&lt;/a&gt; documentation. &lt;a href=&quot;https://www.cisco.com/c/en/us/support/docs/servers-unified-computing/ucs-manager/116349-technote-product-00.html&quot;&gt;&lt;/a&gt;&lt;/div&gt;
&lt;blockquote&gt;
To install the driver on ESXi Release 5.x/6.x: &lt;br /&gt;
esxcli software vib install –v /path/async-driver.vib&lt;/blockquote&gt;
&lt;br /&gt;
Ran the command agaist the IGBN file and it worked. It was installed successfully and needed a reboot to complete.&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhapaQLjY2SBwKghFEdrnfNxSesMGFn6k31X2x6Bs1R-1LSoeAXzfSSSCkGJnqMeqx-l5ISdBGhe04CB6B6ET5DycIgvehh5kK5Kfk9Hi3sVMlcZGQGDd3XttOjINZ6PxgHKGs3s1Ts9evl/s9999/Screen-Shot-2018-09-10-at-5.38.47-PM.png&quot; style=&quot;max-width: 100%;&quot; width=&quot;1902&quot; /&gt;&lt;/div&gt;
&lt;div dir=&quot;ltr&quot;&gt;
To finalize the installation I rebooted the server. Everything came up fine the driver was loaded but the management network still wasn’t working!!!&lt;/div&gt;
&lt;div dir=&quot;ltr&quot;&gt;
Decided to step back and check the network configurations and noticed something. From the ESXi host console vmnic0 was selected and that is usually our 1GB uplink for build/management purposes only.&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhA8gbAnGpnIxSNCeKh2bSX7AAk74Mm611nFC7FJ5W-qXTjL37YfFqiXfzeAu1KLOr4W6o17Hd1wiF8PDnbMQl1VkdbWGPTxCYSJbjjYEJjbjFE3NT603CIFlikriyFOUKyjHanO25XaEHd/s9999/Screen-Shot-2018-09-10-at-5.48.08-PM.png&quot; style=&quot;max-width: 100%;&quot; width=&quot;1000&quot; /&gt;&lt;/div&gt;
&lt;div dir=&quot;ltr&quot;&gt;
When I ran the shell command to list all the vmnic devices. It was telling me that vmnic0 was now the 10GB uplink?!? Somehow the order of the NIC was reversed after the CIMC Firmware upgrade. Duh I did noticed vminc2 was the 1GB  uplink but didn’t occur to me to select that device to begin with&lt;/div&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;img src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjMuHCCmDQN3Mmh8Kg2QWUfQa42sjgwpAQR2KyXj_USUiMfU0LxEajtr0r-CAtyqRSFUlDB59RTYOc1RStdOKiySM3TuUwVmp-_udzgBYcbKiXLfsa94RErdVxTtyRDMI2AUJgIS8c1D9BK/s9999/Screen-Shot-2018-09-10-at-5.46.27-PM.png&quot; style=&quot;max-width: 100%;&quot; width=&quot;1634&quot; /&gt;&lt;/div&gt;
&lt;div dir=&quot;ltr&quot;&gt;
Solution was simply to remove the deselecting vmnic0 and selecting vmnic2…&lt;/div&gt;
&lt;div dir=&quot;ltr&quot;&gt;
&lt;strong&gt;After all this unnecessary work what did I learn today?&lt;/strong&gt;&lt;br /&gt;- How to create ISO files from a folder&lt;br /&gt;- How to mount a CDROM in ESXI using vsish&lt;br /&gt;- How to check make sure the correct network adapter is selected before blaming it on the network driver&lt;/div&gt;
&lt;br /&gt;
&lt;h3&gt;
&lt;/h3&gt;
</content><link rel='replies' type='application/atom+xml' href='http://fdo-workspace.blogspot.com/feeds/1297897797642416697/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://fdo-workspace.blogspot.com/2018/09/esxi-management-network-down-after-host.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/1297897797642416697'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8658731852844520209/posts/default/1297897797642416697'/><link rel='alternate' type='text/html' href='http://fdo-workspace.blogspot.com/2018/09/esxi-management-network-down-after-host.html' title='ESXi Management Network Down After Host Upgrade'/><author><name>fdo</name><uri>http://www.blogger.com/profile/16882300714528613456</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhndsbgzepfJ0U5gXwY3zzRcGOqiMcblr09VzwWLCMA_waqC9FUthSCa8n91RwqW_kZXNo2si5UU3N5Ex6UJbYkcUpcJnxOQw6jPOBYuux7fomIpI0UUf8vOXyBT7hyuuE/s113/IMG_5942.jpg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgZSiExINTF3L7nCPsuAyo1VFJMAQJ0SaNCjMevEPyF3LA2p3GDkmWduBnDiYhDT7jpu6ok6VyGKcduCbVXiXJqt2Io86RKLT5MikM4Guc_w8mz8Xj1uvw677N_IkvLs5YX4i8H_BKnwE4H/s72-c/Screen-Shot-2018-09-10-at-5.19.47-PM.png" height="72" width="72"/><thr:total>0</thr:total></entry></feed>