Some helpfull PowerShell functions (working with 60 days trail license)

Variables:

 $ServerIP = "YourESXiServerIP" $SysLog = "YourSyslogServerIP" 

Configure Syslog server using Powershell

 function syslog { $VMHost = Get-VMHost -Name $ServerIP Set-VMHostSysLogServer -VMHost $VMHost -SysLogServer $SysLog -SysLogServerPort 514 } 

Configure NTP server and restart NTP service

 function set-ntp{ $vmHost = Get-VMHost -Name $ServerIP Add-VMHostNtpServer -VMHost $VMHost -NtpServer YourNTPserver1 Add-VMHostNtpServer -VMHost $VMHost -NtpServer YourNTPserver1 Get-VmHostService -VMHost $VMHost |Where-Object {$_.key-eq "ntpd"} |Start-VMHostService } 

Create a new vSwitch

 function create-vSwitch{ $vmHost = Get-VMHost -Name $ServerIP $vmotion = New-VirtualSwitch -VMHost $vmHost -Name vSwitch1 -Nic vmnic4 -NumPorts 1024 }