<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:clearspace="http://www.jivesoftware.com/xmlns/clearspace/rss" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:opensearch="http://a9.com/-/spec/opensearch/1.1/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>VMware Communities : Document List - Sample Code</title>
    <link>http://communities.vmware.com/community/developer/codecentral?view=documents</link>
    <description>Latest Documents in Sample Code</description>
    <language>en</language>
    <pubDate>Wed, 25 Nov 2009 17:38:14 GMT</pubDate>
    <generator>Clearspace 1.10.12 (http://jivesoftware.com/products/clearspace/)</generator>
    <dc:date>2009-11-25T17:38:14Z</dc:date>
    <dc:language>en</dc:language>
    <item>
      <title>hostOperations.pl</title>
      <link>http://communities.vmware.com/docs/DOC-11435</link>
      <description>This script allows you to perform the following host operations &lt;b&gt;enter_maintenance_mode&lt;/b&gt; and &lt;b&gt;exit_maintenance_mode&lt;/b&gt; across set of ESX(i) hosts being managed by vCenter.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt;&lt;br /&gt;
vCenter 2.5 or vCenter 4.0&lt;br /&gt;
ESX(i) hosts 3.5 or 4.0&lt;br /&gt;
vCLI 4.0 or vMA 4.0&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Operations:&lt;/b&gt;&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;enter_maintenance_mode&lt;/li&gt;
&lt;li&gt;exit_maintenance_mode&lt;/li&gt;
&lt;/ul&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
Create a file with list of hosts you want to perform certain operation on&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ]$ cat hosts
everest.primp-industries.com
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
Enter maintenance mode (will vMotion off any powered on/off VMs to other available host if DRS is enabled with additional hosts):&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;
[vi-admin@scofield ]$ ./hostOperations.pl --server reflex.primp-industries.com --hostfile hosts --operation ent_maint
Entering maintenance mode for host: &amp;quot;everest.primp-industries.com&amp;quot; and evacauating any VMs if host is part of DRS Cluster ...
        Successfully entered maintenance mode for host: &amp;quot;everest.primp-industries.com&amp;quot;!
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
Exit maintenance mode:&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ]$ ./hostOperations.pl --server reflex.primp-industries.com --hostfile hosts --operation exi_maint
Exiting maintenance mode for host: &amp;quot;everest.primp-industries.com&amp;quot; ...
        Successfully exited maintenance mode for host: &amp;quot;everest.primp-industries.com&amp;quot;!
&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">maintenance_mode</category>
      <pubDate>Wed, 25 Nov 2009 17:32:35 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-11435</guid>
      <dc:date>2009-11-25T17:32:35Z</dc:date>
      <clearspace:dateToText>1 day, 1 hour ago</clearspace:dateToText>
    </item>
    <item>
      <title>configureAdvHAClusterOptions.pl</title>
      <link>http://communities.vmware.com/docs/DOC-11221</link>
      <description>This scripts allows you to configure advanced HA Cluster options such as some of the ones described on Duncan's &lt;a class="jive-link-external" href="http://www.yellow-bricks.com/vmware-high-availability-deepdiv/"&gt;HA Deep Dive page&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
The script accepts the name of a HA Cluster and a file that contains the advanced keys and values that you would like to update/overwrite. Make sure the format of each line is the following:&lt;br /&gt;
&lt;br /&gt;
&lt;div class="jive-quote"&gt;
key="value"&lt;br /&gt;
&lt;/div&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt;&lt;br /&gt;
vCenter 2.5 or 4.0&lt;br /&gt;
vSphere SDK for Perl or vMA 4.0&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
Here is a sample file containing 2 advanced options to configure:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ]$ cat ha_configs

das.allownetwork0=&amp;quot;Service Console&amp;quot;
das.failuredetectiontime=&amp;quot;20000&amp;quot;
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
Here is the actual execution:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ]$ ./configureAdvHAClusterOptions.pl --server reflex.primp-industries.com --cluster PRIMP-PROD --file ha_configs

Reconfiguring cluster: &amp;quot;PRIMP-PROD&amp;quot; with the following HA advanced configurations ...
        das.failuredetectiontime =&amp;gt; 20000
        das.allownetwork0 =&amp;gt; Service Console

Successfully added advanced HA configurations to cluster: &amp;quot;PRIMP-PROD&amp;quot;

&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">ha_adv_options</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">ha_advanced_options</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">advanced_options</category>
      <pubDate>Wed, 11 Nov 2009 20:44:10 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-11221</guid>
      <dc:date>2009-11-11T20:44:10Z</dc:date>
      <clearspace:dateToText>2 weeks, 22 hours ago</clearspace:dateToText>
    </item>
    <item>
      <title>vmdkManagement.pl</title>
      <link>http://communities.vmware.com/docs/DOC-11213</link>
      <description>This script allows a user to add, remove and destroy existing VMDK for a given VM. &lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt;&lt;br /&gt;
ESX(i) 3.5 or 4.0 or vCenter 2.5 or 4.0&lt;br /&gt;
vSphere SDK for Perl or vMA 4.0&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Operations&lt;/b&gt;&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;Add&lt;/li&gt;
&lt;li&gt;Remove&lt;/li&gt;
&lt;li&gt;Destroy&lt;/li&gt;
&lt;/ul&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
Add Operation&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./vmdkManagement.pl --server reflex.primp-industries.com --operation add --vmdkname vMA-2_1.vmdk --vmname vMA-2 --datastore himalaya-local-SAS.Constellation

Reconfiguring &amp;quot;vMA-2&amp;quot; to add VMDK: &amp;quot;[http://himalaya-local-SAS.Constellation|http://himalaya-local-SAS.Constellation] vMA-2/vMA-2_1.vmdk&amp;quot; ...
Sucessfully added VMDK to &amp;quot;vMA-2&amp;quot;!

&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;p /&gt;
Remove Operation&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./vmdkManagement.pl --server reflex.primp-industries.com --operation remove --vmdkname vMA-2_1.vmdk --vmname vMA-2

Reconfiguring &amp;quot;vMA-2&amp;quot; to remove VMDK: &amp;quot;vMA-2_1.vmdk&amp;quot; ...
Sucessfully removed VMDK to &amp;quot;vMA-2&amp;quot;!

&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;p /&gt;
Destroy Operation&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]]$ ./vmdkManagement.pl --server reflex.primp-industries.com --operation destroy --vmdkname vMA-2_1.vmdk --vmname vMA-2

Reconfiguring &amp;quot;vMA-2&amp;quot; to destroy VMDK: &amp;quot;vMA-2_1.vmdk&amp;quot; ...
Sucessfully destroyed VMDK to &amp;quot;vMA-2&amp;quot;!
&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">delete_vmdk</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">remove_vmdk</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">add_disk</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">add_vmdk</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <pubDate>Wed, 11 Nov 2009 04:48:47 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-11213</guid>
      <dc:date>2009-11-11T04:48:47Z</dc:date>
      <clearspace:dateToText>1 week, 6 days ago</clearspace:dateToText>
      <clearspace:replyCount>9</clearspace:replyCount>
    </item>
    <item>
      <title>findVMsWithRDMs.pl</title>
      <link>http://communities.vmware.com/docs/DOC-11135</link>
      <description>This script locates VMs with RDMs (Virtual and Physical) and provides a list of the VM name, device name, filename and compatibility mode. The script can be pointed to either an individual ESX(i) or vCenter server.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt;&lt;br /&gt;
ESX(i) 3.5 or 4.0 or vCenter 2.5 or 4.0&lt;br /&gt;
vSphere SDK for Perl or VI Perl Toolkit or vMA 4.0 or VIMA 1.0&lt;br /&gt;
VMs w/RDMs&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
Executing against a vCenter server:&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./findVMsWithRDMs.pl --server ucsb-resnet-vcenter --username primp
Enter password:

