CLI install VMware vCenter server 6.5

Almost on every project I have worked on, I make an kickstart script for installing VMware ESXi. Although at first, it seems a lot of work. Using a kickstart script for installing VMware ESXi has many advantages:

  • Every host is installed consistent.
  • Elimination of human installations errors.
  • Install script can be used as documentation.
  • In case of a re-installation (hardware failure for example), the host is installed quickly.
  • Every IT administrator can perform the installation, you don’t have to be a VMware Expert.
  • I have created kickstart scripts since ESXi version 4.

While reading the VMware vCenter 6.5 installation documentation, I saw the option for a vCenter Server CLI installation or upgrade. Again, performing an unattended installation of vCenter Server has the same advantage as an kickstart for ESXi.

As with everything, the first time, reading, testing, adjusting your script takes time. But it’s while worth it!

First something about the CLI installer.


In the root of the VCSA installation ISO, you will find the vcsa-cli-installer directory.
Here you find 4 OS directories:

  • Lin64 (linux 64)
  • Mac
  • Templates
  • Win32

In the Templates directory, you will find 3 directories: install, migrate and upgrade.
In every directory, you will find example json files who you can use.
I’m going for a fresh install with an embedded Platform Service Controller, the file for this is embedded_vCSA_on_ESXi.json.
I want to leave the orginal file intact, so I’m copying this file to embedded_vCSA_on_ESXI_VirtualHike.json.
The templates is well documented, so providing the correct values shouldn’t be a problem. Below is my version.

{
    "__version": "2.3.0",
    "__comments": "Virtual Hike to deploy a vCenter Server Appliance with an embedded Platform Services Controller on an ESXi host.",
    "new.vcsa": {
        "esxi": {
            "hostname": "esxi01.virtualhike.local",
            "username": "root",
            "password": "Vmware01",
            "deployment.network": "VM Network",
            "datastore": "Local01"
        },
        "appliance": {
            "thin.disk.mode": true,
            "deployment.option": "tiny",
            "name": "vcsa"
        },
        "network": {
            "ip.family": "ipv4",
            "mode": "static",
            "ip": "10.250.50.10",
            "dns.servers": [
                "10.250.200.1"
            ],
            "prefix": "24",
            "gateway": "10.250.50.254",
            "system.name": "vcsa"
        },
        "os": {
            "password": "Vmware0!",
            "ssh.enable": true
        },
        "sso": {
            "password": "Vmware0!",
            "domain-name": "virtualhike.local",
            "site-name": "VirtualHike"
        }
    },
    "ceip": {
        "settings": {
            "ceip.enabled": false
        }
    }
}

After providing the correct values, open a terminal box and goto to the vcsa-cli-installer/OS directory. As I’m performing this installation from my MacBook, I goto vcsa-cli-installer/mac.

Before performing the final installation, you can verity your json file with the following command:

vcsa-deploy install –verify-only ../templates/install/ embedded_vCSA_on_ESXI_VirtualHike.json

The –verify-only option will do a dry run and check your json file. Every check should say PASS.

Below my output:

=================== [1] Verify Template started at 13:10:31 ===================
Performing basic template verification...
CEIP is not enabled because the template key 'ceip.enabled' in section 'ceip',
subsection 'settings' was set to 'false'.
If an untrusted SSL certificate is installed on 'esxi01.virtualhike.local',
secure communication cannot be guaranteed. Depending on your security policy,
this issue might not represent a security concern.
The SHA1 thumbprint of the certificate is
'DA:F4:7D:D8:32:85:D7:48:8D:B1:BE:25:D0:54:18:95:A1:B6:45:56'
Do you accept the thumbprint?
1: Accept and continue.
2: Do not accept and exit.
1
Template verification completed successfully.
=================================== 13:10:33 ===================================
Starting vCenter Server Appliance installer to deploy "scd-vcsa"...
This appliance is a vCenter Server instance with an embedded Platform Services
Controller.
================ [2] Verify Configurations started at 13:10:33 ================
Performing basic verification...
Check target thumbprint: PASS
Check target credentials: PASS
Check Target vCenter Server appliance name: PASS
Check system type: PASS
Check target ESXi host or vCenter version: PASS
Check for OVA property availability: PASS
Check the host's configurations against the vCSA's CPU, memory and datastore
size requirements: PASS
Check VC management status of ESXi containers: PASS
Check target datastore free space: PASS
Check Single Sign-On Server identity: PASS
Check Single Sign-On Server credentials: PASS
Check whether the Platform Services Controller (PSC) is external: PASS
 
