2 Replies Latest reply on Sep 26, 2011 8:30 AM by alanrenouf

    Script to change VMXNET3 MacAddress type to Static with current Mac

    RobbertE Lurker

      Hi!

       

      The inevitable has happend, I have to work with PowerCLI. ANd my gosh, this is Powerful! But still, new to all this and looking for a specific solution:

       

      I need to change the Mac address to static on all VMXNET3 network adapters, whilst retaining the current MAC address. So, in functional Language

       

      For all VMNICs in all WIndows Virtual Machines:

      Get current MAC address

      Set addresstype = static

      Set MAC address = current MAC Addres

       

      Then the changes in VMX msut get to vCenter:

       

      "vim-cmd /vmsvc/reload /vmfs/volumes/<Datastore>/<pathtoVM>/VM.vmx"

       

      Is this all possible with ESX / vCenter 4.1.U1 and WIndows 2008 R2 Sp1?

       

      Many thanks!