iscsiBridge.12162008
        DeviceName: vmhba1:0:211:0
        FileName: [http://dlgCore-FC-LUN203.VMstorage3|http://dlgCore-FC-LUN203.VMstorage3] iscsiBridge.12162008/iscsiBridge.12162008_2.vmdk
        CompatMode: physicalMode

&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">rdm</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">find_rdm</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">physical_rdm</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">virtual_rdm</category>
      <pubDate>Tue, 03 Nov 2009 05:56:04 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-11135</guid>
      <dc:date>2009-11-03T05:56:04Z</dc:date>
      <clearspace:dateToText>3 weeks, 2 days ago</clearspace:dateToText>
    </item>
    <item>
      <title>listHAClusterNodes.pl</title>
      <link>http://communities.vmware.com/docs/DOC-11054</link>
      <description>Motivated by &lt;a class="jive-link-profile" href="http://communities.vmware.com/people/c_shanklin"&gt;c_shanklin&lt;/a&gt; twitter message about &lt;a class="jive-link-external" href="http://www.hypervisor.fr/?p=1320"&gt;http://www.hypervisor.fr/?p=1320&lt;/a&gt; this morning about listing primary HA nodes within vCenter cluster using PowerCLI, I thought I provide an equivalent snippet of vSphere SDK for Perl script. In additional to listing the primary nodes, I'm also outputting the configuration and run state of each node in the cluster.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;&lt;span style="color:red"&gt;Unfortunately, the vSphere API does not provide information about the secondary nodes&lt;/span&gt;&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt;&lt;br /&gt;
vCenter 4.0&lt;br /&gt;
vSphere SDK for Perl or vMA 4.0&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Operations:&lt;/b&gt;&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;Specific cluster (user --cluster)&lt;/li&gt;
&lt;li&gt;All cluster (default)&lt;/li&gt;
&lt;/ul&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
Specific cluster:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;./listHAClusterNodes.pl --server reflex.primp-industries.com --cluster 'R&amp;#38;D'
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;p /&gt;
&lt;img src="http://communities.vmware.com/servlet/JiveServlet/downloadImage/102-11054-2-7410/Picture+1.png" alt="Picture 1.png" width="620" class="jive-image-thumbnail jive-image" onclick="myJiveImage.start(this, 'http://communities.vmware.com/servlet/JiveServlet/downloadImage/102-11054-2-7410/Picture+1.png');return false;"/&gt; &lt;br /&gt;
&lt;br /&gt;
All cluster:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;./listHAClusterNodes.pl --server reflex.primp-industries.com
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;p /&gt;
&lt;img src="http://communities.vmware.com/servlet/JiveServlet/downloadImage/102-11054-2-7444/Picture+2.png" alt="Picture 2.png" width="620" class="jive-image-thumbnail jive-image" onclick="myJiveImage.start(this, 'http://communities.vmware.com/servlet/JiveServlet/downloadImage/102-11054-2-7444/Picture+2.png');return false;"/&gt; &lt;br /&gt;
&lt;br /&gt;
Your output should be much more defined ... my development environment is under construction still &lt;img class="jive-emoticon" border="0" src="http://communities.vmware.com/images/emoticons/wink.gif" alt=";)" /&gt; hence the uninitialized and error messages</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">ha_cluster_node</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">ha_node</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">primary_node</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">ha</category>
      <pubDate>Wed, 28 Oct 2009 17:34:42 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-11054</guid>
      <dc:date>2009-10-28T17:34:42Z</dc:date>
      <clearspace:dateToText>4 weeks, 1 day ago</clearspace:dateToText>
      <clearspace:replyCount>1</clearspace:replyCount>
    </item>
    <item>
      <title>vmISOManagement.pl</title>
      <link>http://communities.vmware.com/docs/DOC-11003</link>
      <description>This script allows you to &lt;b&gt;mount&lt;/b&gt; and &lt;b&gt;unmount&lt;/b&gt; ISO's that are visible to your ESX(i) servers to a particular VM. &lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt;&lt;br /&gt;
ESX(i) 4.0 or vCenter 4.0&lt;br /&gt;
vSphere SDK for Perl or vMA 4.0&lt;br /&gt;
VM(s) that have a valid cdrom device&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Operations:&lt;/b&gt;&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;queryiso&lt;/li&gt;
&lt;li&gt;mount&lt;/li&gt;
&lt;li&gt;umount&lt;/li&gt;
&lt;/ul&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
The &lt;b&gt;queryiso&lt;/b&gt; operation allows you to search an ESX(i) host that the VM you're trying to perform the operation to locate valid ISO's and provide the user with the necessary input information to &lt;b&gt;mount&lt;/b&gt; operation.&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~][http://reflex.primp-industries.com|http://reflex.primp-industries.com]$ ./vmISOManagement.pl --server reflex.primp-industries.com --vmname VCAP --operation queryiso

Datatstore Name &amp;#38; ISO Path:
-----------------------------------------------------------------
\[dlgCore-NFS-bigboi.VM-Backups\] archlinux-2009.02-core-i686.iso
\[himalaya-local-SATA.RE4-GP:Storage\] OSISO/ubuntu-9.04-server-i386.iso
\[himalaya-local-SATA.RE4-GP:Storage\] OSISO/client-10.53_sp41183.iso
\[himalaya-local-SATA.RE4-GP:Storage\] OSISO/gparted-livecd-0.3.4-11.iso
\[himalaya-local-SATA.RE4-GP:Storage\] OSISO/Archlinux-i686-2007.08-2.core.iso
\[himalaya-local-SATA.RE4-GP:Storage\] OSISO/echos-SWAK2004.iso
\[himalaya-local-SATA.RE4-GP:Storage\] OSISO/win2k3adv.iso
\[himalaya-local-SATA.RE4-GP:Storage\] OSISO/esx-kickstart.iso
\[himalaya-local-SATA.RE4-GP:Storage\] OSISO/ServerHyper_MUIx2-080912.iso
\[himalaya-local-SATA.RE4-GP:Storage\] OSISO/esx-DVD-4.0.0-164009.iso
\[himalaya-local-SATA.RE4-GP:Storage\] OSISO/ubuntu-9.04-server-amd64.iso
\[himalaya-local-SATA.RE4-GP:Storage\] OSISO/Memtest86_3.5.iso
\[himalaya-local-SATA.RE4-GP:Storage\] OSISO/VMware-VMvisor-Installer-4.0.0-171294.x86_64.iso
\[himalaya-local-SATA.RE4-GP:Storage\] OSISO/VMware-VMvisor-InstallerCD-3.5.0_Update_4-153875.i386.iso
\[himalaya-local-SATA.RE4-GP:Storage\] OSISO/OpenBSD/cdemu39.iso
\[himalaya-local-SATA.RE4-GP:Storage\] OSISO/OpenBSD/cd39.iso
\[himalaya-local-SATA.RE4-GP:Storage\] OSISO/VMware-ISOs/VMware-VMvisor-Installer-4.0.0-171294.x86_64.iso
\[himalaya-local-SATA.RE4-GP:Storage\] OSISO/VMware-ISOs/VMware-VMvisor-InstallerCD-3.5.0_Update_4-153875.i386.iso
\[himalaya-local-SATA.RE4-GP:Storage\] OSISO/VMware-ISOs/VMware-VIMSetup-all-4.0.0-162902.iso

&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
This will provide you with both the &lt;b&gt;--datastore&lt;/b&gt; name and the &lt;b&gt;--filename&lt;/b&gt; path to the ISO that is required when using &lt;b&gt;mount&lt;/b&gt; operation.&lt;br /&gt;
&lt;br /&gt;
Let's say we want to mount &lt;b&gt;[himalaya-local-SATA.RE4-GP:Storage] OSISO/VMware-ISOs/VMware-VMvisor-Installer-4.0.0-171294.x86_64.iso&lt;/b&gt; to a VM called &lt;u&gt;VCAP&lt;/u&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~][http://reflex.primp-industries.com|http://reflex.primp-industries.com]$ ./vmISOManagement.pl --server reflex.primp-industries.com --vmname VCAP --operation mount --datastore himalaya-local-SATA.RE4-GP:Storage --filename OSISO/VMware-ISOs/VMware-VMvisor-Installer-4.0.0-171294.x86_64.iso

Mounting ISO: &amp;quot;[himalaya-local-SATA.RE4-GP:Storage] OSISO/VMware-ISOs/VMware-VMvisor-Installer-4.0.0-171294.x86_64.iso&amp;quot; to VM: &amp;quot;VCAP&amp;quot; ...
        Successfully added mounted ISO to VM!
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
Let's now unmount the ISO &lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~][http://reflex.primp-industries.com|http://reflex.primp-industries.com]$ ./vmISOManagement.pl --server reflex.primp-industries.com --vmname VCAP --operation umount

Umounting ISO from VM: &amp;quot;VCAP&amp;quot; ...
        Successfully unmounted ISO from VM!

&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">mounting</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">iso</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">unmounting</category>
      <pubDate>Tue, 27 Oct 2009 18:55:26 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-11003</guid>
      <dc:date>2009-10-27T18:55:26Z</dc:date>
      <clearspace:dateToText>1 month, 13 minutes ago</clearspace:dateToText>
    </item>
    <item>
      <title>upgradeVMVirtualHardware.pl</title>
      <link>http://communities.vmware.com/docs/DOC-11000</link>
      <description>Script to upgrade either a list of VMs to Virtual HW 7 &lt;b&gt;OR&lt;/b&gt; all VMs on either ESX(i) or vCenter system. Prior to upgrading, the script will validate that the VM is poweredOff and the version of Virtual HW is not already configured on the VM. Also ensure that your VMs have the latest version of VMware Tools installed as there are changes to the vNIC when going from HW4 to HW7 which you'll get a question prompted if you don't have tools installed. &lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt;&lt;br /&gt;
ESX(i) 4.0 or vCenter 4.0&lt;br /&gt;
vSphere SDK for Perl or vMA 4.0&lt;br /&gt;
VM(s) running Virtual HW Ver 4 and VMware Tools installed &amp;#38; are poweredOff prior to upgrade&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~][http://reflex.primp-industries.com|http://reflex.primp-industries.com]$ ./upgradeVMVirtualHardware.pl --server reflex.primp-industries.com --upgrade_type list --vmfile upgrade_list --hwversion 7

Upgrading VM: &amp;quot;hw-version-4-vm&amp;quot; Virtual HW from: 4 to 7
        Successfully upgraded Virtual HW for hw-version-4-vm
VM: &amp;quot;hw-version-7-vm&amp;quot; is already running Virtual HW version: 7

&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
To upgrade all VMs, use &lt;b&gt;--upgrade_type&lt;/b&gt; all and you don't &lt;b&gt;--vmfile&lt;/b&gt; param</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">virtual_hardware</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">hw7</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">hw4</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">upgrade_hardware</category>
      <pubDate>Mon, 26 Oct 2009 19:16:34 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-11000</guid>
      <dc:date>2009-10-26T19:16:34Z</dc:date>
      <clearspace:dateToText>1 month, 1 day ago</clearspace:dateToText>
    </item>
    <item>
      <title>rdmManagmement.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10974</link>
      <description>This scripts allows you to create and add either physical or virtual RDM to a VM and also removing and deleting pRDM/vRDM to a VM. You must connect directly to the ESX(i) host that is housing the VM in which the RDM is to be added. &lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt;&lt;br /&gt;
ESX(i) 3.5/4.0&lt;br /&gt;
vSphere SDK for Perl or vMA&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
Querying for available LUNS to be used as an RDM ( &lt;b&gt;operation:&lt;/b&gt; query):&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./rdmManagmement.pl --server esx40-1.primp-industries.com --username root --vmname rdmVM --operation query
Enter password:
Device Name: /vmfs/devices/disks/eui.caa68a778fc27982
Capacity: 30.00 GB

Device Name: /vmfs/devices/disks/eui.1f79d354801b3936
Capacity: 1000.00 MB

Device Name: /vmfs/devices/disks/eui.8f713e8e3c0a58d2
Capacity: 1.95 GB

Device Name: /vmfs/devices/disks/eui.c028c79e0ee07daa
Capacity: 28.00 GB

&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
Let's create an physical RDM using &lt;b&gt;1.95gb&lt;/b&gt; LUN ( &lt;b&gt;operation:&lt;/b&gt; add ):&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./rdmManagmement.pl --server esx40-1.primp-industries.com --username root --vmname rdmVM --operation add --device /vmfs/devices/disks/eui.8f713e8e3c0a58d2 --compatmode physical --filename databaseRDM.vmdk
Enter password:
Creating and adding &amp;quot;physicalMode&amp;quot; RDM: &amp;quot;databaseRDM.vmdk&amp;quot; to rdmVM ...
        Successfully added RDM to VM!

&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
Let's remove and delete the RDM from the VM ( &lt;b&gt;operation:&lt;/b&gt; destroy ):&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./rdmManagmement.pl --server esx40-1.primp-industries.com --username root --vmname rdmVM --operation destroy --filename databaseRDM.vmdk
Enter password:
Destroying RDM: &amp;quot;databaseRDM.vmdk&amp;quot; to rdmVM ...
        Successfully destroyed RDM to VM!

&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">rdm</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">physical_rdm</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">virtual_rdm</category>
      <pubDate>Thu, 22 Oct 2009 03:50:03 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10974</guid>
      <dc:date>2009-10-22T03:50:03Z</dc:date>
      <clearspace:dateToText>1 month, 5 days ago</clearspace:dateToText>
      <clearspace:replyCount>2</clearspace:replyCount>
    </item>
    <item>
      <title>VITree - Display vCenter like Datacenter/folder tree and search all VMs in a folder</title>
      <link>http://communities.vmware.com/docs/DOC-10891</link>
      <description>The attached Visual Basic 2008 solution is an example of how to use RetrieveProperties to p ull information from vCenter and populate a treeview with the results. Once populated, you can click on any folder and have the VMs in that folder populated into a grid with boottime displayed.&lt;br /&gt;
&lt;br /&gt;
This project includes a VI.vb module that can easily be reused in other projects. It also includes partially optimized VimApi DLL files and a login form.&lt;br /&gt;
&lt;br /&gt;
Known Issues:&lt;br /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;ul&gt;
&lt;li&gt;If more than one Datacenter is present in vCenter, it will throw an exception that is trapped and continue working with only the single datacenter displayed.&lt;/li&gt;
&lt;/ul&gt;
&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;If you click on anything other than a folder (datacenter for example) it will throw an error and not display the VMs&lt;/li&gt;
&lt;/ul&gt;
&lt;br /&gt;
Screenshot of the populated project below:&lt;br /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;br /&gt;
&lt;img src="http://communities.vmware.com/servlet/JiveServlet/downloadImage/7295/VITree.PNG" alt="http://communities.vmware.com/servlet/JiveServlet/downloadImage/7295/VITree.PNG" class="jive-image"  /&gt;&lt;br /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;p /&gt;
If you want to turn it back on so that it shows VMs in the tree, you will need to:&lt;br /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;ul&gt;
&lt;li&gt;Uncomment Lines 188-191 in VI.vb  (Create VM Property Spec)&lt;/li&gt;
&lt;li&gt;Uncomment Line 211 (setting propSet that includes the VMpSpec)&lt;/li&gt;
&lt;li&gt;Comment out Line 212 (setting propSet that Does NOT include the VMpSpec)&lt;/li&gt;
&lt;/ul&gt;
&lt;p /&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3125">vb.net</category>
      <category domain="http://communities.vmware.com/tags?communityID=3125">general</category>
      <category domain="http://communities.vmware.com/tags?communityID=3125">retrieving</category>
      <category domain="http://communities.vmware.com/tags?communityID=3125">information</category>
      <pubDate>Tue, 13 Oct 2009 18:55:18 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10891</guid>
      <dc:date>2009-10-13T18:55:18Z</dc:date>
      <clearspace:dateToText>1 month, 1 week ago</clearspace:dateToText>
    </item>
    <item>
      <title>getVMDiskInfo.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10885</link>
      <description>This scripts functions similar to that of PowerCLI equivalent at: &lt;a class="jive-link-external" href="http://ict-freak.nl/2009/10/11/powercli-virtual-machine-disk-vmdk-info-v2-analyze-data-with-excel/"&gt;http://ict-freak.nl/2009/10/11/powercli-virtual-machine-disk-vmdk-info-v2-analyze-data-with-excel/&lt;/a&gt; which extracts all VMDK(s) for a given VM and displays the full VMDK path, whether or not the disk was thin provisioned or not and disk mode. There is an additional argument that can be passed on the commandline which will filter &lt;u&gt;only&lt;/u&gt; thin provisioned VM(s) and the script can be executed against ESX(i) or vCenter system.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;&lt;span style="color:blue"&gt;Update:&lt;/b&gt; Added Disk backing version info as found &lt;a class="jive-link-external" href="http://www.vmware.com/support/developer/vc-sdk/visdk400pubs/ReferenceGuide/vim.vm.device.VirtualDevice.FileBackingInfo.html"&gt;here&lt;/a&gt;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt;&lt;br /&gt;
ESX(i) 3.5/4.0&lt;br /&gt;
vCenter 2.5/4.0&lt;br /&gt;
vSphere SDK for Perl or vMA&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
Display all VM(s):&lt;br /&gt;
&lt;img src="http://communities.vmware.com/servlet/JiveServlet/downloadImage/102-10885-2-7278/show_all.png" alt="show_all.png" width="620" class="jive-image-thumbnail jive-image" onclick="myJiveImage.start(this, 'http://communities.vmware.com/servlet/JiveServlet/downloadImage/102-10885-2-7278/show_all.png');return false;"/&gt; &lt;br /&gt;
&lt;br /&gt;
Display all VM(s) with thin provisioned disks only:&lt;br /&gt;
&lt;img src="http://communities.vmware.com/servlet/JiveServlet/downloadImage/102-10885-2-7282/show_thin.png" alt="show_thin.png" width="620" class="jive-image-thumbnail jive-image" onclick="myJiveImage.start(this, 'http://communities.vmware.com/servlet/JiveServlet/downloadImage/102-10885-2-7282/show_thin.png');return false;"/&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">thin</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">thin_provisioned</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">thin_provisioning</category>
      <pubDate>Mon, 12 Oct 2009 04:10:35 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10885</guid>
      <dc:date>2009-10-12T04:10:35Z</dc:date>
      <clearspace:dateToText>3 weeks, 6 days ago</clearspace:dateToText>
    </item>
    <item>
      <title>useVIFastpassOnvMAToRunPerlScriptWithoutClearTextPassword.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10883</link>
      <description>This script makes use of the &lt;b&gt;vi-fastpass&lt;/b&gt; library that is included in VMware vMA and allows you to execute a vSphere SDK for Perl or vCLI script without having to pass in credentials to each host upon execution. This script also does not require you to specify a &lt;b&gt;.viperl&lt;/b&gt; configuration file containing the username/password nor relies on issuing of &lt;b&gt;vifpinit&lt;/b&gt; on a target which has a &lt;b&gt;&lt;u&gt;&lt;span style="color:red"&gt;huge security flaw&lt;/span&gt;&lt;/u&gt;&lt;/b&gt; in which the username/password is stored in &lt;b&gt;plain text&lt;/b&gt; using environmental variables!!! I've been told this has been finally recognized as a bug/security issue and will be fixed in the near future.&lt;br /&gt;
&lt;br /&gt;
This script does &lt;b&gt;&lt;u&gt;require&lt;/u&gt;&lt;/b&gt; that the targets are being managed by vMA that you would like to perform the operations on. Please refer to &lt;a class="jive-link-external" href="http://www.vmware.com/support/developer/vima/index.html"&gt;vMA documentation&lt;/a&gt; on how to setup targets to be managed by vMA. &lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt;&lt;br /&gt;
VIMA 1.0 or vMA 4.0&lt;br /&gt;
ESX(i) 3.5/4.0 or vCenter 2.5/4.0&lt;br /&gt;
vSphere SDK for Perl/vCLI script&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
Let's say I would like to list all NFS datastores on a set of ESX(i) hosts, you would generally do something of the following using vCLI command &lt;b&gt;esxcfg-nas&lt;/b&gt;:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ esxcfg-nas -l --server esxi40-1.primp-industries.com --username root
Enter password:
dlgCore-NFS-bigboi.VM-Backups is /exports/vm-backups from A.B.C.D mounted
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;p /&gt;
and you would continue doing this for however many hosts you had, typing the password each time....&lt;br /&gt;
&lt;br /&gt;
Now, let's see this script in action which only requires one argument which is a file containing the hosts that you want to perform the operation.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Note&lt;/b&gt;: Please make sure the name of the hosts is exactly the name in which it was added to vMA management system&lt;br /&gt;
&lt;br /&gt;
My hostlist file:&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ cat hostlist
esx40-1.primp-industries.com
esx40-2.primp-industries.com
esxi40-1.primp-industries.com
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
You'll need to edit the script to substitute the command you would like to run, look at line #44:&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;$command_to_execute = `esxcfg-nas -l --server $server --username $username --password $password`
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
Ensure when you're editing the script to preserve $server,$username and $password arguments along with the other params to the script&lt;br /&gt;
&lt;p /&gt;
Now let's run the script on the 3 hosts:&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./useVIFastpassOnvMAToRunPerlScriptWithoutClearTextPassword.pl --esxlist hostlist
Executing script on &amp;quot;esx40-1.primp-industries.com&amp;quot; ...
dlgCore-NFS-bigboi.VM-Backups is /exports/vm-backups from A.B.C.D mounted

Executing script on &amp;quot;esx40-2.primp-industries.com&amp;quot; ...
dlgCore-NFS-bigboi.VM-Backups is /exports/vm-backups from A.B.C.D mounted

Executing script on &amp;quot;esxi40-1.primp-industries.com&amp;quot; ...
dlgCore-NFS-bigboi.VM-Backups is /exports/vm-backups from A.B.C.D mounted
&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vifp</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vifpinit</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vi-faspass</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vma</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vma4</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vima</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vima1.0</category>
      <pubDate>Fri, 09 Oct 2009 03:56:37 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10883</guid>
      <dc:date>2009-10-09T03:56:37Z</dc:date>
      <clearspace:dateToText>1 month, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>setUserDatastorePermission.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10866</link>
      <description>This script will apply a permission which contains a &lt;b&gt;username&lt;/b&gt; and &lt;b&gt;role&lt;/b&gt; to a specific datastore. &lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt;&lt;br /&gt;
vCenter 4.0&lt;br /&gt;
ESX(i) 3.5 or 4.0&lt;br /&gt;
vSphere SDK for Perl or vMA 4.0&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Default roles in vCenter (you can use your own):&lt;/b&gt;&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;NoAccess
Anonymous
View
ReadOnly
Admin
VirtualMachinePowerUser
VirtualMachineUser
ResourcePoolAdministrator
VMwareConsolidatedBackupUser
DatastoreConsumer
NetworkConsumer
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;p /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;p /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./setUserDatastorePermission.pl --server reflex.primp-industries.com --username primp --datastore himalaya-iSCSI-starwind.esx-devCluster --user williamlam --rolename DatastoreConsumer
Searching for rolename: DatastoreConsumer...
Applying role: &amp;quot;DatastoreConsumer&amp;quot; to user: &amp;quot;williamlam&amp;quot; on datastore: &amp;quot;himalaya-iSCSI-starwind.esx-devCluster&amp;quot;
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;p /&gt;
&lt;br /&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">configuration</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">storage</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">datastore</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">permission</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">role</category>
      <pubDate>Thu, 08 Oct 2009 04:06:40 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10866</guid>
      <dc:date>2009-10-08T04:06:40Z</dc:date>
      <clearspace:dateToText>1 week, 1 hour ago</clearspace:dateToText>
      <clearspace:replyCount>2</clearspace:replyCount>
    </item>
    <item>
      <title>NTP, PowerShell, It's about time.</title>
      <link>http://communities.vmware.com/docs/DOC-10871</link>
      <description>&lt;br /&gt;
There's no doubt that time is critically important in a computing&lt;br /&gt;
environment. Given this sensitivity, and the recent recognition that we&lt;br /&gt;
had rogue hosts improperly configured, I decided to crank out a script&lt;br /&gt;
that would analyze our environment. I wanted to find whether the NTPD&lt;br /&gt;
service was running, what the NTP server configuration was, and provide&lt;br /&gt;
a report of this. Additionally I wanted to have the option (with&lt;br /&gt;
commenting) to automatically make corrections. &lt;br /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;br /&gt;
Always open to suggestions and improvements.  I hope this helps you in your environment. &lt;br /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;br /&gt;
###----------FULL SCRIPT----------------------#####&lt;br /&gt;
&lt;p /&gt;
&lt;br /&gt;
Connect-VIServer -Server server.domain.com     #Enter your vCenter Server&lt;br /&gt;
&lt;br /&gt;
$NtpServer = "10.10.10.10"   #Provide your default NTP Server. This will be used as default so entering a NTP server when prompted is not necessary&lt;br /&gt;
&lt;br /&gt;
$OldNtpServer = "10.10.10.11"         #Leave set as 127.127.1.0 as default unless you wish to change settings in your environment&lt;br /&gt;
&lt;br /&gt;
$DefaultNtpServer = "127.127.1.0"    #NTP Server Value that is set on a fresh ESX installation.&lt;br /&gt;
&lt;br /&gt;
#Location based on Date&lt;br /&gt;
$date = Get-Date -UFormat %Y%m%d&lt;br /&gt;
$ExportLocation = "C:\NTP-$date.csv"&lt;br /&gt;
&lt;br /&gt;
#Location where you would like report to be saved to.&lt;br /&gt;
#$ExportLocation = 'C:\NTPReport.csv'&lt;br /&gt;
&lt;br /&gt;
$NTPHosts&lt;br /&gt;
= Get-VMHost | Select-Object Name,@{Name="NTPServer";Expression={$_ |&lt;br /&gt;
Get-VMHostNtpServer}}, @{Name="NTPRunning";Expression={($_ |&lt;br /&gt;
Get-VMHostService | Where-Object {$_.key -eq "ntpd"}).Running}} |&lt;br /&gt;
Sort-Object -Property "NTPRunning", "NTPServer"&lt;br /&gt;
&lt;br /&gt;
$NTPHosts | Export-Csv $ExportLocation -NoTypeInformation&lt;br /&gt;
&amp;#38; $ExportLocation #Opens generated report file&lt;br /&gt;
&lt;br /&gt;
$Restart = Read-Host "Would you like to start NTPD services or change NTP configurations on hosts? (y/n)"&lt;br /&gt;
#$Restart = "y"  #Comment above line and uncomment this line if you wish to automatically restart services.&lt;br /&gt;
If ($Restart -eq "y"){&lt;br /&gt;
Import-Csv $ExportLocation | % {&lt;br /&gt;
$vmhost = $_.Name&lt;br /&gt;
&lt;br /&gt;
#Checks the NTP configuration against a value previously determined at the top of script.&lt;br /&gt;
If (($_.NTPServer -eq $OldNtpServer) -or ($_.NTPServer -eq $DefaultNtpServer)){&lt;br /&gt;
$NtpInput&lt;br /&gt;
= Read-Host "Some servers are configured with NTP set as $OldNtpServer&lt;br /&gt;
or $DefaultNtpServer and may need their NTP settings reconfigured.&lt;br /&gt;
Please enter NTP Server FQDN or IP address. &amp;lt;$NtpServer&amp;gt; is&lt;br /&gt;
default."&lt;br /&gt;
&lt;br /&gt;
If ($NtpInput -ne "") {&lt;br /&gt;
$NtpServer = $NtpInput&lt;br /&gt;
#Sets $NtpServer to the inputted value and does nothign if left blank.&lt;br /&gt;
This allows use of default when value is consistent in the environment.&lt;br /&gt;
}&lt;br /&gt;
Add-VMHostNtpServer -VMHost $vmhost -NtpServer $NtpServer | Where-Object {$_.NTPServer -eq $OldNtpServer}&lt;br /&gt;
Remove-VMHostNtpServer -VMHost $vmhost -NtpServer $OldNtpServer&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
#Now time to restart any NTPD services that are currently not running.&lt;br /&gt;
If ($_.NTPRunning -eq "False") {&lt;br /&gt;
Get-VmHostService -VMHost $vmhost | Where-Object {$_.key -eq "ntpd"} | Start-VMHostService&lt;br /&gt;
}&lt;br /&gt;
}&lt;br /&gt;
}&lt;br /&gt;
Write-Host "Process Complete"</description>
      <category domain="http://communities.vmware.com/tags?communityID=3077">powershell</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">script</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">ntp</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">maintenance</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">configuration</category>
      <pubDate>Tue, 06 Oct 2009 21:07:56 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10871</guid>
      <dc:date>2009-10-06T21:07:56Z</dc:date>
      <clearspace:dateToText>1 month, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>Configure Switching for ESX host based on .CSV</title>
      <link>http://communities.vmware.com/docs/DOC-10863</link>
      <description>A couple of weeks ago I was in need to configure several new ESX servers with multiple NICs, vSwitches, and VLANs. Since I'm not one to do the same thing over and over again I turned to scripting. To further complicate things I wanted to allow the same script to create vSwitches, configure vMotion switch, add port groups, and create NIC Teams all from a prepopulated .CSV file. I'm doing this primarily so that all configuration could be done before the server arrived and so that I could create "Switch Profiles" when I add new hosts to clusters.&lt;br /&gt;
&lt;br /&gt;
In the end I developed a script that reads from a .CSV file and then creates the desired switching. The first column tells the script what type of addition it is and the script processes the information for that object accordingly. I've noticed a few others have been posting recently about scripts on setting up portgroups, etc. and thought it was time to no longer keep this to myself (i.e. finally found the time to post). I too would like to also credit Hal Rottenburg's book &lt;a class="jive-link-external" href="http://www.amazon.com/Managing-VMware-Infrastructure-Windows-PowerShell/dp/0982131402"&gt;Managing VMware Infrastructure with Windows Powershell&lt;/a&gt; which was very helpful for this and many other scripting projects I will be posting soon. Mike Laverick's &lt;a class="jive-link-external" href="http://www.rtfm-ed.co.uk/?p=1514"&gt;post&lt;/a&gt; linked below helped in configuring the vMotion switch.&lt;br /&gt;
&lt;br /&gt;
I hope you find this helpful. It has been HUGE in my environment.&lt;br /&gt;
&lt;br /&gt;
Download the files here:&lt;br /&gt;
&lt;a class="jive-link-external" href="http://jatwell.no-ip.info/Main/download/scripts/ESX-ConfigureSwitchCSV-Generic.txt"&gt;ESX-ConfigureSwitchCSV-Generic.txt&lt;/a&gt;&lt;br /&gt;
&lt;a class="jive-link-external" href="http://jatwell.no-ip.info/Main/Download/Scripts/esx_switching-generic.csv"&gt;esx_switching_generic.csv&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
Links where others discuss switch configuration with PowerCLI.&lt;br /&gt;
&lt;a class="jive-link-external" href="http://halr9000.com/article/828"&gt;http://halr9000.com/article/828&lt;/a&gt;&lt;br /&gt;
&lt;a class="jive-link-external" href="http://www.holy-vm.com/2009/10/01/adding-port-groups-with-powercli/"&gt;http://www.holy-vm.com/2009/10/01/adding-port-groups-with-powercli/&lt;/a&gt;&lt;br /&gt;
&lt;a class="jive-link-external" href="http://www.rtfm-ed.co.uk/?p=1514"&gt;http://www.rtfm-ed.co.uk/?p=1514&lt;/a&gt;&lt;br /&gt;
&lt;p /&gt;
Text of Script w/out comments&lt;br /&gt;
&lt;br /&gt;
$getinfo = Import-Csv "\\server\share\file.csv"&lt;br /&gt;
Connect-VIServer -Server vCenterServer&lt;br /&gt;
&lt;br /&gt;
$getinfo | % {&lt;br /&gt;
$Type = $_.Type #!!!! Case Sensitive !!!!!!&lt;br /&gt;
$gethost = Get-VMHost -Name $_.HostName&lt;br /&gt;
$SwitchName = $_.SwitchName&lt;br /&gt;
$PortGroup = $_.PortGroupName&lt;br /&gt;
$Nic = $_.NIC&lt;br /&gt;
$VLAN = $_.VLAN&lt;br /&gt;
$IP = $_.IP&lt;br /&gt;
$Subnet = $_.Subnet&lt;br /&gt;
$kernelGW = $_.KernelGW&lt;br /&gt;
&lt;br /&gt;
If ($Type -eq "Switch") {&lt;br /&gt;
$gethost | New-VirtualSwitch -Name $SwitchName -Nic $Nic&lt;br /&gt;
}&lt;br /&gt;
If ($Type -ne "vMotion") {&lt;br /&gt;
$getswitch = Get-VirtualSwitch -VMHost $gethost -Name $SwitchName&lt;br /&gt;
}&lt;br /&gt;
If ($Type -eq "Team"){&lt;br /&gt;
$getswitch | Set-VirtualSwitch -Nic $Nic&lt;br /&gt;
}&lt;br /&gt;
IF ($Type -eq "Portgroup") {&lt;br /&gt;
$getswitch | New-VirtualPortGroup $PortGroup -VLanId $VLAN&lt;br /&gt;
}&lt;br /&gt;
IF ($Type -eq "vMotion") {&lt;br /&gt;
&lt;br /&gt;
$newvswitch = New-VirtualSwitch -VMHost $gethost -Name $SwitchName -Nic $Nic&lt;br /&gt;
$vmotion = New-VirtualPortGroup -VirtualSwitch $newvswitch -Name $PortGroup&lt;br /&gt;
New-VMHostNetworkAdapter -VMHost $gethost -PortGroup $PortGroup -VirtualSwitch $newvswitch -IP $IP -SubnetMask $subnet -VMotionEnabled: $true&lt;br /&gt;
&lt;br /&gt;
$vmhostnetwork = get-vmhostnetwork $gethost&lt;br /&gt;
set-vmhostnetwork -network $vmhostnetwork -vmkernelgateway $kernelGW&lt;br /&gt;
}&lt;br /&gt;
}</description>
      <category domain="http://communities.vmware.com/tags?communityID=3077">powershell</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">script</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">scripting</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">networking</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">vswitch</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">portgroups</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">csv</category>
      <pubDate>Tue, 06 Oct 2009 17:32:12 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10863</guid>
      <dc:date>2009-10-06T17:32:12Z</dc:date>
      <clearspace:dateToText>1 month, 3 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>Job-Rescan-ALL-HBA</title>
      <link>http://communities.vmware.com/docs/DOC-10855</link>
      <description>This program will rescan all the HBA's in your vm enviroment, and instead of doing it one at a time, it creates a seperate job for each ESX host. Thus multithreading the rescan. For ESX 3.5 this is really handy, for vsphere 4 you can have it do a rescan of all HBA's through the vi interface. But this will work against vsphere as well. &lt;br /&gt;
&lt;br /&gt;
I developed this script as I needed a quick way to rescan the HBA's when a failover of our HP EVA occurs. And I need the servers to rescan. I'll be working on another version which will suspend the vm's on a particular LUN, failover that particular LUN, rescan and then restart the vm.. As you can imagine this will be tricky and others have written it for other storage systems but not for HP EVA's.  &lt;br /&gt;
&lt;p /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;#Rescan all HBA's creating 1 job for each ESX server


# Kyle Weir, jkw117@gmail.com, 10-05-09

#connects initially to get the list of ESX servers 



Connect-VIServer  &amp;quot;vcenter&amp;quot; -User Administrator -Password password 



vm=get-vmhost



#Passes the server names individually to different jobs. Thus allowing it to ask each ESX host to rescan itself. 



for ($x=0 ; $x -le $vm.length; $x++)
{
Start-Job -ArgumentList $vm[$x|http://communities.vmware.com/community-document-picker.jspa?communityID=3077&amp;#38;subject=%24x].name -ScriptBlock {
Add-PSSnapin VMware.VimAutomation.Core
Connect-VIServer  &amp;quot;vcenter&amp;quot; -User Administrator -Password $pasd
get-vmhost $args| Get-VMHostStorage -RescanAllHBA -rescanVMFS -refresh
} 
} 


&lt;/code&gt;&lt;/pre&gt; &lt;br /&gt;
&lt;p /&gt;
Any questions please email me, I am sure this can be updated to eliminate</description>
      <category domain="http://communities.vmware.com/tags?communityID=3077">hba</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">powershell</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">storage</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">performance</category>
      <pubDate>Mon, 05 Oct 2009 14:57:13 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10855</guid>
      <dc:date>2009-10-05T14:57:13Z</dc:date>
      <clearspace:dateToText>1 month, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>pluginExtensionManager.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10847</link>
      <description>Script to retrieve the list of extensions installed on your vCenter server OR to unregister a specific plugin that has been installed.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt;&lt;br /&gt;
vCenter 2.5 or 4.0&lt;br /&gt;
vSphere SDK for Perl or vMA 4.0&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
List installed plugins against vCenter&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./pluginExtensionManager.pl --server reflex.primp-industries.com --username primp --operation list

------------------------------------------------------
Label: vCenter Hardware Status
Summary: Displays the hardware status of hosts (CIM monitoring)
Version: 4.0
Company: VMware, Inc.
Key: cim-ui
Server info:
        Admin Email: noreply@vmware.com -
        Company: VMware, Inc.
        Description:
        Type: com.vmware.vim.viClientScripts
        Url: https://reflex.primp-industries.com:8443/cim-ui/scriptConfig.xml


------------------------------------------------------
Label: vCenter Storage Monitoring
Summary: Storage Monitoring and Reporting
Version: 4.0
Company: VMware Inc.
Key: com.vmware.vim.sms

------------------------------------------------------
Label: report
Summary: report
Version: 1.0.0
Key: com.vmware.vim.stats.report
Server info:
        Company: VMware, Inc.
        Description:
        Type: HTTP
        Url: https://reflex.primp-industries.com:8443/statsreport/vicr.do


------------------------------------------------------
Label: vCenter Service Status
Summary: Displays the health status of vCenter services
Version: 4.0
Company: VMware, Inc.
Key: health-ui
Server info:
        Admin Email: noreply@vmware.com -
        Company: VMware, Inc.
        Description:
        Type: com.vmware.vim.viClientScripts
        Url: https://reflex.primp-industries.com:8443/health-ui/scriptConfig.xml


------------------------------------------------------
Label: hostdiag
Summary: hostdiag
Version: 1.0
Key: hostdiag

------------------------------------------------------
Label: VirtualCenter dynamic events and tasks
Summary: Extension for declaring dynamic events, tasks and faults from within the VirtualCenter server
Version: 1.0
Key: VirtualCenter

------------------------------------------------------
Label: com
Summary: com
Version: 4.0
Key: com.vmware.vSphereWebServicesSDK.primp-industries.com
Server info:
        Admin Email: william.lam@primp-industries.com -
        Company: primp-industries.com
        Description:
        Type: com.vmware.vim.viClientScripts
        Url: https://reflex.primp-industries.com/ui/plugin/primp.xml


&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
Remove specific plugin from vCenter (use operation 'list' to figure out the &lt;b&gt;key&lt;/b&gt; for plugin):&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]]$ ./pluginExtensionManager.pl --server reflex.primp-industries.com --username primp --operation remove --key com.vmware.vSphereWebServicesSDK.primp-industries.com

Removing plugin key: &amp;quot;com.vmware.vSphereWebServicesSDK.primp-industries.com&amp;quot;

&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
Alternatively, you can also remove any of the plugins by using the Manager Object Browser. You just need to point your web browser to your vCenter server:&lt;a class="jive-link-external" href="https://&amp;lt;your_vc_server&amp;gt;/mob"&gt;https://&amp;lt;your_vc_server&amp;gt;/mob&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;1. Click on &lt;b&gt;content&lt;/b&gt; &lt;/h2&gt;
&lt;br /&gt;
 &lt;img src="http://img59.imageshack.us/img59/3299/15398269.png" alt="http://img59.imageshack.us/img59/3299/15398269.png" class="jive-image"  /&gt; &lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;2. Locate and click on &lt;b&gt;ExtensionManager&lt;/b&gt;&lt;/h2&gt;
&lt;br /&gt;
 &lt;img src="http://img269.imageshack.us/img269/3717/71270742.png" alt="http://img269.imageshack.us/img269/3717/71270742.png" class="jive-image"  /&gt; &lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;3. Click on the plugin you're interested in removing&lt;/h2&gt;
&lt;br /&gt;
 &lt;img src="http://img36.imageshack.us/img36/2893/65422162.png" alt="http://img36.imageshack.us/img36/2893/65422162.png" class="jive-image"  /&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;4. Record the plugin &lt;b&gt;key&lt;/b&gt; id which is required to remove the plugin&lt;/h2&gt;
&lt;br /&gt;
 &lt;img src="http://img197.imageshack.us/img197/9592/50082541.png" alt="http://img197.imageshack.us/img197/9592/50082541.png" class="jive-image"  /&gt; &lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;5. Go back to the previous page and at the bottom click on the function &lt;b&gt;UnregisterExtension&lt;/b&gt;, a new window will pop-up which will ask for the plugin &lt;b&gt;key&lt;/b&gt;. Enter the key and then click on &lt;b&gt;Invoke Method&lt;/b&gt; to remove the plugin.&lt;/h2&gt;
&lt;br /&gt;
 &lt;img src="http://img190.imageshack.us/img190/3784/94366121.png" alt="http://img190.imageshack.us/img190/3784/94366121.png" class="jive-image"  /&gt; &lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;6. You can refresh the page and you'll notice the plugin is no longer available and you can restart your vSphere Client to see the plugin has no been removed.&lt;/h2&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">extension</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vcenter4</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vcenter</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">plugin</category>
      <pubDate>Sat, 03 Oct 2009 17:57:58 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10847</guid>
      <dc:date>2009-10-03T17:57:58Z</dc:date>
      <clearspace:dateToText>1 month, 3 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>Deploy VM From Template</title>
      <link>http://communities.vmware.com/docs/DOC-10818</link>
      <description />
      <category domain="http://communities.vmware.com/tags?communityID=3079">vm_operations</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">template</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">deploy</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">vm</category>
      <pubDate>Wed, 30 Sep 2009 03:20:16 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10818</guid>
      <dc:date>2009-09-30T03:20:16Z</dc:date>
      <clearspace:dateToText>1 month, 3 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>addVMAnnotation.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10779</link>
      <description>This script allows you to set 'annotation' field for a specific VM when connecting to either ESX9i) or vCenter host.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;&lt;span style="color:red"&gt;Note:&lt;/span&gt;&lt;/b&gt; This script was generated using the same snippet of code as &lt;a class="jive-link-wiki" href="http://communities.vmware.com/docs/DOC-10551"&gt;addVMAdvParamOption.pl&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt;&lt;br /&gt;
ESX(i) 3.5 or 4.0 or vCenter 2.5 or 4.0&lt;br /&gt;
vSphere SDK for Perl or vMA&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield]$ ./addVMAnnotation.pl --server reflex.primp-industries.com --username primp --vmname vMA-2 --annotation &amp;quot;vMA-2 dev system&amp;quot;

Reconfiguring &amp;quot;vMA-2&amp;quot; with annotation: &amp;quot;vMA-2 dev system&amp;quot; ...
Sucessfully updated annotation for &amp;quot;vMA-2&amp;quot;!

&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">configuration</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">annotation</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vma</category>
      <pubDate>Mon, 28 Sep 2009 19:25:00 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10779</guid>
      <dc:date>2009-09-28T19:25:00Z</dc:date>
      <clearspace:dateToText>1 month, 4 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>getVMThinProvisionedSavings.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10777</link>
      <description>While looking around the forums, I noticed this thread: &lt;a class="jive-link-thread" href="http://communities.vmware.com/thread/233775"&gt;Script to determine disk space saved by thin provisioning&lt;/a&gt; which had an interesting request from the OP. This script will extract the &lt;u&gt;total&lt;/u&gt; amount of provisioned space across all datastore(s) and consumed space for a VM and display in either the raw format in total &lt;b&gt;bytes&lt;/b&gt; OR it's properly formatted disk consumption &lt;b&gt;(B,KB,MB,GB,TB)&lt;/b&gt;. This data is primarily useful when using thin provisioning &lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt;&lt;br /&gt;
ESX(i) 4.0 or vCenter 4.0&lt;br /&gt;
vSphere SDK for Perl or vMA 4.0&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
Raw output (in bytes by default):&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]./getVMThinProvisionedSavings.pl --server reflex.primp-industries.com --username primp

VM Name                                  Provisioned          Used                % Saved
-------------------------------------------------------------------------------------------
Auroa                                    4833604510           4288344990          11.3 %
-------------------------------------------------------------------------------------------
Bitsy                                    2686155138           1851488642          31.1 %
-------------------------------------------------------------------------------------------
Certiorari                               9395724427           8590418059          8.6 %
-------------------------------------------------------------------------------------------
Clifford                                 10766700317          10766700317         0 %
-------------------------------------------------------------------------------------------
ESX-Kickstart                            13423364683          7031259723          47.6 %
-------------------------------------------------------------------------------------------
ESX40-1                                  46171339531          4402363147          90.5 %
-------------------------------------------------------------------------------------------
ESX40-2                                  30065354586          4306036570          85.7 %
-------------------------------------------------------------------------------------------
ESXi40-1                                 30065197293          4318462189          85.6 %

.........
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;p /&gt;
Formated output:&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./getVMThinProvisionedSavings.pl --server reflex.primp-industries.com --username primp --format 1

VM Name                                  Provisioned          Used                % Saved
-------------------------------------------------------------------------------------------
Auroa                                    4.50 GB              3.99 GB             11.3 %
-------------------------------------------------------------------------------------------
Bitsy                                    2.50 GB              1.72 GB             31.1 %
-------------------------------------------------------------------------------------------
Certiorari                               8.75 GB              8.00 GB             8.6 %
-------------------------------------------------------------------------------------------
Clifford                                 10.03 GB             10.03 GB            0 %
-------------------------------------------------------------------------------------------
ESX-Kickstart                            12.50 GB             6.55 GB             47.6 %
-------------------------------------------------------------------------------------------
ESX40-1                                  43.00 GB             4.10 GB             90.5 %
-------------------------------------------------------------------------------------------
ESX40-2                                  28.00 GB             4.01 GB             85.7 %
-------------------------------------------------------------------------------------------
ESXi40-1                                 28.00 GB             4.02 GB             85.6 %
.....

