ESXi with PowerCLI ex: Syslog

You can download VMware PowerCLI below link.

https://my.vmware.com/web/vmware/details?productId=352&downloadGroup=PCLI550

Connect V Center

Connect-VIServer VCENTER

 

Syslog Change all vmhost

get-vmhost | Set-VMHostAdvancedConfiguration -NameValue @{'Config.HostAgent.log.level'='warning';'Vpx.Vpxa.config.log.level'='warning';'Syslog.global.logHost'='udp://172.16.253.20:514'}

PowerCLI like to Powershell base.

powercli

And you can use command like this.

foreach ($myHost in Get-VMHost)
{
    Write-Host "ESX: $myHost"

    $esxcli = Get-EsxCli -VMHost $myHost
    $esxcli.system.syslog.reload()
}

Good luck!

Facebook Comments

Leave A Reply

이메일은 공개되지 않습니다. 필수 입력창은 * 로 표시되어 있습니다

This site uses Akismet to reduce spam. Learn how your comment data is processed.