GuerrillaNtp CLI

GuerrillaNtp » CLI

GuerrillaNtp CLI is a demo command-line SNTP client written in C# using GuerrillaNtp library. It queries specified NTP servers and prints NTP time details.


Since this is just a demo, there is no binary distribution. Download and build the sources from GitHub or Bitbucket. You will need NET 6+. Sources are distributed under Apache License 2.0.


Use the dotnet tool to build and run the program.

dotnet run --project GuerrillaNtp.Cli

You should get output that looks something like this:

GuerrillaNtp CLI 1.1.0 using GuerrillaNtp library 3.1.0


Received response
Synchronized:       yes
Network time (UTC): 08:59:47.427
Network time:       08:59:47.428
Correction offset:  0.0019808
Round-trip time:    0.0122998
Origin time:        08:59:47.406
Receive time:       08:59:47.414
Transmit time:      08:59:47.414
Destination time:   08:59:47.418
Leap second:        NoWarning
Stratum:            4
Reference ID:       0xa29fc87b
Reference time:     08:52:57.323
Root delay:         25.5889ms
Root dispersion:    21.8048ms
Poll interval:      2^3s
Precision:          2^-23s

To query other NTP servers, just list them space-separated on the command line.

Next steps