&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">thin_provisioning</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">thin</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">datastore</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">committed</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">uncommitted</category>
      <pubDate>Sat, 26 Sep 2009 23:28:29 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10777</guid>
      <dc:date>2009-09-26T23:28:29Z</dc:date>
      <clearspace:dateToText>2 months, 18 hours ago</clearspace:dateToText>
    </item>
    <item>
      <title>generateVMRemoteConsoleURL.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10809</link>
      <description>Motivated by this thread: &lt;a class="jive-link-thread" href="http://communities.vmware.com/thread/133551"&gt;Programatically Generate Remote Console URL&lt;/a&gt;, here is a script that will generate the proper remote console URL for vSphere vCenter 4.0&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt;&lt;br /&gt;
vCenter 4.0&lt;br /&gt;
ESX(i) 4.0&lt;br /&gt;
vSphere SDK for Perl or vMA 4.0&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
Do not obfuscate URL:&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~][http://reflex.primp-industries.com|http://reflex.primp-industries.com]$ ./generateVMRemoteConsoleURL.pl --server reflex.primp-industries.com --username primp --obfuscate 0 --vmname William-XP
https://reflex.primp-industries.com/ui/?wsUrl=http://localhost:80/sdk&amp;#38;mo=VirtualMachine|vm-91&amp;#38;inventory=none&amp;#38;tabs=hide_
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
Obfuscate URL:&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~][http://reflex.primp-industries.com|http://reflex.primp-industries.com]$ ./generateVMRemoteConsoleURL.pl --server reflex.primp-industries.com --username primp --obfuscate 1 --vmname William-XP
https://reflex.primp-industries.com/ui/?view=aHR0cDovL2xvY2FsaG9zdDo4MC9zZGsmbW89VmlydHVhbE1hY2hpbmV8dm0tOTEmaW52ZW50b3J5PW5vbmUmdGFicz1oaWRlXw==
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
There are two other optional flags that can be set which are &lt;b&gt;--limit_single_vm_view&lt;/b&gt; and &lt;b&gt;--limit_workspace_view&lt;/b&gt; which is described in the vSphere Web Access for vCenter when generating the URL which can be set in this script to provide the correct permissions in the URL. By default both parameters have a default of &lt;b&gt;&lt;u&gt;1&lt;/u&gt;&lt;/b&gt; or enabled, you may set it to false by passing in the value of &lt;b&gt;&lt;u&gt;0&lt;/u&gt;&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
 &lt;img src="http://communities.vmware.com/servlet/JiveServlet/downloadImage/102-10809-1-7136/remoteURL.png" alt="remoteURL.png" class="jive-image"  /&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">remote_url</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">remote_console</category>
      <pubDate>Sat, 26 Sep 2009 04:33:39 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10809</guid>
      <dc:date>2009-09-26T04:33:39Z</dc:date>
      <clearspace:dateToText>2 months, 1 day ago</clearspace:dateToText>
    </item>
    <item>
      <title>getVMsPerDatastore.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10807</link>
      <description>I noticed Alan Renof's &lt;b&gt;&lt;a class="jive-link-external" href="http://www.virtu-al.net/2009/09/23/powercli-how-many-vms-on-your-datastores/"&gt;How many VMs on your Datastores ?&lt;/a&gt;&lt;/b&gt; article today and realized I had written something similar a few months back but forgot to publish. This script will retrieve all datastores from either ESX(i) or vCenter host and extract the number of VM(s), % free and the datastore type.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt;&lt;br /&gt;
ESX(i) 3.5 or 4.0&lt;br /&gt;
vCenter 2.5 or 4.0&lt;br /&gt;
vSphere SDK for Perl or vMA 4.0&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;./getVMsPerDatastore.pl --server reflex.primp-industries.com --username primp

Datastore                                        % Free              # of VMs        Datastore Type
-----------------------------------------------------------------------------------------------------
dlgCore-NFS-bigboi.VM-Backups                    41.2                3               NFS
-----------------------------------------------------------------------------------------------------
dlgCore-iSCSI.test                               48.6                1               VMFS
-----------------------------------------------------------------------------------------------------
himalaya-local-SAS.Constellation                 20.5                10              VMFS
-----------------------------------------------------------------------------------------------------
himalaya-local-SAS.Savvio                        46.2                23              VMFS
-----------------------------------------------------------------------------------------------------
himalaya-local-SATA.RE4-GP:Boot                  48.2                0               VMFS
-----------------------------------------------------------------------------------------------------
himalaya-local-SATA.RE4-GP:Storage               49.3                31              VMFS
-----------------------------------------------------------------------------------------------------
dlgCore-NFS-bigboi.VM-Backups                    41.1                0               NFS
-----------------------------------------------------------------------------------------------------
esx40-1-local-storage                            98.7                0               VMFS
-----------------------------------------------------------------------------------------------------
esx40-2-local-storage                            98.1                0               VMFS
-----------------------------------------------------------------------------------------------------
esxi40-1-local-storage                           98.1                2               VMFS
-----------------------------------------------------------------------------------------------------
himalaya-iSCSI-starwind.esx-devCluster           97.6                2               VMFS
-----------------------------------------------------------------------------------------------------

&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">storage</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">datastore</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vms_free</category>
      <pubDate>Fri, 25 Sep 2009 04:16:11 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10807</guid>
      <dc:date>2009-09-25T04:16:11Z</dc:date>
      <clearspace:dateToText>2 months, 2 days ago</clearspace:dateToText>
    </item>
    <item>
      <title>listVMsInResourcePool.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10805</link>
      <description>Script to query VM(s) in a specific Resource Pool, this will work if the Resource Pool is nested.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt; &lt;br /&gt;
vCenter 2.5 or 4.0&lt;br /&gt;
vSphere SDK for Perl or vMA 4.0&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;./listVMsInResourcePool.pl --server reflex.primp-industries.com --username primp --resource_pool production

vm-1
vm-2
vm-3
vm-4
&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">resource_pool</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">resourcepool</category>
      <pubDate>Thu, 24 Sep 2009 16:35:48 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10805</guid>
      <dc:date>2009-09-24T16:35:48Z</dc:date>
      <clearspace:dateToText>2 months, 3 days ago</clearspace:dateToText>
    </item>
    <item>
      <title>Configure numDisplays using vmware.vim.dll</title>
      <link>http://communities.vmware.com/docs/DOC-10804</link>
      <description>Private Function WriteVDI_VMXFile(ByVal VCClient As VMware.Vim.VimClient, ByVal textToUse As String, ByVal HWProfile As String, ByVal BindOU As DirectoryEntry, ByVal eucnotes As String)&lt;br /&gt;
&lt;br /&gt;
	Dim vmCenter As String = vce&lt;br /&gt;
        Dim vmFilter, cluFilter As New NameValueCollection&lt;br /&gt;
        vmFilter.Add("Runtime.PowerState", "PoweredOff")&lt;br /&gt;
        vmFilter.Add("name", "^" &amp;#38; vma &amp;#38; "$")&lt;br /&gt;
&lt;br /&gt;
        Dim vmList As IList(Of EntityViewBase) = VCClient.FindEntityViews(GetType(VirtualMachine), Nothing, vmFilter, Nothing)&lt;br /&gt;
        If vmList Is Nothing Then&lt;br /&gt;
&lt;br /&gt;
            Return False&lt;br /&gt;
        End If&lt;br /&gt;
&lt;p /&gt;
	For Each vm As VirtualMachine In vmList ' Looping through all VMs found that match the filter&lt;br /&gt;
            If vm.Name.ToUpper = vma Then 'The filter matches machines objects that has "StartsWith" &amp;lt;^value&amp;gt;..&lt;br /&gt;
&lt;p /&gt;
&lt;br /&gt;
         Dim info As VMware.Vim.VirtualMachineConfigSpec&lt;br /&gt;
                info = New VMware.Vim.VirtualMachineConfigSpec&lt;br /&gt;
&lt;br /&gt;
                With info&lt;br /&gt;
                    .NumCPUs = cpp&lt;br /&gt;
                    .MemoryMB = mep&lt;br /&gt;
&lt;br /&gt;
                    If Me.cbx_GBM_BBP_NumDisplays.SelectedIndex  -1 Then&lt;br /&gt;
                         If displyConfig IsNot Nothing Then&lt;br /&gt;
                            .ExtraConfig = New VMware.Vim.OptionValue(2) {}&lt;br /&gt;
                            .ExtraConfig(0) = New VMware.Vim.OptionValue()&lt;br /&gt;
                            .ExtraConfig(0).Key = maxWidthKey&lt;br /&gt;
                            .ExtraConfig(0).Value = maxWidthValue&lt;br /&gt;
                            .ExtraConfig(1) = New VMware.Vim.OptionValue()&lt;br /&gt;
                            .ExtraConfig(1).Key = maxHeightKey&lt;br /&gt;
                            .ExtraConfig(1).Value = maxHeightValue&lt;br /&gt;
                            .ExtraConfig(2) = New VMware.Vim.OptionValue()&lt;br /&gt;
                            .ExtraConfig(2).Key = numDisplaysKey&lt;br /&gt;
                            .ExtraConfig(2).Value = numDisplaysValue&lt;br /&gt;
&lt;p /&gt;
			     Call ConfigureVirtualVideoRAMsize(vramSizeValue, vm)&lt;br /&gt;
&lt;br /&gt;
                        End If&lt;br /&gt;
&lt;br /&gt;
                    End If&lt;br /&gt;
&lt;br /&gt;
                End With&lt;br /&gt;
End Function&lt;br /&gt;
&lt;br /&gt;
Public Sub ConfigureVirtualVideoRAMsize(ByVal vramInKB As Integer, ByVal vm As VirtualMachine)&lt;br /&gt;
        Dim videoCard As VirtualMachineVideoCard = Nothing&lt;br /&gt;
        ' Get all the virtual devices of a VirtualMachine &lt;br /&gt;
        Dim vDevices As VirtualDevice() = vm.Config.Hardware.Device&lt;br /&gt;
        ' Find the video card from available virtual devices &lt;br /&gt;
        For x As Integer = 0 To vDevices.Length - 1&lt;br /&gt;
            If TypeOf vDevices(x) Is VMware.Vim.VirtualMachineVideoCard Then&lt;br /&gt;
                videoCard = DirectCast(vDevices(x), VirtualMachineVideoCard)&lt;br /&gt;
                Exit For&lt;br /&gt;
            End If&lt;br /&gt;
        Next&lt;br /&gt;
&lt;br /&gt;
        If videoCard IsNot Nothing Then&lt;br /&gt;
            ' Set the new videoRamSize&lt;br /&gt;
            videoCard.VideoRamSizeInKB = vramInKB&lt;br /&gt;
            ' Create the configuration spec to be passed in ReconfigVM method &lt;br /&gt;
            Dim deviceSpec As New VirtualDeviceConfigSpec()&lt;br /&gt;
            deviceSpec.Operation = VirtualDeviceConfigSpecOperation.edit&lt;br /&gt;
            deviceSpec.Device = videoCard&lt;br /&gt;
&lt;br /&gt;
            Dim confSpec As New VirtualMachineConfigSpec()&lt;br /&gt;
            confSpec.DeviceChange = New VirtualDeviceConfigSpec() {deviceSpec}&lt;br /&gt;
            vm.ReconfigVM(confSpec)&lt;br /&gt;
        End If&lt;br /&gt;
End Sub</description>
      <category domain="http://communities.vmware.com/tags?communityID=3125">svga.maxheight</category>
      <category domain="http://communities.vmware.com/tags?communityID=3125">svga.maxwidth</category>
      <category domain="http://communities.vmware.com/tags?communityID=3125">svga.numdisplays</category>
      <category domain="http://communities.vmware.com/tags?communityID=3125">svga.vramsize</category>
      <category domain="http://communities.vmware.com/tags?communityID=3125">virtualmachinevideocard</category>
      <category domain="http://communities.vmware.com/tags?communityID=3125">videoramsizeinkb</category>
      <pubDate>Thu, 24 Sep 2009 14:49:33 GMT</pubDate>
      <author>richard.judd@rbs.com</author>
      <guid>http://communities.vmware.com/docs/DOC-10804</guid>
      <dc:date>2009-09-24T14:49:33Z</dc:date>
      <clearspace:dateToText>2 months, 3 days ago</clearspace:dateToText>
    </item>
    <item>
      <title>Change Network Card on VM (Network0, Network1)</title>
      <link>http://communities.vmware.com/docs/DOC-10803</link>
      <description>Private Function WriteVDI_VMXFile(ByVal VCClient As VMware.Vim.VimClient, ByVal textToUse As String, ByVal HWProfile As String, ByVal BindOU As DirectoryEntry, ByVal eucnotes As String)&lt;br /&gt;
&lt;br /&gt;
	Dim vmCenter As String = vce&lt;br /&gt;
        Dim vmFilter, cluFilter As New NameValueCollection&lt;br /&gt;
        vmFilter.Add("Runtime.PowerState", "PoweredOff")&lt;br /&gt;
        vmFilter.Add("name", "^" &amp;#38; vma &amp;#38; "$")&lt;br /&gt;
&lt;br /&gt;
        Dim vmList As IList(Of EntityViewBase) = VCClient.FindEntityViews(GetType(VirtualMachine), Nothing, vmFilter, Nothing)&lt;br /&gt;
        If vmList Is Nothing Then&lt;br /&gt;
&lt;br /&gt;
            Return False&lt;br /&gt;
        End If&lt;br /&gt;
&lt;p /&gt;
	For Each vm As VirtualMachine In vmList ' Looping through all VMs found that match the filter&lt;br /&gt;
            If vm.Name.ToUpper = vma Then 'The filter matches machines objects that has "StartsWith" &amp;lt;^value&amp;gt;..&lt;br /&gt;
&lt;p /&gt;
If Me.cbx_GBM_BBP_NetworkConnection.SelectedIndex  -1 Then ' Looking at a combo box control&lt;br /&gt;
                    For Each mor As ManagedObjectReference In vm.Network&lt;br /&gt;
                        Dim virtualDevices As VMware.Vim.VirtualDevice() = vm.Config.Hardware.Device&lt;br /&gt;
                        Dim nicList As New List(Of VMware.Vim.VirtualEthernetCard)()&lt;br /&gt;
                        For x As Integer = 0 To virtualDevices.Length - 1&lt;br /&gt;
                            If TypeOf virtualDevices(x) Is VMware.Vim.VirtualEthernetCard Then&lt;br /&gt;
                                Dim nic As VMware.Vim.VirtualEthernetCard = DirectCast(virtualDevices(x), VMware.Vim.VirtualEthernetCard)&lt;br /&gt;
                                nicList.Add(nic)&lt;br /&gt;
                                Dim NetworkType As String = Me.cbx_GBM_BBP_NetworkConnection.SelectedItem.ToString 'reading a value from combo box control&lt;br /&gt;
                                Dim _Network As String = Nothing&lt;br /&gt;
                                _Network = GetHashTableVal(_VMHardwareConfig, NetworkType) ' getting value from hash table&lt;br /&gt;
&lt;br /&gt;
                                Call ConfigureVirtualNIC(_Network, nicList, mor, vm)&lt;br /&gt;
&lt;br /&gt;
                                Exit For&lt;br /&gt;
                            End If&lt;br /&gt;
                        Next&lt;br /&gt;
                    Next&lt;br /&gt;
                End If&lt;br /&gt;
End Function&lt;br /&gt;
&lt;br /&gt;
Public Sub ConfigureVirtualNIC(ByVal NicName As String, ByVal niclist As List(Of VMware.Vim.VirtualEthernetCard), ByVal mor As ManagedObjectReference, ByVal vm As VirtualMachine)&lt;br /&gt;
        Dim deviceSpec As VirtualDeviceConfigSpec() = New VirtualDeviceConfigSpec(niclist.Count - 1) {}&lt;br /&gt;
&lt;br /&gt;
        For x As Integer = 0 To niclist.Count - 1&lt;br /&gt;
            deviceSpec(x) = New VMware.Vim.VirtualDeviceConfigSpec()&lt;br /&gt;
            deviceSpec(x).Operation = VMware.Vim.VirtualDeviceConfigSpecOperation.edit&lt;br /&gt;
            deviceSpec(x).Device = niclist(x)&lt;br /&gt;
            Dim nicBacking As New VMware.Vim.VirtualEthernetCardNetworkBackingInfo()&lt;br /&gt;
            nicBacking.Network = mor&lt;br /&gt;
            nicBacking.DeviceName = NicName&lt;br /&gt;
            niclist(x).Backing = nicBacking&lt;br /&gt;
        Next&lt;br /&gt;
&lt;br /&gt;
        Dim newSpec As New VirtualMachineConfigSpec()&lt;br /&gt;
        newSpec.DeviceChange = deviceSpec&lt;br /&gt;
        Try&lt;br /&gt;
            vm.ReconfigVM(newSpec)&lt;br /&gt;
&lt;br /&gt;
        Catch ex As Exception&lt;br /&gt;
&lt;br /&gt;
        End Try&lt;br /&gt;
End Sub</description>
      <category domain="http://communities.vmware.com/tags?communityID=3125">virtualethernetcard</category>
      <category domain="http://communities.vmware.com/tags?communityID=3125">virtualethernetcardnetworkbackinginfo</category>
      <category domain="http://communities.vmware.com/tags?communityID=3125">vb.net</category>
      <pubDate>Thu, 24 Sep 2009 13:51:15 GMT</pubDate>
      <author>richard.judd@rbs.com</author>
      <guid>http://communities.vmware.com/docs/DOC-10803</guid>
      <dc:date>2009-09-24T13:51:15Z</dc:date>
      <clearspace:dateToText>2 months, 3 days ago</clearspace:dateToText>
    </item>
    <item>
      <title>suspend.C Demonstrates how to power on, suspend, and resume a virtual machine</title>
      <link>http://communities.vmware.com/docs/DOC-10802</link>
      <description>&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;VIX API 1.7 Sample Code - from Documentation Website

* *********************************************************************
* Copyright (c) 2007 VMware, Inc.
* All rights not expressly granted to you by VMware, Inc. are reserved.
* *********************************************************************/

/* This demonstrates how to power on, suspend, and resume a virtual machine.
* The virtual machine will remain powered on at the end of this program.
*
* This uses the VixJob_Wait function to block after starting each
* asynchronous function. This effectively makes the asynchronous
* functions synchronous, because VixJob_Wait will not return until the
* asynchronous function has completed.
*/

#include &amp;lt;stdio.h&amp;gt;
#include &amp;lt;stdlib.h&amp;gt;

#include &amp;quot;vix.h&amp;quot;

/*
* Certain arguments differ when using VIX with VMware Server 2.0
* and VMware Workstation.
*
* Comment out this definition to use this code with VMware Server 2.0.
*/
#define USE_WORKSTATION

#ifdef USE_WORKSTATION

#define  CONNTYPE    VIX_SERVICEPROVIDER_VMWARE_WORKSTATION

#define  HOSTNAME &amp;quot;&amp;quot;
#define  HOSTPORT 0
#define  USERNAME &amp;quot;&amp;quot;
#define  PASSWORD &amp;quot;&amp;quot;

#define  VMPOWEROPTIONS   VIX_VMPOWEROP_LAUNCH_GUI   // Launches the VMware Workstaion UI
// when powering on the virtual machine.

#define VMXPATH_INFO &amp;quot;where vmxpath is an absolute path to the .vmx file &amp;quot; \
&amp;quot;for the virtual machine.&amp;quot;

#else    // USE_WORKSTATION

/*
* For VMware Server 2.0
*/

#define CONNTYPE VIX_SERVICEPROVIDER_VMWARE_VI_SERVER

#define HOSTNAME &amp;quot;https://192.2.3.4:8333/sdk&amp;quot;
/*
* NOTE: HOSTPORT is ignored, so the port should be specified as part
* of the URL.
*/
#define HOSTPORT 0
#define USERNAME &amp;quot;root&amp;quot;
#define PASSWORD &amp;quot;hideme&amp;quot;

#define  VMPOWEROPTIONS VIX_VMPOWEROP_NORMAL

#define VMXPATH_INFO &amp;quot;where vmxpath is a datastore-relative path to the &amp;quot; \
&amp;quot;.vmx file for the virtual machine, such as &amp;quot;        \
&amp;quot;\&amp;quot;[standard] ubuntu/ubuntu.vmx\&amp;quot;.&amp;quot;

#endif    // USE_WORKSTATION

/*
* Global variables.
*/

static char *progName;



/*
* Local functions.
*/

////////////////////////////////////////////////////////////////////////////////
static void
usage()
{
fprintf(stderr, &amp;quot;Usage: %s &amp;lt;vmxpath&amp;gt;\n&amp;quot;, progName);
fprintf(stderr, &amp;quot;%s&amp;quot;, VMXPATH_INFO);
}

////////////////////////////////////////////////////////////////////////////////
int
main(int argc, char **argv)
{
VixError err;
char *vmxPath;
VixHandle hostHandle = VIX_INVALID_HANDLE;
VixHandle jobHandle = VIX_INVALID_HANDLE;
VixHandle vmHandle = VIX_INVALID_HANDLE;

progName = argv[0];
if (argc &amp;gt; 1) {
vmxPath = argv[1];
} else {
usage();
exit(EXIT_FAILURE);
}

jobHandle = VixHost_Connect(VIX_API_VERSION,
CONNTYPE,
HOSTNAME, // *hostName,
HOSTPORT, // hostPort,
USERNAME, // *userName,
PASSWORD, // *password,
0, // options,
VIX_INVALID_HANDLE, // propertyListHandle,
NULL, // *callbackProc,
NULL); // *clientData);

err = VixJob_Wait(jobHandle, 
VIX_PROPERTY_JOB_RESULT_HANDLE, 
&amp;#38;hostHandle,
VIX_PROPERTY_NONE);
if (VIX_FAILED(err)) {
goto abort;
}

Vix_ReleaseHandle(jobHandle);
jobHandle = VixVM_Open(hostHandle,
vmxPath,
NULL, // VixEventProc *callbackProc,
NULL); // void *clientData);
err = VixJob_Wait(jobHandle, 
VIX_PROPERTY_JOB_RESULT_HANDLE, 
&amp;#38;vmHandle,
VIX_PROPERTY_NONE);
if (VIX_FAILED(err)) {
goto abort;
}

Vix_ReleaseHandle(jobHandle);
jobHandle = VixVM_PowerOn(vmHandle,
VMPOWEROPTIONS,
VIX_INVALID_HANDLE,
NULL, // *callbackProc,
NULL); // *clientData);
err = VixJob_Wait(jobHandle, VIX_PROPERTY_NONE);
if (VIX_FAILED(err)) {
goto abort;
}

Vix_ReleaseHandle(jobHandle);
jobHandle = VixVM_Suspend(vmHandle,
VIX_VMPOWEROP_NORMAL,
NULL, // *callbackProc,
NULL); // *clientData);
err = VixJob_Wait(jobHandle, VIX_PROPERTY_NONE);
if (VIX_FAILED(err)) {
goto abort;
}

Vix_ReleaseHandle(jobHandle);

/*
* Calling VixVM_PowerOn() on a virtual machine that has been
* suspended will resume the virtual machine from the suspended state.
*/
jobHandle = VixVM_PowerOn(vmHandle,
VMPOWEROPTIONS,
VIX_INVALID_HANDLE,
NULL, // *callbackProc,
NULL); // *clientData);
err = VixJob_Wait(jobHandle, VIX_PROPERTY_NONE);
if (VIX_FAILED(err)) {
goto abort;
}

abort:
Vix_ReleaseHandle(jobHandle);
Vix_ReleaseHandle(vmHandle);

VixHost_Disconnect(hostHandle);



return 0;
}



/*If you have obtained this sample code as part of the VMware Server 1.0 SDK, or are using this sample code in conjunction with the VMware Server 1.0 SDK, the license terms of that SDK will govern your use of this sample code.

Otherwise, the sample code is provided &amp;quot;AS-IS&amp;quot; for use, modification, and redistribution in source and binary forms, provided that the copyright notice and this following list of conditions are retained and/or reproduced in your distribution. To the maximum extent permitted by law, VMware, Inc., its subsidiaries and affiliates hereby disclaim all express, implied and/or statutory warranties, including duties or conditions of merchantability, fitness for a particular purpose, and non-infringement of intellectual property rights. IN NO EVENT WILL VMWARE, ITS SUBSIDIARIES OR AFFILIATES BE LIABLE TO ANY OTHER PARTY FOR THE COST OF PROCURING SUBSTITUTE GOODS OR SERVICES, LOST PROFITS, LOSS OF USE, LOSS OF DATA, OR ANY INCIDENTAL, CONSEQUENTIAL, DIRECT, INDIRECT, OR SPECIAL DAMAGES, ARISING OUT OF THIS OR ANY OTHER AGREEMENT RELATING TO THE SAMPLE CODE.

You agree to defend, indemnify and hold harmless VMware, and any of its directors, officers, employees, agents, affiliates, or subsidiaries from and against all losses, damages, costs and liabilities arising from your use, modification and distribution of the sample code.

VMware does not certify or endorse your use of the sample code, nor is any support or other service provided in connection with the sample code.*/

&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3262">vix_api_1.7</category>
      <category domain="http://communities.vmware.com/tags?communityID=3262">demonstrates</category>
      <category domain="http://communities.vmware.com/tags?communityID=3262">how</category>
      <category domain="http://communities.vmware.com/tags?communityID=3262">to</category>
      <category domain="http://communities.vmware.com/tags?communityID=3262">power</category>
      <category domain="http://communities.vmware.com/tags?communityID=3262">on</category>
      <category domain="http://communities.vmware.com/tags?communityID=3262">suspend</category>
      <category domain="http://communities.vmware.com/tags?communityID=3262">and</category>
      <category domain="http://communities.vmware.com/tags?communityID=3262">resume</category>
      <category domain="http://communities.vmware.com/tags?communityID=3262">a</category>
      <category domain="http://communities.vmware.com/tags?communityID=3262">virtual</category>
      <category domain="http://communities.vmware.com/tags?communityID=3262">machine</category>
      <pubDate>Wed, 23 Sep 2009 22:18:14 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10802</guid>
      <dc:date>2009-09-23T22:18:14Z</dc:date>
      <clearspace:dateToText>2 months, 2 days ago</clearspace:dateToText>
    </item>
    <item>
      <title>powerOn.c - Shows how to open a virtual machine, power it on, and power it off.</title>
      <link>http://communities.vmware.com/docs/DOC-10801</link>
      <description>&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;/*Link to sample code from Documentation website Shows how to open a virtual machine, power it on, and power it off.*/

 

* *********************************************************************
* Copyright (c) 2007 VMware, Inc.
* All rights not expressly granted to you by VMware, Inc. are reserved.
* *********************************************************************/

/* This demonstrates how to open a virtual machine,
* power it on, and power it off.
*
* This uses the VixJob_Wait function to block after starting each
* asynchronous function. This effectively makes the asynchronous
* functions synchronous, because VixJob_Wait will not return until the
* asynchronous function has completed.
*/

#include &amp;lt;stdio.h&amp;gt;
#include &amp;lt;stdlib.h&amp;gt;

#include &amp;quot;vix.h&amp;quot;

/*
* Certain arguments differ when using VIX with VMware Server 2.0
* and VMware Workstation.
*
* Comment out this definition to use this code with VMware Server 2.0.
*/
#define USE_WORKSTATION

#ifdef USE_WORKSTATION

#define  CONNTYPE    VIX_SERVICEPROVIDER_VMWARE_WORKSTATION

#define  HOSTNAME &amp;quot;&amp;quot;
#define  HOSTPORT 0
#define  USERNAME &amp;quot;&amp;quot;
#define  PASSWORD &amp;quot;&amp;quot;

#define  VMPOWEROPTIONS   VIX_VMPOWEROP_LAUNCH_GUI   // Launches the VMware Workstaion UI
// when powering on the virtual machine.

#define VMXPATH_INFO &amp;quot;where vmxpath is an absolute path to the .vmx file &amp;quot; \
&amp;quot;for the virtual machine.&amp;quot;

#else    // USE_WORKSTATION

/*
* For VMware Server 2.0
*/

#define CONNTYPE VIX_SERVICEPROVIDER_VMWARE_VI_SERVER

#define HOSTNAME &amp;quot;https://192.2.3.4:8333/sdk&amp;quot;
/*
* NOTE: HOSTPORT is ignored, so the port should be specified as part
* of the URL.
*/
#define HOSTPORT 0
#define USERNAME &amp;quot;root&amp;quot;
#define PASSWORD &amp;quot;hideme&amp;quot;

#define  VMPOWEROPTIONS VIX_VMPOWEROP_NORMAL

#define VMXPATH_INFO &amp;quot;where vmxpath is a datastore-relative path to the &amp;quot; \
&amp;quot;.vmx file for the virtual machine, such as &amp;quot;        \
&amp;quot;\&amp;quot;[standard] ubuntu/ubuntu.vmx\&amp;quot;.&amp;quot;

#endif    // USE_WORKSTATION

/*
* Global variables.
*/

static char *progName;



/*
* Local functions.
*/

////////////////////////////////////////////////////////////////////////////////
static void
usage()
{
fprintf(stderr, &amp;quot;Usage: %s &amp;lt;vmxpath&amp;gt;\n&amp;quot;, progName);
fprintf(stderr, &amp;quot;%s\n&amp;quot;, VMXPATH_INFO);
}



////////////////////////////////////////////////////////////////////////////////
int
main(int argc, char **argv)
{
VixError err;
char *vmxPath;
VixHandle hostHandle = VIX_INVALID_HANDLE;
VixHandle jobHandle = VIX_INVALID_HANDLE;
VixHandle vmHandle = VIX_INVALID_HANDLE;

progName = argv[0];
if (argc &amp;gt; 1) {
vmxPath = argv[1];
} else {
usage();
exit(EXIT_FAILURE);
}

jobHandle = VixHost_Connect(VIX_API_VERSION,
CONNTYPE,
HOSTNAME, // *hostName,
HOSTPORT, // hostPort,
USERNAME, // *userName,
PASSWORD, // *password,
0, // options,
VIX_INVALID_HANDLE, // propertyListHandle,
NULL, // *callbackProc,
NULL); // *clientData);
err = VixJob_Wait(jobHandle, 
VIX_PROPERTY_JOB_RESULT_HANDLE, 
&amp;#38;hostHandle,
VIX_PROPERTY_NONE);
if (VIX_FAILED(err)) {
goto abort;
}

Vix_ReleaseHandle(jobHandle);
jobHandle = VixVM_Open(hostHandle,
vmxPath,
NULL, // VixEventProc *callbackProc,
NULL); // void *clientData);
err = VixJob_Wait(jobHandle, 
VIX_PROPERTY_JOB_RESULT_HANDLE, 
&amp;#38;vmHandle,
VIX_PROPERTY_NONE);
if (VIX_FAILED(err)) {
goto abort;
}

Vix_ReleaseHandle(jobHandle);
jobHandle = VixVM_PowerOn(vmHandle,
VMPOWEROPTIONS,
VIX_INVALID_HANDLE,
NULL, // *callbackProc,
NULL); // *clientData);
err = VixJob_Wait(jobHandle, VIX_PROPERTY_NONE);
if (VIX_FAILED(err)) {
goto abort;
}

Vix_ReleaseHandle(jobHandle);
jobHandle = VixVM_PowerOff(vmHandle,
VIX_VMPOWEROP_NORMAL,
NULL, // *callbackProc,
NULL); // *clientData);
err = VixJob_Wait(jobHandle, VIX_PROPERTY_NONE);
if (VIX_FAILED(err)) {
goto abort;
}

abort:
Vix_ReleaseHandle(jobHandle);
Vix_ReleaseHandle(vmHandle);

VixHost_Disconnect(hostHandle);

return 0;
}



/*If you have obtained this sample code as part of the VMware Server 1.0 SDK, or are using this sample code in conjunction with the VMware Server 1.0 SDK, the license terms of that SDK will govern your use of this sample code.

Otherwise, the sample code is provided &amp;quot;AS-IS&amp;quot; for use, modification, and redistribution in source and binary forms, provided that the copyright notice and this following list of conditions are retained and/or reproduced in your distribution. To the maximum extent permitted by law, VMware, Inc., its subsidiaries and affiliates hereby disclaim all express, implied and/or statutory warranties, including duties or conditions of merchantability, fitness for a particular purpose, and non-infringement of intellectual property rights. IN NO EVENT WILL VMWARE, ITS SUBSIDIARIES OR AFFILIATES BE LIABLE TO ANY OTHER PARTY FOR THE COST OF PROCURING SUBSTITUTE GOODS OR SERVICES, LOST PROFITS, LOSS OF USE, LOSS OF DATA, OR ANY INCIDENTAL, CONSEQUENTIAL, DIRECT, INDIRECT, OR SPECIAL DAMAGES, ARISING OUT OF THIS OR ANY OTHER AGREEMENT RELATING TO THE SAMPLE CODE.

You agree to defend, indemnify and hold harmless VMware, and any of its directors, officers, employees, agents, affiliates, or subsidiaries from and against all losses, damages, costs and liabilities arising from your use, modification and distribution of the sample code.

VMware does not certify or endorse your use of the sample code, nor is any support or other service provided in connection with the sample code.*/

&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3262">vix_api_1.7</category>
      <category domain="http://communities.vmware.com/tags?communityID=3262">sample</category>
      <category domain="http://communities.vmware.com/tags?communityID=3262">code</category>
      <category domain="http://communities.vmware.com/tags?communityID=3262">poweron.c</category>
      <category domain="http://communities.vmware.com/tags?communityID=3262">open</category>
      <category domain="http://communities.vmware.com/tags?communityID=3262">virtual_machine</category>
      <pubDate>Wed, 23 Sep 2009 22:14:36 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10801</guid>
      <dc:date>2009-09-23T22:14:36Z</dc:date>
      <clearspace:dateToText>2 months, 2 days ago</clearspace:dateToText>
    </item>
    <item>
      <title>queryVMsCreated.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10773</link>
      <description>Script to query when VM(s) were created (cloned, deployed or created). &lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt;&lt;br /&gt;
ESX(i) 3.5 or 4.0 &amp;#38; vCenter 2.5 or 4.0 (&lt;span style="color:red"&gt;&lt;b&gt;vCenter is a requirement&lt;/b&gt;&lt;/span&gt;)&lt;br /&gt;
vSphere SDK for Perl or vMA 4.0&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./queryVMsCreated.pl --server reflex.primp-industries.com --username primp

Enter password:
VM                                                                                      | TIME                          | USERNAME
Created virtual machine vm-1 on esxi40-1.primp-industries.com in Primp-R&amp;#38;D              | 2009-09-21T00:29:24.576999Z   | root
Created virtual machine vm-2 on esxi40-1.primp-industries.com in Primp-R&amp;#38;D              | 2009-09-21T00:29:09.362999Z   | root
Created virtual machine test on esx40-2.primp-industries.com in Primp-R&amp;#38;D               | 2009-09-20T23:46:06.04Z       | PRIMP-IND\primp
Created virtual machine rdm-vm on himalaya.primp-industries.com in Primp-Production     | 2009-09-20T20:58:56.807Z      | PRIMP-IND\primp
Created virtual machine test on esxi40-1.primp-industries.com in Primp-R&amp;#38;D              | 2009-09-20T20:03:22.413Z      | PRIMP-IND\primp
Created virtual machine PROTECT-ME-PLEASE on esxi40-1.primp-industries.com in Primp-R&amp;#38;D | 2009-09-18T23:01:59.149999Z   | PRIMP-IND\primp
Created virtual machine ESXi40-1 on himalaya.primp-industries.com in Primp-Production   | 2009-09-18T20:58:52.353Z      | PRIMP-IND\primp
&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">general</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vms_created</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">created</category>
      <pubDate>Tue, 22 Sep 2009 04:27:32 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10773</guid>
      <dc:date>2009-09-22T04:27:32Z</dc:date>
      <clearspace:dateToText>2 months, 5 days ago</clearspace:dateToText>
    </item>
    <item>
      <title>listDatastoreFiles.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10788</link>
      <description>This script lists the contents of a specific datastore on ESX(i) and all subsequent folders providing the fileName, owner, fileSize and the type of file. In the current form, the script is to be executed against a specific ESX(i) host, but can be extended to query against a vCenter host, I will leave that as an additional exercise for end users.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt;&lt;br /&gt;
ESX(i) 3.5 or 4.0&lt;br /&gt;
vSphere SDK for Perl or vMA 4.0&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./listDatastoreFiles.pl --server esxi40-1.primp-industries.com --username root --datastore esxi40-1-local-storage
Enter password:

Name                                    Owner                                   Size                    Type
vm-1                                     | root                              | 1.50 KB              | FolderFileInfo
vm-2                                     | root                              | 980 Bytes            | FolderFileInfo
vm-1.vmx                                 | root                              | 2.63 KB              | VmConfigFileInfo
vm-1.vmdk                                | root                              | 0                    | VmDiskFileInfo
vm-1.nvram                               | root                              | 8.48 KB              | VmNvramFileInfo
vmware-1.log                             | root                              | 31.62 KB             | VmLogFileInfo
vmware.log                               | root                              | 30.81 KB             | VmLogFileInfo
vm-1.vmxf                                | root                              | 259 Bytes            | FileInfo
vm-1.vmsd                                | root                              | 0                    | FileInfo
vm-1-13e373e7.vswp                       | root                              | 1.00 GB              | FileInfo
vm-2.vmx                                 | root                              | 1.73 KB              | VmConfigFileInfo
vm-2.vmdk                                | root                              | 0                    | VmDiskFileInfo
vm-2.vmxf                                | root                              | 259 Bytes            | FileInfo
vm-2.vmsd                                | root                              | 0                    | FileInfo

&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">datastore</category>
      <pubDate>Mon, 21 Sep 2009 16:58:17 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10788</guid>
      <dc:date>2009-09-21T16:58:17Z</dc:date>
      <clearspace:dateToText>2 months, 6 days ago</clearspace:dateToText>
    </item>
    <item>
      <title>getAllVMsDiskFormatType.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10761</link>
      <description>Script to retrieve VMs disk format type, specifically either &lt;b&gt;'thick'&lt;/b&gt; or &lt;b&gt;'thin'&lt;/b&gt; from either an ESX(i) host or vCenter. &lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt;&lt;br /&gt;
ESX(i) 3.5 or 4.0&lt;br /&gt;
vCenter 2.5 or 4.0&lt;br /&gt;
VIMA 1.0 or vMA 4.0&lt;br /&gt;
VI Perl Toolkit or vSphere SDK for Perl&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./getAllVMsDiskFormatType.pl --server himalaya.primp-industries.com --username root 
Enter password:

vm-1
=============================================
[himalaya-local-storage-1] vm-1/vm-1.vmdk isThinProv: NO
=============================================

vm-2
=============================================
[himalaya-local-storage-1] vm-2/vm-2.vmdk isThinProv: NO
=============================================

vm-3
=============================================
[himalaya-local-storage-2] vm-3/vm-3.vmdk isThinProv: YES
=============================================

&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">disk_format</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">thin_provisioned</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">thin</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <pubDate>Mon, 14 Sep 2009 22:14:55 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10761</guid>
      <dc:date>2009-09-14T22:14:55Z</dc:date>
      <clearspace:dateToText>2 months, 1 week ago</clearspace:dateToText>
    </item>
    <item>
      <title>Sample to perform Netwoking related operations on VM NICs</title>
      <link>http://communities.vmware.com/docs/DOC-10742</link>
      <description>Usage:&lt;br /&gt;
java VMNetworkingOps &amp;lt;server&amp;gt; &amp;lt;username&amp;gt; &amp;lt;password&amp;gt; &amp;lt;vmName&amp;gt; &amp;lt;print|add|change&amp;gt; &amp;lt;portGroupName&amp;gt; &amp;lt;adpaterType|vmNicNames&amp;gt;&lt;br /&gt;
&lt;p /&gt;
Case 1:&lt;br /&gt;
Print the VMNic details (name, and the port group it is connected to)&lt;br /&gt;
&lt;p /&gt;
Input:&lt;br /&gt;
&lt;a class="jive-link-external" href="https://10.20.140.47/sdk"&gt;https://10.20.140.47/sdk&lt;/a&gt; root password vMATemplate_vMAClone1 print&lt;br /&gt;
&lt;p /&gt;
Output:&lt;br /&gt;
&lt;br /&gt;
VM Name: vMATemplate_vMAClone1&lt;br /&gt;
MOR Type : VirtualMachine&lt;br /&gt;
ObjectContent Length : 1&lt;br /&gt;
config.hardware : com.vmware.vim25.VirtualHardware@98f2c13f&lt;br /&gt;
*******************************************************&lt;br /&gt;
vmnic Info (Label) : Network adapter 1&lt;br /&gt;
vmnic Port Group: VM Network&lt;br /&gt;
&lt;br /&gt;
vmnic Info (Label) : Network adapter 2&lt;br /&gt;
vmnic Port Group: VM Network&lt;br /&gt;
&lt;br /&gt;
vmnic Info (Label) : Network adapter 3&lt;br /&gt;
vmnic Port Group: PGroup1&lt;br /&gt;
&lt;br /&gt;
vmnic Info (Label) : Network adapter 4&lt;br /&gt;
vmnic Port Group: PGroup1&lt;br /&gt;
&lt;br /&gt;
*******************************************************&lt;br /&gt;
&lt;p /&gt;
################################################################################&lt;br /&gt;
&lt;br /&gt;
Case 2:&lt;br /&gt;
Change the vmnic port group&lt;br /&gt;
&lt;p /&gt;
Input:&lt;br /&gt;
&lt;a class="jive-link-external" href="https://10.20.140.47/sdk"&gt;https://10.20.140.47/sdk&lt;/a&gt; root password vMATemplate_vMAClone1 change "Network adapter 3,Network adapter 4" "VM Network"&lt;br /&gt;
&lt;p /&gt;
Output:&lt;br /&gt;
VM Name: vMATemplate_vMAClone1&lt;br /&gt;
vmnic adapters: Network adapter 3&lt;br /&gt;
vmnic adapters: Network adapter 4&lt;br /&gt;
MOR Type : VirtualMachine&lt;br /&gt;
ObjectContent Length : 1&lt;br /&gt;
config.hardware : com.vmware.vim25.VirtualHardware@98f2c13f&lt;br /&gt;
vmnic Info (Label) : Network adapter 1&lt;br /&gt;
vmnic Info (Label) : Network adapter 2&lt;br /&gt;
vmnic Info (Label) : Network adapter 3&lt;br /&gt;
vmnic Info (Label) : Network adapter 4&lt;br /&gt;
Success: VM Reconfiguration&lt;br /&gt;
Successfully changed the portgroup for the vmnic adapters&lt;br /&gt;
&lt;p /&gt;
################################################################################&lt;br /&gt;
&lt;br /&gt;
Case 3:&lt;br /&gt;
Print the VMNic details (name, and the port group it is connected to)&lt;br /&gt;
&lt;p /&gt;
Input:&lt;br /&gt;
&lt;a class="jive-link-external" href="https://10.20.140.47/sdk"&gt;https://10.20.140.47/sdk&lt;/a&gt; root password vMATemplate_vMAClone1 print&lt;br /&gt;
&lt;p /&gt;
Output:&lt;br /&gt;
&lt;br /&gt;
VM Name: vMATemplate_vMAClone1&lt;br /&gt;
MOR Type : VirtualMachine&lt;br /&gt;
ObjectContent Length : 1&lt;br /&gt;
config.hardware : com.vmware.vim25.VirtualHardware@54a1587f&lt;br /&gt;
*******************************************************&lt;br /&gt;
vmnic Info (Label) : Network adapter 1&lt;br /&gt;
vmnic Port Group: VM Network&lt;br /&gt;
&lt;br /&gt;
vmnic Info (Label) : Network adapter 2&lt;br /&gt;
vmnic Port Group: VM Network&lt;br /&gt;
&lt;br /&gt;
vmnic Info (Label) : Network adapter 3&lt;br /&gt;
vmnic Port Group: VM Network&lt;br /&gt;
&lt;br /&gt;
vmnic Info (Label) : Network adapter 4&lt;br /&gt;
vmnic Port Group: VM Network&lt;br /&gt;
&lt;br /&gt;
*******************************************************&lt;br /&gt;
&lt;p /&gt;
################################################################################&lt;br /&gt;
&lt;br /&gt;
Case 4:&lt;br /&gt;
Add vmnic to a VM, and assign it to the given port group&lt;br /&gt;
&lt;br /&gt;
Input:&lt;br /&gt;
&lt;a class="jive-link-external" href="https://10.20.140.47/sdk"&gt;https://10.20.140.47/sdk&lt;/a&gt; root password vMATemplate_vMAClone1 add e1000 PGroup1&lt;br /&gt;
&lt;p /&gt;
Output:&lt;br /&gt;
&lt;br /&gt;
VM Name: vMATemplate_vMAClone1&lt;br /&gt;
MOR Type : VirtualMachine&lt;br /&gt;
Success: VM Reconfiguration&lt;br /&gt;
Successfully added a vmnic adapter to the VM&lt;br /&gt;
&lt;br /&gt;
################################################################################&lt;br /&gt;
&lt;br /&gt;
Case 5:&lt;br /&gt;
Print the VMNic details (name, and the port group it is connected to)&lt;br /&gt;
&lt;p /&gt;
Input:&lt;br /&gt;
&lt;a class="jive-link-external" href="https://10.20.140.47/sdk"&gt;https://10.20.140.47/sdk&lt;/a&gt; root password vMATemplate_vMAClone1 print&lt;br /&gt;
&lt;p /&gt;
Output:&lt;br /&gt;
&lt;br /&gt;
VM Name: vMATemplate_vMAClone1&lt;br /&gt;
MOR Type : VirtualMachine&lt;br /&gt;
ObjectContent Length : 1&lt;br /&gt;
config.hardware : com.vmware.vim25.VirtualHardware@ee6e956&lt;br /&gt;
*******************************************************&lt;br /&gt;
vmnic Info (Label) : Network adapter 1&lt;br /&gt;
vmnic Port Group: VM Network&lt;br /&gt;
&lt;br /&gt;
vmnic Info (Label) : Network adapter 2&lt;br /&gt;
vmnic Port Group: VM Network&lt;br /&gt;
&lt;br /&gt;
vmnic Info (Label) : Network adapter 3&lt;br /&gt;
vmnic Port Group: VM Network&lt;br /&gt;
&lt;br /&gt;
vmnic Info (Label) : Network adapter 4&lt;br /&gt;
vmnic Port Group: VM Network&lt;br /&gt;
&lt;br /&gt;
vmnic Info (Label) : Network adapter 5&lt;br /&gt;
vmnic Port Group: PGroup1&lt;br /&gt;
&lt;br /&gt;
*******************************************************&lt;br /&gt;
&lt;p /&gt;
################################################################################&lt;br /&gt;
&lt;br /&gt;
Case 6:&lt;br /&gt;
Remove vmnic from a VM&lt;br /&gt;
&lt;br /&gt;
Input:&lt;br /&gt;
&lt;a class="jive-link-external" href="https://10.20.140.47/sdk"&gt;https://10.20.140.47/sdk&lt;/a&gt; root password vMATemplate_vMAClone1 remove "Network adapter 5"&lt;br /&gt;
&lt;p /&gt;
Output:&lt;br /&gt;
&lt;br /&gt;
VM Name: vMATemplate_vMAClone1&lt;br /&gt;
MOR Type : VirtualMachine&lt;br /&gt;
ObjectContent Length : 1&lt;br /&gt;
config.hardware : com.vmware.vim25.VirtualHardware@54a1587f&lt;br /&gt;
vmnic Info (Label) : Network adapter 1&lt;br /&gt;
vmnic Info (Label) : Network adapter 2&lt;br /&gt;
vmnic Info (Label) : Network adapter 3&lt;br /&gt;
vmnic Info (Label) : Network adapter 4&lt;br /&gt;
&lt;p /&gt;
################################################################################&lt;br /&gt;
&lt;br /&gt;
Case 7:&lt;br /&gt;
Print the VMNic details (name, and the port group it is connected to)&lt;br /&gt;
&lt;p /&gt;
Input:&lt;br /&gt;
&lt;a class="jive-link-external" href="https://10.20.140.47/sdk"&gt;https://10.20.140.47/sdk&lt;/a&gt; root password vMATemplate_vMAClone1 print&lt;br /&gt;
&lt;p /&gt;
Output:&lt;br /&gt;
&lt;br /&gt;
VM Name: vMATemplate_vMAClone1&lt;br /&gt;
MOR Type : VirtualMachine&lt;br /&gt;
ObjectContent Length : 1&lt;br /&gt;
config.hardware : com.vmware.vim25.VirtualHardware@54a1587f&lt;br /&gt;
*******************************************************&lt;br /&gt;
vmnic Info (Label) : Network adapter 1&lt;br /&gt;
vmnic Port Group: VM Network&lt;br /&gt;
&lt;br /&gt;
vmnic Info (Label) : Network adapter 2&lt;br /&gt;
vmnic Port Group: VM Network&lt;br /&gt;
&lt;br /&gt;
vmnic Info (Label) : Network adapter 3&lt;br /&gt;
vmnic Port Group: VM Network&lt;br /&gt;
&lt;br /&gt;
vmnic Info (Label) : Network adapter 4&lt;br /&gt;
vmnic Port Group: VM Network&lt;br /&gt;
&lt;br /&gt;
*******************************************************</description>
      <category domain="http://communities.vmware.com/tags?communityID=3079">networking</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">network</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">vm_operations</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">general</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">nic</category>
      <pubDate>Mon, 14 Sep 2009 20:58:28 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10742</guid>
      <dc:date>2009-09-14T20:58:28Z</dc:date>
      <clearspace:dateToText>2 months, 1 week ago</clearspace:dateToText>
    </item>
    <item>
      <title>executeCommandUsingFastPass.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10730</link>
      <description>Execute vCLI/vSphere SDK for Perl scripts utilizing VMware vMA/VIMA vi-fastpass without user interaction or issuing &lt;b&gt;vifpinit&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Setup:&lt;/b&gt;&lt;br /&gt;
Here is the input file which contains the list of ESX(i) hosts that are being managed by VIMA/vMA&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ cat hostlist
lazarus.primp-industries.com
kang.primp-industries.com

&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
Here is just a dummy conf that is read in because of the default parsing/validation that is required for some of the perl modules that are written by default&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ cat DUMMY_CONF
VI_USERNAME=dummy
VI_PASSWORD=dummy

&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
Execute a vSphere SDK for Perl utility called &lt;b&gt;viversion.pl&lt;/b&gt; across set of hosts:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./executeCommandUsingFastPass.pl --hostlist hostlist --config DUMMY_CONF
Executing viversion.pl on Server: lazarus.primp-industries.com 
================ RESULTS ================

This is  HostAgent 4.0

This is VMware ESX 4.0.0 build-164009 running on x86 ESX Server microkernel
The product Line ID is a unique identifier for a product line. This is VMware ESX Server product.

Short form of the product name is VMware ESX having version 4.0.0

System is running on x86 ESX Server microkernel


Executing viversion.pl on Server: kang.primp-industries.com
================ RESULTS ================

This is  HostAgent 2.5u2

This is VMware ESX Server 3i 3.5.0 build-110271 running on x86 ESX Server microkernel
The product Line ID is a unique identifier for a product line. product line id is embeddedEsx
Short form of the product name is VMware ESX Server 3i having version 3.5.0

System is running on x86 ESX Server microkernel

&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
You can easily modify the script to execute additional commands or even write directly to the vSphere SDK for Perl and use the fastpass credentials to connect to your hosts.</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">host_operation</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vifpinit</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vifp</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vma</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vima</category>
      <pubDate>Sat, 12 Sep 2009 18:15:13 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10730</guid>
      <dc:date>2009-09-12T18:15:13Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>getDatastoreUUID.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10706</link>
      <description>Retrieve datastore UUID from either ESX(i) host or vCenter.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt;&lt;br /&gt;
ESX(i) 3.5 or 4.0&lt;br /&gt;
vCenter 2.5 or 4.0&lt;br /&gt;
vSphere SDK for Perl or vMA 4.0&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./getDatastoreUUID.pl --server himalaya.primp-industries.com --username root --datastore himalaya-local-SAS.Constellation
Enter password:

Datastore: himalaya-local-SAS.Constellation     UUID: 4a30b278-33269041-4a07-003048d9586a

&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">storage</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">host_operation</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">datastore</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">uuid</category>
      <pubDate>Fri, 11 Sep 2009 03:00:10 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10706</guid>
      <dc:date>2009-09-11T03:00:10Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
      <clearspace:replyCount>1</clearspace:replyCount>
    </item>
    <item>
      <title>Host Profile Manager</title>
      <link>http://communities.vmware.com/docs/DOC-10720</link>
      <description />
      <category domain="http://communities.vmware.com/tags?communityID=3079">host_profiles</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">manager</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">java</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">general</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">vm_operations</category>
      <pubDate>Thu, 10 Sep 2009 22:10:07 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10720</guid>
      <dc:date>2009-09-10T22:10:07Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>getWWPN.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10687</link>
      <description>Script to extract WWPN from you vmhba's provided a list of ESX(i) hosts. This script could be re-written to query from a specific ESX(i) host but currently requires host to be connected and managed by vCenter. Useful script if you need to re-zone existing or new hosts&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt;&lt;br /&gt;
ESX(i) 3.5 or 4.0&lt;br /&gt;
vCenter 2.5 or 4.0&lt;br /&gt;
vSphere SDK for Perl or vMA 4.0&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
Input file which contains the list of ESX(i) hosts that is currently being managed by vCenter&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ cat hosts
helga.primp-industries.com
bertha.primp-industries.com

&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;p /&gt;
Execute script against your vCenter that is managing the list of ESX(i) hosts&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./getWWPN.pl --server refelex.primp-industries.com --username primp --list hosts
Enter password:

helga.primp-industries.com-vmhba1    10:00:00:00:c9:79:c9:84
helga.primp-industries.com-vmhba2    10:00:00:00:c9:79:c9:85
bertha.primp-industries.com-vmhba1    10:00:00:00:c9:7d:74:e8
bertha.primp-industries.com-vmhba2    10:00:00:00:c9:7d:74:e9 

&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">wwpn</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">hba</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">configuration</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">host_operation</category>
      <pubDate>Wed, 09 Sep 2009 20:47:34 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10687</guid>
      <dc:date>2009-09-09T20:47:34Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>Server Hardware Health Monitoring - How to retrieve Health information using CIM / Perl</title>
      <link>http://communities.vmware.com/docs/DOC-10643</link>
      <description>&lt;a class="jive-link-external" href="http://communities.vmware.com/docs/DOC-10665"&gt;http://communities.vmware.com/docs/DOC-10665&lt;/a&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">configuration</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">troubleshooting</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">general</category>
      <pubDate>Thu, 03 Sep 2009 14:36:56 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10643</guid>
      <dc:date>2009-09-03T14:36:56Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>Service status and email if down (as well as try to start it)</title>
      <link>http://communities.vmware.com/docs/DOC-10641</link>
      <description>Here is a script I sorta came up with that checks common vmware services and then emails if any one of them aren't running (and trys to start them)(since our vsphere upgrade bombed a few times thanks to sql i was asked to try to write this), I am sure this has been done before and bits where taking from another place that I can't find again to give credit, so its not all mine, but somone might find this usefull, write back with questions or comments&lt;br /&gt;
&lt;br /&gt;
Thanks!&lt;br /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;br /&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3077">service</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">script</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">powershell</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">email</category>
      <pubDate>Mon, 31 Aug 2009 19:48:03 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10641</guid>
      <dc:date>2009-08-31T19:48:03Z</dc:date>
      <clearspace:dateToText>2 months, 3 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>getVMsResourcePools.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10637</link>
      <description>This script extracts all the &lt;b&gt;Resource Pools&lt;/b&gt; for a given ESX(i) host or vCenter and provides a list of VMs under each resource pool. If you're not using any resource pools, then all VMs under a given host will be mapped to the root resource pool which is just called &lt;u&gt;&lt;b&gt;Resources&lt;/b&gt;&lt;/u&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt;&lt;br /&gt;
ESX(i) 3.5 or 4.0&lt;br /&gt;
vCenter 2.5 or 4.0&lt;br /&gt;
vSphere SDK for Perl or vMA 4.0&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./getVMsResourcePools.pl --server reflex.primp-industries.com --username primp
Enter password:
Resource Pools:

Production -
        vm2
        sap2
        exchange2

Proof Of Concept -
        vm1
        sap1
        exchange1

Resources -
        vm01
        vm02
        vm03
        vm04
&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <pubDate>Mon, 31 Aug 2009 02:35:03 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10637</guid>
      <dc:date>2009-08-31T02:35:03Z</dc:date>
      <clearspace:dateToText>2 months, 3 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>Retrieving Performance Statistics Info</title>
      <link>http://communities.vmware.com/docs/DOC-10658</link>
      <description>This sample retrieves the performance statistics information using multi-threaded client program. It demonstrates using the best practices.&lt;br /&gt;
&lt;br /&gt;
Usage:&lt;br /&gt;
java GetMultiPerfStats &amp;lt;host&amp;gt; &amp;lt;username&amp;gt; &amp;lt;password&amp;gt; &amp;lt;EntityName:EntityType[vm|host|rp|ccr]&amp;gt; &amp;lt;PerfGroup.PerfCounter.RollupType&amp;gt; [isCSVOutput]&lt;br /&gt;
&lt;br /&gt;
################################################################################&lt;br /&gt;
&lt;br /&gt;
Case 1:&lt;br /&gt;
Retrieved the past 1 hour samples (180 samples) for two entities.&lt;br /&gt;
One VM, and one Host. The VM is running on the specified Host.&lt;br /&gt;
All Perf stats are retrieved for each entity in one call, and for all entities&lt;br /&gt;
in one call. The times are recorded in both the cases.&lt;br /&gt;
&lt;br /&gt;
Input:&lt;br /&gt;
&lt;a class="jive-link-external" href="https://10.20.140.70/sdk"&gt;https://10.20.140.70/sdk&lt;/a&gt; Administrator password ITSM701:vm,rkoganty-dev1.eng.vmware.com:host cpu,mem,net,disk,cpu.usagemhz.average,mem.overhead.average,net.packetsRx.summation,net.packetsTx.summation true&lt;br /&gt;
&lt;br /&gt;
Output:&lt;br /&gt;
&lt;br /&gt;
MOR Type : VirtualMachine&lt;br /&gt;
&lt;hr /&gt;
Managed entity: vm-27&lt;br /&gt;
Current supported: true&lt;br /&gt;
Refresh rate: 20&lt;br /&gt;
Summary supported: true&lt;br /&gt;
&lt;hr /&gt;
PerfCountersArr length: 8&lt;br /&gt;
&lt;hr /&gt;
Time for all perf query specs are in one array for one entity&lt;br /&gt;
&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;
&lt;li&gt;One entity Thread start time: 1251408083890 ms&lt;/li&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
MOR Type : HostSystem&lt;br /&gt;
&lt;hr /&gt;
Managed entity: host-10&lt;br /&gt;
Current supported: true&lt;br /&gt;
Refresh rate: 20&lt;br /&gt;
Summary supported: true&lt;br /&gt;
&lt;hr /&gt;
$$$$$$$$$$$$$$$ Total time for the perf stats query: 576 ms&lt;br /&gt;
PerfQuerySpec Arr Length: 8&lt;br /&gt;
PerfEntityMetricBase array length: 8&lt;br /&gt;
PerfCountersArr length: 8&lt;br /&gt;
&lt;hr /&gt;
Time for all perf query specs are in one array for one entity&lt;br /&gt;
&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;
&lt;li&gt;One entity Thread start time: 1251408084706 ms&lt;/li&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;hr /&gt;
Cumulative time for all entities when all perf query specs are in one array&lt;br /&gt;
%%%%%%%%%%%%%%% Cumulative Thread start time: 1251408084706 ms&lt;br /&gt;
$$$$$$$$$$$$$$$ Total time for the perf stats query: 654 ms&lt;br /&gt;
PerfQuerySpec Arr Length: 8&lt;br /&gt;
PerfEntityMetricBase array length: 8&lt;br /&gt;
$$$$$$$$$$$$$$$ Total time for the perf stats query: 1005 ms&lt;br /&gt;
PerfQuerySpec Arr Length: 16&lt;br /&gt;
PerfEntityMetricBase array length: 16&lt;br /&gt;
&lt;br /&gt;
################################################################################&lt;br /&gt;
&lt;br /&gt;
Case 2:&lt;br /&gt;
Retrieved the past 1 hour samples (180 samples) for three entities.&lt;br /&gt;
One VM, and two Hosts. The VM is running on one of the specified Hosts.&lt;br /&gt;
All Perf stats are retrieved for each entity in one call, and for all entities&lt;br /&gt;
in one call. The times are recorded in both the cases.&lt;br /&gt;
&lt;br /&gt;
Input:&lt;br /&gt;
&lt;a class="jive-link-external" href="https://10.20.140.70/sdk"&gt;https://10.20.140.70/sdk&lt;/a&gt; Administrator password ITSM701:vm,rkoganty-dev1.eng.vmware.com:host,10.17.204.255:host cpu,mem,net,disk,cpu.usagemhz.average,mem.overhead.average,net.packetsRx.summation,net.packetsTx.summation true&lt;br /&gt;
&lt;br /&gt;
Output:&lt;br /&gt;
&lt;br /&gt;
MOR Type : VirtualMachine&lt;br /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;hr /&gt;
Managed entity: vm-27&lt;br /&gt;
Current supported: true&lt;br /&gt;
Refresh rate: 20&lt;br /&gt;
Summary supported: true&lt;br /&gt;
&lt;hr /&gt;
PerfCountersArr length: 8&lt;br /&gt;
&lt;hr /&gt;
Time for all perf query specs are in one array for one entity&lt;br /&gt;
&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;
&lt;li&gt;One entity Thread start time: 1251408272940 ms&lt;/li&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
MOR Type : HostSystem&lt;br /&gt;
&lt;hr /&gt;
Managed entity: host-46&lt;br /&gt;
Current supported: true&lt;br /&gt;
Refresh rate: 20&lt;br /&gt;
Summary supported: true&lt;br /&gt;
&lt;hr /&gt;
$$$$$$$$$$$$$$$ Total time for the perf stats query: 548 ms&lt;br /&gt;
PerfQuerySpec Arr Length: 8&lt;br /&gt;
PerfEntityMetricBase array length: 8&lt;br /&gt;
PerfCountersArr length: 8&lt;br /&gt;
&lt;hr /&gt;
Time for all perf query specs are in one array for one entity&lt;br /&gt;
&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;
&lt;li&gt;One entity Thread start time: 1251408273791 ms&lt;/li&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
MOR Type : HostSystem&lt;br /&gt;
&lt;hr /&gt;
Managed entity: host-10&lt;br /&gt;
Current supported: true&lt;br /&gt;
Refresh rate: 20&lt;br /&gt;
Summary supported: true&lt;br /&gt;
&lt;hr /&gt;
PerfCountersArr length: 8&lt;br /&gt;
&lt;hr /&gt;
Time for all perf query specs are in one array for one entity&lt;br /&gt;
&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;

&lt;ol&gt;
&lt;li&gt;One entity Thread start time: 1251408274503 ms&lt;/li&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;/ol&gt;
&lt;hr /&gt;
Cumulative time for all entities when all perf query specs are in one array&lt;br /&gt;
%%%%%%%%%%%%%%% Cumulative Thread start time: 1251408274504 ms&lt;br /&gt;
$$$$$$$$$$$$$$$ Total time for the perf stats query: 1200 ms&lt;br /&gt;
PerfQuerySpec Arr Length: 8&lt;br /&gt;
PerfEntityMetricBase array length: 8&lt;br /&gt;
$$$$$$$$$$$$$$$ Total time for the perf stats query: 612 ms&lt;br /&gt;
PerfQuerySpec Arr Length: 8&lt;br /&gt;
PerfEntityMetricBase array length: 8&lt;br /&gt;
$$$$$$$$$$$$$$$ Total time for the perf stats query: 2255 ms&lt;br /&gt;
PerfQuerySpec Arr Length: 24&lt;br /&gt;
PerfEntityMetricBase array length: 24</description>
      <category domain="http://communities.vmware.com/tags?communityID=3079">performance</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">troubleshooting</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">java</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">retrieve</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">statistics</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">information</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">info</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">multi-threaded</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">client</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">program</category>
      <pubDate>Fri, 28 Aug 2009 23:04:59 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10658</guid>
      <dc:date>2009-08-28T23:04:59Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>Monitor Properties using View Object</title>
      <link>http://communities.vmware.com/docs/DOC-10636</link>
      <description>Here is a sample to monitor properties using&lt;br /&gt;
&lt;br /&gt;
Usage:&lt;br /&gt;
java MonitorUsingView &amp;lt;VC_SERVER&amp;gt; &amp;lt;USERNAME&amp;gt; &amp;lt;PASSWORD&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Input:&lt;br /&gt;
&lt;br /&gt;
&lt;a class="jive-link-external" href="https://10.20.140.70/sdk"&gt;https://10.20.140.70/sdk&lt;/a&gt; Administrator password&lt;br /&gt;
&lt;br /&gt;
Output:&lt;br /&gt;
&lt;br /&gt;
ObjectContent Length : 37&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-19&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-637&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-644&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-211&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-457&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-619&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-710&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-218&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-583&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-639&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-891&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-137&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-16&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-222&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-231&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-659&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-633&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-889&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-893&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-203&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-215&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-220&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-27&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-362&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-641&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-229&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-635&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-226&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-592&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-667&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-144&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-224&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-606&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-896&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-883&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-899&lt;br /&gt;
MOR TYPE: VirtualMachine --- vm-201&lt;br /&gt;
&lt;br /&gt;
vmFilter : PropertyFilter : session[F55668BA-5579-4BD2-8C55-E68007649237]3D8120DC-BF13-4A29-B386-E794CB59C5C1&lt;br /&gt;
Update received: 1&lt;br /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;hr /&gt;
Filter val: PropertyFilter : session[F55668BA-5579-4BD2-8C55-E68007649237]3D8120DC-BF13-4A29-B386-E794CB59C5C1&lt;br /&gt;
VirtualMachine : DevVM&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: DevVM&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOn&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : Reflex VMC&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: Reflex VMC&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOn&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : vCenterOrchestrator_4_0_0_4386&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: vCenterOrchestrator_4_0_0_4386&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOn&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : RemedyITSMTemplate701&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: RemedyITSMTemplate701&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : NostalgiaTemplate&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: NostalgiaTemplate&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : win-2k3-32-ent-sp2-esx3_1&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: win-2k3-32-ent-sp2-esx3_1&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : Nost1&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: Nost1&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : Nost4&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: Nost4&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : N4_Temp&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: N4_Temp&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : linuxVM-Raju&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: linuxVM-Raju&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : NostTemplate&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: NostTemplate&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : RHEL-5-Server-32bit-GOS1&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: RHEL-5-Server-32bit-GOS1&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOn&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : Nost3&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: Nost3&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOn&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : win2k3-32-ent-sp2-temp&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: win2k3-32-ent-sp2-temp&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : lcm-071&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: lcm-071&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : test1&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: test1&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : test2&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: test2&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : linuxVM-200&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: linuxVM-200&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : LCM_1_0_1_3668&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: LCM_1_0_1_3668&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : ubuntu-710-1&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: ubuntu-710-1&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : win-2k3-32-ent-sp2-esx3&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: win-2k3-32-ent-sp2-esx3&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOn&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : SMI-S_RLCI_Appliance_Beta2&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: SMI-S_RLCI_Appliance_Beta2&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : N1&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: N1&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOn&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : SecurityAppliance1&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: SecurityAppliance1&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : vmxnet3-test&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: vmxnet3-test&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOn&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : Win2k3_32Template&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: Win2k3_32Template&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : ubuntu-710-2&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: ubuntu-710-2&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : RHEL-5-Server-32bit-GOS2&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: RHEL-5-Server-32bit-GOS2&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOn&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : BLR-win2k3-32&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: BLR-win2k3-32&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : BMC_Remedy_ITSM701&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: BMC_Remedy_ITSM701&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOn&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : N_T&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: N_T&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : linuxVM-201&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: linuxVM-201&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : VC4&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: VC4&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : Unknown&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: Unknown&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : XSA2&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: XSA2&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : Nost2&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: Nost2&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
VirtualMachine : AltorVMSafeTemplate&lt;br /&gt;
Property Name: name&lt;br /&gt;
Property Val: AltorVMSafeTemplate&lt;br /&gt;
&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
&lt;hr /&gt;
Update received: 2&lt;br /&gt;
&lt;br /&gt;
&lt;hr /&gt;
Filter val: PropertyFilter : session[F55668BA-5579-4BD2-8C55-E68007649237]3D8120DC-BF13-4A29-B386-E794CB59C5C1&lt;br /&gt;
VirtualMachine : N1&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOff&lt;br /&gt;
&lt;br /&gt;
&lt;hr /&gt;
Update received: 3&lt;br /&gt;
&lt;br /&gt;
&lt;hr /&gt;
Filter val: PropertyFilter : session[F55668BA-5579-4BD2-8C55-E68007649237]3D8120DC-BF13-4A29-B386-E794CB59C5C1&lt;br /&gt;
VirtualMachine : N1&lt;br /&gt;
Property Name: runtime.powerState&lt;br /&gt;
Property Val: poweredOn&lt;br /&gt;
&lt;br /&gt;
&lt;hr /&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3079">monitor_properties</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">general</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">view</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">object</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">java</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">troubleshooting</category>
      <pubDate>Fri, 28 Aug 2009 18:17:10 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10636</guid>
      <dc:date>2009-08-28T18:17:10Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>factoryResetESXi.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10651</link>
      <description>Read a pretty interesting &lt;a class="jive-link-external" href="http://www.rtfm-ed.co.uk/?p=1671"&gt;article&lt;/a&gt; by &lt;a class="jive-link-external" href="http://www.rtfm-ed.co.uk/"&gt;Mike Laverick&lt;/a&gt; this morning regarding factory resetting ESXi systems, here is a Perl script that does the same thing. (note, in the current form of the script, it requires ESXi host to be managed by vMA. The reason for this is that additional credentials do not need to be specify)&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt; &lt;br /&gt;
vCenter 2.5 or vCenter 4.0&lt;br /&gt;
ESXi 3.5 or 4.0&lt;br /&gt;
vMA 4.0&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./factoryResetESXi.pl --server reflex.primp-industries.com --username primp --vihost kang.primp-industries.com
Enter password:
&amp;quot;kang.primp-industries.com&amp;quot; is entering maintenance mode ...
        &amp;quot;kang.primp-industries.com&amp;quot; has successfully entered maintenance mode!
Removing &amp;quot;kang.primp-industries.com&amp;quot; from vCenter ...
        &amp;quot;kang.primp-industries.com&amp;quot; has successfully been remove from vCenter!
Resetting factory settings on &amp;quot;kang.primp-industries.com&amp;quot;!
&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">configuration</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">esxi_4</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">esxi_3.5</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">esxi_reset</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">factory_reset</category>
      <pubDate>Fri, 28 Aug 2009 17:08:51 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10651</guid>
      <dc:date>2009-08-28T17:08:51Z</dc:date>
      <clearspace:dateToText>3 months, 1 hour ago</clearspace:dateToText>
    </item>
    <item>
      <title>To mount LVM Volumes</title>
      <link>http://communities.vmware.com/docs/DOC-10616</link>
      <description>&lt;a class="jive-link-external" href="http://communities.vmware.com/servlet/JiveServlet/download/1359583-28031/VMware%20Contributed%20Sample%20Code.pdf"&gt;VMware Contributed Sample Code Disclaimer&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
Below are the attached two simple scripts to show how you can use vmware-mount on Linux to open LVM volumes. &lt;br /&gt;
&lt;br /&gt;
lvmMount.sh is a barebones script to mount lvm disks. Basic idea is&lt;br /&gt;
simple, vmware-mount on Linux allows you to mount a VMDK in flat mode.&lt;br /&gt;
Using this, we mount all the disks in an LVM physical group in flat&lt;br /&gt;
mode. We can then use LVM to scan for volume groups, activate the&lt;br /&gt;
volume group of interest and mount the volume. &lt;br /&gt;
&lt;br /&gt;
lvmCreate.sh is another barebones script to test the lvmMount.sh. It&lt;br /&gt;
creates 2 disks, makes a group out of these, creates a volume, mounts&lt;br /&gt;
it and copies a test file into the volume. &lt;br /&gt;
&lt;br /&gt;
I have hardcoded many parameters and removed any error checking to show&lt;br /&gt;
the sequence of commands. I don't claim to be a Linux/Scripting expert,&lt;br /&gt;
please feel free to comment.&lt;br /&gt;
&lt;br /&gt;
Sample Code: &lt;a class="jive-link-blogpost" href="http://communities.vmware.com/blogs/sudarsan/2009/02/05/sample-script-to-mount-lvm-volumes"&gt;http://communities.vmware.com/blogs/sudarsan/2009/02/05/sample-script-to-mount-lvm-volumes&lt;/a&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3233">lvm</category>
      <category domain="http://communities.vmware.com/tags?communityID=3233">volumes</category>
      <category domain="http://communities.vmware.com/tags?communityID=3233">sample_code</category>
      <category domain="http://communities.vmware.com/tags?communityID=3233">vddk</category>
      <category domain="http://communities.vmware.com/tags?communityID=3233">mount</category>
      <pubDate>Wed, 26 Aug 2009 17:14:05 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10616</guid>
      <dc:date>2009-08-26T17:14:05Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>How to quarantine a VM using VIX and VDDK?</title>
      <link>http://communities.vmware.com/docs/DOC-10615</link>
      <description>&lt;a class="jive-link-external" href="http://communities.vmware.com/servlet/JiveServlet/download/1359583-28031/VMware%20Contributed%20Sample%20Code.pdf"&gt;VMware Contributed Sample Code Disclaimer&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
The attached sample code shows off the integration between VIX and&lt;br /&gt;
VDDK (VixDiskLib and vmware-mount). The sample is fairly complex,&lt;br /&gt;
showing the usecase of quantining a workstation VM.&lt;br /&gt;
&lt;br /&gt;
Here is what this sample does:&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;Read and analyze the MBR of the primary disk&lt;/li&gt;
&lt;li&gt;Read boot.ini from the active partition - deterime and mount the boot volume&lt;/li&gt;
&lt;li&gt;Copy the system hive and  determine the mounted drives&lt;/li&gt;
&lt;li&gt;'Scan'  the  drives to 'find' an infected file&lt;/li&gt;
&lt;li&gt;Quarentine the VM by removing the network device from VMX&lt;/li&gt;
&lt;li&gt;Power On the VM and Delete the files using VIX api&lt;/li&gt;
&lt;li&gt;Power off the VM and restore back the original configuration&lt;/li&gt;
&lt;/ul&gt;
&lt;br /&gt;
Sample Code: &lt;a class="jive-link-blogpost" href="http://communities.vmware.com/blogs/sudarsan/2009/01/21/sample-code-showing-how-to-quarantine-a-vm-using-vix-and-vddk"&gt;http://communities.vmware.com/blogs/sudarsan/2009/01/21/sample-code-showing-how-to-quarantine-a-vm-using-vix-and-vddk&lt;/a&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3233">vm</category>
      <category domain="http://communities.vmware.com/tags?communityID=3233">vix</category>
      <category domain="http://communities.vmware.com/tags?communityID=3233">vddk</category>
      <category domain="http://communities.vmware.com/tags?communityID=3233">quarantine</category>
      <pubDate>Wed, 26 Aug 2009 17:12:26 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10615</guid>
      <dc:date>2009-08-26T17:12:26Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>Extracting and modifying Disk Signature</title>
      <link>http://communities.vmware.com/docs/DOC-10614</link>
      <description>&lt;a class="jive-link-external" href="http://communities.vmware.com/servlet/JiveServlet/download/1359583-28031/VMware%20Contributed%20Sample%20Code.pdf"&gt;VMware Contributed Sample Code Disclaimer&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
The attahced sample code shows how to use VDDK to extract disk signature and possibly modify it - both in managed and hosted scenarios. &lt;br /&gt;
&lt;br /&gt;
Hopefully, you will find them useful. Note that this is sample code to show how to work with VDDK and not meant for direct use in your production code. &lt;br /&gt;
&lt;p /&gt;
Sample Code: &lt;a class="jive-link-blogpost" href="http://communities.vmware.com/blogs/sudarsan/2009/01/21/new-sample-code-for-vddk"&gt;http://communities.vmware.com/blogs/sudarsan/2009/01/21/new-sample-code-for-vddk&lt;/a&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3233">extract</category>
      <category domain="http://communities.vmware.com/tags?communityID=3233">modify</category>
      <category domain="http://communities.vmware.com/tags?communityID=3233">disk</category>
      <category domain="http://communities.vmware.com/tags?communityID=3233">signature</category>
      <category domain="http://communities.vmware.com/tags?communityID=3233">vddk</category>
      <category domain="http://communities.vmware.com/tags?communityID=3233">managed</category>
      <category domain="http://communities.vmware.com/tags?communityID=3233">hosted</category>
      <pubDate>Wed, 26 Aug 2009 17:07:33 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10614</guid>
      <dc:date>2009-08-26T17:07:33Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>Using vmware-mount to mount disks on ESX / VC</title>
      <link>http://communities.vmware.com/docs/DOC-10606</link>
      <description>&lt;a class="jive-link-external" href="http://communities.vmware.com/servlet/JiveServlet/download/1359583-28031/VMware%20Contributed%20Sample%20Code.pdf"&gt;VMware Contributed Sample Code Disclaimer&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
How to use vmware-mount to mount disks on esx / vc seems to be a&lt;br /&gt;
frequent question. I attached 2 pictures here to show the usage.&lt;br /&gt;
Hopefully, these help. &lt;br /&gt;
&lt;br /&gt;
A couple of points to note: &lt;br /&gt;
&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;ha-datacenter is the data center name for any ESX. You can see this also in the Managed Object Viewer. ([/]&amp;lt;esx address&amp;gt;/mob/?moid=ha-datacenter)&lt;/li&gt;
&lt;li&gt;The inventory path can just be read off the VC client display (set &lt;br clear="all" /&gt;			 	the display mode to Virtual Machines &amp;#38; Templates) - insert "/vm" &lt;br clear="all" /&gt;			 	just after the datacenter name.&lt;/li&gt;
&lt;/ul&gt;
&lt;br /&gt;
Sample Code: &lt;a class="jive-link-blogpost" href="http://communities.vmware.com/blogs/sudarsan/2009/01/14/using-vmwaremount-to-mount-disks-on-esx-vc"&gt;http://communities.vmware.com/blogs/sudarsan/2009/01/14/using-vmwaremount-to-mount-disks-on-esx-vc&lt;/a&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3233">mount</category>
      <category domain="http://communities.vmware.com/tags?communityID=3233">vmware-mounts</category>
      <category domain="http://communities.vmware.com/tags?communityID=3233">vmware_mounts</category>
      <category domain="http://communities.vmware.com/tags?communityID=3233">disks</category>
      <pubDate>Wed, 26 Aug 2009 00:34:49 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10606</guid>
      <dc:date>2009-08-26T00:34:49Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>Manage Disk Load Hive</title>
      <link>http://communities.vmware.com/docs/DOC-10605</link>
      <description>&lt;a class="jive-link-external" href="http://communities.vmware.com/servlet/JiveServlet/download/1359583-28031/VMware%20Contributed%20Sample%20Code.pdf"&gt;VMware Contributed Sample Code Disclaimer&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
The attached sample code shows how to work with VDDK and VIM apis together. &lt;br /&gt;
&lt;br /&gt;
It uses C# to call the VI methods to get disk details, mount the system volume and load a registry hive.&lt;br /&gt;
&lt;p /&gt;
&lt;br /&gt;
Note that the sample only handles basic disk - also it is meant to show the VDDK api's working with VI api's, not meant for use in production code.&lt;br /&gt;
&lt;p /&gt;
&lt;br /&gt;
Sample Code: &lt;a class="jive-link-blogpost" href="http://communities.vmware.com/blogs/sudarsan/2009/01/21/more-sample-code"&gt;http://communities.vmware.com/blogs/sudarsan/2009/01/21/more-sample-code&lt;/a&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3233">manage</category>
      <category domain="http://communities.vmware.com/tags?communityID=3233">disk</category>
      <category domain="http://communities.vmware.com/tags?communityID=3233">vddk</category>
      <category domain="http://communities.vmware.com/tags?communityID=3233">vim</category>
      <category domain="http://communities.vmware.com/tags?communityID=3233">apis</category>
      <category domain="http://communities.vmware.com/tags?communityID=3233">disk_details</category>
      <category domain="http://communities.vmware.com/tags?communityID=3233">mount</category>
      <category domain="http://communities.vmware.com/tags?communityID=3233">registry_hive</category>
      <category domain="http://communities.vmware.com/tags?communityID=3233">hive</category>
      <pubDate>Wed, 26 Aug 2009 00:19:44 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10605</guid>
      <dc:date>2009-08-26T00:19:44Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>listAllDatastoresInCluster.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10612</link>
      <description>List all datastores for a given vCenter cluster.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt;&lt;br /&gt;
vCenter 2.5 / 4.0&lt;br /&gt;
ESX(i) 3.5 / 4.0&lt;br /&gt;
vSphere SDK for Perl or vMA 4.0&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@optimus]$ ./listAllDatastoresInCluster.pl --server teletron1.primp-industries.com --username primp --cluster autobots
This could take a few minutes depending on the size of the cluster ...

Cluster: autobots
        megatron-local-storage-1
        jetfire-local-storage-1
        sideswipe-local-storage-1
        sideswipe-local-storage-2
&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">cluster</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">datastore</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">list</category>
      <pubDate>Mon, 24 Aug 2009 20:57:18 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10612</guid>
      <dc:date>2009-08-24T20:57:18Z</dc:date>
      <clearspace:dateToText>3 months, 3 days ago</clearspace:dateToText>
    </item>
    <item>
      <title>Number of vCPUs in a cluster</title>
      <link>http://communities.vmware.com/docs/DOC-10565</link>
      <description>&lt;br /&gt;
Inspired by Jason Boche&amp;rsquo;s article: &lt;a class="jive-link-external" href="http://www.boche.net/blog/index.php/2009/08/18/hidden-virtual-cpu-limit-restriction-in-esx-3-5/"&gt;http://www.boche.net/blog/index.php/2009/08/18/hidden-virtual-cpu-limit-restriction-in-esx-3-5/&lt;/a&gt; and also William Lam&amp;rsquo;s Perl Script (&lt;a class="jive-link-wiki" href="http://communities.vmware.com/docs/DOC-10556"&gt;http://communities.vmware.com/docs/DOC-10556&lt;/a&gt;).  I decided to re-create this in PowerCLI.&lt;br /&gt;
&lt;p /&gt;
More information can be found here: &lt;a class="jive-link-external" href="http://www.virtu-al.net/2009/08/20/powercli-number-of-vcpus-in-a-cluster/"&gt;http://www.virtu-al.net/2009/08/20/powercli-number-of-vcpus-in-a-cluster/&lt;/a&gt;&lt;br /&gt;
&lt;p /&gt;
&lt;br /&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3077">cluster</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">vmservers</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">powershell</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">vm</category>
      <pubDate>Thu, 20 Aug 2009 21:13:42 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10565</guid>
      <dc:date>2009-08-20T21:13:42Z</dc:date>
      <clearspace:dateToText>3 months, 1 week ago</clearspace:dateToText>
    </item>
    <item>
      <title>renameLocalStorageDatastore.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10571</link>
      <description>Have a bunch of ESX(i) hosts in vCenter? When you view their datastores, do you see a bunch of &lt;b&gt;localstorage (x)&lt;/b&gt; ? Would you like to rename it to something more useful like which local storage it belongs to? This script is for you!&lt;br /&gt;
&lt;br /&gt;
&lt;span style="color:red"&gt;&lt;b&gt;Note:&lt;/b&gt;&lt;/span&gt; Please test this out in your environment before using.&lt;br /&gt;
&lt;br /&gt;
This script &lt;u&gt;requires&lt;/u&gt; vCenter and host(s) under a vCenter cluster and will look at all hosts datastores and find local storage and rename to the following format: "hostname-local-storage-X". It will try to use the short hostname on the ESX(i) host, but if it's not configured, it will use the ESX(i) display name and append the proper count if there are more than one local VMFS volume. There is a &lt;b&gt;just kidding mode&lt;/b&gt; which can be enabled to see what volumes it locates and show you the rename without actually executing the rename. If you set _&lt;b&gt;jk_mode&lt;/b&gt;_ to 0, the rename will execute, please run with 1 if you're not sure.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirement:&lt;/b&gt;&lt;br /&gt;
vCenter 2.5 / 4.0&lt;br /&gt;
ESX(i) 3.5 / 4.0&lt;br /&gt;
vSphere SDK for Perl or vMA 4.0&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
Just Kidding mode:&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@optimus]$ ./renameLocalStorageDatastore.pl --server teletron1.primp-industries.com --username primp --cluster autobots --jk_mode 1
This could take a few minutes depending on the size of the cluster ...

Cluster: autobots
Just Kidding Mode ENABLED! - Will not rename datastors but display what it would be renamed to

	Host: sideswipe.primp-industries.com
		Localstorage: local-storage (2)
		Rename to: [sideswipe-local-storage-1]
	Total # of local datastores on host: 1

	Host: jetfire.primp-industries.com
		Localstorage: local-storage
		Rename to: [jetfire-local-storage-1]
		Localstorage: local-storage (1)
		Rename to: [jetfire-local-storage-2]
	Total # of local datastores on host: 2
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
Rename mode:&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@optimus]$ ./renameLocalStorageDatastore.pl --server teletron1.primp-industries.com --username primp --cluster autobots --jk_mode 0
This could take a few minutes depending on the size of the cluster ...

Cluster: autobots

	Host: sideswipe.primp-industries.com
		Localstorage: local-storage (2)
		Rename to: [sideswipe-local-storage-1]
	Total # of local datastores on host: 1

	Host: jetfire.primp-industries.com
		Localstorage: local-storage
		Rename to: [jetfire-local-storage-1]
		Localstorage: local-storage (1)
		Rename to: [jetfire-local-storage-2]
	Total # of local datastores on host: 2
&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">rename_datastore</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">local_storage</category>
      <pubDate>Wed, 19 Aug 2009 22:28:33 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10571</guid>
      <dc:date>2009-08-19T22:28:33Z</dc:date>
      <clearspace:dateToText>3 months, 1 week ago</clearspace:dateToText>
    </item>
    <item>
      <title>getNumofvCPUInCluster.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10556</link>
      <description>While waiting for VUM to finish up on some new vSphere ESX 4.0 hosts, I was reading VMTN blogs and noticed this interesting article by Jason Boche: &lt;a class="jive-link-external" href="http://www.boche.net/blog/index.php/2009/08/18/hidden-virtual-cpu-limit-restriction-in-esx-3-5/"&gt;http://www.boche.net/blog/index.php/2009/08/18/hidden-virtual-cpu-limit-restriction-in-esx-3-5/&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
This script will query a specific cluster and extract out the number of vCPU for the given cluster, each individual host and the advanced configuration &lt;b&gt;Misc.RunningVCpuLimit&lt;/b&gt; set for each host. &lt;br /&gt;
&lt;br /&gt;
In ESX 3.5 as Jason pointed out the default is &lt;u&gt;128&lt;/u&gt; with maximum support of &lt;u&gt;192&lt;/u&gt; and with vSphere ESX 4.0, this has changed to default of &lt;u&gt;512&lt;/u&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirement:&lt;/b&gt;&lt;br /&gt;
VI Toolkit for Perl/vSphere SDK for Perl/VIMA 1.0/vMA 4.0&lt;br /&gt;
vCenter 2.5 / 4.0&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
On ESX 3.5:&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield]$ ./getNumofvCPUInCluster.pl --server reflex.primp-industries.com --username primp --cluster primp-cluster
This could take a few minutes depending on the size of the cluster ...

