how can I change my hostname's SHORT NAME to its FQDM.
$short = disney
want:
$FQDN = disney.land.com
thanks
Did you already try with the Set-VMHostNetwork cmdlet ?
Something like
Get-VMHost MyESx | Get-VMHostNetwork |
Set-VMHostNetwork -DomainName "land.com"
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
Did you already try with the Set-VMHostNetwork cmdlet ?
Something like
Get-VMHost MyESx | Get-VMHostNetwork |
Set-VMHostNetwork -DomainName "land.com"
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
I seen that but isn't that just for the esx nodes? This is a vm. I need it because I'm calling another script that requires the FQDN as one of the args.
Not sure if this is the best way to acheive these results... but it works..
$short = "disney"
$fqdn = $short | ForEach-Object{ $_ + '.land.com' }
One of the following looks easier to me:
$short = "disney"
$fqdn = "$short.land.com"
or:
$fqdn = $short + ".land.com"
Do you only want to set the FQDN in a variable, or set it in the OS of the guest ?
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
Only in a variable to be use elsewhere
And do you know the domainname ? Is it always the same ?
In that case the solution from Robert will work.
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
yes the domainname is always the same... Robert's will work just find.
thank you