<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.vi-toolkit.com/index.php?action=history&amp;feed=atom&amp;title=PowerCLI%3A_Scripted_edit_of_a_VMX_file</id>
	<title>PowerCLI: Scripted edit of a VMX file - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.vi-toolkit.com/index.php?action=history&amp;feed=atom&amp;title=PowerCLI%3A_Scripted_edit_of_a_VMX_file"/>
	<link rel="alternate" type="text/html" href="https://wiki.vi-toolkit.com/index.php?title=PowerCLI:_Scripted_edit_of_a_VMX_file&amp;action=history"/>
	<updated>2026-06-17T17:33:52Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.43.8</generator>
	<entry>
		<id>https://wiki.vi-toolkit.com/index.php?title=PowerCLI:_Scripted_edit_of_a_VMX_file&amp;diff=1096&amp;oldid=prev</id>
		<title>Wila: Scripted edit of VMX file by Craig Baltzer</title>
		<link rel="alternate" type="text/html" href="https://wiki.vi-toolkit.com/index.php?title=PowerCLI:_Scripted_edit_of_a_VMX_file&amp;diff=1096&amp;oldid=prev"/>
		<updated>2009-09-08T12:46:33Z</updated>

		<summary type="html">&lt;p&gt;Scripted edit of VMX file by Craig Baltzer&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;===  Scripted edit of a VMX file ===&lt;br /&gt;
author: Craig Baltzer&lt;br /&gt;
==== Description ====&lt;br /&gt;
Craig shows here how you can adjust keys and values in a scripted manner for the hardware configuration of your virtual machine.&lt;br /&gt;
&lt;br /&gt;
==== Code ====&lt;br /&gt;
  $vm = Get-View (Get-VM +NameofVMtoUpdate+).ID&lt;br /&gt;
  $vmConfigSpec = New-Object VMware.Vim.VirtualMachineConfigSpec&lt;br /&gt;
  $vmConfigSpec.extraconfig += New-Object VMware.Vim.optionvalue&lt;br /&gt;
  $vmConfigSpec.extraconfig[0].Key=&amp;quot;lefthandsideofentry&amp;quot;&lt;br /&gt;
  $vmConfigSpec.extraconfig[0].Value=&amp;quot;rigthhandsideofentry&amp;quot;&lt;br /&gt;
  $vm.ReconfigVM($vmConfigSpec)&lt;br /&gt;
&lt;br /&gt;
Where&lt;br /&gt;
&lt;br /&gt;
* NameofVMtoUpdate is the name of the VM you want to update (from the vCenter inventory)&lt;br /&gt;
* lefthandsideofentry is the advanced configuration entry you want to set&lt;br /&gt;
* rigthhandsideofentry is the value for the advanced configuration entry&lt;br /&gt;
&lt;br /&gt;
==== Location ====&lt;br /&gt;
&lt;br /&gt;
[http://communities.vmware.com/thread/189302 VMTN: Scripted edit of a VMX file]&lt;br /&gt;
&lt;br /&gt;
[[Category: PowerCLI]] [[Category: VM Management]]&lt;/div&gt;</summary>
		<author><name>Wila</name></author>
	</entry>
</feed>