Cluster: primp-cluster
	Host: primp-esx01
		Misc.RunningVCpuLimit: 128
		# of vCPU on host: 12
	Host: primp-esx02
		Misc.RunningVCpuLimit: 128
		# of vCPU on host: 13
	Host: primp-esx03
		Misc.RunningVCpuLimit: 128
		# of vCPU on host: 16
	Host: primp-esx04
		Misc.RunningVCpuLimit: 128
		# of vCPU on host: 16
      ..........
      # of vCPU: 463
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;p /&gt;
On ESX 4.0:&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield]$ ./getNumofvCPUInCluster.pl --server mauna-loa.primp-industries.com --username primp --cluster primpProd-cluster
This could take a few minutes depending on the size of the cluster ...

Cluster: primp-cluster
	Host: primp-esx01
		Misc.RunningVCpuLimit: 512
		# of vCPU on host: 21
	Host: primp-esx02
		Misc.RunningVCpuLimit: 512
		# of vCPU on host: 22
      # of vCPU: 23
&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <pubDate>Tue, 18 Aug 2009 23:07:28 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10556</guid>
      <dc:date>2009-08-18T23:07:28Z</dc:date>
      <clearspace:dateToText>3 months, 1 week ago</clearspace:dateToText>
      <clearspace:replyCount>3</clearspace:replyCount>
    </item>
    <item>
      <title>addvSwitchWSecurityPolicy.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10555</link>
      <description>Adding a vSwitch with Security Policy such as (allowPromiscuous,forgedTransmits,macChanges) along with other vSwitch parameters (not available by default with esxcfg-vswitch -A vSwitchX)&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@simplejack.primp-industries.com]$ ./addvSwitchWSecurityPolicy.pl --server simplejack.primp-industries.com --username root --ap 1 --ft 0 --mc 1 --ports 256 --vswitch_name vSwitch2003
