1 |
1 |
'''[wiki:GraspExtrasSoftware STARGRASP NTP client]''' |
2 |
2 |
[[TracNav(GraspExtrasContents)]] |
3 |
3 |
As of SVN revision 4427 of the stage 2 software, the STARGRASP controller has included experimental support for synchronising with an NTP server to provide timing for various events. The client can be started via the '''[wiki:GraspSwControllerCmdNtp ntp]''' command. |
4 |
4 |
== Startup Performance == |
5 |
5 |
When first started, the NTP client first sets the system time from the first NTP transaction in a single step. Since it cannot make any assumptions about the system's clock drift, it initially starts with a drift correction of zero and attempts to figure out the drift from first principles over successive updates. The result is an initial overshoot that's typically on the order of a couple of milliseconds (the vertical scale below is in usec): |
6 |
6 |
[[Image(stargrasp_ntp_startup.png)]] |
7 |
7 |
After a couple of minutes, the NTP client typically settles to an NTP offset in the region of 100-200 usec, barring perturbations from the NTP server. |
|
8 |
== Stargrasp Client: NTP server link speed == |
|
9 |
|
|
10 |
It has been observed that the controller's NTP client performs far better when connected to an NTP server via a Gigabit ethernet link as opposed to one serving time via an 100Mbit link. |
|
11 |
|
|
12 |
The following two graphs are the calculated NTP offset for 16 STARGRASP servers synched to a local network NTP server on the same computing hardware first via a 100Mbit link (top) and then via a Gigabit ethernet port (bottom): |
|
13 |
|
|
14 |
[[Image(ntp_controller_100mbit.png)]] |
|
15 |
[[Image(ntp_controller_gigabit.png)]] |
|
16 |
|
|
17 |
The path to the server via its Gigabit port is somewhat lower-latency, but the additional round-trip time is supposed to be accounted for by the two pairs of timestamps in the NTP packet. |
|
18 |
|
|
19 |
It is therefore recommended that if the controller NTP client is used, the server should connect to the controller via a Gigabit link for better performance. |
|
20 |
|