Pages

Saturday, January 26, 2008

Edit vswitch properties via command-line

OK so I have been trying to figure out a way to script the settings for vSwitches in ESX 3.x and got it!

vimsh is the command and there is a great site out there that has some pdf files talking about the various things you can do with vimsh.xtravirt.com

So for example: if you wanted to Reject Forged Transmits you would issue the following command from the service console.
vimsh -n -e "hostsvc/net/vswitch_setpolicy --securepolicy-forgedxmit=false vSwitch0"