Enter password: 

Adding new vSwitch: &amp;quot;vSwitch2003&amp;quot; with the following conf: 
	[allowPromiscuous 1]
	[forgedTransmits 0]
	[macChanges 1]
	[ports 256]

&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">configuration</category>
      <pubDate>Tue, 18 Aug 2009 18:58:24 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10555</guid>
      <dc:date>2009-08-18T18:58:24Z</dc:date>
      <clearspace:dateToText>3 months, 1 week ago</clearspace:dateToText>
    </item>
    <item>
      <title>getVMToolsStatus.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10563</link>
      <description>Retrieves the current status of all VMs VMware Tools against vCenter or individual ESX(i).&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./getVMToolsStatus.pl --server reflex.primp-industries.com --username primp
Enter password:

Auroa   toolsNotInstalled
Bitsy   toolsNotInstalled
Certiorari      toolsNotRunning
Clifford        toolsOk
ESX-Kickstart   toolsNotInstalled
ESX3.5u4        toolsNotInstalled
ESX4-2  toolsNotInstalled
.........
&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <pubDate>Sun, 16 Aug 2009 19:36:39 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10563</guid>
      <dc:date>2009-08-16T19:36:39Z</dc:date>
      <clearspace:dateToText>3 months, 1 week ago</clearspace:dateToText>
    </item>
    <item>
      <title>getShareableAndNonSharDatastore.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10552</link>
      <description>Extract all VMs on non-sharable datastores from vCenter, also allowing granularity at datacenter or cluster level.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt;&lt;br /&gt;
