VMware Cloud Community
Sunny4422000
Contributor
Contributor

Assign IP address to Multiple VM's from Excel

Hi All

I've tried several ways to assign IP address to multiple servers from Excel (IP address, Gateway, Subnet, DNS1, DNS2) spread sheet and non of them worked.

Used the Set-networkadpater and it seems like its not valid anymore.

Is there an easy way to do this?

Thanks

0 Kudos
1 Reply
LucD
Leadership
Leadership

I suspect you are referring to the Set-VMGuestNetworkInterface cmdlet and not the Set-NetworkAdapter cmdlet.

That one indeed allowed you to set the network configuration inside a guest OS for specific guest OS families and versions.

The latter never had an option to set the IP address in the guest OS.

Those 'Guest' cmdlets have been removed, since they required quite a bit of customised scripts.

Nowadays, you can run the network configuration for a guest OS inside the guest OS with the Invoke-VMScript cmdlet.

There are many sample script for that available in this forum.

For example Re: Create a VM from CSV File


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

0 Kudos