I would like to save Linux’s iftop command in DB and display it as a time series dashboard through sql query.
The query is:
SELECT
UNIX_TIMESTAMP(timestamp) AS time_sec,
bytes AS value,
CONCAT(src_ip, ":", src_port, " -> ", dst_ip, ":", dst_port) AS
FROM
network_traffic.traffic_log
WHERE
$__timeFilter(timestamp)
ORDER BY
timestamp
I want the y-axis to display bytes, the x-axis to display time, and metric data to be displayed when the mouse is hovered over.