ntp_main_graph () { last_x="$1" /usr/bin/rrdtool graph /srv/www/img/ntp-main-$last_x.png --title "NTP Gesamtuebersicht - $last_x" \ --imginfo 'NTP Gesamtuebersicht' \ $rrd_width $rrd_height $rrd_common_opts --watermark "$rrd_watermark" \ --end now --start end-${last_x} \ --vertical-label "Sekunden" \ DEF:time_offset_error=$rrd_dbpath/ntpd/time_offset-error.rrd:seconds:AVERAGE \ DEF:time_offset_loop=$rrd_dbpath/ntpd/time_offset-loop.rrd:seconds:AVERAGE \ VDEF:time_offset_error_max=time_offset_error,MAXIMUM \ VDEF:time_offset_error_avg=time_offset_error,AVERAGE \ VDEF:time_offset_error_min=time_offset_error,MINIMUM \ VDEF:time_offset_error_last=time_offset_error,LAST \ VDEF:time_offset_loop_max=time_offset_loop,MAXIMUM \ VDEF:time_offset_loop_avg=time_offset_loop,AVERAGE \ VDEF:time_offset_loop_min=time_offset_loop,MINIMUM \ VDEF:time_offset_loop_last=time_offset_loop,LAST \ COMMENT:"\t\t\t\t\g" \ COMMENT:"Maximum\t\t\g" \ COMMENT:"Durchschnitt\t\g" \ COMMENT:"Minimum\t\t\g" \ COMMENT:"Letzter\l" \ LINE1:time_offset_error$rrd_col_blue_light:"time-offset-error" \ GPRINT:time_offset_error_max:"% 2.1lf " \ GPRINT:time_offset_error_avg:"% 2.1lf " \ GPRINT:time_offset_error_min:"% 2.1lf " \ GPRINT:time_offset_error_last:"% 2.1lf \l" \ LINE1:time_offset_loop$rrd_col_red_light:"time-offset-loop" \ GPRINT:time_offset_loop_max:"% 2.1lf " \ GPRINT:time_offset_loop_avg:"% 2.1lf " \ GPRINT:time_offset_loop_min:"% 2.1lf " \ GPRINT:time_offset_loop_last:"% 2.1lf \l" \ COMMENT:"Letztes update\:\t$rrd_last_update" } ntp_frequency_graph () { last_x="$1" /usr/bin/rrdtool graph /srv/www/img/ntp-frequency-$last_x.png --title "NTP Frequenz in ppm - $last_x" \ --imginfo 'NTP Frequenz in ppm' \ $rrd_width $rrd_height $rrd_common_opts --watermark "$rrd_watermark" \ --end now --start end-${last_x} \ --vertical-label "Frequenz" \ DEF:frequency=$rrd_dbpath/ntpd/frequency_offset-loop.rrd:ppm:AVERAGE \ VDEF:frequency_max=frequency,MAXIMUM \ VDEF:frequency_avg=frequency,AVERAGE \ VDEF:frequency_min=frequency,MINIMUM \ VDEF:frequency_last=frequency,LAST \ COMMENT:"\t\t\g" \ COMMENT:"Maximum\t\t\g" \ COMMENT:"Durchschnitt\t\g" \ COMMENT:"Minimum\t\t\g" \ COMMENT:"Letzter\l" \ LINE1:frequency$rrd_col_red_light:"frequency" \ GPRINT:frequency_max:"% 2.1lf ppm " \ GPRINT:frequency_avg:"% 2.1lf ppm " \ GPRINT:frequency_min:"% 2.1lf ppm " \ GPRINT:frequency_last:"% 2.1lf ppm\l" \ COMMENT:"Letztes update\: $rrd_last_update" } ntp_generic_graph () { last_x="$1" /usr/bin/rrdtool graph /srv/www/img/ntp-generic-0-$last_x.png --title "GENERIC(0) offset und dispersion in Sekunden - $last_x" \ --imginfo 'GENERIC(0) offset und dispersion in Sekunden' \ $rrd_width $rrd_height $rrd_common_opts --watermark "$rrd_watermark" \ --end now --start end-${last_x} \ --vertical-label "Sekunden" \ DEF:dispersion=$rrd_dbpath/ntpd/time_dispersion-GENERIC.rrd:seconds:AVERAGE \ DEF:offset=$rrd_dbpath/ntpd//time_offset-GENERIC.rrd:seconds:AVERAGE \ VDEF:dispersion_max=dispersion,MAXIMUM \ VDEF:dispersion_avg=dispersion,AVERAGE \ VDEF:dispersion_min=dispersion,MINIMUM \ VDEF:dispersion_last=dispersion,LAST \ VDEF:offset_max=offset,MAXIMUM \ VDEF:offset_avg=offset,AVERAGE \ VDEF:offset_min=offset,MINIMUM \ VDEF:offset_last=offset,LAST \ COMMENT:"\t\t\g" \ COMMENT:"Maximum\t\t\g" \ COMMENT:"Durchschnitt\t\g" \ COMMENT:"Minimum\t\t\g" \ COMMENT:"Letzter\l" \ LINE1:dispersion$rrd_col_red_light:"dispersion\t\g" \ GPRINT:dispersion_max:"%.2lf%s\t\t\g" \ GPRINT:dispersion_avg:"%.2lf%s\t\t\g" \ GPRINT:dispersion_min:"%.2lf%s\t\t\g" \ GPRINT:dispersion_last:"%.2lf%s\l" \ LINE1:offset$rrd_col_blue_light:"offset\t\g" \ GPRINT:offset_max:"%.2lf%s\t\t\g" \ GPRINT:offset_avg:"%.2lf%s\t\t\g" \ GPRINT:offset_min:"%.2lf%s\t\t\g" \ GPRINT:offset_last:"%.2lf%s\l" \ COMMENT:"Letztes update\: $rrd_last_update" }