What is the output from the ifstats.php script?
Guest last edited by
I hope this is the right place to ask this, I thought the pfSense developers might be more likely to know the answer rather than the end users.
What is the output from the ifstats.php?if=vr1 page? It looks like this:
I assume they are some kind of counter? Is an an incrementing value, like how much traffic has passed since last boot? What are the 3 separate values?
I'm thinking about writing a script on our monitoring server that pulls in this data ever second or two and logs it for charting. I run pfsense embeded so I can't install any plugins to do long term graphing there.
Is there a lot of overhead when calling this script? If it just pulls some counters off the nic then I would assume not, but maybe its calculating these values somehow.
Also if I call the script with ifstats.php?if=vr2, ifstats.php?if=vr3, etc. I keep getting values, at least in the first column. But my hardware device only has 3 network ports. What are these additional interfaces, are they virtual IPs?
Thanks for any info.
Zorac last edited by
from the php code:
echo "$timing|" . $ifinfo['inbytes'] . "|" . $ifinfo['outbytes'] . "\n";
if you pick an interface that doesnt exist, it gives you only the time. try using 'wan' or 'lan' instead.
you could use this every easily to write a monitoring program, or you could use snmp as well.