- Install the Auto Deploy Server
This is located on the vSphere install disk, this can be installed on the vCenter or on a standalone host, Attach media and install.
Auto Deploy comes pre installed on the vCenter appliance but is disabled by default, Browse to the web management of the vCenter appliance and start AutoDeploy.
Next we need to download and setup the Auto Deploy files to a server which has a TFTP server running, I am using “open TFTP server” from sourceforge other people use starwinds free TFTP server that they offer.
Open up the viclient and connect to vCenter from home page select Auto Deploy and download the TFTP boot.zip.
Unzip these files into the TFTP directory that you have selected the TFTP server to make available.
Next we need to setup DHCP server, you would generally utilise you environments DHCP server, Configure Scope, this scope needs to be configured with option 66 boot server host this is the TFTP server, and 67 this is the file that you want to use. In this case we want to use “undionly.kpxe.vmw-hardwired”
Now if you were to boot an ESXi host you should get the below screens, it should be successful apart from saying there is no image available, We are on the right path.
Now we need to add an image to use, download the ESXi 5.x offline bundle which will be used. Connect to the vCenter server with PowerCLI and enter the command:
Now we can see the image profiles by using the command
Now we need to create a rule. I will create a first boot rule and very basic run of the mill AutoDeploy Functionality.
Use the command:
New-DeployRule -Name "firstboot" -Item "ESXi-5.1.0-799733-standard" -Pattern "model=VMware Virtual Platform"
It will then complete the upload.
Last but not least we need to add the rule we just created, using the command:
Add-DeployRule -DeployRule firstboot
Boot away and the new ESXi should boot up and appear in the vCenter.
- Utilize Auto Deploy cmdlets to deploy ESXi hosts
See the above objective to see some of the cmdlets that are used. to get a full list of deploy commands use the follwoing command:
To ad a slightly more advanced profile over what was done above this is what we would do.
First we need to add another software depot, this is for HA client. IP address is the IP address of your vCenter server.
Now we want to clone the standard image we created previously:
New-EsxImageProfile -CloneProfile ESXi-5.1.0-799733-standard -Name "ESXiHA"
Now we want to add the HA client software package to the image:
Add-EsxSoftwarePackage -ImageProfile "ESXiHA" -SoftwarePackage vmware-fdm
Now we would want to remove the firstboot deploy rule we setup:
Remove-DeployRule -DeployRule firstboot -Delete
And then create a new rule that will use the new image profile and add the server into a cluster.
New-DeployRule -Name “Production” -Item “ESXiHA”,ESXiLabHostProfile,”ACME Local -Pattern “model=VMware Virtual Platform”
Note – ESXiHA is the image profile, ESXiLabHostProfile is the name of a host profile you setup in vCenter and want applied to the host. AMCE local is the name of the cluster you want the host placed and the pattern is how a host knows if this rule is to be applied, pattern usually would be used with ipv4″<ipaddress range>” I have done the model of the host which is a virtual machine in this case.
Now all that is needed is to activate the rule by adding it:
Add-DeployRule -DeployRule "Production"
- Configure Bulk Licensing
This is straight out of the vSphere 5 documentation for VMware:
- Provision/Re-provision ESXi hosts using Auto Deploy
On the first provision you will be required to run through the answer file for the host if host profiles are used, and subsequent re-provisions this will be automatic.
To re-provision an ESXi host using auto deploy is actually just a reboot for a simple re-provision. You can also assign different image profiles or host profiles by using the above PowerCLI commands.
if you require the hosts to be added using FQDN, then DNS will have to be setup with revers look up working, Auto deploy works best with DHCP and this is a simple matter of making reservations and pre filling out DNS with the FQDN.
- Configure an Auto Deploy reference host
This is basically setting up a host profile for the first host that gets provisioned. when the first host is provisioned set it up like you would any host, by adding or changing:
Firewall rules, networking configuration, NTP servers, syslog, storage configuration basically set this single host up so its ready to be used. Create a host profile from this host.
This is the host profile that you will use for all future AutoDeploy provision hosts for that cluster, this will have to be done for different clusters or configuration that is needed in your environment.