Files

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

24 lines
770 B
PHP
Raw Permalink Normal View History

2012-04-09 12:53:44 +00:00
<?php
2019-04-11 23:26:42 -05:00
require 'includes/html/graphs/common.inc.php';
2012-04-09 12:53:44 +00:00
$sla = dbFetchRow('SELECT `sla_nr` FROM `slas` WHERE `sla_id` = ?', [$vars['id']]);
2015-07-13 20:10:26 +02:00
2012-04-09 12:53:44 +00:00
if ($sla['owner']) {
$name .= ' (Owner: ' . $sla['owner'] . ')';
2015-07-13 20:10:26 +02:00
}
2012-04-09 12:53:44 +00:00
2021-03-28 17:25:30 -05:00
$rrd_filename = Rrd::name($device['hostname'], ['sla', $sla['sla_nr']]);
2012-04-09 12:53:44 +00:00
$rrd_options .= ' -l 0 ';
2016-08-11 17:05:45 +10:00
$rrd_options .= " COMMENT:'Round Trip Time Cur Min Max\\n'";
$rrd_options .= " DEF:rtt=$rrd_filename:rtt:AVERAGE ";
2012-04-09 12:53:44 +00:00
$rrd_options .= ' VDEF:avg=rtt,AVERAGE ';
2016-08-11 17:05:45 +10:00
$rrd_options .= " LINE1:avg#CCCCFF:'Average':dashes";
$rrd_options .= ' GPRINT:rtt:AVERAGE:%4.1lfms\\l ';
2016-08-11 17:05:45 +10:00
$rrd_options .= " LINE1:rtt#CC0000:'RTT'";
$rrd_options .= ' GPRINT:rtt:LAST:%4.1lfms ';
$rrd_options .= ' GPRINT:rtt:MIN:%4.1lfms ';
$rrd_options .= ' GPRINT:rtt:MAX:%4.1lfms\\l ';