ESXi will not resume syslog log sending when destination has been down for some time

Recently I was playing with ESXi syslog and Logstash + Graylog. For some reason Logstash instance died. After restarting the Logstash only some ESXi hosts resumed log sending. Quick google search revealed that it is a know issue and solution is to reload syslog on the host. After running following script in PowerCLI against my vCenter the log sending resumed.

$hosts = Get-VMHost
foreach($vihost in $hosts){
$esxcli = get-vmhost $vihost | Get-EsxCli
$esxcli.system.syslog.reload()
}

Good information about PowerCLI and ESXCLI:
http://www.virten.net/2016/11/how-to-use-esxcli-v2-commands-in-powercli/
http://www.virten.net/2014/02/howto-use-esxcli-in-powercli/