> You might try fping. It is easier to parse and you can also add some extra
> parameters.
Doh, I wish I had seen your response sooner... I've already hacked around with
sed and gotten it to parse normal ping correctly. fping would have been a lot
easier. Maybe I'll try that in the future.
I'll share what I've got in case anybody is interested. The results is
semi-smokepingish graphs. Please note that this will probably not work
cross-platform, because ping and sed take different flags and give different
output on different platforms. Your mileage may vary, but this works perfectly
for me on Ubuntu 7.10:
Here's the command: (It's ugly, it's hackish, it's long. But it works.)
Code:
/bin/ping -n -q -c 2 $devname | sed -n -e '/loss/p' -e '/rtt/p' | sed -e
's/.*\([0-9].*.% packet loss\).*/PING OK|loss=\1/;s/[0-9] received//;s/%//;s/,
//;s/packet loss//' -e 's/rtt min\/avg\/max\/mdev = /min=/;s/ ms//;s/\//
avg=/;s/\// max=/;s/\// mdev=/' | sed '/$$/ {;N;s/\n//}'
That should output something like:
Code:
PING OK|loss=0 min=2.486 avg=3.358 max=4.230 mdev=0.872
So, you can create datapoints called "loss", "min", "max", "avg", "mdev". Throw
them in a graph, assign some colors, and watch the pretty results. I haven't
found a good way to graph Packet Loss... I like the way smokeping does this,
but I don't think that would be easy to do in Zenoss.
-------------------- m2f --------------------
Read this topic online here:
http://community.zenoss.com/forums/viewtopic.php?p=21508#21508
-------------------- m2f --------------------
_______________________________________________
zenoss-users mailing list
[email protected]
http://lists.zenoss.org/mailman/listinfo/zenoss-users