Basic verification completed successfully.
============== [3] Verify OVF Tool Parameters started at 13:10:35 ==============
Running OVF Tool parameter verification...
OVF Tool: Opening OVA source:
/Users/mike/Documents/SCD/vcsa-cli-installer/mac/../../vcsa/VMware-vCenter-Server-Appliance-6.5.0.5600-5705665_OVF10.ova
OVF Tool: Opening VI target: vi://root@esxi01.virtualhike.local:443/
OVF Tool: Supported disk provisioning:
OVF Tool:   monolithicSparse
OVF Tool:   monolithicFlat
OVF Tool:   thin
OVF Tool:   thick
OVF Tool:   flat
OVF Tool:   seSparse
OVF Tool:   eagerZeroedThick
OVF Tool: Connected networks:
OVF Tool:   VM Network
OVF Tool: Deploying to VI: vi://root@esxi01.virtualhike.local:443/
OVF Tool: Transfer Completed
OVF Tool: Completed successfully
OVF Tool verification completed successfully.
Verification completed successfully.

If everything is OK, you can start the installation with the same command without the –verify-only option, but with the –accept-eula option.

After providing the correct values, open a terminal box and goto to the vcsa-cli-installer/OS directory. As I’m performing this installation from my MacBook, I goto vcsa-cli-installer/mac.

Before performing the final installation, you can verity your json file with the following command:

vcsa-deploy install –verify-only ../templates/install/ embedded_vCSA_on_ESXI_VirtualHike.json

The –verify-only option will do a dry run and check your json file. Every check should say PASS.

Below my output:

=================== [1] Verify Template started at 21:23:26 ===================
Performing basic template verification...
CEIP is not enabled because the template key 'ceip.enabled' in section 'ceip',
subsection 'settings' was set to 'false'.
If an untrusted SSL certificate is installed on 'esxi01.virtualhike.local',
secure communication cannot be guaranteed. Depending on your security policy,
this issue might not represent a security concern.
The SHA1 thumbprint of the certificate is
'DA:F4:7D:D8:32:85:D7:48:8D:B1:BE:25:D0:54:18:95:A1:B6:45:56'
Do you accept the thumbprint?
1: Accept and continue.
2: Do not accept and exit.
1
Template verification completed successfully.
=================================== 21:23:28 ===================================
Starting vCenter Server Appliance installer to deploy "vcsa"...
This appliance is a vCenter Server instance with an embedded Platform Services
Controller.
================ [2] Verify Configurations started at 21:23:28 ================
Performing basic verification...
Check target thumbprint: PASS
Check target credentials: PASS
Check Target vCenter Server appliance name: PASS
Check system type: PASS
Check target ESXi host or vCenter version: PASS
Check for OVA property availability: PASS
Check the host's configurations against the vCSA's CPU, memory and datastore
size requirements: PASS
Check VC management status of ESXi containers: PASS
Check target datastore free space: PASS
Check Single Sign-On Server identity: PASS
Check Single Sign-On Server credentials: PASS
Check whether the Platform Services Controller (PSC) is external: PASS

