Network Time Protocol (NTP) is a service that can be used to synchronize time on network connected devices. Before we dive into what NTP is, we need to understand why we need accurate time.
The obvious thing is network devices need an accurate clock. Things like log files with the proper time stamp are important in troubleshooting. Accurate timing also helps with security prevention measures. Some attacks use vulnerabilities in time stamps to add in bad payloads or manipulate data. Some companies require accurate time stamps on files and transactions as well for compliance purposes.
So what are these Stratum levels I hear about?
NTP has several levels divided into stratum. All this is the distance from the reference clock source. A clock which relays UTC (Coordinated Universal Time) that has little to no delay (we are talking nanoseconds) are Stratum-0 servers. These are not used on the network. These are usually atomic and GPS clocks. A Stratum-0 server is connected to time servers or stratum-1 via GPS or a national time and frequency transmission. A Stratum 1 device is a very accurate device and is not connected to a Stratum-0 clock over a network. A Stratum-2 clock receives NTP packets from a Stratum-1 server, a Stratum-3 receives packets from a Stratum-2 server, and so on. It’s all relative of where the NTP is in relationship to Stratum-1 servers.
Why are there levels?
The further you get away from Stratum-0 the more delay there is. Things like jitter and network delays affect accuracy. Most of us network engineers are concerned with milliseconds (ms) of latency. Time servers are concerned with nanoseconds (ns). Even a server directly connected to a Stratum-0 reference will add 8-10 nanoseconds to UTC time.
My Mikrotik has an NTP server built in? Is that good enough?
This depends on what level of accuracy you want. Do you just need to make sure all of your routers have the same time? then synchronizing with an upstream time server is probably good enough. Having 5000 devices with the same time, AND not having to manually set them or keep them in sync manually is a huge deal.
Do you run a VOIP switch or need to be compliant when it comes to transactions on servers or need to be compliant with various things like Sox compliance you may need a more accurate time source.
What can I do for more accurate time?
Usually, a dedicated appliance is what many networks use. These are purpose built hardware that receives a signal from GPS. the more accurate you need the time, the more expensive it will become. Devices that need to be accurate to the nanosecond are usually more expensive than ones accurate to a microsecond.
If you google NTP Appliance you will get a bunch of results. If you want to setp up from what you are doing currently you can look into these links:
How to Build a Stratum 1 NTP Server Using A Raspberry Pi
Building a Stratum 1 NTP Server with a Raspberry Pi