Automation

 View Only
  • 1.  VLAN id change

    Posted Sep 15, 2023 05:13 PM

    Hi everyone

     I would like to change the vlan ID on my esxi host VM network adapter from 0 to another vlain ID , how can I accomplish this using powercli, so I can change 200 esxi host during a loop to the same new vland id

     

    Thanks 



  • 2.  RE: VLAN id change

    Posted Sep 15, 2023 05:29 PM

    I assume you are talking about a VSS?
    If yes, have a look at Solved: Re: script to change vlanid ip and gateway for ES... - VMware Technology Network VMTN



  • 3.  RE: VLAN id change

    Posted Sep 15, 2023 07:32 PM

    yes sir

     

    fborges555_0-1694806311074.png

     



  • 4.  RE: VLAN id change

    Posted Sep 26, 2023 09:14 AM

    I think when you only change the VLAN it will be unavailable by the current network and it will be revert back to the previous state maybe better to create a new vmkernel in new vlan



  • 5.  RE: VLAN id change

    Posted Sep 26, 2023 05:35 PM

    That depends on how your infrastructure is configured.

    Changing the vlan id on a vm port group means that all VMs may not be reachable (if it is not done right). 

     

    I would prefer, to create a new port group with the new vlan and then move the VMs to the new port group, one by one (of course with a script) and perform a PING after each change so that you're sure that the VMs are reachable on the network.

     

    Can you tell us more about your infrastructure, then we can write some kind of script that helps you automate that.