Basic verification completed successfully.
=============== [3] Execute OVF Tool Command started at 21:23:30 ===============
Running OVF Tool to deploy the OVF...
OVF Tool: Opening OVA source:
/Users/mike/Documents/vcsa-cli-installer/mac/../../vcsa/VMware-vCenter-Server-Appliance-6.5.0.5600-5705665_OVF10.ova
OVF Tool: Opening VI target: vi://root@esxi01.virtualhike.local:443/
OVF Tool: Deploying to VI: vi://root@esxi01.virtualhike.local:443/
OVF Tool: Disk progress: 99%
OVF Tool: Transfer Completed
OVF Tool: Powering on VM: vcsa
OVF Tool: Task progress: 32%
OVF Tool: Task Completed
OVF Tool: Completed successfully
=================== [4] Install Services started at 21:28:52 ===================
Installing services...
RPM Install: Progress: 5% Setting up storage
RPM Install: Progress: 51% Installed VMware-jmemtool-6.5.0-5705665.x86_64.rpm
RPM Install: Progress: 54% Installed
VMware-unixODBC-2.3.2.vmw.2-6.5.0.x86_64.rpm
RPM Install: Progress: 59% Installed
vmware-certificate-server-6.5.0.1641-5086229.x86_64.rpm
RPM Install: Progress: 64% Installed VMware-cis-license-6.5.0-4812515.x86_64.rpm
RPM Install: Progress: 73% Installed
VMware-Postgres-extras-9.4.9.1-4536683.x86_64.rpm
RPM Install: Progress: 78% Installed VMware-mbcs-6.5.0-5705665.x86_64.rpm
RPM Install: Progress: 81% Installed
VMware-cloudvm-vimtop-6.5.0-5705665.x86_64.rpm
RPM Install: Progress: 82% Installed vmware-vmrc-6.5.0-5705665.x86_64.rpm
RPM Install: Progress: 84% Installed ipxe-1.0.0-1.4446055.vmw.i686.rpm
RPM Install: Progress: 86% Installed
VMware-UpdateManager-6.5.0-5178944.x86_64.rpm
RPM Install: Progress: 90% Installed vmware-vsm-6.5.0-5705665.x86_64.rpm
RPM Install: Progress: 91% Installed VMware-perfcharts-6.5.0-5705665.x86_64.rpm
RPM Install: Progress: 95% Configuring the machine
Services installations succeeded.
============== [5] Configure vCenter Services started at 21:35:30 ==============
Configuring services for first time use...
Initial Configuration: Progress: 2% Starting VMware Authentication Framework...
Initial Configuration: Progress: 5% Starting VMware Identity Management
Service...
Initial Configuration: Progress: 11% Starting VMware Service Lifecycle
Manager...
Initial Configuration: Progress: 17% Starting VMware Component Manager...
Initial Configuration: Progress: 20% Starting VMware License Service...
Initial Configuration: Progress: 22% Starting VMware Platform Services
Controller Client...
Initial Configuration: Progress: 25% Starting VMware Service Control Agent...
Initial Configuration: Progress: 28% Starting VMware vAPI Endpoint...
Initial Configuration: Progress: 31% Starting VMware Service Lifecycle Manager
API...
Initial Configuration: Progress: 34% Starting VMware Appliance Management
Service...
Initial Configuration: Progress: 45% Starting VMware Postgres...
Initial Configuration: Progress: 51% Starting VMware vCenter-Services...
Initial Configuration: Progress: 54% Starting VMware Message Bus Configuration
Service...
Initial Configuration: Progress: 58% Starting VMware vSphere Web Client...
Initial Configuration: Progress: 59% Starting VMware vSphere Web Client...
Initial Configuration: Progress: 61% Starting VMware vSphere Client...
Initial Configuration: Progress: 62% Starting VMware vCenter Server...
Initial Configuration: Progress: 65% Starting VMware Content Library Service...
Initial Configuration: Progress: 68% Starting VMware ESX Agent Manager...
Initial Configuration: Progress: 71% Starting VMware vSphere Auto Deploy
Waiter...
Initial Configuration: Progress: 74% Starting VMware vSphere Profile-Driven
Storage Service...
Initial Configuration: Progress: 77% Starting VMware Update Manager...
Initial Configuration: Progress: 80% Starting VMware vCenter High
Availability...
Initial Configuration: Progress: 82% Starting VMware vSphere Authentication
Proxy...
Initial Configuration: Progress: 85% Starting VMware VSAN Health Service...
Initial Configuration: Progress: 88% Starting VMware vService Manager...
Initial Configuration: Progress: 91% Starting VMware Image Builder Manager...
Initial Configuration: Progress: 97% Starting VMware Performance Charts...
First time configuration succeeded.
=================================== 21:44:15 ===================================
vCenter Server Appliance installer finished deploying "vcsa".
This appliance is a vCenter Server instance with an embedded Platform Services
Controller.
    System Name: vcsa.virtualhike.local
    Log in as: Administrator@virtualhike.local
Finished successfully.
================= [6] Result and Log Files started at 21:44:15 =================
Summarizing result and log files...
The vCenter Server Appliance installer result file is at:
/var/folders/b8/k540tl_919j8k1rmmn7vdlq80000gn/T/vcsaCliInstaller-2017-07-10-21-23-3q_lQT/vcsa-cli-installer.json
The vCenter Server Appliance installer log file is at:
/var/folders/b8/k540tl_919j8k1rmmn7vdlq80000gn/T/vcsaCliInstaller-2017-07-10-21-23-3q_lQT/vcsa-cli-installer.log
The generated template file is at:
/var/folders/b8/k540tl_919j8k1rmmn7vdlq80000gn/T/vcsaCliInstaller-2017-07-10-21-23-3q_lQT/generated_install.json
And there you go, a fully automated VMware vCenter Appliance installation.

If everything is OK, you can start the installation with the same command without the –verify-only option, but with the –accept-eula option.

About Michael
Michael Wilmsen is a experienced VMware Architect with more than 20 years in the IT industry. Main focus is VMware vSphere, Horizon View and Hyper Converged with a deep interest into performance and architecture. Michael is VCDX 210 certified, has been rewarded with the vExpert title from 2011, Nutanix Tech Champion and a Nutanix Platform Professional.

RSS feed for comments on this post.

Leave a Reply

You must be logged in to post a comment.