What I am trying to do is get alerts when my bandwidth goes above a limit. I am using Cacti to graph my bandwidth usage, but I currently get no alerts if my usage goes up.
So I think the best way to do this would be to write a script to check the graph data every say 5 mins.
Please can someone start me on the right track to this? I have looked online how to view the graphs but it gets very complicated for me.
If you are already using Cacti to collect and graph your bandwidth usage, then the
thold
plugin will allow you to set thresholds and notification methods. http://docs.cacti.net/plugin:tholdIf you are not already using Cacti, then you could instead use MRTG (with RRDTool as the backend) to collect and graph the data. MRTG has a
ThreshMaxO[]
directive (and corresponding directives for Inbound and Minima) to define thresholds, and aThreshProg[]
directive to define which program or script to call to do the notification.