Scripted Full-Deploy of vRealize Automation 6.2 (vRA)
The title says it all. As I’ve talked with many folks around the globe either through social media, email, or in person. One thing people seem to always want in regards to vRA, is a way to quickly deploy it to play with it, test something, evaluate it, etc. Currently there is no quick solution.
I’ve tried to help alleviate some of the pain by creating the vRA 6.2 Pre-Req Automation Script, which has seen over 20,000 downloads since I posted the vCAC 6.0 version last December. To make things EVEN EASIER, I’ve thrown together a script that will:
- Deploy the Identity Server
- Configure the Identity Server
- Deploy the vRA Appliance
- Configure the Appliance
- Verify DNS (Forward and Reverse) entries
But that’s not all, If you have a Windows 2008r2 VM (untested on 2012 r2), with an internet connection, the script will also:
- Perform all vRA Prerequisite tasks
- Set Batch Logon’s
- Download and install .Net 4.5.2
- Download and install Java JRE 1.7 64-bit
- Set the Java_Home variable
- Firewall configuration
- Download and install SQL Server 2008r2 SP1 Express
- Configure SQL for use with vRA (Includes opening the correct port and enabling the IPv4 connection)
- Grab and install the needed vRA Appliance certificate
- Download all vRA Component installers
- Install and Configure the vRA Components
- Install and configure a Distributed Execution Manager (DEM) Worker
- Install and configure a Distributed Execution Orechestrator (DEO)
- Install and configure the Web API (WAPI)
- Install and configure the vSphere Agent
Now I know you are reading this and saying “BRIAN! Leave some of the fun for me!!” (ok ok maybe not). This will bring your vRA deployment to the point where you will then login to the portal using the https://FQDNofvRA/shell-ui-app/ where you will then create your identity stores, tenants, and so on and so forth. The rest of the installation can be customized by following the vRA 6.2 Installation Guide.
Maybe if I get ambitious enough in the future I’ll script part of that as well 🙂
Ok, so now that I have your attention after listing off everything this script will do, let’s take a look at it and see how it works.
You will need PowerCLI 5.8 r1 to perform this install.
You will need a Windows Server 2008r2 virtual machine with an internet connection (yes it can be done without but there’s a bit of tweaking to do that, so just bear with me and give it a connection)
You will also need to populate forward and reverse DNS with the settings for these VM’s prior to running the script.
If you take a look at the script, you’ll notice there are a number of variables to set to make this work correctly. Starting with line 28:
I’ve added in more comments than I regularly do to ensure that users understand what they need to enter for each variable. Failure to give each variable a value unless otherwise stated in the code, will result in a failed vRA deployment.
In the above screenshot you can see that you will need to add the vCenter credentials. You will also add the VM Name of the Identity Server and vRA Appliance, along with a password for each. If these appliances haven’t been deployed, this information will be used to deploy and configure. If these appliances HAVE been deployed, we still need this information. and of course DO NOT FORGET TO ADD A LICENSE KEY HERE OR THE DEPLOYMENT WILL NOT WORK!
Moving on: We’ll do the same thing for the Windows IAAS machine. Like I stated earlier, I have only tested this with Server 2008r2 (if you don’t have a copy go download the 180-day trial). I did test this using the credentials “Administrator” and password “VMware1!”
Add in whatever details you wish to use for the Certificate generation and then move into the vCAC Component variables.
As you can see, if you are using this to deploy both OVA’s and you do not specify their location, the script will look in the c:\temp\ folder and find and use them.
RUNNING THE SCRIPT
Upon executing this script in PowerShell, the script will query the DNS server to ensure your DNS entries are correct prior to proceeding. If you do not have 3 valid lines under both forward and reverse here, hit ‘N’ and go fix your DNS issue. This will make things much easier to verify and take care of DNS prior to starting the installation.
The next prompt will happen after the PowerShell session connects to vCenter. It will present you with 4 options:
- Deploy & Configure both Virtual Appliances, Install & Configure IAAS (essentially the full install)
- Configure both Virtual Appliances (Already deployed OVAs), Install & Configure IAAS
- Just Install & Configure IAAS (Pre-reqs, SQL, and vRA Software)
Most people will tend to choose option 1.
Once the script starts to install the vRA components, you can tail the install log by consoling the IAAS VM, opening PowerShell and running: get-content c:\temp\vcac-config.log -wait
At the end of the deploy you should see a something like this at the end of the log: vCloud Automation Center Server Configuration is complete.
If you’ve entered all the values into the variables correctly and followed this post, about 30-40 minutes later, you’ll have a vRA deployment up and running and ready to finish setup.
Please feel free to provide feedback and comments below or on twitter: @vBrianGraf
# Also a shoutout to William Lam (www.virtuallyghetto.com) for originally creating a version for vCAC 6.0. That version was fantastic but also required a few more steps than this. Also vCAC has had a number of changes in 6.1 and 6.2 that required changes to his code, however it’s what got the idea rolling and jumpstarted for 6.1 (although I didn’t release it) and 6.2 (which you can find below).