<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>article Script to pre-answer static IP addresses for Auto Deploy hosts (stateless ESXi) in VMware PowerCLI Documents</title>
    <link>https://communities.vmware.com/t5/VMware-PowerCLI-Documents/Script-to-pre-answer-static-IP-addresses-for-Auto-Deploy-hosts/ta-p/2786919</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The attached script demonstrates how you can automate bulk addition of stateless ESXi hosts via Auto Deploy with static IP addresses using Host Profile Answer files, as long as you know the primary boot MAC address, or BIOS UUID of the new hosts ahead of time.&amp;nbsp; The following excerpt from the script describes how this works (refer to the script for more details):&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;DIV id="_mcePaste"&gt;# There are two common ways to set up hosts with static IP addresses using Auto&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# Deploy.&amp;nbsp; The preferred mechanism is to enter static entries within your DHCP&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# server so it always hands out the same IP address to a given MAC address.&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# Then ESX is configured to use DHCP, but will always get the same IP.&amp;nbsp; This&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# script does not address that approach.&amp;nbsp; Please refer to your DHCP server&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# documentation for more details on setting this up.&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;#&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# The alternative approach is to set up host profiles to use a static IP&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# address and have an answer file for each host that defines its addresses.&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# Normally on first boot, the host will stay in maintenance mode, and require&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# the admin to manually re-apply the profile, at which point you would enter&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# the IP addresses in the GUI which are then stored in the answer file.&amp;nbsp; This&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# script demonstrates how you can "pre-answer" the static IP settings for hosts&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# so that no user intervention is required on first boot.&amp;nbsp; The script&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# is structured to facilitate bulk addition of new servers.&amp;nbsp; As long as you&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# know the MAC address of the primary boot NIC, or the BIOS UUID, then you&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# can run this script to set up all the IP addresses&lt;/DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here's what the CSV file might look like, assuming you have two portgroups with vmkernel networking&amp;nbsp; - "Management Network" and "vmotion"&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;00:50:56:9c:0e:c8,ESXi-5.0.0-469512-no-tools,MyClusterName,Management Network,192.168.1.10,255.255.255.0,vmotion,192.168.2.10,255.255.255.0&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;00:50:56:9c:0e:c9,ESXi-5.0.0-469512-no-tools,MyClusterName,Management Network,192.168.1.11,255.255.255.0,vmotion,192.168.2.11,255.255.255.0&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then running the script (assuming the file above is called "hosts.csv") would look like:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Connect-VIServer MyVcServerName&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Add-EsxSoftwareDepot &lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="https://hostupdate.vmware.com/software/VUM/PRODUCTION/main/vmw-depot-index.xml"&gt;https://hostupdate.vmware.com/software/VUM/PRODUCTION/main/vmw-depot-index.xml&lt;/A&gt;&lt;/P&gt;&lt;P&gt;.\pre-answer.ps1 .\hosts.csv&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Once the script completes, you can power on your systems and they'll come up with the desired static IPs automatically without user invervention.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Daniel&lt;/P&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And another great script, your on fire !&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This document was generated from the following discussion: &lt;A&gt;javascript:;&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 12 Sep 2011 21:29:40 GMT</pubDate>
    <dc:creator>alanrenouf</dc:creator>
    <dc:date>2011-09-12T21:29:40Z</dc:date>
    <item>
      <title>Script to pre-answer static IP addresses for Auto Deploy hosts (stateless ESXi)</title>
      <link>https://communities.vmware.com/t5/VMware-PowerCLI-Documents/Script-to-pre-answer-static-IP-addresses-for-Auto-Deploy-hosts/ta-p/2786919</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The attached script demonstrates how you can automate bulk addition of stateless ESXi hosts via Auto Deploy with static IP addresses using Host Profile Answer files, as long as you know the primary boot MAC address, or BIOS UUID of the new hosts ahead of time.&amp;nbsp; The following excerpt from the script describes how this works (refer to the script for more details):&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;DIV id="_mcePaste"&gt;# There are two common ways to set up hosts with static IP addresses using Auto&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# Deploy.&amp;nbsp; The preferred mechanism is to enter static entries within your DHCP&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# server so it always hands out the same IP address to a given MAC address.&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# Then ESX is configured to use DHCP, but will always get the same IP.&amp;nbsp; This&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# script does not address that approach.&amp;nbsp; Please refer to your DHCP server&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# documentation for more details on setting this up.&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;#&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# The alternative approach is to set up host profiles to use a static IP&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# address and have an answer file for each host that defines its addresses.&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# Normally on first boot, the host will stay in maintenance mode, and require&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# the admin to manually re-apply the profile, at which point you would enter&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# the IP addresses in the GUI which are then stored in the answer file.&amp;nbsp; This&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# script demonstrates how you can "pre-answer" the static IP settings for hosts&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# so that no user intervention is required on first boot.&amp;nbsp; The script&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# is structured to facilitate bulk addition of new servers.&amp;nbsp; As long as you&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# know the MAC address of the primary boot NIC, or the BIOS UUID, then you&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;# can run this script to set up all the IP addresses&lt;/DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here's what the CSV file might look like, assuming you have two portgroups with vmkernel networking&amp;nbsp; - "Management Network" and "vmotion"&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;00:50:56:9c:0e:c8,ESXi-5.0.0-469512-no-tools,MyClusterName,Management Network,192.168.1.10,255.255.255.0,vmotion,192.168.2.10,255.255.255.0&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;00:50:56:9c:0e:c9,ESXi-5.0.0-469512-no-tools,MyClusterName,Management Network,192.168.1.11,255.255.255.0,vmotion,192.168.2.11,255.255.255.0&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then running the script (assuming the file above is called "hosts.csv") would look like:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Connect-VIServer MyVcServerName&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Add-EsxSoftwareDepot &lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="https://hostupdate.vmware.com/software/VUM/PRODUCTION/main/vmw-depot-index.xml"&gt;https://hostupdate.vmware.com/software/VUM/PRODUCTION/main/vmw-depot-index.xml&lt;/A&gt;&lt;/P&gt;&lt;P&gt;.\pre-answer.ps1 .\hosts.csv&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Once the script completes, you can power on your systems and they'll come up with the desired static IPs automatically without user invervention.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Daniel&lt;/P&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And another great script, your on fire !&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This document was generated from the following discussion: &lt;A&gt;javascript:;&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 12 Sep 2011 21:29:40 GMT</pubDate>
      <guid>https://communities.vmware.com/t5/VMware-PowerCLI-Documents/Script-to-pre-answer-static-IP-addresses-for-Auto-Deploy-hosts/ta-p/2786919</guid>
      <dc:creator>alanrenouf</dc:creator>
      <dc:date>2011-09-12T21:29:40Z</dc:date>
    </item>
    <item>
      <title>Re: Script to pre-answer static IP addresses for Auto Deploy hosts (stateless ESXi)</title>
      <link>https://communities.vmware.com/t5/VMware-PowerCLI-Documents/Script-to-pre-answer-static-IP-addresses-for-Auto-Deploy-hosts/tac-p/2786920#M189</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;STRONG&gt; &lt;/STRONG&gt;&lt;/P&gt;&lt;DIV class="jive-thread-reply-message"&gt;&lt;DIV class="jive-rendered-content"&gt;&lt;P&gt;I am new to VMWare ESXi 5.0 Architecture. I have just assembled a PC with i7 3.5 GHz processor installed on ASUS Server board P8BWS&lt;/P&gt;&lt;P&gt;and have enabled the Intel Bios to Virtualization.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I will appreciate assistance in installing my downloaded ESXi 5.0 Evaluation CD Installation program using an AUTO DEPLOY method&lt;/P&gt;&lt;P&gt;by specifiying the SCript to look into the USB flash drive for my DHCP Static IP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My ultimate goal is to be able to create Virtualization and further install Microsoft Server 2008 R2 Server over ESXi 5.0&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have read some threads here about Auto deploy but I am still very confused. I will appreciate a step by step writeup being a novice.&lt;/P&gt;&lt;P&gt;If a sample AUTO DEPLOY script can be uploaded here - it will be great WHEREBY I can place the SCRIPT in my USB flash drive and have the ESXi 5x installation CD to look into that flash drive and do the following:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1). AUTO CONFIGURE PASSWORD FOR ROOT:&lt;BR /&gt;2). AUTO CONFIGURE DHCP Static IP without user intervention.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A sample script and a step by step write will be appreciated please.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PrinceBill&lt;/P&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 08 Apr 2012 12:37:37 GMT</pubDate>
      <guid>https://communities.vmware.com/t5/VMware-PowerCLI-Documents/Script-to-pre-answer-static-IP-addresses-for-Auto-Deploy-hosts/tac-p/2786920#M189</guid>
      <dc:creator>PrinceBill</dc:creator>
      <dc:date>2012-04-08T12:37:37Z</dc:date>
    </item>
  </channel>
</rss>

