Subject: Clearing counters

From: "Reshad Rahman (rrahman)" <[email-masked]>
Date: Fri, 27 Mar 2015 15:52:06 +0000

This is regarding the comment I made yesterday during draft-liu-rtgwg-yang-vrrp, Xufeng rightfully stated that this was a question which had to be addressed for all YANG models.

I have attached Juergen’s email on this topic.

Regards,
Reshad.

Subject: Re: [Rtg-yang-coord] Clearing all stats in a container
From: Juergen Schoenwaelder <[email-masked]>
To: Mahesh Jethanandani <[email-masked]>
Cc: <[email-masked]>
Date: Thu, 5 Mar 2015 08:45:29 +0100
List-Id: "\"List to discuss coordination between the Routing related YANG models\"" <rtg-yang-coord.ietf.org>

On Wed, Mar 04, 2015 at 10:30:37PM -0800, Mahesh Jethanandani wrote:
> Assuming one has defined stat counters in one container, like
ietf-interfaces has done with its statistics, does anyone have suggestions
on how one can essentially clear (reset to 0) all the counters in that
container.

Resetting counters is a bad idea. Once you have more than one
application trying to reset counters you get into trouble. Note
this RFC 6991 (lifted from RFC 2578):

       Counters have no defined 'initial' value, and thus, a
       single value of a counter has (in general) no information
       content.

Applications have to read a counter C at time t0 and then again at
time t1 and then calculate the difference C(t1) - C(t0). This allows
applications to obtain statistics at different time granularities
without stepping on each other.

/js

-- 
Juergen Schoenwaelder           Jacobs University Bremen gGmbH
Phone: +49 421 200 3587         Campus Ring 1 | 28759 Bremen | Germany
Fax:   +49 421 200 3103         <http://www.jacobs-university.de/>

_______________________________________________
Rtg-yang-coord mailing list
[email-masked]
https://www.ietf.org/mailman/listinfo/rtg-yang-coord

---

From: "Acee Lindem (acee)" <[email-masked]>
Date: Sat, 28 Mar 2015 00:18:02 +0000

Hi Reshad,
So the application is responsible for calculating its own delta counters.  Network devices that support CLI clearing of counters will need to maintain the last cleared value as well for counters that are accessible via YANG model operational state.
Thanks,
Acee

From: "Reshad Rahman (rrahman)" <[email-masked]<mailto:[email-masked]>>
Date: Friday, March 27, 2015 at 10:52 AM
To: Routing WG <[email-masked]<mailto:[email-masked]>>
Cc: Juergen Schoenwaelder <[email-masked]<mailto:[email-masked]>>
Subject: Clearing counters

Regards,
Reshad.

---

From: "Reshad Rahman (rrahman)" <[email-masked]>
Date: Sat, 28 Mar 2015 15:04:55 +0000

Hi Acee,

Yes to support clear CLI the network device would need to maintain 2 sets of counters, I don’t see any other way.

Regards,
Reshad.

From: "Acee Lindem (acee)" <[email-masked]<mailto:[email-masked]>>
Date: Friday, March 27, 2015 at 8:18 PM
To: Reshad <[email-masked]<mailto:[email-masked]>>, "[email-masked]<mailto:[email-masked]>" <[email-masked]<mailto:[email-masked]>>
Cc: Juergen Schoenwaelder <[email-masked]<mailto:[email-masked]>>
Subject: Re: Clearing counters

Hi Reshad,

Regards,
Reshad.