UberGeek1
Contributor
Contributor

Migrate Host and VMKernel Adapters to vSS from vDS

Jump to solution

I'm having a brain fart here.  I need to move a host from one vCenter to another, and to do this I have to move the vmk interfaces back to vSS so I can unjoin the host from the "source" vCenter and join to the "destination" vCenter and then migrate them to the new vDS.  My brain fart is what is the command to move the vmk0 (management) back to vSS from vDS? 

The flow I'm planning on is create vSwitch0 if it doesn't exist, create the Standard PG in the correct VLAN for Management, then move one pNIC from the vDS to the vSS, then move the vmk0, and finally move the second pNIC to the vSS, then unjoin from the "source" vCenter.  I will then rinse and repeat for the destination vCenter.

For background, I have a vCenter that the web client has completely borked itself, and the only option is to migrate to a new vCenter.  Doing this manually isn't bad for one or two, or even 10 hosts, but I have almost 200 hosts I need to do this process.  So I plan to evacuate a couple hosts, move them to the "destination" vCenter, then use Cross vCenter vMotion to move the VMs to these hosts until I get a chunk moved, move a bunch more hosts, and repeat until complete.  Oh, and it's a couple thousand VMs on these hosts, so the more scripted I can make this the better.  I already have the Cross vCenter vMotion stuff scripted and such, it's this scripting/automation of moving the host that is alluding me.

If I figure this out before it's answered, I will post here as I'm hearing a lot of folks are having issues with vCenter Appliance 6.0 U3e having certificate issues internally that breaks inventory service and web client, which is the issue I have that engineering at VMware can't figure out.

Sincerely, Jody L. Whitlock
0 Kudos
1 Solution

Accepted Solutions
LucD
Leadership
Leadership

I suspect William has already tackled your issue.

See Automate the reverse, migrating from vSphere Distributed Switch to Virtual Standard Switch using Pow...

Don't mind the PowerCLI 5.5 reference in the post, this will also work for later PowerCLI versions.

---------------------------------------------------------------------------------------------------------

Was it helpful? Let us know by completing this short survey here.


Blog: lucd.info  Twitter: @LucD22  Co-author PowerCLI Reference

View solution in original post

0 Kudos
2 Replies
LucD
Leadership
Leadership

I suspect William has already tackled your issue.

See Automate the reverse, migrating from vSphere Distributed Switch to Virtual Standard Switch using Pow...

Don't mind the PowerCLI 5.5 reference in the post, this will also work for later PowerCLI versions.

---------------------------------------------------------------------------------------------------------

Was it helpful? Let us know by completing this short survey here.


Blog: lucd.info  Twitter: @LucD22  Co-author PowerCLI Reference

View solution in original post

0 Kudos
UberGeek1
Contributor
Contributor

It definitely does look like it's the same thing William addresses and never would've thought of using Add-VirtualSwitchPhysicalNetworkAdapter for this.  I'm surprised that it doesn't bomb out with the pNICs assigned to the vDS already, but then again if I would've just RTFM then I would've seen the critical piece:

"This cmdlet adds a host physical NIC to a standard virtual switch. If VMHost virtual network adapters are specified, the cmdlet migrates them to the virtual switch as well.

Note: If VMHost virtual network adapters are specified, the cmdlet migrates them to the respective port groups or creates new ones if VirtualNicPortgroup is not specified."

So it seems that there's more hidden features in the cmdlet than one would assume with it using the ADD verb.  Lesson learned.

Thanks for the response!

Sincerely, Jody L. Whitlock
0 Kudos