vCenter 2.5.x or 4.0&lt;br /&gt;
ESX(i) 3.5 or 4.0&lt;br /&gt;
vMA 4.0&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
Querying from entire vCenter:&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./getVMonShareableAndNonSharDatastore.pl --server mauna-loa.primp-industries.com --username primp --type all
Enter password:
Datacenter: mauna-loa
        Shared Datastores:
                Datastore: [http://dlgCore-FC-LUN202.VMstorage2|http://dlgCore-FC-LUN202.VMstorage2] is VMFS with: 58 VMs
                Datastore: [http://dlgCore-FC-LUN201.VMstorage1|http://dlgCore-FC-LUN201.VMstorage1] is VMFS with: 6 VMs
                Datastore: [http://dlgCore-FC-LUN200.Templates|http://dlgCore-FC-LUN200.Templates] is VMFS with: 8 VMs
                Datastore: [http://dlgCore-FC-LUN204.VMstorage4|http://dlgCore-FC-LUN204.VMstorage4] is VMFS with: 23 VMs
                Datastore: [http://dlgCore-NFS-bigboi.VM-Backups|http://dlgCore-NFS-bigboi.VM-Backups] is NFS with: 3 VMs
                Datastore: [http://dlgCore-FC-LUN203.VMstorage3|http://dlgCore-FC-LUN203.VMstorage3] is VMFS with: 11 VMs

        Non-Shared Datastores:
                Datastore: [http://esx-1-local-SAS.Storage|http://esx-1-local-SAS.Storage] is VMFS with: 0 VMs
                Datastore: [http://esx-2-local-SAS.Storage|http://esx-2-local-SAS.Storage] is VMFS with: 0 VMs
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;p /&gt;
Querying from specific vCenter datacenter:&lt;br /&gt;
&lt;p /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./getVMonShareableAndNonSharDatastore.pl --server reflex.primp-industries.com --username primp --type datacenter --datacenter Primp   
Enter password:
Datacenter: Primp
        Shared Datastores:
                Datastore: [http://dlgCore-NFS-bigboi.VM-Backups|http://dlgCore-NFS-bigboi.VM-Backups] is NFS with: 4 VMs

        Non-Shared Datastores:
                Datastore: [simplejack-local-storage] is VMFS with: 4 VMs
                        ghettoVCB4i-test-vm-backup
                        ide-vm
                        .......
                Datastore: [kang-local-storage] is VMFS with: 0 VMs
                Datastore: [lazarus-local-storage] is VMFS with: 0 VMs
                Datastore: [http://dlgCore-iSCSI.test|http://dlgCore-iSCSI.test] is VMFS with: 0 VMs
                Datastore: [http://himalaya-local-SAS.Constellation|http://himalaya-local-SAS.Constellation] is VMFS with: 18 VMs
                        Iaorana
                        .......
                Datastore: [http://himalaya-local-SAS.Savvio|http://himalaya-local-SAS.Savvio] is VMFS with: 30 VMs
                        Fugue
                        VIMA
                        Rhapsody
                        Oxygen
                        .......
                Datastore: [himalaya-local-SATA.RE4-GP:Boot] is VMFS with: 0 VMs
                Datastore: [himalaya-local-SATA.RE4-GP:Storage] is VMFS with: 22 VMs
                        simplejack.primp-industries.com
                        lazarus.primp-industries.com
                        vMA-resize
                        ThinStation-Dev
                        ESX-Kickstart
                        primp-vapp-esx01
                        ubuntu-test
                        .......
                Datastore: [storage1] is VMFS with: 2 VMs
                        Test-WinXP
                        Test-RHEL

&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;p /&gt;
Querying from specific vCenter cluster:&lt;br /&gt;
&lt;p /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./getVMonShareableAndNonSharDatastore.pl --server reflex.primp-industries.com --username primp --type cluster --cluster PrimpESXi-cluster
Enter password:
Cluster: PrimpESXi-cluster
        Shared Datastores:
                Datastore: [http://dlgCore-NFS-bigboi.VM-Backups|http://dlgCore-NFS-bigboi.VM-Backups] is NFS with: 4 VMs

        Non-Shared Datastores:
                Datastore: [storage1] is VMFS with: 2 VMs
                        Test-WinXP
                        Test-RHEL
                Datastore: [simplejack-local-storage] is VMFS with: 4 VMs
                        ghettoVCB4i-test-vm-backup
                        ide-vm
                        itorga backuptrigger
                        dnie workstation
                Datastore: [kang-local-storage] is VMFS with: 0 VMs
                Datastore: [lazarus-local-storage] is VMFS with: 0 VMs


&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <pubDate>Fri, 14 Aug 2009 07:28:17 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10552</guid>
      <dc:date>2009-08-14T07:28:17Z</dc:date>
      <clearspace:dateToText>3 months, 2 weeks ago</clearspace:dateToText>
      <clearspace:replyCount>2</clearspace:replyCount>
    </item>
    <item>
      <title>addVMAdvParamOption.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10551</link>
      <description>This script allows you to add/modify advanced parameter configuration for a given VM such as &lt;b&gt;vmsafe.enable&lt;/b&gt;, &lt;b&gt;monitor_control.restrict_backdoor&lt;/b&gt;, &lt;b&gt;vmx.allowNested&lt;/b&gt; and other advanced configuration keys. This script can execute against vCenter or individual ESX(i) host.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirement:&lt;/b&gt;&lt;br /&gt;
ESX(i) 3.5+ or 4.0&lt;br /&gt;
VIMA 1.0/vMA 4.0&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
Adding a new param called &lt;b&gt;vmsafe.enable&lt;/b&gt; with value &lt;b&gt;false&lt;/b&gt; to a VM against vCenter:&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./addVMAdvParamOption.pl --server reflex.primp-industries.com --username primp --vmname kate --key vmsafe.enable --value false
Enter password:
Reconfiguring &amp;quot;kate&amp;quot; with advanced parameter configuration: &amp;quot;vmsafe.enable=&amp;gt;false&amp;quot; ...
Sucessfully updated advanced parameter configuration for &amp;quot;kate&amp;quot;!

&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;p /&gt;
Adding a new param called &lt;b&gt;vmx.allowNested&lt;/b&gt; with value &lt;b&gt;true&lt;/b&gt; to a VM against ESX host:&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./addVMAdvParamOption.pl --server himalaya.primp-industries.com --username root --vmname ESX3.5u4 --key vmx.allowNested --value true
Enter password:
Reconfiguring &amp;quot;ESX3.5u4&amp;quot; with advanced parameter configuration: &amp;quot;vmx.allowNested=&amp;gt;true&amp;quot; ...
Sucessfully updated advanced parameter configuration for &amp;quot;ESX3.5u4&amp;quot;!
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
Ensure your VM is powered off before trying to modify any advanced parameters, else script will error out with a warning.</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <pubDate>Fri, 14 Aug 2009 04:17:13 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10551</guid>
      <dc:date>2009-08-14T04:17:13Z</dc:date>
      <clearspace:dateToText>3 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>addVMCustomField.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10550</link>
      <description>Adding/updating a custom field to VM (available with vCenter _only_)&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements:&lt;/b&gt;&lt;br /&gt;
VIMA/vMA&lt;br /&gt;
ESX(i) 3.5 or 4.0&lt;br /&gt;
vCenter 2.5 or 4.0&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample Execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
Adding a custom field as a VirtualMachine attribute, this takes affect on the entire infrastructure, whether or not you want to set an actual value for a given VM.&lt;br /&gt;
&lt;br /&gt;
This will add a new custom field to all VMs called &lt;b&gt;SERVER_TYPE&lt;/b&gt; and the operation is an &lt;b&gt;add&lt;/b&gt;&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./addVMCountCustomField.pl --server reflex.primp-industries.com --username primp --key SERVER_TYPE --operation add
Enter password:
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
To update a certain VM with a value to the custom field, you'll use the operation &lt;b&gt;update&lt;/b&gt;&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./addVMCountCustomField.pl --server reflex.primp-industries.com --username primp --key SERVER_TYPE --value PRODUCTION --operation update --vmname kate
Enter password:
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
You'll see the changes right away on vCenter and you'll notice with a specific VM, you would have updated it's custom field &lt;b&gt;SERVER_TYPE&lt;/b&gt; with the value &lt;b&gt;PRODUCTION&lt;/b&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <pubDate>Fri, 14 Aug 2009 03:16:49 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10550</guid>
      <dc:date>2009-08-14T03:16:49Z</dc:date>
      <clearspace:dateToText>3 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>vCheck (Daily Report) V3</title>
      <link>http://communities.vmware.com/docs/DOC-10521</link>
      <description>&lt;br /&gt;
Daily Report does what it says on the tin, it runs as a scheduled task before you get into the office to present you with key information about your infrastructure in a nice easily readable format.&lt;br /&gt;
&lt;br /&gt;
For more information see &lt;a class="jive-link-external" href="http://www.virtu-al.net/2009/07/14/powercli-daily-report/#more-792"&gt;my blog post&lt;/a&gt;.&lt;br /&gt;
&lt;br /&gt;
This script picks on the key areas of the virtual infrastructure and reports it all in one place so all you do in the morning is check your email.&lt;br /&gt;
&lt;br /&gt;
One of they key things about this report is if there is no issue in a particular place you will not receive that section in the email, for example if there are no datastores with less than 5% free space (configurable) then the disk space section will not show in the email, this ensures that you have only the information you need in front of you when you get into the office.&lt;br /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;br /&gt;
Initially when I started this script I wanted people to be clear&lt;br /&gt;
that this was a report that was going to give you a daily summary of&lt;br /&gt;
any issues which may exist in your Virtual Infrastructure, from the&lt;br /&gt;
beta testing I did to a select few it was clear that they were&lt;br /&gt;
expecting this to send them a full inventory of their infrastructure.&lt;br /&gt;
&lt;p /&gt;
That wasn&amp;rsquo;t the point in this script and I think people now have the&lt;br /&gt;
idea that this is more of an issue log than an audit script so I will&lt;br /&gt;
now revert to my original name of&amp;hellip;. &lt;b&gt;vCheck.&lt;/b&gt;&lt;br /&gt;
&lt;p /&gt;
The key thing to remember is that if an issue does not exist in a&lt;br /&gt;
particular area then it will not show in the output, when and if issues&lt;br /&gt;
turn up they will start appearing in the output almost like magic !&lt;br /&gt;
&lt;p /&gt;
I want to thank everyone who is using this script and those who have&lt;br /&gt;
left a comment, even if its just to say how much you like it !&lt;br /&gt;
&lt;p /&gt;
I especially want to thank Rapha&amp;euml;l SCHITZ (&lt;a class="jive-link-external" href="http://www.hypervisor.fr/"&gt;http://www.hypervisor.fr/&lt;/a&gt;) for all his contributions, he has added some great features to this version and helped me take it to a new level.&lt;br /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;p /&gt;
&lt;b&gt;So what areas does this script report on ?&lt;/b&gt;&lt;br /&gt;
&lt;p /&gt;
&lt;br /&gt;
The previous version already reported on these areas:&lt;br /&gt;
&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;General Details
&lt;ul&gt;
&lt;li&gt;Number of Hosts&lt;/li&gt;
&lt;li&gt;Number of VMs&lt;/li&gt;
&lt;li&gt;Number of Templates&lt;/li&gt;
&lt;li&gt;Number of Clusters&lt;/li&gt;
&lt;li&gt;Number of Datastores&lt;/li&gt;
&lt;li&gt;Number of Active VMs&lt;/li&gt;
&lt;li&gt;Number of Inactive VMs&lt;/li&gt;
&lt;li&gt;Number of DRS Migrations for the last days&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Snapshots over x Days old&lt;/li&gt;
&lt;li&gt;Datastores with less than x% free space&lt;/li&gt;
&lt;li&gt;VMs created over the last x days&lt;/li&gt;
&lt;li&gt;VMs removed over the last x days&lt;/li&gt;
&lt;li&gt;VMs with No Tools&lt;/li&gt;
&lt;li&gt;VMs with CD-Roms connected&lt;/li&gt;
&lt;li&gt;VMs with Floppy Drives Connected&lt;/li&gt;
&lt;li&gt;VMs stored on local datastores&lt;/li&gt;
&lt;li&gt;VMs with CPU ready over x%&lt;/li&gt;
&lt;li&gt;VMs with over x amount of vCPUs&lt;/li&gt;
&lt;li&gt;List of DRS Migrations&lt;/li&gt;
&lt;li&gt;Hosts in Maintenance Mode&lt;/li&gt;
&lt;li&gt;Hosts in disconnected state&lt;/li&gt;
&lt;li&gt;NTP Server check for a given NTP Name&lt;/li&gt;
&lt;li&gt;NTP Service check&lt;/li&gt;
&lt;li&gt;vmkernel warning messages ov the last x days&lt;/li&gt;
&lt;li&gt;VC Error Events over the last x days&lt;/li&gt;
&lt;li&gt;VC Windows Event Log Errors for the last x days with VMware in the details&lt;/li&gt;
&lt;li&gt;VC VMware Service details&lt;/li&gt;
&lt;/ul&gt;
&lt;br /&gt;
&lt;b&gt;So what is added to V3 ?&lt;/b&gt;&lt;br /&gt;
&lt;p /&gt;
Well firstly I have fixed some bugs which existed in V2 and made things slightly faster.&lt;br /&gt;
&lt;p /&gt;
The other added features are as below:&lt;br /&gt;
&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;Status report to screen whilst running interactively&lt;/li&gt;
&lt;li&gt;At the top of the script you can now turn off any areas you do not want to report on (this makes it faster to run)&lt;/li&gt;
&lt;li&gt;VMs on Local storage has been changed to report VMs stored on datastores attached to only one host&lt;/li&gt;
&lt;li&gt;VM active alerts&lt;/li&gt;
&lt;li&gt;Cluster Active Alerts&lt;/li&gt;
&lt;li&gt;If HA Cluster is set to use host datastore for swapfile, check the host has a swapfile location set&lt;/li&gt;
&lt;li&gt;Host active Alerts&lt;/li&gt;
&lt;li&gt;Dead SCSI Luns&lt;/li&gt;
&lt;li&gt;VMs with over x amount of vCPUs&lt;/li&gt;
&lt;li&gt;vSphere check: Slot Sizes&lt;/li&gt;
&lt;li&gt;vSphere check: Outdated VM Hardware (Less than V7)&lt;/li&gt;
&lt;li&gt;VMs in Inconsistent folders (the name of the folder is not the same as the name)&lt;/li&gt;
&lt;li&gt;Added the number of issues to each title line&lt;/li&gt;
&lt;/ul&gt;
&lt;br /&gt;
As always please let me know if you have any comments, I already&lt;br /&gt;
have some great ideas that I could not fit into this version so watch&lt;br /&gt;
out for V4 !&lt;br /&gt;
&lt;p /&gt;
+Also a reminder that this script also checks your Windows&lt;br /&gt;
vCenter server for services and event logs, it does this via WMI and&lt;br /&gt;
therefore needs the correct permissions, there is still an area at the&lt;br /&gt;
top of the script which you can give alternate credentials from the&lt;br /&gt;
account that is running the script if needed.+&lt;br /&gt;
&lt;p /&gt;
If your new to this script and would like more details on how it looks or how to run it please check &lt;a class="jive-link-external" href="http://www.virtu-al.net/2009/07/14/powercli-daily-report/"&gt;this post.&lt;/a&gt;&lt;br /&gt;
&lt;p /&gt;
At the bottom of he script is also an area which you can uncomment to save a the daily report as a htm file in a specific folder.&lt;br /&gt;
&lt;br /&gt;
I think that&amp;rsquo;s it !&lt;br /&gt;
&lt;br /&gt;
If there is anything missing please let me know and I will add it to future versions.&lt;br /&gt;
&lt;br /&gt;
To run this script simple setup a scheduled task as per my previous post running the script and passing it your VI server as a parameter as below:&lt;br /&gt;
&lt;br /&gt;
C:\WINDOWS\system32\windowspowershell\v1.0\powershell.exe -PSConsoleFile &amp;ldquo;C:\Program Files\VMware\Infrastructure\vSphere PowerCLI\vim.psc1&amp;Prime; &amp;rdquo; &amp;#38;  &amp;ldquo;C:\Scripts\DailyReport.ps1 TESTVC01&amp;Prime;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3077">email</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">powershell</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">report</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">snapshots</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">storage</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">tools</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">vmdks</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">vm</category>
      <pubDate>Wed, 12 Aug 2009 22:38:55 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10521</guid>
      <dc:date>2009-08-12T22:38:55Z</dc:date>
      <clearspace:dateToText>3 weeks, 23 hours ago</clearspace:dateToText>
    </item>
    <item>
      <title>getAllVMGuestHostname.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10500</link>
      <description>Retrieves all VMs and their guestOS hostnames &lt;b&gt;if&lt;/b&gt; VMware Tools is installed.&lt;br /&gt;
&lt;br /&gt;
Example Execution:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./getAllVMGuestHostname.pl --server himalaya.primp-industries.com --username root
Enter password:
VM Display Name         VM Guest Hostname               VMware Tools Status
------------------------------------------------------------------------
winXP-base              Not Available           toolsNotRunning
Imager          Not Available           toolsNotRunning
ESX4-2          Not Available           toolsNotInstalled
kate            Not Available           toolsNotRunning
primp-vapp-esx01                Not Available           toolsNotInstalled
primp-vapp-vcenter01            Not Available           toolsNotInstalled
William-XP              william         toolsOk
simplejack.primp-industries.com         Not Available           toolsNotInstalled
VIMA            vima.primp-industries.com               toolsOld
&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <pubDate>Sat, 08 Aug 2009 18:32:27 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10500</guid>
      <dc:date>2009-08-08T18:32:27Z</dc:date>
      <clearspace:dateToText>3 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>getAllVMMacs.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10490</link>
      <description>Extract MAC Addresses for all VMs residing on either vCenter or individual ESX(i) 3.5+ or 4.0 host&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./getAllVMMacs.pl --server simplejack.primp-industries.com
ghettoVCB4i-test-vm-backup
        [Network adapter 1] : 00:50:56:b0:0d:dc

ide-vm
        [Network adapter 1] : 00:50:56:99:2f:15
        [Network adapter 2] : 00:50:56:99:2f:16
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;p /&gt;
The label &lt;b&gt;Network adapter&lt;/b&gt; is what is shown in the vSphere Client under VM configuration, it does not necessary match up to eth0,1,etc.</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <pubDate>Fri, 07 Aug 2009 23:09:17 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10490</guid>
      <dc:date>2009-08-07T23:09:17Z</dc:date>
      <clearspace:dateToText>3 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>whichClusterIsMyVMIn.pl - Find which Cluster your VM is part of (requires vCenter)</title>
      <link>http://communities.vmware.com/docs/DOC-10439</link>
      <description>This scripts allows you to find out which Cluster a given VM is part of.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirements&lt;/b&gt;&lt;br /&gt;
vCenter 2.5.x or 4.x&lt;br /&gt;
ESX(i) 3.5.x or 4.x&lt;br /&gt;
VI Perl Toolkit or vSphere SDK for Perl&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample execution&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./whichClusterIsMyVMIn.pl --server reflex.primp-industries.com --username primp --vmname simplejack.primp-industries.com

Located VM: &amp;quot;simplejack.primp-industries.com&amp;quot;!
VM: &amp;quot;simplejack.primp-industries.com&amp;quot; is hosted on &amp;quot;himalaya.primp-industries.com&amp;quot;
VM: &amp;quot;simplejack.primp-industries.com&amp;quot; is located on Cluster: &amp;quot;PrimpESX-cluster&amp;quot;

&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <pubDate>Fri, 31 Jul 2009 17:05:38 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10439</guid>
      <dc:date>2009-07-31T17:05:38Z</dc:date>
      <clearspace:dateToText>3 months, 4 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>VM Snapshot Detials</title>
      <link>http://communities.vmware.com/docs/DOC-10409</link>
      <description />
      <category domain="http://communities.vmware.com/tags?communityID=3080">vm_operations</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">snapshot</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">information</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">vm</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">details</category>
      <pubDate>Thu, 30 Jul 2009 17:28:11 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10409</guid>
      <dc:date>2009-07-30T17:28:11Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>relocate VMs to a new host - Storage VMotion</title>
      <link>http://communities.vmware.com/docs/DOC-10436</link>
      <description />
      <category domain="http://communities.vmware.com/tags?communityID=3079">storage</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">vmotion</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">vm_operations</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">relocate</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">move</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">host</category>
      <pubDate>Thu, 30 Jul 2009 00:37:55 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10436</guid>
      <dc:date>2009-07-30T00:37:55Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>Migrate VMs to a new host</title>
      <link>http://communities.vmware.com/docs/DOC-10435</link>
      <description />
      <category domain="http://communities.vmware.com/tags?communityID=3079">vm_operations</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">migrate</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">vm</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">host</category>
      <pubDate>Thu, 30 Jul 2009 00:14:02 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10435</guid>
      <dc:date>2009-07-30T00:14:02Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
      <clearspace:replyCount>1</clearspace:replyCount>
    </item>
    <item>
      <title>Task History Collector</title>
      <link>http://communities.vmware.com/docs/DOC-10434</link>
      <description />
      <category domain="http://communities.vmware.com/tags?communityID=3079">task</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">history</category>
      <category domain="http://communities.vmware.com/tags?communityID=3079">collector</category>
      <pubDate>Thu, 30 Jul 2009 00:11:59 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10434</guid>
      <dc:date>2009-07-30T00:11:59Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>dumpDVS.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10328</link>
      <description>A script that dumps a variety of information about all the Distributed Virtual Switches (DVS) that are managed by the specified vCenter server.&lt;br /&gt;
There are no command line options.&lt;br /&gt;
&lt;br /&gt;
This example command line will redirect the output to the file dumpDVS.log.  The IP address refers to a vCenter server.  Sample output is attached&lt;br /&gt;
&lt;p /&gt;
./dumpDVS.pl --server 192.168.137.139 --username administrator --password vmware &amp;gt;dumpDVS.log</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vi-perl</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">sample</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">dvs</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vcenter</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">network</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">virtual_switch</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">distributed_virtual_switch</category>
      <pubDate>Wed, 08 Jul 2009 07:35:42 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10328</guid>
      <dc:date>2009-07-08T07:35:42Z</dc:date>
      <clearspace:dateToText>4 months, 3 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>poweroff_suspend_vm.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10269</link>
      <description>A script that allows you to perform either &lt;b&gt;"Power Off"&lt;/b&gt; or &lt;b&gt;"Suspend"&lt;/b&gt; operation against a list of VMs.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample execution&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
Sample VM file containing displayName of each VM separated by a newline to perform the operations against. &lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ cat vmList
Quentin
VCAP
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;p /&gt;
Suspending VMs&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./vmPowerOps.pl --config .viconfig --operation suspend --vmfile vmList
Trying to suspend Quentin
        Successfully suspended Quentin
Trying to suspend VCAP
        Successfully suspended VCAP
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;p /&gt;
Powering off VMs&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./vmPowerOps.pl --config .viconfig --operation poweroff --vmfile vmList
Trying to poweroff Quentin
        Successfully poweredoff Quentin
Trying to poweroff VCAP
        Successfully poweredoff VCAP
&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <pubDate>Thu, 02 Jul 2009 03:01:33 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10269</guid>
      <dc:date>2009-07-02T03:01:33Z</dc:date>
      <clearspace:dateToText>4 months, 3 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>ftCLI.pl - VMware Fault Tolerant Managment</title>
      <link>http://communities.vmware.com/docs/DOC-10279</link>
      <description>&lt;b&gt;Description&lt;/b&gt;: Managing VMware Fault Tolerant via the command line. &lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Params&lt;/b&gt;: The following operations are supported: create|enable|disable|stop&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Requirement&lt;/b&gt;: &lt;br /&gt;
vSphere vCenter 4.0&lt;br /&gt;
ESX(i) 4.0&lt;br /&gt;
Advanced, Enterprise, Enterprise Plus or Eval licensing&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Assumption&lt;/b&gt;: Your environment is FT capable and is configured properly&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;Sample Execution using ftCLI.pl&lt;/h2&gt;
&lt;hr /&gt;
&lt;br /&gt;
To create a newly fault tolerant VM, you'll want to use &lt;b&gt;create&lt;/b&gt; operation and specify the VM that you would like to protect (A valid host within the cluster will be selected for you):&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./ftCLI.pl --server reflex.primp-industries.com --username primp --vmname Devastator --operation create
Enter password:
Creating FT secondary VM for &amp;quot;Devastator&amp;quot; ...
        Successfully created FT protection for &amp;quot;Devastator&amp;quot;!
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;p /&gt;
If you have fault tolerant enabled on a specific VM and would like to disable, you'll want to use &lt;b&gt;disable&lt;/b&gt; operation: &lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./ftCLI.pl --server reflex.primp-industries.com --username primp --vmname Devastator --operation disable
Enter password:
Disabling FT secondary VM for &amp;quot;Devastator&amp;quot; on host &amp;quot;everest.primp-industries.com&amp;quot; ...
        Successfully disabled FT protection for &amp;quot;Devastator&amp;quot;!
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;p /&gt;
If you have fault tolerant disabled on a specific VM and would like to re-enable, you'll want to use &lt;b&gt;enable&lt;/b&gt; operation: &lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./ftCLI.pl --server reflex.primp-industries.com --username primp --vmname Devastator --operation enable
Enter password:
Enabling FT secondary VM for &amp;quot;Devastator&amp;quot; on host &amp;quot;everest.primp-industries.com&amp;quot; ...
        Successfully enabled FT protection for &amp;quot;Devastator&amp;quot;!
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;p /&gt;
If you like to turn off fault tolerant completely and destroy the secondary VM, you'll want to use &lt;b&gt;stop&lt;/b&gt; operation:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./ftCLI.pl --server reflex.primp-industries.com --username primp --vmname Devastator --operation stop
Enter password:
Turning off FT for secondary VM for Devastator ...
        Successfully stopped FT protection for &amp;quot;Devastator&amp;quot;!
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;p /&gt;
&lt;h2&gt;Sample Execution using ftCLI2.pl&lt;/h2&gt;
&lt;hr /&gt;
&lt;br /&gt;
Hosts to configure FT logging on:&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ cat hostlists
simplejack.primp-industries.com
lazarus.primp-industries.com
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
If you would like to enable FT logging on your FT portgroup for a specific ESX(i) host, you'll want to use &lt;b&gt;config_enable&lt;/b&gt; specifying &lt;b&gt;host&lt;/b&gt; and &lt;b&gt;portgroup_name&lt;/b&gt; param:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./ftCLI2.pl --server reflex.primp-industries.com --username primp --operation config_enable --hostlist hostlists --portgroup_name ft_portgroup
Enabling FT logging on &amp;quot;simplejack.primp-industries.com&amp;quot; for port group &amp;quot;ft_portgroup&amp;quot; ...
        Successfully enabled FT logging on &amp;quot;simplejack.primp-industries.com&amp;quot; for port group ft_portgroup.
Enabling FT logging on &amp;quot;lazarus.primp-industries.com&amp;quot; for port group &amp;quot;ft_portgroup&amp;quot; ...
        Successfully enabled FT logging on &amp;quot;lazarus.primp-industries.com&amp;quot; for port group ft_portgroup.
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;p /&gt;
If you would like to disable FT logging on your FT portgroup for a specific ESX(i) host, you'll want to use &lt;b&gt;config_disable&lt;/b&gt; specifying &lt;b&gt;host&lt;/b&gt; and &lt;b&gt;portgroup_name&lt;/b&gt; param:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./ftCLI2.pl --server reflex.primp-industries.com --username primp --operation config_disable --hostlist hostlists --portgroup_name ft_portgroup
Disabling FT logging on &amp;quot;simplejack.primp-industries.com&amp;quot; for port group &amp;quot;ft_portgroup&amp;quot; ...
        Successfully disabled FT logging on &amp;quot;simplejack.primp-industries.com&amp;quot; for port group ft_portgroup.
Disabling FT logging on &amp;quot;lazarus.primp-industries.com&amp;quot; for port group &amp;quot;ft_portgroup&amp;quot; ...
        Successfully disabled FT logging on &amp;quot;lazarus.primp-industries.com&amp;quot; for port group ft_portgroup.

&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;p /&gt;
To create a newly fault tolerant VM, you'll want to use &lt;b&gt;create&lt;/b&gt; operation and specify the VM that you would like to protect (A valid host within the cluster will be selected for you):&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./ftCLI2.pl --server reflex.primp-industries.com --username primp --operation create --vmname protect_thee_vm
Creating FT secondary VM for &amp;quot;protect_thee_vm&amp;quot; ...
        Successfully created FT protection for &amp;quot;protect_thee_vm&amp;quot;!
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;p /&gt;
If you have fault tolerant configured and would like to enable it for a VM, you would use &lt;b&gt;enable&lt;/b&gt; operation: &lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./ftCLI2.pl --server reflex.primp-industries.com --username primp --operation disable --vmname protect_thee_vm
Disabling FT secondary VM for &amp;quot;protect_thee_vm&amp;quot; on host &amp;quot;simplejack.primp-industries.com&amp;quot; ...
        Successfully disabled FT protection for &amp;quot;protect_thee_vm&amp;quot;!
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;p /&gt;
If you have fault tolerant configured and would like to enable it for a VM, you would use &lt;b&gt;disable&lt;/b&gt; operation: &lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./ftCLI2.pl --server reflex.primp-industries.com --username primp --operation enable --vmname protect_thee_vm
Enabling FT secondary VM for &amp;quot;protect_thee_vm&amp;quot; on host &amp;quot;simplejack.primp-industries.com&amp;quot; ...
        Successfully enabled FT protection for &amp;quot;protect_thee_vm&amp;quot;!
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;p /&gt;
If you like to turn off fault tolerant completely and destroy the secondary VM, you'll want to use &lt;b&gt;stop&lt;/b&gt; operation:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./ftCLI2.pl --server reflex.primp-industries.com --username primp --operation stop --vmname protect_thee_vm
Turning off FT for secondary VM for protect_thee_vm ...
        Successfully stopped FT protection for &amp;quot;protect_thee_vm&amp;quot;!
&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">ft</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">fault_tolerant</category>
      <pubDate>Wed, 01 Jul 2009 00:26:32 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10279</guid>
      <dc:date>2009-07-01T00:26:32Z</dc:date>
      <clearspace:dateToText>2 months, 3 days ago</clearspace:dateToText>
      <clearspace:replyCount>2</clearspace:replyCount>
    </item>
    <item>
      <title>Retrieving Host Information</title>
      <link>http://communities.vmware.com/docs/DOC-10278</link>
      <description>The enclosed Visual Basic 2008 project show a sample console application that queries all hosts known to the VC server and reports their vmotion capability back.&lt;br /&gt;
&lt;br /&gt;
The project uses a  vc_functions module, which I use in most my applications. It simplifies a few things;&lt;br /&gt;
&lt;p /&gt;
&lt;ul&gt;
&lt;li&gt;Setup the SSL certificate handling, that any certificate will be accepted:-)&lt;/li&gt;
&lt;li&gt;Offers 3 basic functions; Login, FindObjects and ViewObject.&lt;/li&gt;
&lt;/ul&gt;
&lt;p /&gt;
Especially finding objects with the native SDK is very complicated, as you have to create some difficult filter and objects specs. This module massively simplifies this process.&lt;br /&gt;
&lt;p /&gt;
&lt;br /&gt;
The project comes with optimized DLLs that were created from the .wdsl files that come with the vSphere SDK. Just make sure your project references to the 2 DLLs.&lt;br /&gt;
&lt;p /&gt;
&lt;p /&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3125">vb</category>
      <category domain="http://communities.vmware.com/tags?communityID=3125">retrieving</category>
      <category domain="http://communities.vmware.com/tags?communityID=3125">host</category>
      <category domain="http://communities.vmware.com/tags?communityID=3125">information</category>
      <pubDate>Tue, 30 Jun 2009 22:31:24 GMT</pubDate>
      <author>richard@vmware.com</author>
      <guid>http://communities.vmware.com/docs/DOC-10278</guid>
      <dc:date>2009-06-30T22:31:24Z</dc:date>
      <clearspace:dateToText>4 months, 4 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>queryDeletedVMs.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10282</link>
      <description>Query User and Date/Time on when a specific VM was deleted.&lt;br /&gt;
&lt;br /&gt;
Sample Execution:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield ~]$ ./queryDeletedVMs.pl --server reflex.primp-industries.com --username primp --vmname blah
Enter password:
User: PRIMP-IND\primp
Deleted VM: Removed blah on himalaya.primp-industries.com from Primp
Date/Time: 2009-06-27T01:53:14.106999Z

&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <pubDate>Sat, 27 Jun 2009 06:22:22 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10282</guid>
      <dc:date>2009-06-27T06:22:22Z</dc:date>
      <clearspace:dateToText>5 months, 2 days ago</clearspace:dateToText>
    </item>
    <item>
      <title>Sample Code Guidelines</title>
      <link>http://communities.vmware.com/docs/DOC-10226</link>
      <description>Please follow these guidelines to keep sample code more descriptive and consistent throughout the community&lt;br /&gt;
&lt;br /&gt;
Please have these guidelines in mind for your next post:&lt;br /&gt;
&lt;p /&gt;
&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;&lt;span style="color:#3366ff"&gt;&lt;b&gt;Descriptive name&lt;/b&gt;&lt;/span&gt; to sample script/code&lt;/li&gt;
&lt;li&gt;Note on what &lt;span style="color:#3366ff"&gt;&lt;b&gt;task&lt;/b&gt;&lt;/span&gt; your script/code is performing&lt;/li&gt;
&lt;li&gt;&lt;span style="color:#3366ff"&gt;&lt;b&gt;Relevant tags&lt;/b&gt;&lt;/span&gt; for searching, and tags come out of your code's task(use the default tags suggested in addition)&lt;/li&gt;
&lt;li&gt;A screen shot of your script's &lt;b&gt;&lt;span style="color:#3366ff"&gt;trail run&lt;/span&gt;&lt;/b&gt;&lt;/li&gt;
&lt;li&gt;A well &lt;span style="color:#3366ff"&gt;&lt;b&gt;documented script/code&lt;/b&gt;&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;Additional links(resources, related sample codes, etc)&lt;/li&gt;
&lt;/ul&gt;
&lt;br /&gt;
&lt;a class="jive-link-wiki" href="http://communities.vmware.com/docs/DOC-9202"&gt;An example with above guidelines&lt;/a&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">sample</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">code</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">guidelines</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">guide</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">lines</category>
      <pubDate>Wed, 24 Jun 2009 21:08:07 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10226</guid>
      <dc:date>2009-06-24T21:08:07Z</dc:date>
      <clearspace:dateToText>5 months, 4 days ago</clearspace:dateToText>
    </item>
    <item>
      <title>Folder Name Mismatch</title>
      <link>http://communities.vmware.com/docs/DOC-10233</link>
      <description>&lt;br /&gt;
Isn&amp;rsquo;t it annoying when you are looking for a VM on your datastore and you cant find it because the folder name is not the same as the VM,&lt;br /&gt;
use the below script and you will never have that problem again.&lt;br /&gt;
&lt;br /&gt;
This script will compare the name of the VM to the folder it is stored in, any mismatches will be output.&lt;br /&gt;
&lt;br /&gt;
I know a regex expert could probably do this better, let me know if you are one  &lt;br /&gt;
&lt;br /&gt;
Sample Output:&lt;br /&gt;
&lt;p /&gt;
&lt;br /&gt;
&lt;table class="jive-wiki-table"&gt;
&lt;tr&gt;
&lt;td&gt;VM&lt;/td&gt;
&lt;td&gt;Path&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;New VM 1&lt;/td&gt;
&lt;td&gt;storage1 New VM&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;ABCDEV01&lt;/td&gt;
&lt;td&gt;storage1 Dev Test&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;MicroDS&lt;/td&gt;
&lt;td&gt;SAN11 New VM&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;VM127&lt;/td&gt;
&lt;td&gt;SAN11 Windows 2003 Server&lt;/td&gt;
&lt;/tr&gt;
&lt;/table&gt;
&lt;br clear="left" /&gt;
&lt;br /&gt;
For more information visit: &lt;a class="jive-link-external" href="http://www.virtu-al.net/2009/06/22/powercli-folder-name-mismatch/"&gt;http://www.virtu-al.net/2009/06/22/powercli-folder-name-mismatch/&lt;/a&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3077">vm</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">vmdks</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">powershell</category>
      <pubDate>Wed, 24 Jun 2009 13:17:40 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10233</guid>
      <dc:date>2009-06-24T13:17:40Z</dc:date>
      <clearspace:dateToText>5 months, 5 days ago</clearspace:dateToText>
    </item>
    <item>
      <title>Snapshot Email Reminder</title>
      <link>http://communities.vmware.com/docs/DOC-10232</link>
      <description>&lt;br /&gt;
Fed up of chasing those people who constantly create snapshots and leave them hanging around for weeks or even months on end ?&lt;br /&gt;
&lt;br /&gt;
You no longer have to do the chasing, just use the following script to automatically find the offending snapshot, find the person who created it, get their email address from AD and send them an email reminding them of their mortal sin.&lt;br /&gt;
&lt;br /&gt;
A few requirements:&lt;br /&gt;
&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;The accounts must have the E-Mail field filled outin AD&lt;/li&gt;
&lt;li&gt;The account you run the script as must have read permissions to AD (Any member of the domain should have this)&lt;/li&gt;
&lt;li&gt;You need to fill in the smtp server address, VI Server name and the from address at the top of this script&lt;/li&gt;
&lt;/ul&gt;
&lt;br /&gt;
The script is set to remind of anything over 2 weeks old but this can easily be amended&lt;br /&gt;
&lt;p /&gt;
&lt;br /&gt;
More information is available here: &lt;a class="jive-link-external" href="http://www.virtu-al.net/2009/06/22/powercli-snapreminder/"&gt;http://www.virtu-al.net/2009/06/22/powercli-snapreminder/&lt;/a&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3077">snapshot</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">powershell</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">email</category>
      <pubDate>Wed, 24 Jun 2009 13:01:19 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10232</guid>
      <dc:date>2009-06-24T13:01:19Z</dc:date>
      <clearspace:dateToText>5 months, 5 days ago</clearspace:dateToText>
    </item>
    <item>
      <title>Scripts for "Proactive DRS"</title>
      <link>http://communities.vmware.com/docs/DOC-10231</link>
      <description>&lt;br /&gt;
This posting includes 3 scripts that can be used to make DRS "proactive"&lt;br /&gt;
with respect to an expected steep increase in VM demand.  This scripts&lt;br /&gt;
may be appropriate in conjunction with those posted as "Proactive DPM".&lt;br /&gt;
[Please note that in many cluster environments, these scripts will not&lt;br /&gt;
be needed, but they are included in case testing has established that&lt;br /&gt;
they are applicable.]&lt;br /&gt;
&lt;p /&gt;
1) setDRSAggressive.pl&lt;br /&gt;
2) setDRSDefault.pl&lt;br /&gt;
3) setMaxMovesPerHost.pl&lt;br /&gt;
&lt;p /&gt;
All scripts have perldoc information documenting their usage parameters.&lt;br /&gt;
&lt;p /&gt;
The use case for these scripts is that a large number of VMs are highly&lt;br /&gt;
consolidated on a few hosts (e.g., due to DPM placing hosts in standby&lt;br /&gt;
during idle periods) and during a steep increase in demand, it takes&lt;br /&gt;
nontrivial time to redistribute the VMs across hosts in the cluster,&lt;br /&gt;
particularly because performing the associated VMotions during the period&lt;br /&gt;
of demand increase puts pressure on available cluster resources.  The&lt;br /&gt;
scripts facilitate redistributing the VMs across hosts in the cluster&lt;br /&gt;
before the VM demand increase makes this redistribution appear worthwhile.&lt;br /&gt;
&lt;p /&gt;
The script setDRSAggressive.pl sets various DRS operating parameters so&lt;br /&gt;
that it will recommend rebalancing VMotions even when current VM demand&lt;br /&gt;
does not make those moves appear worthwhile.  As an example use case, if&lt;br /&gt;
powerOnHosts.pl (see "Proactive DPM" posting) is used to trigger host&lt;br /&gt;
power-ons at 8am before an expected steep increase in VM demand weekdays&lt;br /&gt;
at 9am, setDRSAggressive.pl can also be scheduled to run at 8am to force&lt;br /&gt;
rebalancing moves to the powered-on hosts.  The script setDRSDefault.pl&lt;br /&gt;
resets DRS' operating parameters so that it resumes its normal behavior.&lt;br /&gt;
In the example use case, setDRSDefault.pl could be scheduled to run at&lt;br /&gt;
(say) 8:50am to resume DRS normal reactive behavior prior to the expected&lt;br /&gt;
steep increase in VM demand at 9am.&lt;br /&gt;
&lt;p /&gt;
The script setMaxMovesPerHost.pl can be used to increase DRS' limit on the&lt;br /&gt;
number of VMotions it will recommend in each (default every 5 minutes)&lt;br /&gt;
regular DRS invocation; this can to be used to allow the redistribution of&lt;br /&gt;
VMs to be accomplished in a shorter period of time than default) and can&lt;br /&gt;
then be used to reset DRS's limit to its default value (8) when normal DRS&lt;br /&gt;
operation is to be resumed.  In the example use case, if many redistribution&lt;br /&gt;
VMotions are needed between 8am and an expected steep increase in VM demand&lt;br /&gt;
at 9am, setMaxMovesPerHost.pl could be scheduled to run at 8am and set the&lt;br /&gt;
limit to a larger number than 8, depending on how many VMotions are needed&lt;br /&gt;
to redistribute the VMs before 9am and then setMaxMovesPerHost.pl can be&lt;br /&gt;
scheduled to run at (say) 8:50am to reset the limit back to its default of 8.&lt;br /&gt;
&lt;p /&gt;
&lt;br /&gt;</description>
      <pubDate>Tue, 23 Jun 2009 19:08:37 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10231</guid>
      <dc:date>2009-06-23T19:08:37Z</dc:date>
      <clearspace:dateToText>5 months, 6 days ago</clearspace:dateToText>
    </item>
    <item>
      <title>Scripts for "Proactive DPM"</title>
      <link>http://communities.vmware.com/docs/DOC-10230</link>
      <description>&lt;br /&gt;
This posting includes 2 scripts that can be used to make DPM&lt;br /&gt;
"proactive" with respect to an expected steep increase in VM demand.&lt;br /&gt;
&lt;p /&gt;
1) powerOnHosts.pl&lt;br /&gt;
2) enableDPM.pl&lt;br /&gt;
&lt;p /&gt;
Both scripts have perldoc information documenting their usage parameters.&lt;br /&gt;
&lt;p /&gt;
The script powerOnHosts.pl changes cluster settings to engender&lt;br /&gt;
recommendations to power on all standby hosts and then to disable DPM&lt;br /&gt;
so that those hosts are kept on while demand remains low.  As an example&lt;br /&gt;
use case, this script can be scheduled (e.g., with schtasks) to run each&lt;br /&gt;
weekday morning at (say) 8am to power-on hosts in advance of an expected&lt;br /&gt;
steep increase in VM demand at 9am.  The script enableDPM.pl re-enables&lt;br /&gt;
DPM to run in its normal reactive behavior.  As an example use case, this&lt;br /&gt;
script can be scheduled to run each weekday morning at (say) 10am (after&lt;br /&gt;
full VM demand load is expected to be established) or at (say) 5pm (after&lt;br /&gt;
full VM demand load is likely to diminish) to resume normal DPM operation.&lt;br /&gt;
Note that using the 10am scheduling strategy for enableDPM.pl allows&lt;br /&gt;
power to be saved when the expected steep increase in demand does not&lt;br /&gt;
actually occur (e.g., a work holiday).</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">dpm</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">drs</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">cluster</category>
      <pubDate>Tue, 23 Jun 2009 19:06:28 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10230</guid>
      <dc:date>2009-06-23T19:06:28Z</dc:date>
      <clearspace:dateToText>5 months, 6 days ago</clearspace:dateToText>
      <clearspace:replyCount>2</clearspace:replyCount>
    </item>
    <item>
      <title>queryVMCustomField.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10220</link>
      <description>Originally syndicated from: &lt;a class="jive-link-message" href="http://communities.vmware.com/message/1288452#1288452"&gt;Re: viPerl: List specific custom attributes for specific VM&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
Query custom fields defined for a virtual machine. &lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Note:&lt;/b&gt; This is only available when querying against vCenter, this will not work for individual ESX(i) host&lt;br /&gt;
&lt;br /&gt;
Sample execution:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@tancredi ~]$ ./queryVMCustomField.pl --server reflex2.primp-industries.com --username primp --customfield SLA --vmname William-XP
Enter password:
Virtual Machine: William-XP
   SLA = 30min
&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <pubDate>Fri, 19 Jun 2009 02:14:27 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10220</guid>
      <dc:date>2009-06-19T02:14:27Z</dc:date>
      <clearspace:dateToText>5 months, 1 week ago</clearspace:dateToText>
    </item>
    <item>
      <title>queryVMDiskUUID.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10200</link>
      <description>Query VMDK UUID &lt;br /&gt;
&lt;br /&gt;
Sample Execution:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@vi-admin]$ ./queryVMDiskUUID.pl --vmname tancredi --server everest.primp-industries.com
Virtual Machine: tancredi
[everest-local-storage] tancredi/tancredi.vmdk
60 00 C2 91 db 51 be 29-fd c7 79 ec 27 8c c0 be
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Note:&lt;/b&gt; Ensure you're providing ESX(i) host as the &lt;b&gt;QueryVirtualDiskUuid()&lt;/b&gt; is not supported with vCenter.</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <pubDate>Thu, 18 Jun 2009 17:32:51 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10200</guid>
      <dc:date>2009-06-18T17:32:51Z</dc:date>
      <clearspace:dateToText>5 months, 1 week ago</clearspace:dateToText>
    </item>
    <item>
      <title>getVMDiskCID.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10189</link>
      <description>Retrieve the CID value for VMDK(s) for a given virtual machine.&lt;br /&gt;
&lt;br /&gt;
Sample Execution:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@rafaeli ~]$ ./getVMDiskCID.pl --server mauna-loa.primp-industries.com --username primp --vmname lamw_base
Enter password:
Virtual Machine: lamw_base
        CURRENT VMDK: [everest-local-storage] lamw_base/lamw_base-000002.vmdk
        CID: 0xb95ddf5b
        PARENT VMDK: [everest-local-storage] lamw_base/lamw_base-000001.vmdk
        CID: 0xb95ddf5b
        PARENT VMDK: [everest-local-storage] lamw_base/lamw_base.vmdk
        CID: 0xb95ddf5b

&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <pubDate>Thu, 18 Jun 2009 02:58:07 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10189</guid>
      <dc:date>2009-06-18T02:58:07Z</dc:date>
      <clearspace:dateToText>5 months, 1 week ago</clearspace:dateToText>
    </item>
    <item>
      <title>rdm.sh</title>
      <link>http://communities.vmware.com/docs/DOC-10188</link>
      <description>Locate VM(s) with RDMs on ESX(i) 3.5+</description>
      <category domain="http://communities.vmware.com/tags?communityID=3078">vm_operations</category>
      <pubDate>Thu, 18 Jun 2009 02:45:36 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10188</guid>
      <dc:date>2009-06-18T02:45:36Z</dc:date>
      <clearspace:dateToText>5 months, 1 week ago</clearspace:dateToText>
    </item>
    <item>
      <title>rescanAllHBAInCluster.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10187</link>
      <description>Rescan all HBAs, VMFS volumes and refresh storage summary provided a vCenter cluster.&lt;br /&gt;
&lt;br /&gt;
Sample execution:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@tancredi ~]$ ./rescanAllHBAInCluster.pl --cluster development --server reflex2.primp-industries.com --username primp
Enter password:
Scanning cluster: development ...
        Rescan all HBAs successful for host everest.primp-industries.com.
        Rescan for new VMFS volumes successful for host everest.primp-industries.com.
        Refresh storage information successful for host everest.primp-industries.com.
Scanning cluster complete!

&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">storage</category>
      <pubDate>Thu, 18 Jun 2009 02:42:40 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10187</guid>
      <dc:date>2009-06-18T02:42:40Z</dc:date>
      <clearspace:dateToText>5 months, 1 week ago</clearspace:dateToText>
    </item>
    <item>
      <title>Linked Clones script for ESXi</title>
      <link>http://communities.vmware.com/docs/DOC-10193</link>
      <description>&lt;a class="jive-link-external" href="http://communities.vmware.com/servlet/JiveServlet/download/1359583-28031/VMware%20Contributed%20Sample%20Code.pdf"&gt;VMware Contributed Sample Code Disclaimer&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
This script allows users to create linked cloned virtual machine(s) from a &lt;br /&gt;
master (or golden) virtual machine. Clones may be stored on any type of &lt;br /&gt;
datastore (LOCAL, SAN, NFS) that is presented to the ESXi host. The script is &lt;br /&gt;
very capable in deploying a large VDI environment in a relatively short amount &lt;br /&gt;
of time.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Script:&lt;/b&gt; &lt;br /&gt;
&lt;a class="jive-link-wiki" href="http://communities.vmware.com/docs/DOC-9202"&gt;http://communities.vmware.com/docs/DOC-9202&lt;/a&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3078">vm_operations</category>
      <category domain="http://communities.vmware.com/tags?communityID=3078">clone</category>
      <category domain="http://communities.vmware.com/tags?communityID=3078">cloned</category>
      <category domain="http://communities.vmware.com/tags?communityID=3078">vm</category>
      <category domain="http://communities.vmware.com/tags?communityID=3078">virtual</category>
      <category domain="http://communities.vmware.com/tags?communityID=3078">machines</category>
      <category domain="http://communities.vmware.com/tags?communityID=3078">machine</category>
      <category domain="http://communities.vmware.com/tags?communityID=3078">master</category>
      <pubDate>Wed, 17 Jun 2009 21:14:18 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10193</guid>
      <dc:date>2009-06-17T21:14:18Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>VMs Backup on ESX servers</title>
      <link>http://communities.vmware.com/docs/DOC-10192</link>
      <description>&lt;a class="jive-link-external" href="http://communities.vmware.com/servlet/JiveServlet/download/1359583-28031/VMware%20Contributed%20Sample%20Code.pdf"&gt;VMware Contributed Sample Code Disclaimer&lt;/a&gt;&lt;br /&gt;
&lt;p /&gt;
This script performs backups of virtual machines residing on *ESX(i) &lt;br /&gt;
3.5/4.0+* servers using methodology similar to VMware's VCB tool. The script &lt;br /&gt;
takes snapshots of live virtual machines, backs up the master VMDK(s) and then &lt;br /&gt;
upon completion, deletes the snapshot until the next backup. The only caveat is &lt;br /&gt;
that it utilizes resources available to the Service Console of the ESX server &lt;br /&gt;
running the backups as opposed to following the traditional method of offloading &lt;br /&gt;
virtual machine backups through a VCB proxy.&lt;br /&gt;
&lt;p /&gt;
&lt;b&gt;Script:&lt;/b&gt;&lt;br /&gt;
&lt;a class="jive-link-wiki" href="http://communities.vmware.com/docs/DOC-8760"&gt;http://communities.vmware.com/docs/DOC-8760&lt;/a&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3078">vm_operations</category>
      <category domain="http://communities.vmware.com/tags?communityID=3078">backup</category>
      <category domain="http://communities.vmware.com/tags?communityID=3078">back</category>
      <category domain="http://communities.vmware.com/tags?communityID=3078">up</category>
      <category domain="http://communities.vmware.com/tags?communityID=3078">esx</category>
      <category domain="http://communities.vmware.com/tags?communityID=3078">servers</category>
      <category domain="http://communities.vmware.com/tags?communityID=3078">server</category>
      <category domain="http://communities.vmware.com/tags?communityID=3078">vm</category>
      <pubDate>Wed, 17 Jun 2009 21:07:49 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10192</guid>
      <dc:date>2009-06-17T21:07:49Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>removeOrphansFromvCenter.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10190</link>
      <description>Remove virtual machines that may have been deleted directly on ESX(i) host but not reflected in vCenter, also known as orphaned VMs.&lt;br /&gt;
&lt;br /&gt;
Sample execution:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@tancredi ~]$ ./removeOrphansFromvCenter.pl --server reflex2.primp-industries.com --username primp
Enter password:
Searching Host: everest.primp-industries.com
        hey_im_orphaned orphaned &amp;#38; Removed from inventory!
&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">orphaned_vm</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">orphaned</category>
      <pubDate>Mon, 15 Jun 2009 00:16:19 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10190</guid>
      <dc:date>2009-06-15T00:16:19Z</dc:date>
      <clearspace:dateToText>5 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>reconfigureDRS.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10181</link>
      <description>Enable/Disable DRS on a vCenter cluster.&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;Sample execution:&lt;/b&gt;&lt;br /&gt;
&lt;br /&gt;
Enable DRS&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@vima ~]$ ./reconfigureDRS.pl --cluster development --operation enable --server reflex2.primp-industries.com --username primp
Enter password:
enable DRS on Cluster: development
Cluster reconfiguration completed!

