I am trying to run two scripts in the Set-AdvancedSetting -Value for alll hosts in a particular "Datacenter".
How would I create one script that sets the Adv settings without me actually manually starting the second one? Please help if you can.
#Set Hostd logging level to info (default is verbose)
Get-VMHost xxhost01.sidley.com | Get-AdvancedSetting -Name Config.HostAgent.log.level | Set-AdvancedSetting -Value "info" -Confirm:$false
#Set Vpxa logging level to info (default is verbose)(must be connected to VC)
Get-VMHost xxhost01.sidley.com | Get-AdvancedSetting -Name Vpx.Vpxa.config.log.level | Set-AdvancedSetting -Value "info" -Confirm:$false
There are multiple hosts all in the same Datacenter .. "Zed".
How can I run both scripts on all the hosts?
Thank you very much..