Hi @GRAY Mike , I understand you want to make sure that all VMs (Windows and Linux) and Azure Functions use the same source for time synchronization.
Azure hosts are synchronized to internal Microsoft time servers that take their time from Microsoft-owned Stratum 1 devices, with GPS antennas. Virtual machines in Azure can either depend on their host to pass the accurate time (host time) on to the VM or the VM can directly get time from a time server, or a combination of both.
There are three options for configuring time sync for your Windows VMs hosted in Azure:
- Host time and time.windows.com. This is the default configuration used in Azure Marketplace images.
- Host-only.
- Use another, external time server with or without using host time. For this option follow the Time mechanism for Active Directory Windows Virtual Machines in Azure guide.
Historically, most Azure Marketplace images with Linux have been configured in one of these: (to confirm ntpd is synchronizing correctly, run the ntpq -p
command)
- No time sync service is running by default.
- ntpd is running as the time sync service, and synchronizing against an external NTP time source that is accessed over the network. For example, Ubuntu 18.04 LTS Marketplace images use ntp.ubuntu.com.
- Some Azure Marketplace images with Linux are being changed to use chronyd as the time sync service, and chronyd is configured to synchronize against the Azure host rather than an external NTP time source.
The Azure host time is usually the best time source to synchronize against, as it is maintained accurately and reliably, and is accessible without the variable network delays inherent in accessing an external NTP time source over the public internet.
Azure Functions, depending on the OS and the hosting plan, will use the default time sync configuration on the host.
Please accept an answer if correct. Original posters help the community find answers faster by identifying the correct answer. Here is how.