[ntp:questions] Selective peerstats collection

David Lord snews at lordynet.org
Sun Dec 2 22:01:15 UTC 2012


David Taylor wrote:
> On 02/12/2012 17:51, David Lord wrote:
> []
>> I use peer_summary (and loop_summary) from the ntpd distro. It
>> may not be what you are looking for. It should also be easy to
>> set a cron job to filter peerstats each day to extract entries
>> for peers you want.
>>
>> This is from peer_summary on 192.168.59.67:
>>
>> Two stratum-1 on the lan, 192.168.59.61 from a Sure gps/pps
>> usually with offset < 3 usec, and 192.168.59.64 from a Conrad MSF
>> receiver usually with offset < 300 usec.
>>
>> peerstats.20110101
>>         ident     cnt     mean     rms      max     delay     dist     
>> disp
>> ========================================================================== 
>>
>> 192.168.59.22    112    0.158    0.624    1.557    0.567   23.763    
>> 9.854
>> 192.168.59.61     90    0.585    0.812    1.731    0.811   22.482    
>> 9.296
>> 192.168.59.64    207   -0.421    0.853    3.106    0.415  192.259    
>> 7.576
>> 192.168.59.210    92    0.424    0.566    1.567    0.630   20.648    
>> 8.252
>> 158.152.1.76      55   -0.088    0.768    2.052   30.318   46.053   
>> 16.456
>> 130.159.196.117   52   -0.124    0.731    1.691   39.524   51.098   
>> 16.490
> []
>> David
> 
> Thanks for that, David.  No, what I want is to /collect/ data only for 
> selected peers, to reduce the file size and amount of I/O activity (the 
> "disk" for the system might be an SD card).  I can select 
> post-collection with my own NTP Plotter program, which runs on Windows.
> 
>   http://www.satsignal.eu/software/net.htm#NTPplotter

My peerstats grows but the summary is manageable. I have the option
of logging to /tmpfs in memory but if your peerstats is that large
that would be a problem. My daily peerstats would be under 1 MB for
when I had about 6 pcs on the lan but is under 100 kB per system and
I have enough ram to use /tmpfs if it was needed. Using peer_summary
trims the logfile daily so just now peerstats for the day is 43076
whilst peer_summary 20120101-20121201 is 204606 bytes. When I
started with NetBSD 1.5 the pcs each had 8 MB ram, and hdd were one
with 245 MB and second with 450 MB so ram was tight but storage
wasn't  a problem.


David



More information about the questions mailing list