<?xml version="1.0" encoding="UTF-8"?> <rss
version="2.0"
xmlns:content="http://purl.org/rss/1.0/modules/content/"
xmlns:wfw="http://wellformedweb.org/CommentAPI/"
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/"
xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
> <channel><title>Professional VMware &#187; VI Toolkit</title> <atom:link href="http://professionalvmware.com/category/vi-toolkit/feed/" rel="self" type="application/rss+xml" /><link>http://professionalvmware.com</link> <description>How Many Turtles Can You Fit On A Rock?</description> <lastBuildDate>Fri, 10 Feb 2012 00:37:53 +0000</lastBuildDate> <language>en</language> <sy:updatePeriod>hourly</sy:updatePeriod> <sy:updateFrequency>1</sy:updateFrequency> <generator>http://wordpress.org/?v=3.2.1</generator> <item><title>The Turtles Are Upon Us &#8211; The VESI</title><link>http://professionalvmware.com/2009/04/the-turtles-are-upon-us-the-vesi/</link> <comments>http://professionalvmware.com/2009/04/the-turtles-are-upon-us-the-vesi/#comments</comments> <pubDate>Tue, 28 Apr 2009 16:05:00 +0000</pubDate> <dc:creator>bunchc</dc:creator> <category><![CDATA[powershell]]></category> <category><![CDATA[VI Toolkit]]></category> <category><![CDATA[Virtu-AL]]></category> <category><![CDATA[Virtu-al.net]]></category> <guid
isPermaLink="false">http://professionalvmware.com/2009/04/28/the-turtles-are-upon-us-the-vesi/</guid> <description><![CDATA[So one of the things that did happen whilst I was away, and that does bear repeating (as it’s not marketing fluff) is the Virtualization Eco Shell Initiative and their beta release landing (Thanks Virtua-al). The goal of the Vizioncore Virtualization EcoShell is to provide a freeware desktop application for novice and expert IT administrators [...]]]></description> <content:encoded><![CDATA[<p></p><p>So one of the things that did happen whilst I was away, and that does bear repeating (as it’s not marketing fluff) is the <a
href="http://www.thevesi.org/index.jspa">Virtualization Eco Shell Initiative</a> and their beta release <a
href="http://www.virtu-al.net/2009/04/15/the-turtle-has-landed-the-ves-is-here/">landing</a> (Thanks Virtua-al).</p><blockquote><p>The goal of the Vizioncore Virtualization EcoShell is to provide a freeware desktop application for novice and expert IT administrators leveraging Windows PowerShell scripts across their multi-platform virtual environments.&#160;&#160;</p><p>Fostered and supported by The Virtualization EcoShell Initiative (VESI) &#8211; an online community-driven Web site sponsored by Vizioncore &#8211; the Virtualization EcoShell is enhanced by the participation of community members through the exchange of new ideas, value-add services and extendable scripts.</p></blockquote><p>Slick, no? Ok, so that was a marketing quote there, but it is quite impressive, look at some of the HTML reports:</p><p><img
height="437" src="http://www.virtu-al.net/wp-content/uploads/2009/04/virtualcenterreport.jpg" width="584" /></p><p><img
src="http://www.virtu-al.net/wp-content/uploads/2009/04/hostreport-thumb.jpg" /></p><p>Screenshots also the thanks of Mr Al. I’ll try to get a quick demo posted in the next day or so as well.</p> ]]></content:encoded> <wfw:commentRss>http://professionalvmware.com/2009/04/the-turtles-are-upon-us-the-vesi/feed/</wfw:commentRss> <slash:comments>1</slash:comments> </item> <item><title>PoSH Article of the Week! &#8211; Secure Credential Storage</title><link>http://professionalvmware.com/2009/04/posh-article-of-the-week-secure-credential-storage/</link> <comments>http://professionalvmware.com/2009/04/posh-article-of-the-week-secure-credential-storage/#comments</comments> <pubDate>Fri, 10 Apr 2009 02:27:56 +0000</pubDate> <dc:creator>bunchc</dc:creator> <category><![CDATA[powershell]]></category> <category><![CDATA[Scripting]]></category> <category><![CDATA[VI Toolkit]]></category> <category><![CDATA[security]]></category> <guid
isPermaLink="false">http://professionalvmware.com/2009/04/09/posh-article-of-the-week-secure-credential-storage/</guid> <description><![CDATA[While glancing over at PoSH today (the tiny turtle) I was inspired to do a bit of thinking and talking about using PoSH. Specifically the VI Toolkit, it really wouldn’t be blog worth otherwise would it? What I got thinking on, and what someone on irc clued me into, was storing credentials. Why store credentials? [...]]]></description> <content:encoded><![CDATA[<p></p><p>While glancing over at PoSH today (the tiny turtle) I was inspired to do a bit of thinking and talking about using PoSH. Specifically the VI Toolkit, it really wouldn’t be blog worth otherwise would it? What I got thinking on, and what someone on irc clued me into, was storing credentials.</p><h3>Why store credentials?</h3><p>Well, the beauty of automation is that you don’t have to be there for it to happen. I mean really, your sprinklers go off without intervention, why shouldn’t your scripts? The conflict come is, is that Virtual Center requires authentication, and based on that authentication, you are granted some permissions and such. Storing these credentials is what makes the hands off automation happen. After all, do you really want to turn your sprinklers on each time?</p><h3>Storing Credentials</h3><p>This is the part of the post where we get into the code, so if you are faint of heart, or allergic to chicken teriyaki, you can move along now. Still with us? Great!</p><p>Built into the <a
href="http://vmware.com/go/powershell">VMware VI ToolKit (for Windows) Version 1.5</a> are a few cmdlets that make this really really simple:</p><ul><li>New-VICredentialStoreItem</li><li>Get-VICredentialStoreItem</li><li>Remove-VICredentialStoreItem</li></ul><p>Rather self explanatory, no? Let us glance at what they look like in use:</p><h3>New-VICredentialStoreItem</h3><p><font
face="Courier New" color="#ff8040">New-VICredentialStoreItem -host &#8216;vCenter.professionalvmware.com&#8217; -user &#8216;marcus&#8217; -password &#8216;garvey&#8217; -file c:\test</font></p><p>That is all one line, and what that basically does is create an XML file representing a credential store, with your encrypted password, like this:</p><p><font
face="Courier New" color="#ff8040">&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt; <br
/>&lt;viCredentials&gt; <br
/>&#160; &lt;version&gt;1.0&lt;/version&gt; <br
/>&#160; &lt;passwordEntry&gt; <br
/>&#160;&#160;&#160; &lt;host&gt;vCenter.professionalvmware.com&lt;/host&gt; <br
/>&#160;&#160;&#160; &lt;username&gt;marcus&lt;/username&gt; <br
/>&#160;&#160;&#160; &lt;password&gt;omitted&lt;/password&gt; <br
/>&#160; &lt;/passwordEntry&gt; <br
/>&lt;/viCredentials&gt;</font></p><p>Cleared out the &lt;password&gt;&lt;/password&gt; area for space. It should also be noted here, that C:\ is likely not the best place to be storing these, and that they’re secured by NTFS file permissions, so use whatever security policies your organization dictates for this function (if they allow this at all). This is all well and good, how do we use them now?</p><h3>Get-VICredentialStoreItem</h3><p>Well, who didn’t see this cmdlet coming next? I mean 1/2 the page up I foreshadowed it quite heavily. As you can guess, using this cmdlet is not all that difficult, but we’ll show you how to use it anyways:</p><p><font
face="Courier New" color="#ff8040">[VI Toolkit] C:\&gt; $creds = Get-VICredentialStoreItem -file c:\test <br
/>[VI Toolkit] C:\&gt; $creds | fl * </font></p><p><font
face="Courier New" color="#ff8040">Host&#160;&#160;&#160;&#160; : vCenter.professionalvmware.com <br
/>User&#160;&#160;&#160;&#160; : marcus <br
/>Password : garvey <br
/>File&#160;&#160;&#160;&#160; : c:\test</font></p><p>Cool, so we opened our credential store, and stored it in a variable, and as we can see that variable has a few properties to it, so lets use these to connect to a vCenter:</p><p><font
face="Courier New" color="#ff8040">[VI Toolkit] C:\&gt; connect-viserver -Server $creds.Host -User $creds.User -Password $creds.Password</font></p><p>Good stuff, in fact, excellent stuff. Considering, you can use this beyond storing just vCenter/ESX credentials, anything that requires a user/pass/hostname can be stored in this manner, and used again within your VI ToolKit scripts.</p><p>Now that we have all of this excellence, we’ll take a look at making it go away once your security guys catch wind of what you’ve been up to.</p><h3>Remove-VICredentialStoreItem</h3><p>Now, the foreshadowing and the lead in, if you couldn’t guess this title… no bacon and pancakes for you.</p><p>Looking at the get-help for Remove-VICredentialStoreItem, there are a number of ways you can remove said credential stores, you can specify the file, like we did in the past two examples, or, you can do like we do in this one, and use the pipeline:</p><p><font
face="Courier New" color="#ff8040">[VI Toolkit] C:\&gt; $creds | Remove-VICredentialStoreItem </font></p><p><font
face="Courier New" color="#ff8040">Confirm <br
/>Are you sure you want to perform this action? <br
/>Performing operation &quot;Remove-VICredentialStoreItem&quot; on Target &quot;Remove credential store item for <br
/>host &#8216;vCenter.professionalvmware.com&#8217; and username &#8216;marcus&#8217;?&quot;. <br
/>[Y] Yes&#160; [A] Yes to All&#160; [N] No&#160; [L] No to All&#160; [S] Suspend&#160; [?] Help (default is &quot;Y&quot;):</font></p><p>Of course the answer is [Y]es, we want to do this, and if you want to actually turn the confirmation off, you can specify the “-confirm:$false” flag.</p><p>This of course brings us to the grand conclusion of this post. If you found this useful, please consider subscribing, and telling a friend (or three), if not, well… don’t tell anyone. If you have questions or comments, ping me on <a
href="http://twitter.com/cody_bunch">twitter</a>, or via the comments.</p> ]]></content:encoded> <wfw:commentRss>http://professionalvmware.com/2009/04/posh-article-of-the-week-secure-credential-storage/feed/</wfw:commentRss> <slash:comments>8</slash:comments> </item> <item><title>Go Go PowerShell Speed Racer! &#8211; Speeding up PowerShell scripts.</title><link>http://professionalvmware.com/2009/03/go-go-powershell-speed-racer-speeding-up-powershell-scripts/</link> <comments>http://professionalvmware.com/2009/03/go-go-powershell-speed-racer-speeding-up-powershell-scripts/#comments</comments> <pubDate>Wed, 25 Mar 2009 14:27:24 +0000</pubDate> <dc:creator>bunchc</dc:creator> <category><![CDATA[powershell]]></category> <category><![CDATA[VI Toolkit]]></category> <category><![CDATA[VM]]></category> <guid
isPermaLink="false">http://professionalvmware.com/2009/03/25/go-go-powershell-speed-racer-speeding-up-powershell-scripts/</guid> <description><![CDATA[From the VI Toolkit blog. Can you spot the difference between this code: 1: foreach ($vm in (get-vm)) { 2: $disks = Get-HardDisk -vm $vm 3: foreach ($disk in $disks) { 4:&#160; Write-Host $disk.CapacityKB 5: } 6: } And this code: 1: foreach ($vm in (get-vm)) { 2: $disks = Get-HardDisk -vm $vm.name 3: foreach [...]]]></description> <content:encoded><![CDATA[<p></p><p>From the <a
href="http://blogs.vmware.com/vipowershell/2009/03/why-is-my-code-so-slow.html">VI Toolkit</a> blog.</p><blockquote><p>Can you spot the difference between this code:</p><p> 1: foreach ($vm in (get-vm)) {</p><p> 2: $disks = Get-HardDisk -vm $vm</p><p> 3: foreach ($disk in $disks) {</p><p> 4:&#160; Write-Host $disk.CapacityKB</p><p> 5: }</p><p> 6: }</p><p>And this code:</p><p> 1: foreach ($vm in (get-vm)) {</p><p> 2: $disks = Get-HardDisk -vm $vm.name</p><p> 3: foreach ($disk in $disks) {</p><p> 4:&#160; Write-Host $disk.CapacityKB</p><p> 5: }</p><p> 6: }</p><p>This is not quite a trick question, the only difference is that one uses $vm and one uses $vm.name in the second line. Both of these are valid and produce the same results. However, there’s a really important difference between them. I timed these code samples in my environment and here are the results:</p><p>&#160;&#160;&#160; * Code sample 1 (aka Fast): 13.44 seconds. <br
/>&#160;&#160;&#160; * Code sample 2 (aka Slow): 3178.55 seconds.</p></blockquote><ol><li>Try to load as many objects as possible into arrays beforehand. Once you’ve got them loaded you can use them as arguments to multiple calls without having to resort to potentially expensive lookups every time.</li><li>Just like in sample 1 above, when you’ve loaded objects, use the objects directly rather than using their names. This is usually not hard as our cmdlets are designed to take object first-and-foremost, and names are supported just as a convenience.</li><li>If you absolutely need to load a single VM object by name, load it using the Get-VMFast function below. While this approach can certainly help, it’s not nearly as good as using the other two techniques mentioned above.</li></ol> ]]></content:encoded> <wfw:commentRss>http://professionalvmware.com/2009/03/go-go-powershell-speed-racer-speeding-up-powershell-scripts/feed/</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>Chicken Counter Script</title><link>http://professionalvmware.com/2009/03/chicken-counter-script/</link> <comments>http://professionalvmware.com/2009/03/chicken-counter-script/#comments</comments> <pubDate>Thu, 12 Mar 2009 21:10:34 +0000</pubDate> <dc:creator>bunchc</dc:creator> <category><![CDATA[powershell]]></category> <category><![CDATA[Reporting]]></category> <category><![CDATA[Scripting]]></category> <category><![CDATA[VI Toolkit]]></category> <guid
isPermaLink="false">http://professionalvmware.com/2009/03/12/chicken-counter-script/</guid> <description><![CDATA[What we have today, was brought up on #ESX on EfNet. They were looking for a script to generate output similar to what you get by clicking on “Hosts and Clusters”, selecting “File &#62; Export &#62; Export List…” Like this: What I came up with is not quite as pretty, but, it works, and you [...]]]></description> <content:encoded><![CDATA[<p></p><p>What we have today, was brought up on #ESX on EfNet. They were looking for a script to generate output similar to what you get by clicking on “Hosts and Clusters”, selecting “File &gt; Export &gt; Export List…”</p><p>Like this:</p><p><a
href="http://professionalvmware.com/wp-content/uploads/2009/03/20090312-1556.png"><img
title="2009-03-12_1556" style="border-right: 0px; border-top: 0px; display: inline; border-left: 0px; border-bottom: 0px" height="108" alt="2009-03-12_1556" src="http://professionalvmware.com/wp-content/uploads/2009/03/20090312-1556-thumb.png" width="227" border="0" /></a></p><p><a
href="http://professionalvmware.com/wp-content/uploads/2009/03/20090312-1558.png"><img
title="2009-03-12_1558" style="border-right: 0px; border-top: 0px; display: inline; border-left: 0px; border-bottom: 0px" height="86" alt="2009-03-12_1558" src="http://professionalvmware.com/wp-content/uploads/2009/03/20090312-1558-thumb.png" width="543" border="0" /></a></p><p>What I came up with is not quite as pretty, but, it works, and you can schedule it using the Windows Task Scheduler. First the code:</p><div
class="csharpcode"><pre class="alt"><span class="lnum">   1:  </span>Begin {</pre><pre><span class="lnum">   2:  </span>    $hostCount= @{</pre><pre class="alt"><span class="lnum">   3:  </span>        Name = <span class="str">&quot;hostCount&quot;</span></pre><pre><span class="lnum">   4:  </span>        Expression = { $_ | get-vmhost | measure-<span class="kwrd">object</span> | %{$_.Count} }</pre><pre class="alt"><span class="lnum">   5:  </span>    }</pre><pre><span class="lnum">   6:  </span>    $vmCount = @{</pre><pre class="alt"><span class="lnum">   7:  </span>        Name = <span class="str">&quot;vmCount&quot;</span></pre><pre><span class="lnum">   8:  </span>        Expression = { $_ | get-vm | measure-<span class="kwrd">object</span> | %{$_.Count}  }</pre><pre class="alt"><span class="lnum">   9:  </span>    }</pre><pre><span class="lnum">  10:  </span>}</pre><pre class="alt"><span class="lnum">  11:  </span>&#160;</pre><pre><span class="lnum">  12:  </span>Process {</pre><pre class="alt"><span class="lnum">  13:  </span>    $InputTypeName = $_.GetType().Name</pre><pre><span class="lnum">  14:  </span>    <span class="kwrd">if</span> ( $InputTypeName -eq <span class="str">&quot;DatacenterImpl&quot;</span> ) {</pre><pre class="alt"><span class="lnum">  15:  </span>        $output = $_ | select Name, $hostCount, $vmCount</pre><pre><span class="lnum">  16:  </span>        <span class="kwrd">return</span> $output</pre><pre class="alt"><span class="lnum">  17:  </span>    }</pre><pre><span class="lnum">  18:  </span>}</pre></div><style type="text/css">.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }</style></p><p>I’ve saved this in a file creatively called export-list.ps1. It requires you to be connected to a vCenter server, and accepts a datacenter object ($InputTypeName –eq “DatacenterImpl”) from the pipeline. From there it takes each, and spits them out, like this:</p><p><font
face="Courier New" color="#ff8040">[VI Toolkit] C:\&gt; get-datacenter | .\scripts\export-list.ps1 </font></p><p><font
face="Courier New" color="#ff8040">Name&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; hostCount&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; vmCount<br
/> <br
/>&#8212;-&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &#8212;&#8212;&#8212;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &#8212;&#8212;-</p><p>dev&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; 1&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; 3</p><p>stage&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; 1&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; 5</p><p>prod&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; 1&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; 8</font></p><p>Sexy, right? Not so much, but this is where PowerShell and the VI Toolkit shine, in their flexibility. So you want HTML? Check this out:</p><p><font
face="Courier New" color="#ff8040">[VI Toolkit] C:\&gt; get-datacenter | .\scripts\export-list.ps1 | ConvertTo-HTML &gt; report.html </font></p><p>Just open report.html, and run with it. Scheduling this in Task manager isn’t that much harder, but will remain a task for the reader.</p> ]]></content:encoded> <wfw:commentRss>http://professionalvmware.com/2009/03/chicken-counter-script/feed/</wfw:commentRss> <slash:comments>1</slash:comments> </item> <item><title>Oh My! PowerGUI VMware PowerPack 2.1.5 &#8211; Now On &#8216;Roids!</title><link>http://professionalvmware.com/2009/03/oh-my-powergui-vmware-powerpack-215-now-on-roids/</link> <comments>http://professionalvmware.com/2009/03/oh-my-powergui-vmware-powerpack-215-now-on-roids/#comments</comments> <pubDate>Mon, 09 Mar 2009 19:06:00 +0000</pubDate> <dc:creator>bunchc</dc:creator> <category><![CDATA[powershell]]></category> <category><![CDATA[VI Toolkit]]></category> <guid
isPermaLink="false">http://professionalvmware.com/2009/03/09/oh-my-powergui-vmware-powerpack-215-now-on-roids/</guid> <description><![CDATA[Maybe not ‘roids, but with a large helping of awesome, like, vDiagram, shown below. Click on over to virtu-al.net to see the rest.]]></description> <content:encoded><![CDATA[<p></p><p>Maybe not ‘roids, but with a large helping of awesome, like, vDiagram, shown below. Click on over to <a
href="http://www.virtu-al.net/2009/03/09/powergui-vmware-powerpack-215-released/">virtu-al.net</a> to see the rest.</p><p><a
href="http://professionalvmware.com/wp-content/uploads/2009/03/vmgurulab41.png"><img
style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="vmguru-lab4[1]" border="0" alt="vmguru-lab4[1]" src="http://professionalvmware.com/wp-content/uploads/2009/03/vmgurulab41-thumb.png" width="436" height="331" /></a></p> ]]></content:encoded> <wfw:commentRss>http://professionalvmware.com/2009/03/oh-my-powergui-vmware-powerpack-215-now-on-roids/feed/</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>VMworld Europe 2009 &#8211; VI Toolkit Lab Manual Available!</title><link>http://professionalvmware.com/2009/03/vmworld-europe-2009-vi-toolkit-lab-manual-available/</link> <comments>http://professionalvmware.com/2009/03/vmworld-europe-2009-vi-toolkit-lab-manual-available/#comments</comments> <pubDate>Mon, 09 Mar 2009 11:53:18 +0000</pubDate> <dc:creator>bunchc</dc:creator> <category><![CDATA[VI Toolkit]]></category> <category><![CDATA[VMWorld Europe]]></category> <guid
isPermaLink="false">http://professionalvmware.com/2009/03/09/vmworld-europe-2009-vi-toolkit-lab-manual-available/</guid> <description><![CDATA[If like me you couldn’t get to VMworld Europe 2009, this will be great news. They’ve made the VI Toolkit Lab available online. I’ll give this a run through later tonight.]]></description> <content:encoded><![CDATA[<p></p><p>If like me you couldn’t get to VMworld Europe 2009, this will be great news. They’ve made the <a
href="http://blogs.vmware.com/vipowershell/2009/02/vi-toolkit-lab-at-vmworld-europe-2009.html">VI Toolkit Lab available online</a>. I’ll give this a run through later tonight.</p> ]]></content:encoded> <wfw:commentRss>http://professionalvmware.com/2009/03/vmworld-europe-2009-vi-toolkit-lab-manual-available/feed/</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>ProfessionalVMware @ VMWorld Europe 2009</title><link>http://professionalvmware.com/2009/03/professionalvmware-vmworld-europe-2009/</link> <comments>http://professionalvmware.com/2009/03/professionalvmware-vmworld-europe-2009/#comments</comments> <pubDate>Mon, 02 Mar 2009 21:08:00 +0000</pubDate> <dc:creator>bunchc</dc:creator> <category><![CDATA[VI Toolkit]]></category> <category><![CDATA[VMWorld Europe]]></category> <guid
isPermaLink="false">http://professionalvmware.com/2009/03/02/professionalvmware-vmworld-europe-2009/</guid> <description><![CDATA[I wasn’t there, but had a few other folks on Twitter point out to me that I got a mention during one of Carters presentations on automating VMware with PowerShell. Startled and amazed by this, I asked for some proof, and well… got it: Woo! For those that didn’t know I’ll be doing a similar [...]]]></description> <content:encoded><![CDATA[<p></p><p>I wasn’t there, but had a few other folks on Twitter point out to me that I got a mention during one of Carters presentations on automating VMware with PowerShell. Startled and amazed by this, I asked for some proof, and well… got it:</p><p><a
href="http://professionalvmware.com/wp-content/uploads/2009/03/vmworldftw.png"><img
style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="VMWorld FTW" border="0" alt="VMWorld FTW" src="http://professionalvmware.com/wp-content/uploads/2009/03/vmworldftw-thumb.png" width="477" height="311" /></a></p><p>Woo! For those that didn’t know I’ll be doing a similar presentation, along side Pancil at the <a
href="http://virtualizationcongress.com/">Virtualization Congress in Vegas this May.</a></p> ]]></content:encoded> <wfw:commentRss>http://professionalvmware.com/2009/03/professionalvmware-vmworld-europe-2009/feed/</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>Where Did I Put My Tools? Are They In Sync? – Checking the VMware Tools with PowerShell</title><link>http://professionalvmware.com/2009/02/where-did-i-put-my-tools-are-they-in-sync-checking-the-vmware-tools-with-powershell/</link> <comments>http://professionalvmware.com/2009/02/where-did-i-put-my-tools-are-they-in-sync-checking-the-vmware-tools-with-powershell/#comments</comments> <pubDate>Mon, 23 Feb 2009 16:10:00 +0000</pubDate> <dc:creator>bunchc</dc:creator> <category><![CDATA[powershell]]></category> <category><![CDATA[VI Toolkit]]></category> <guid
isPermaLink="false">http://professionalvmware.com/2009/02/16/where-did-i-put-my-tools-are-they-in-sync-checking-the-vmware-tools-with-powershell/</guid> <description><![CDATA[It’s 7PM, do you know where your VMware Tools are? Rather, do you know if all your VM’s have them installed and running? Here is a one-liner to check that with PowerShell: get-vm &#124; where { $_.PowerState -eq &#34;PoweredOn&#34; } &#124; Get-VMGuest &#124; where { $_.State -ne &#34;Running&#34; } &#124; select vmName, State What this [...]]]></description> <content:encoded><![CDATA[<p></p><p>It’s 7PM, do you know where your VMware Tools are? Rather, do you know if all your VM’s have them installed and running?</p><p>Here is a one-liner to check that with PowerShell:</p><p>get-vm | where { $_.PowerState -eq &quot;PoweredOn&quot; } | Get-VMGuest | where { $_.State -ne &quot;Running&quot; } | select vmName, State</p><p>What this does, is get a list of VM’s, selects those that are running, and then gets the tools status and selects those that do not have a status of “Running”. Easy… no?</p><p>Here’s another one-liner to check to see if you have the tools configured to sync time with the host system:</p><p>get-vm |where { ( %{ get-view $_.Id } | where { $_.Config.Tools.SyncTimeWithHost -ne &quot;True&quot; } ) } | select name</p><p>This one, gets a list of VM’s, then takes from that list, the VM’s that do not have tools set to sync with the host system. There is a lot of { and ( action there… because that info is pretty well hidden.</p><p>What else do you check for on your VM’s… tools versions? etc? Leave me a note in the comments.</p> ]]></content:encoded> <wfw:commentRss>http://professionalvmware.com/2009/02/where-did-i-put-my-tools-are-they-in-sync-checking-the-vmware-tools-with-powershell/feed/</wfw:commentRss> <slash:comments>4</slash:comments> </item> <item><title>What VLAN is that VM On? Ask PowerShell!</title><link>http://professionalvmware.com/2009/02/what-vlan-is-that-vm-on-ask-powershell/</link> <comments>http://professionalvmware.com/2009/02/what-vlan-is-that-vm-on-ask-powershell/#comments</comments> <pubDate>Fri, 20 Feb 2009 14:26:37 +0000</pubDate> <dc:creator>bunchc</dc:creator> <category><![CDATA[Network Diagram]]></category> <category><![CDATA[networking]]></category> <category><![CDATA[powershell]]></category> <category><![CDATA[VI Toolkit]]></category> <guid
isPermaLink="false">http://professionalvmware.com/2009/02/20/what-vlan-is-that-vm-on-ask-powershell/</guid> <description><![CDATA[When your network engineer, or other random folks are looking for some assistance in updating their vlan map Visio, or are generally trying to make their work yours (who doesn’t love to delegate) you can bash out this one liner against your VI, and instantly have a list of what VM is on what VLAN. [...]]]></description> <content:encoded><![CDATA[<p></p><p>When your network engineer, or other random folks are looking for some assistance in updating their vlan map Visio, or are generally trying to make their work yours (who doesn’t love to delegate) you can bash out this one liner against your VI, and instantly have a list of what VM is on what VLAN.</p><p>Yes the formatting sucks, and yes, in my lab I only have a single VLAN (unless someone wants to send me a smart switch), but this gets the point across:</p><p><span
style="font-family: Courier New; color: #ff8040;">PS C:\Users\bunchc&gt; get-vm | %{ write-host $_.Name `t ($_ | Get-VirtualPortGroup | select vlanid)}<br
/> dc01.nerv.local      @{VLanId=0}<br
/> monitoring.nerv.local      @{VLanId=0}<br
/> rcli.nerv.local      @{VLanId=0}<br
/> This Is A Clone      @{VLanId=0}<br
/> shell.nerv.local      @{VLanId=0}<br
/> fs.nerv.local      @{VLanId=0}</span></p><p>For further network information, all wrapped up in a sexy csv, you can use Alan Renouf&#8217;s script <a
href="http://teckinfo.blogspot.com/2009/02/more-network-info.html">here.</a><br
/> Questions? Thoughts? Corrections on my Caca code? Leave me a note in the comments, or hit me up on twitter <a
href="http://twitter.com/cody_bunch">@cody_bunch</a></p> ]]></content:encoded> <wfw:commentRss>http://professionalvmware.com/2009/02/what-vlan-is-that-vm-on-ask-powershell/feed/</wfw:commentRss> <slash:comments>2</slash:comments> </item> <item><title>Log Bundles, of the Virtual Center Variety</title><link>http://professionalvmware.com/2009/01/log-bundles-of-the-virtual-center-variety/</link> <comments>http://professionalvmware.com/2009/01/log-bundles-of-the-virtual-center-variety/#comments</comments> <pubDate>Tue, 27 Jan 2009 17:46:00 +0000</pubDate> <dc:creator>bunchc</dc:creator> <category><![CDATA[Troubleshooting]]></category> <category><![CDATA[VI Toolkit]]></category> <category><![CDATA[Virtual Infrastructure]]></category> <category><![CDATA[VMware]]></category> <category><![CDATA[VMware Powershell]]></category> <category><![CDATA[powershell]]></category> <guid
isPermaLink="false">http://professionalvmware.com/2009/01/26/log-bundles-of-the-virtual-center-variety/</guid> <description><![CDATA[Things break. They always do. Chaos is inevitable. So how do you get insight into some of the chaos that was occurring in your Virtual Center when disaster strikes? Turns out, the VI Client makes this quite easy. After you get your Virtual Center service running again, connect using the VI Client. Once connected… well [...]]]></description> <content:encoded><![CDATA[<p></p><p>Things break. They always do. Chaos is inevitable. So how do you get insight into some of the chaos that was occurring in your Virtual Center when disaster strikes? Turns out, the VI Client makes this quite easy.</p><p>After you get your Virtual Center service running again, connect using the VI Client. Once connected… well follow along:</p><p>File &gt; Export &gt; Export Diag Data<br
/> <a
href="http://professionalvmware.com/wp-content/uploads/2009/01/20090125-1901.png"><img
style="display: inline; border: 0px;" title="2009-01-25_1901" src="http://professionalvmware.com/wp-content/uploads/2009/01/20090125-1901-thumb.png" border="0" alt="2009-01-25_1901" width="244" height="142" /></a></p><p>The resulting window:<br
/> <a
href="http://professionalvmware.com/wp-content/uploads/2009/01/20090125-1902.png"><img
style="display: inline; border: 0px;" title="2009-01-25_1902" src="http://professionalvmware.com/wp-content/uploads/2009/01/20090125-1902-thumb.png" border="0" alt="2009-01-25_1902" width="242" height="244" /></a></p><p>The options you select here determine the logs you get… Be careful when doing this across your entire VI, as it may take quite some time. For our example, we’ll stick with just the Virtual Center logs. After that, select a path and hit OK! This generates a task, much like the following:</p><p><a
href="http://professionalvmware.com/wp-content/uploads/2009/01/20090125-1903.png"><img
style="display: inline; border: 0px;" title="2009-01-25_1903" src="http://professionalvmware.com/wp-content/uploads/2009/01/20090125-1903-thumb.png" border="0" alt="2009-01-25_1903" width="589" height="76" /></a></p><p>What this task does, is give you the time to go get a cup of coffee. Really (Remember the note above? Now imagine we did this across 200 hosts).  Done:</p><p><a
href="http://professionalvmware.com/wp-content/uploads/2009/01/20090126-0431.png"><img
style="display: inline; border: 0px;" title="2009-01-26_0431" src="http://professionalvmware.com/wp-content/uploads/2009/01/20090126-0431-thumb.png" border="0" alt="2009-01-26_0431" width="391" height="258" /></a></p><p>This task generates a folder in the location you specified prior. The contents of the folder file look very much like:</p><p><span
style="color: #000000;"><span
style="font-family: Courier New;">PS C:Documents and Settingscody.bunchDesktopVMware-VirtualCenter-support-2009-01-25@19-07-49&gt; dir </span></span></p><p><span
style="color: #000000;"><span
style="font-family: Courier New;"> Directory: C:Documents and Settingscody.bunchDesktopVMware-VirtualCenter-support-2009-01-25@19-07-49 </span></span></p><p><span
style="color: #000000;"><span
style="font-family: Courier New;">Mode                LastWriteTime     Length Name<br
/> &#8212;-                &#8212;&#8212;&#8212;&#8212;-     &#8212;&#8212; &#8212;-<br
/> d&#8212;-         1/25/2009   7:07 PM            viclient-support<br
/> -a&#8212;         1/25/2009   7:09 PM   76580475 </span><span
style="font-family: Courier New;">vcsupport-2009-01-25@19-07-49.zip</span></span></p><p>Contained within the sub folder are logs related to the VI Client. They look like:</p><p><span
style="color: #000000;"><span
style="font-family: Courier New;">PS C:Documents and Settingscody.bunchDesktopVMware-VirtualCenter-support-2009-01-25@19-07-49viclient-support&gt; dir </span></span></p><p><span
style="color: #000000;"><span
style="font-family: Courier New;"> Directory: C:Documents and Settingscody.bunchDesktopVMware-VirtualCenter-support-2009-01-25@19-07-49viclient-s<br
/> upport </span></span></p><p><span
style="color: #000000;"><span
style="font-family: Courier New;">Mode                LastWriteTime     Length Name<br
/> &#8212;-                &#8212;&#8212;&#8212;&#8212;-     &#8212;&#8212; &#8212;-<br
/> -a&#8212;         1/12/2009   9:15 PM      73010 viclient-0.log<br
/> -a&#8212;         1/18/2009   9:50 AM      43329 viclient-1.log<br
/> -a&#8212;         1/18/2009  10:49 AM     295807 viclient-2.log<br
/> -a&#8212;         1/18/2009  12:22 PM      63804 viclient-3.log<br
/> -a&#8212;         1/18/2009   9:29 PM      46094 viclient-4.log<br
/> -a&#8212;         1/19/2009   8:28 AM     106489 viclient-5.log<br
/> -a&#8212;         1/20/2009   1:30 PM      63542 viclient-6.log<br
/> -a&#8212;         1/20/2009   4:03 PM        133 viclient-7.log<br
/> -a&#8212;         1/25/2009   7:07 PM     142524 viclient-8.log<br
/> -a&#8212;          1/9/2009   8:17 PM     169476 viclient-9.log<br
/> -a&#8212;         1/25/2009   1:43 PM        235 viclient-index.xml</span></span></p><p><span
style="color: #000000;">Cool. Good to know but for the moment we’re after the Virtual Center logs, hidden in that zip file. Go ahead and extract that out, it’ll give you something like this:</span></p><p><span
style="color: #000000;"><span
style="font-family: Courier New;">PS C:Documents and Settingscody.bunchDesktopVMware-VirtualCenter-support-2009-01-25@19-07-49vcsupport-1-25-2009-19-<br
/> 4&gt; dir </span></span></p><p><span
style="color: #000000;"><span
style="font-family: Courier New;"> Directory: C:Documents and Settingscody.bunchDesktopVMware-VirtualCenter-support-2009-01-25@19-07-49vcsupport-<br
/> 1-25-2009-19-4 </span></span></p><p><span
style="color: #000000;"><span
style="font-family: Courier New;">Mode                LastWriteTime     Length Name<br
/> &#8212;-                &#8212;&#8212;&#8212;&#8212;-     &#8212;&#8212; &#8212;-<br
/> d&#8212;-         1/25/2009   7:09 PM            Config<br
/> d&#8212;-         1/25/2009   7:09 PM            DrmDumps<br
/> d&#8212;-         1/25/2009   7:08 PM            Logs<br
/> -a&#8212;         1/25/2009   7:09 PM       4003 tree-vc-support.txt<br
/> -a&#8212;         1/25/2009   7:04 PM         12 vc-support-ver.txt<br
/> -a&#8212;         1/25/2009   7:09 PM       9656 vc-support.log</span></span></p><p><span
style="color: #000000;">Config, DMP Dumps, and Logs. Looks like we’ve found the meat of this search. In the log’s folder you’ll find a *.csv and *.evt of the event logs on the system at the time this dump as taken. More importantly tho, you’ll also find the vpxd folder… these are the logs we’re after!</span></p><p><span
style="color: #000000;"><span
style="font-family: Courier New;">PS C:Documents and Settingscody.bunchDesktopVMware-VirtualCenter-support-2009-01-25@19-07-49vcsupport-1-25-2009-19-<br
/> 4Logsvpxd&gt; dir </span></span></p><p><span
style="color: #000000;"><span
style="font-family: Courier New;"> Directory: C:Documents and Settingscody.bunchDesktopVMware-VirtualCenter-support-2009-01-25@19-07-49vcsupport-<br
/> 1-25-2009-19-4Logsvpxd </span></span></p><p><span
style="color: #000000;"><span
style="font-family: Courier New;">Mode                LastWriteTime     Length Name<br
/> &#8212;-                &#8212;&#8212;&#8212;&#8212;-     &#8212;&#8212; &#8212;-<br
/> -a&#8212;         1/25/2009   7:04 PM    9437340 profiler-0.log<br
/> -a&#8212;         1/25/2009   6:05 AM  209715224 profiler-1.log<br
/> -a&#8212;         1/24/2009  11:40 AM  209715224 scoreboard-0.log<br
/> -a&#8212;         1/25/2009   7:05 PM   26585551 scoreboard-1.log<br
/> -a&#8212;         1/23/2009   7:33 AM    5242904 vpxd-0.log<br
/> -a&#8212;         1/25/2009   7:05 AM    5242904 vpxd-1.log<br
/> -a&#8212;         1/25/2009   7:04 PM    1719036 vpxd-2.log<br
/> -a&#8212;          1/9/2009   3:44 PM    5242904 vpxd-3.log<br
/> -a&#8212;         1/11/2009   1:50 PM    5242904 vpxd-4.log<br
/> -a&#8212;         1/13/2009  12:22 PM    5242904 vpxd-5.log<br
/> -a&#8212;         1/15/2009  12:35 PM    5242904 vpxd-6.log<br
/> -a&#8212;         1/17/2009  12:41 PM    5242904 vpxd-7.log<br
/> -a&#8212;         1/19/2009   8:48 AM    5242904 vpxd-8.log<br
/> -a&#8212;         1/21/2009   7:51 AM    5242904 vpxd-9.log</span></span></p><p><span
style="color: #000000;">On these I believe they count from 0 to 9, 9 being the oldest, 0 being the most recent, but the dates on these files seem to disagree with me…</span></p><p><span
style="color: #000000;">These logs, can also be grabbed using the VI Toolkit for windows like this:</span></p><p><span
style="color: #000000;"><span
style="font-family: Courier New;">PS C:&gt; get-log –bundle</span></span></p><p><span
style="color: #000000;">That’s it! Next time we’ll go over reading these a bit.</span></p> ]]></content:encoded> <wfw:commentRss>http://professionalvmware.com/2009/01/log-bundles-of-the-virtual-center-variety/feed/</wfw:commentRss> <slash:comments>9</slash:comments> </item> </channel> </rss>
