Ad blocker detected: Our website is made possible by displaying online advertisements to our visitors. Please consider supporting us by disabling your ad blocker on our website.
Just thought this might be handy. I'm running RH7.1, and don't have IP accounting compilied into the kernel (this is on a production server, I don't want to mess with the kernel now), so netstat doesn't show the traffic data.
However, I came across the data in /proc/net/dev (couldn't find a util to extract it) so here's a quick script to extract the data:
Hi, I don't undertand for what we need this script if we can get the traffic of a linux using the "Get SNMP Network Data" that already comes with CACTI ?
I'm working with this in a LINUX and works perfect.
Can someone help me install this script? I have it setup in scripts/ and am not too sure exacty how to load it although I have attempted. I may or may not have made the right kind of data input method but after that point I can't figure out how to get that input method into becoming a graph. So if I could get the steps from after putting it on the server all the way to setting up the graph I'd appreciate it.
It's written in PHP, which means you need the PHP-CLI binary.
Paste it into a file called "nettraffic" or whatever, probably in your cacti scripts directory, but it doesnt really matter as long as cacti can run it, and run "chmod a+x nettraffic".
After that, as long as you can run it manually ("./nettraffic eth0") and get some numbers, it should be working fine. Just add it as an input source with two fields.
As an input source with two fields how? I'm not following as far as setting it up via the php webconsole.
Add it as a "data input method" with the line: perl <path_cacti>/scripts/netstatint.pl <> <> and that being it? Or is there something else I'm not understanding?