LVS
lvs-users
Google
 
Web LinuxVirtualServer.org

RE: ipvsadm --stats and number representation

To: "LinuxVirtualServer.org users mailing list." <lvs-users@xxxxxxxxxxxxxxxxxxxxxx>
Subject: RE: ipvsadm --stats and number representation
From: "Peter Mueller" <pmueller@xxxxxxxxxxxx>
Date: Fri, 13 May 2005 11:33:49 -0700
> I'm currently running IPVS 1.0.9 and ipvsadm 1.21 (compiled with popt 
> and IPVS 1.0.9). I plan to upgrade before the year is out. All my 
> services use LVS-NAT.
> 
> I'm writing a Nagios plugin to check details about an LVSed 
> service and 
> return information to the monitoring host. I started trying 
> to get the 
> statistics with SNMP, but I couldn't get the LVS-MIB to work 
> (quickly). 
> Looking at /proc/net/ip_vs_stats, it seems to be overall 
> stats for the 
> director, not per service. So I thought I'd parse the output of 
> 'ipvsadm' to get the statistics.
> 
> I'm having a problem, however. The counters for InPkts, 
> OutPkts, InBytes 
> and OutBytes are often returned by ipvsadm with a K, M, G, or 
> T suffix 
> (e.g. numbers are in kilobytes, megabytes etc.). 
> Unfortunately, this is 
> not granular enough for running checks every 5 minutes - the 
> counters do 
> not update in that time, so it appears there is no traffic 
> going through 
> for that service.
> 
> Can anyone suggest how I might get the stats values in bytes? 
> Is there 
> something in /proc for IPVS 1.0.9 that I can use, or does a later 
> version of IPVS have more detailed stats somewhere?

Neat idea.  I use Nagios too, it is really nice.

Have you thought about using rate instead of exact packets?

    --rate    Output  of  rate information. The rate information (such as
con-
              nections/second, bytes/second and  packets/second)  of
services
              and its servers will be displayed, when the services are
listed.

Regards,

P

<Prev in Thread] Current Thread [Next in Thread>