<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Automated VM provisioning</title>
	<atom:link href="http://www.virtu-al.net/2010/02/08/automated-vm-provisioning/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.virtu-al.net/2010/02/08/automated-vm-provisioning/</link>
	<description>Virtually everything is poshable</description>
	<lastBuildDate>Thu, 09 Feb 2012 21:00:13 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<xhtml:meta xmlns:xhtml="http://www.w3.org/1999/xhtml" name="robots" content="noindex" />
	<item>
		<title>By: All things Virtual V &#171; TheSaffaGeek</title>
		<link>http://www.virtu-al.net/2010/02/08/automated-vm-provisioning/#comment-1864</link>
		<dc:creator>All things Virtual V &#171; TheSaffaGeek</dc:creator>
		<pubDate>Fri, 19 Feb 2010 12:01:51 +0000</pubDate>
		<guid isPermaLink="false">http://www.virtu-al.net/?p=1427#comment-1864</guid>
		<description>[...] field in using powershell for VMware tasks is Alan Renouf(@alanrenouf). Last Monday he posted a brilliant article detailing automated vm provisioning. I have yet to try these scripts out but if these do what they [...]</description>
		<content:encoded><![CDATA[<p>[...] field in using powershell for VMware tasks is Alan Renouf(@alanrenouf). Last Monday he posted a brilliant article detailing automated vm provisioning. I have yet to try these scripts out but if these do what they [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Virtu-Al</title>
		<link>http://www.virtu-al.net/2010/02/08/automated-vm-provisioning/#comment-1841</link>
		<dc:creator>Virtu-Al</dc:creator>
		<pubDate>Fri, 12 Feb 2010 09:17:11 +0000</pubDate>
		<guid isPermaLink="false">http://www.virtu-al.net/?p=1427#comment-1841</guid>
		<description>@Chris,

Yeah thats a nice way to do it but its worth noting that you are assuming you have enough room on the databases, mine checks the size of the original VM and makes sure that space is on the disk.

Obviously if I was to take this script further we would put some nice error checiking in there to do both and also send an email if there was not enough room etc.

Thanks for the comment, I love people adding their own code.</description>
		<content:encoded><![CDATA[<p>@Chris,</p>
<p>Yeah thats a nice way to do it but its worth noting that you are assuming you have enough room on the databases, mine checks the size of the original VM and makes sure that space is on the disk.</p>
<p>Obviously if I was to take this script further we would put some nice error checiking in there to do both and also send an email if there was not enough room etc.</p>
<p>Thanks for the comment, I love people adding their own code.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Chris</title>
		<link>http://www.virtu-al.net/2010/02/08/automated-vm-provisioning/#comment-1839</link>
		<dc:creator>Chris</dc:creator>
		<pubDate>Thu, 11 Feb 2010 21:02:41 +0000</pubDate>
		<guid isPermaLink="false">http://www.virtu-al.net/?p=1427#comment-1839</guid>
		<description>I use this to find the datastore with the most free space for my (still rough) script that deploys VMs using a CSV file as input.  Sometime soon I need to add in logic for our free space buffer and if no disks have enough free space.  Also, I wrote it a few months ago and just pasting it here I see some things I can improve.  :)

==================
#Parameter- Name of the VMware cluster the VM will be assigned to
param ($cluster)

#get alphabetically last ESX host in the VMware cluster (it&#039;s likely the last host added to the cluster, so this might smoke out any problems)
$vmh = get-vmhost -Location $cluster &#124; Select-Object -Property Name &#124; Sort-Object Name &#124; Select -Last 1 -Property Name

#select the LUN with the most free space
$luns = Get-Datastore -VMHost $vmh.Name

$dst = $luns &#124; Where-Object { $_.Type -eq &quot;VMFS&quot; } &#124; Sort-Object FreeSpaceMB &#124; Select-Object -Last 1 -Property Name

write-output $dst</description>
		<content:encoded><![CDATA[<p>I use this to find the datastore with the most free space for my (still rough) script that deploys VMs using a CSV file as input.  Sometime soon I need to add in logic for our free space buffer and if no disks have enough free space.  Also, I wrote it a few months ago and just pasting it here I see some things I can improve.  <img src='http://www.virtu-al.net/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>==================<br />
#Parameter- Name of the VMware cluster the VM will be assigned to<br />
param ($cluster)</p>
<p>#get alphabetically last ESX host in the VMware cluster (it&#8217;s likely the last host added to the cluster, so this might smoke out any problems)<br />
$vmh = get-vmhost -Location $cluster | Select-Object -Property Name | Sort-Object Name | Select -Last 1 -Property Name</p>
<p>#select the LUN with the most free space<br />
$luns = Get-Datastore -VMHost $vmh.Name</p>
<p>$dst = $luns | Where-Object { $_.Type -eq &#8220;VMFS&#8221; } | Sort-Object FreeSpaceMB | Select-Object -Last 1 -Property Name</p>
<p>write-output $dst</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Virtu-Al</title>
		<link>http://www.virtu-al.net/2010/02/08/automated-vm-provisioning/#comment-1835</link>
		<dc:creator>Virtu-Al</dc:creator>
		<pubDate>Wed, 10 Feb 2010 21:49:13 +0000</pubDate>
		<guid isPermaLink="false">http://www.virtu-al.net/?p=1427#comment-1835</guid>
		<description>Mike, Glad you got it working, allworks fine for me on my home lab and at work, not sure I get the issue

Glad its working now, thanks fo the comments.</description>
		<content:encoded><![CDATA[<p>Mike, Glad you got it working, allworks fine for me on my home lab and at work, not sure I get the issue</p>
<p>Glad its working now, thanks fo the comments.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mike R</title>
		<link>http://www.virtu-al.net/2010/02/08/automated-vm-provisioning/#comment-1834</link>
		<dc:creator>Mike R</dc:creator>
		<pubDate>Wed, 10 Feb 2010 21:25:00 +0000</pubDate>
		<guid isPermaLink="false">http://www.virtu-al.net/?p=1427#comment-1834</guid>
		<description>Actually-I was able to cast the $Total var and then all worked beautifully-thanks much for the code!

$OriginalSRV &#124; Select -ExpandProperty HardDisks &#124; Foreach { [int]$Total += $_.CapacityKB }</description>
		<content:encoded><![CDATA[<p>Actually-I was able to cast the $Total var and then all worked beautifully-thanks much for the code!</p>
<p>$OriginalSRV | Select -ExpandProperty HardDisks | Foreach { [int]$Total += $_.CapacityKB }</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mike R</title>
		<link>http://www.virtu-al.net/2010/02/08/automated-vm-provisioning/#comment-1833</link>
		<dc:creator>Mike R</dc:creator>
		<pubDate>Wed, 10 Feb 2010 21:11:51 +0000</pubDate>
		<guid isPermaLink="false">http://www.virtu-al.net/?p=1427#comment-1833</guid>
		<description>Hey,
great scripts-but one question-it&#039;s not picking up a datastore because querying the disks on line 24 and then adding for required size is actually concatenating, not adding, so you never find a datastore with enough room. I&#039;ve tried an explicit cast for $_.CapacityKB values to int, but no luck. It will work if I manually specify a value for the $NewDatastore var...

$OriginalSRV &#124; Select -ExpandProperty HardDisks &#124; Foreach { $Total += $_.CapacityKB }</description>
		<content:encoded><![CDATA[<p>Hey,<br />
great scripts-but one question-it&#8217;s not picking up a datastore because querying the disks on line 24 and then adding for required size is actually concatenating, not adding, so you never find a datastore with enough room. I&#8217;ve tried an explicit cast for $_.CapacityKB values to int, but no luck. It will work if I manually specify a value for the $NewDatastore var&#8230;</p>
<p>$OriginalSRV | Select -ExpandProperty HardDisks | Foreach { $Total += $_.CapacityKB }</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Virtu-Al</title>
		<link>http://www.virtu-al.net/2010/02/08/automated-vm-provisioning/#comment-1823</link>
		<dc:creator>Virtu-Al</dc:creator>
		<pubDate>Tue, 09 Feb 2010 23:13:23 +0000</pubDate>
		<guid isPermaLink="false">http://www.virtu-al.net/?p=1427#comment-1823</guid>
		<description>Yeah shouldnt be too bad, just a VM which runs a batch file as part of the sysprep.

Im glad you enjoyed the weather addin, just shows the power of PowerShell</description>
		<content:encoded><![CDATA[<p>Yeah shouldnt be too bad, just a VM which runs a batch file as part of the sysprep.</p>
<p>Im glad you enjoyed the weather addin, just shows the power of PowerShell</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ionut Nica</title>
		<link>http://www.virtu-al.net/2010/02/08/automated-vm-provisioning/#comment-1822</link>
		<dc:creator>Ionut Nica</dc:creator>
		<pubDate>Tue, 09 Feb 2010 21:03:28 +0000</pubDate>
		<guid isPermaLink="false">http://www.virtu-al.net/?p=1427#comment-1822</guid>
		<description>Nice post, the weather stuff was particularly funny :)

The real magic lies within the templated VM, which is prepped to join the load balancing fun:)</description>
		<content:encoded><![CDATA[<p>Nice post, the weather stuff was particularly funny <img src='http://www.virtu-al.net/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>The real magic lies within the templated VM, which is prepped to join the load balancing fun:)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: uberVU - social comments</title>
		<link>http://www.virtu-al.net/2010/02/08/automated-vm-provisioning/#comment-1820</link>
		<dc:creator>uberVU - social comments</dc:creator>
		<pubDate>Mon, 08 Feb 2010 14:33:14 +0000</pubDate>
		<guid isPermaLink="false">http://www.virtu-al.net/?p=1427#comment-1820</guid>
		<description>&lt;strong&gt;Social comments and analytics for this post...&lt;/strong&gt;

This post was mentioned on Twitter by afokkema: RT @alanrenouf: New Blog post: Automated VM provisioning http://bit.ly/93v3cA #PowerCLI #PowerShell...</description>
		<content:encoded><![CDATA[<p><strong>Social comments and analytics for this post&#8230;</strong></p>
<p>This post was mentioned on Twitter by afokkema: RT @alanrenouf: New Blog post: Automated VM provisioning <a href="http://bit.ly/93v3cA" rel="nofollow">http://bit.ly/93v3cA</a> #PowerCLI #PowerShell&#8230;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Virtu-Al</title>
		<link>http://www.virtu-al.net/2010/02/08/automated-vm-provisioning/#comment-1819</link>
		<dc:creator>Virtu-Al</dc:creator>
		<pubDate>Mon, 08 Feb 2010 14:28:03 +0000</pubDate>
		<guid isPermaLink="false">http://www.virtu-al.net/?p=1427#comment-1819</guid>
		<description>Yeah I agree, this was more of a proof of concept to show people what could be done.

We could obviously have a script to do the reverse and remove teh VM&#039;s once they are no loger needed.

Thanks for the comment.</description>
		<content:encoded><![CDATA[<p>Yeah I agree, this was more of a proof of concept to show people what could be done.</p>
<p>We could obviously have a script to do the reverse and remove teh VM&#8217;s once they are no loger needed.</p>
<p>Thanks for the comment.</p>
]]></content:encoded>
	</item>
</channel>
</rss>