&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
Disable DRS&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@vima ~]$ ./reconfigureDRS.pl --cluster development --operation disable --server reflex2.primp-industries.com --username primp
Enter password:
disable DRS on Cluster: development
Cluster reconfiguration completed!

&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">general</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">drs</category>
      <pubDate>Sun, 14 Jun 2009 16:15:13 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10181</guid>
      <dc:date>2009-06-14T16:15:13Z</dc:date>
      <clearspace:dateToText>5 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>queryDiskParition.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10173</link>
      <description>Take a look at this thread for more information:&lt;br /&gt;
&lt;br /&gt;
&lt;a class="jive-link-message" href="http://communities.vmware.com/message/1283135#1283135"&gt;Re: get disk partitions&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
Sample execution:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@vima ~]$ ./queryDiskParition.pl --server &amp;lt;esx_erver&amp;gt; --device /dev/cciss/c0d0
partition: 1
type: linuxNative
startSector: 63
endSector: 514079
isLogical: NO
size: 250.98 MB

partition: 2
type: linuxNative
startSector: 514080
endSector: 17285939
isLogical: NO
size: 8.00 GB

partition: 3
type: linuxSwap
startSector: 17285940
endSector: 20643524
isLogical: NO
size: 1.60 GB

partition: 4
type: extended
startSector: 20643525
endSector: 143299799
isLogical: NO
size: 58.49 GB

