mirror of
https://github.com/ntop/ntopng.git
synced 2026-05-06 03:45:26 +00:00
Implement Misbehaving vs Alerted flows chart
This commit is contained in:
parent
7f6e69653e
commit
8d51dae0e5
12 changed files with 74 additions and 2 deletions
|
|
@ -1140,6 +1140,9 @@ elseif(page == "historical") then
|
|||
timeseries = {
|
||||
{schema="iface:flows", label=i18n("graphs.active_flows")},
|
||||
{schema="iface:new_flows", label=i18n("graphs.new_flows"), value_formatter = {"fflows", "formatFlows"}},
|
||||
{schema="custom:flow_misbehaving_vs_alerted", label=i18n("graphs.misbehaving_vs_alerted"),
|
||||
value_formatter = {"formatFlows", "formatFlows"},
|
||||
metrics_labels = {i18n("flow_details.mibehaving_flows"), i18n("flow_details.alerted_flows")}},
|
||||
{schema="iface:hosts", label=i18n("graphs.active_hosts")},
|
||||
{schema="iface:engaged_alerts", label=i18n("show_alerts.engaged_alerts")},
|
||||
{schema="custom:flows_vs_local_hosts", label=i18n("graphs.flows_vs_local_hosts"), check={"iface:flows", "iface:local_hosts"}, step=60},
|
||||
|
|
|
|||
|
|
@ -188,6 +188,18 @@ schema:addMetric("num_flows")
|
|||
|
||||
-- ##############################################
|
||||
|
||||
schema = ts_utils.newSchema("iface:misbehaving_flows", {step=60, metrics_type=ts_utils.metrics.gauge})
|
||||
schema:addTag("ifid")
|
||||
schema:addMetric("num_flows")
|
||||
|
||||
-- ##############################################
|
||||
|
||||
schema = ts_utils.newSchema("iface:alerted_flows", {step=60, metrics_type=ts_utils.metrics.gauge})
|
||||
schema:addTag("ifid")
|
||||
schema:addMetric("num_flows")
|
||||
|
||||
-- ##############################################
|
||||
|
||||
schema = ts_utils.newSchema("iface:http_hosts", {step=60, rrd_fname="num_http_hosts", metrics_type=ts_utils.metrics.gauge})
|
||||
schema:addTag("ifid")
|
||||
schema:addMetric("num_hosts")
|
||||
|
|
|
|||
|
|
@ -113,6 +113,8 @@ function ts_dump.iface_update_general_stats(when, ifstats, verbose)
|
|||
ts_utils.append("iface:flows", {ifid=ifstats.id, num_flows=ifstats.stats.flows}, when, verbose)
|
||||
ts_utils.append("iface:http_hosts", {ifid=ifstats.id, num_hosts=ifstats.stats.http_hosts}, when, verbose)
|
||||
ts_utils.append("iface:engaged_alerts", {ifid=ifstats.id, alerts=ifstats.stats.engaged_alerts}, when, verbose)
|
||||
ts_utils.append("iface:alerted_flows", {ifid=ifstats.id, num_flows=ifstats.stats.num_alerted_flows}, when, verbose)
|
||||
ts_utils.append("iface:misbehaving_flows", {ifid=ifstats.id, num_flows=ifstats.stats.num_misbehaving_flows}, when, verbose)
|
||||
end
|
||||
|
||||
function ts_dump.iface_update_l4_stats(when, ifstats, verbose)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue