Quantcast
Channel: VMware Communities: Message List
Viewing all articles
Browse latest Browse all 220961

Re: While trying to deploy Linux VM from template using PowerCLI , during customization it giving error as "you must not provide dns when you create NIC mapping for customization with type "Linux"

$
0
0

When I use the below PowerCLI script to deploy VMs from Template I am getting the below error.

 

 

Here is the Complete PowerCLI script:

Import-Csv "C:\Users\sg0217865\Desktop\NewVMs.csv" -UseCulture | %{

    Get-OSCustomizationSpec $_.Customization | Get-OSCustomizationNicMapping | `

    Set-OSCustomizationNicMapping -IpMode UseStaticIP -IpAddress $_.ip `

        -SubnetMask $_.Subnet -DefaultGateway $_.gw

    $vm=New-VM -Name $_.Name -Template $_.Template -Host $_.Host `

        -Datastore $_.Datastore -Confirm:$false -RunAsync | Set-OSCustomizationSpec -OSCustomizationSpec $_.Customization

}


Viewing all articles
Browse latest Browse all 220961

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>