partition: 5
type: vmfs
startSector: 20643588
endSector: 126319094
isLogical: YES
size: 50.39 GB

partition: 6
type: linuxNative
startSector: 126319158
endSector: 134705024
isLogical: YES
size: 4.00 GB

partition: 7
type: linuxNative
startSector: 134705088
endSector: 138897989
isLogical: YES
size: 2.00 GB

partition: 8
type: linuxNative
startSector: 138898053
endSector: 143090954
isLogical: YES
size: 2.00 GB

partition: 9
type: vmkDiagnostic
startSector: 143091018
endSector: 143299799
isLogical: YES
size: 101.94 MB

Total size: 68.33 GB
&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">storage</category>
      <pubDate>Sat, 13 Jun 2009 23:15:16 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10173</guid>
      <dc:date>2009-06-13T23:15:16Z</dc:date>
      <clearspace:dateToText>5 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>updateVMPortgroup.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10112</link>
      <description>Sample execution:&lt;br /&gt;
&lt;br /&gt;
Update Network Adapter 1 to portgroup &lt;b&gt;"production_network"&lt;/b&gt;&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@tancredi ~][http://everest.primp-industries.com|http://everest.primp-industries.com]$ ./updateVMPortgroup.pl --server everest.primp-industries.com --vmname &amp;quot;thegeneral&amp;quot; --vnic 1 --portgroup &amp;quot;production_network&amp;quot;
Reconfiguration of portgroup &amp;quot;production_network&amp;quot; successful for &amp;quot;thegeneral&amp;quot;.
&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;p /&gt;
Update Network Adapter 2 to portgroup &lt;b&gt;"test_network"&lt;/b&gt;&lt;br /&gt;
&lt;p /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@tancredi ~][http://everest.primp-industries.com|http://everest.primp-industries.com]$ ./updateVMPortgroup.pl --server everest.primp-industries.com --vmname &amp;quot;thegeneral&amp;quot; --vnic 2 --portgroup &amp;quot;test_network&amp;quot;
Reconfiguration of portgroup &amp;quot;test_network&amp;quot; successful for &amp;quot;thegeneral&amp;quot;.

&lt;/code&gt;&lt;/pre&gt;&lt;br /&gt;
&lt;p /&gt;
Make sure you spell the VM portgroup correctly as it is case sensitive to your vSwitch configurations. To check, you can always run &lt;b&gt;esxcfg-vswitch -l&lt;/b&gt; on the Service Console or using the vCLI.</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <pubDate>Sun, 07 Jun 2009 03:58:33 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10112</guid>
      <dc:date>2009-06-07T03:58:33Z</dc:date>
      <clearspace:dateToText>5 months, 3 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>listVMByFolder.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10059</link>
      <description>Original Author: &lt;a href="http://communities.vmware.com/people/stumpr" class="jive-link-profile"&gt;stumpr&lt;/a&gt; syndicated from &lt;a class="jive-link-message" href="http://communities.vmware.com/message/1265766#1265766"&gt;Re: listing of folders and its respective vms&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
Sample execution ( &lt;b&gt;--server can be either ESX(i) or vCenter&lt;/b&gt; ):&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@scofield scripts]$ ./listVMByFolder.pl --server reflex.primp-industries.com --username primp

Enter password:
Datacenter: Primp
    Folder: Dev-Hypervisors
        Virtual Machine: ESXi3.5
        Virtual Machine: ESXi4
    Folder: Dev
        Virtual Machine: Devastator
        Virtual Machine: Quentin
        Virtual Machine: ThinStation-Dev
        Virtual Machine: Thinapp
        Virtual Machine: WinXPeDev
        Virtual Machine: grimlock
        Virtual Machine: knoppix
        Virtual Machine: master-xp
        Virtual Machine: testpvscsi
    Folder: Discovered virtual machine
        Virtual Machine: horrid
        Virtual Machine: inTheGhetto
    Folder: ESX-Admin
        Virtual Machine: ESX-Kickstart
        Virtual Machine: VIMA
        Virtual Machine: dhcp-test
        Virtual Machine: kate
        Virtual Machine: scofield
        Virtual Machine: vmm
    Folder: LabDev
        Virtual Machine: testRGS
        Virtual Machine: vdiMaster
    Folder: Primp-Servers
        Folder: GH-ProjectDev
            Virtual Machine: jerry
            Virtual Machine: tom
        Virtual Machine: Auroa
    Folder: Templates
    Folder: User VMs
        Virtual Machine: STA202I
        Virtual Machine: William-XP
    Folder: VMwareViewComposerReplicaFolder
Datacenter: PrimpSkunkworks
    Folder: Discovered Virtual Machine
&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">general</category>
      <pubDate>Fri, 29 May 2009 16:14:51 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10059</guid>
      <dc:date>2009-05-29T16:14:51Z</dc:date>
      <clearspace:dateToText>6 months, 1 day ago</clearspace:dateToText>
    </item>
    <item>
      <title>getAllPowedOffVMs.pl</title>
      <link>http://communities.vmware.com/docs/DOC-10058</link>
      <description>Sample execution:&lt;br /&gt;
&lt;br /&gt;
&lt;pre class="jive-pre"&gt;&lt;code class="jive-code jive-plain"&gt;[vi-admin@vima ~]$ ./getAllPowedOffVMs.pl --server reflex.primp-industries.com --username primp --cluster PrimpESX-cluster
Enter password:
Found Cluster: PrimpESX-cluster
        Checking host: himalaya.primp-industries.com
                vmm is poweredOff

                ESXi3.5 is poweredOff
                knoppix is poweredOff
                horrid is poweredOff
                ThinStation-Dev is poweredOff
                vdiMaster is poweredOff
                Fourier is poweredOff
        Checking host: kang.primp-industries.com
                master-xp is poweredOff
&lt;/code&gt;&lt;/pre&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">general</category>
      <pubDate>Thu, 28 May 2009 16:59:08 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10058</guid>
      <dc:date>2009-05-28T16:59:08Z</dc:date>
      <clearspace:dateToText>6 months, 2 days ago</clearspace:dateToText>
    </item>
    <item>
      <title>ghettoVCBg2.pl - Free alternative for backing up VMs in ESX(i) 3.5 and 4.x (no SSH console required!)</title>
      <link>http://communities.vmware.com/docs/DOC-9984</link>
      <description>&lt;h2&gt;Description:&lt;/h2&gt;
This tool is the follow up release of the &lt;a class="jive-link-wiki" href="http://communities.vmware.com/docs/DOC-8760"&gt;ghettoVCB&lt;/a&gt; backup utility which allows users to perform backups of virtual machines residing on &lt;b&gt;ESX(i) 3.5+&lt;/b&gt; servers using methodology similar to VMware's VCB tool. By incorporating highly constructive feedback from the VMware community and utilizing the existing VI API, ghettoVCB&amp;rsquo;s framework was completely rewritten to be &lt;a class="jive-link-external" href="http://www.youtube.com/watch?v=K2cYWfq--Nw"&gt;harder, better, faster, stronger&lt;/a&gt;.&lt;br /&gt;
&lt;br /&gt;
The primary motivation for ghettoVCBg2 was to provide ESXi users with access to the utility without relying on unlocking and utilizing the unsupported console. To satisfy this requirement, the rebuilt framework takes advantage of the &lt;a class="jive-link-external" href="http://www.vmware.com/support/developer/viperltoolkit/"&gt;VI Perl Toolkit/vSphere SDK for Perl&lt;/a&gt; which is present in the &lt;a class="jive-link-external" href="http://www.vmware.com/support/developer/vima/"&gt;VIMA/vMA&lt;/a&gt; virtual appliance provided by VMware. As a result, ghettoVCBg2 provides a more proper backup solution that administrators can utilize in their virtual infrastructure. &lt;br /&gt;
&lt;br /&gt;
As it stands, it is a requirement that ghettoVCB be invoked directly on each of the ESX servers hosting virtual machines in need of a backup. By taking advantage of VIMA/vMA, the entire backup process becomes centralized in turn eliminating the abovementioned requirement. Additionally, by leveraging the vi-fastpass library, unattended authentication between VIMA/vMA and target ESX servers is made possible. This alleviates the need to continually pass in credentials for each ESX server. &lt;br /&gt;
&lt;br /&gt;
By centralizing the backup process, individual virtual machine backup lists pertaining to their respective ESX(i) servers are no longer required. ghettoVCBg2 has the ability to identify virtual machines and their respective hosts, potentially eliminating any past confusion associated with maintaining multiple lists. &lt;br /&gt;
&lt;br /&gt;
In its current configuration, the script will allow up to 3 unique backups of the Virtual Machine before it will overwrite the previous backups; this however, can be modified to fit procedures if need be. Please be diligent in running the script in a test or staging environment before using it on production live Virtual Machines; this script functions well within our environment but there is a chance that it may not fit well into other environments.&lt;br /&gt;
&lt;br /&gt;
Find more information at: &lt;a class="jive-link-wiki" href="http://communities.vmware.com/docs/DOC-9843"&gt;http://communities.vmware.com/docs/DOC-9843&lt;/a&gt;</description>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vcb</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">backup</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_backup</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">esx3.5</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vima</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vima1.0</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vma</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vma4.0</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">ghettovcbg2</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">esx3.5</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">esx4</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">esxi_3.5</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">esxi_4</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">esxi_4</category>
      <pubDate>Thu, 21 May 2009 14:32:09 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-9984</guid>
      <dc:date>2009-05-21T14:32:09Z</dc:date>
      <clearspace:dateToText>6 months, 1 week ago</clearspace:dateToText>
    </item>
    <item>
      <title>Windows VM Names List</title>
      <link>http://communities.vmware.com/docs/DOC-10041</link>
      <description />
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">general</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">names</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">list</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vms</category>
      <pubDate>Wed, 20 May 2009 22:35:47 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10041</guid>
      <dc:date>2009-05-20T22:35:47Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>VMs Snapshot</title>
      <link>http://communities.vmware.com/docs/DOC-10040</link>
      <description />
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">snapshot</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vms</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">all</category>
      <pubDate>Wed, 20 May 2009 22:34:55 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10040</guid>
      <dc:date>2009-05-20T22:34:55Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>vMotion</title>
      <link>http://communities.vmware.com/docs/DOC-10039</link>
      <description />
      <category domain="http://communities.vmware.com/tags?communityID=3076">storage</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">move</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">host</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">target</category>
      <pubDate>Wed, 20 May 2009 22:33:36 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10039</guid>
      <dc:date>2009-05-20T22:33:36Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>VM Host List</title>
      <link>http://communities.vmware.com/docs/DOC-10038</link>
      <description />
      <category domain="http://communities.vmware.com/tags?communityID=3076">data</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">center</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">general</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">list</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">hosts</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vms</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">host</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">datacenter</category>
      <pubDate>Wed, 20 May 2009 22:32:25 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10038</guid>
      <dc:date>2009-05-20T22:32:25Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>Print Performance</title>
      <link>http://communities.vmware.com/docs/DOC-10037</link>
      <description />
      <category domain="http://communities.vmware.com/tags?communityID=3076">performance</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">print</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">printing</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">data</category>
      <pubDate>Wed, 20 May 2009 22:31:12 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10037</guid>
      <dc:date>2009-05-20T22:31:12Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
      <clearspace:replyCount>1</clearspace:replyCount>
    </item>
    <item>
      <title>Powering on VMs</title>
      <link>http://communities.vmware.com/docs/DOC-10036</link>
      <description />
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm_operations</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">powering</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">on</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vms</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">vm</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">power</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">on</category>
      <pubDate>Wed, 20 May 2009 22:28:47 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10036</guid>
      <dc:date>2009-05-20T22:28:47Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>Basic Template</title>
      <link>http://communities.vmware.com/docs/DOC-10035</link>
      <description />
      <category domain="http://communities.vmware.com/tags?communityID=3076">general</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">basic</category>
      <category domain="http://communities.vmware.com/tags?communityID=3076">template</category>
      <pubDate>Wed, 20 May 2009 22:27:40 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10035</guid>
      <dc:date>2009-05-20T22:27:40Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>Clone VM from SnapShot</title>
      <link>http://communities.vmware.com/docs/DOC-10034</link>
      <description />
      <category domain="http://communities.vmware.com/tags?communityID=3077">vm_operations</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">clone</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">cloning</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">vm</category>
      <category domain="http://communities.vmware.com/tags?communityID=3077">snapshot</category>
      <pubDate>Wed, 20 May 2009 21:04:24 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10034</guid>
      <dc:date>2009-05-20T21:04:24Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
      <clearspace:replyCount>3</clearspace:replyCount>
    </item>
    <item>
      <title>Retrieve Performance Statistics</title>
      <link>http://communities.vmware.com/docs/DOC-10033</link>
      <description />
      <category domain="http://communities.vmware.com/tags?communityID=3080">performance</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">retrieve</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">stats</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">statistics</category>
      <pubDate>Wed, 20 May 2009 20:55:27 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10033</guid>
      <dc:date>2009-05-20T20:55:27Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
      <clearspace:replyCount>12</clearspace:replyCount>
    </item>
    <item>
      <title>Create/Remove Snapshots</title>
      <link>http://communities.vmware.com/docs/DOC-10032</link>
      <description />
      <category domain="http://communities.vmware.com/tags?communityID=3080">vm_operations</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">create</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">remove</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">snapshots</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">snap</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">shots</category>
      <pubDate>Wed, 20 May 2009 20:53:15 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10032</guid>
      <dc:date>2009-05-20T20:53:15Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>Monitor Changes to Properties of Managed Objects</title>
      <link>http://communities.vmware.com/docs/DOC-10031</link>
      <description />
      <category domain="http://communities.vmware.com/tags?communityID=3080">general</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">monitor</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">properties</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">managed</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">objects</category>
      <pubDate>Wed, 20 May 2009 20:51:45 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10031</guid>
      <dc:date>2009-05-20T20:51:45Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>Property Collector to Retrieve Properties  of managed objects(multiple ways)</title>
      <link>http://communities.vmware.com/docs/DOC-10030</link>
      <description />
      <category domain="http://communities.vmware.com/tags?communityID=3080">general</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">properties</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">propertycollector</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">retrieve</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">managed</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">objects</category>
      <pubDate>Wed, 20 May 2009 20:49:06 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10030</guid>
      <dc:date>2009-05-20T20:49:06Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
    </item>
    <item>
      <title>PropertyCollector to Retrieve the Properties of a Managed Object</title>
      <link>http://communities.vmware.com/docs/DOC-10029</link>
      <description />
      <category domain="http://communities.vmware.com/tags?communityID=3080">general</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">retrieve</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">properties</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">of</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">managed</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">objects</category>
      <pubDate>Wed, 20 May 2009 20:46:34 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10029</guid>
      <dc:date>2009-05-20T20:46:34Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
      <clearspace:replyCount>2</clearspace:replyCount>
    </item>
    <item>
      <title>Search For Managed Entity</title>
      <link>http://communities.vmware.com/docs/DOC-10028</link>
      <description />
      <category domain="http://communities.vmware.com/tags?communityID=3080">general</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">search</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">managed</category>
      <category domain="http://communities.vmware.com/tags?communityID=3080">entity</category>
      <pubDate>Wed, 20 May 2009 20:44:59 GMT</pubDate>
      <guid>http://communities.vmware.com/docs/DOC-10028</guid>
      <dc:date>2009-05-20T20:44:59Z</dc:date>
      <clearspace:dateToText>2 months, 2 weeks ago</clearspace:dateToText>
    </item>
  </channel>
</rss>

