[ECOS] SNMP shows zero tx packets?

Andrew Lunn andrew.lunn@ascom.ch
Thu Jan 4 00:15:00 GMT 2001


On Wed, Jan 03, 2001 at 03:19:46PM -0600, Grant Edwards wrote:
> All seems well except for two thing
> 
>  1) the tx packet count is always zero.  I get what looks like
>     reasonable numbers for rx packets and rx bytes and also for
>     tx bytes, but tx packets is always 0.

You need to look in packages/net/snmp/agent/mibgroups/mibII/inferfaces.c

The offending bit of code is 

    case IFOUTUCASTPKTS:
        long_ret = ifp->if_opackets - ifp->if_omcasts;
        return (unsigned char *) &long_ret;
 
This is returning the number of multicast packets output!
It should return if_opackets.

> 2)  I've also noticed that the system uptime is always zero...

Sorry, i cannot help here. I reimplemented the system group so that i
could get/set values from flash etc. Look in the same directory as the
interfaces.c.

        Andrew


More information about the Ecos-discuss mailing list