Asterisk
  1. Asterisk
  2. ASTERISK-9754

[patch] Add additional call counter information to res_snmp

    Details

    • Type: New Feature New Feature
    • Status: Closed
    • Severity: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Target Release Version/s: None
    • Component/s: Core/General
    • Labels:
      None
    • SVN Revision Number:
      71655
    • Mantis ID:
      10057
    • Regression:
      No

      Description

      This patch adds 2 more datapoints to the Asterisk MIB, number of calls currently on the PBX, (what you would see with 'core show channels') and an entirely new counter, the total number of calls passed through the PBX since time of last restart. The total number of calls statistic required a new variable and functions in pbx.c/pbx.h.

                • ADDITIONAL INFORMATION ******

      I put these new datapoints in the ast_var_Config() section of the MIB for now but we may want to separate out a new section for some of these statistics if we intend to add more of these types of things in the future.

      The total call counter statistic could useful when saying things like, "My Asterisk box crashes after handling x calls" or for other less technical statements such as "My Asterisk box has been up for x days and has handled y calls".

      Comments and feedback are welcome.

      1. call_counters_2.diff.txt
        6 kB
      2. call_counters_3.diff.txt
        7 kB
      3. call_counters_4.diff.txt
        7 kB
      4. call_counters_5.diff.txt
        7 kB
        Curt Moore
      5. call_counters_6.diff.txt
        7 kB
        Curt Moore
      6. call_counters.diff.txt
        5 kB

        Activity

        Hide
        Jeff Gehlbach added a comment -

        Forgot to say in my previous note – the syntaxes for these new objects should be updated to provide hints about how they are updated. Specifically, ast~CallsActive should be a Gauge and ast~CallsProcessed should be a Counter.

        Show
        Jeff Gehlbach added a comment - Forgot to say in my previous note – the syntaxes for these new objects should be updated to provide hints about how they are updated. Specifically, ast~CallsActive should be a Gauge and ast~CallsProcessed should be a Counter.
        Hide
        Curt Moore added a comment -

        I've attached an updated patch against r80131. I removed the XXX comment I'd forgotten noted by qwell and also changed the data type for astConfigCallsActive from an Integer32 to a Gauge32 as suggested by jeffg.

        As far as a new branch for these sorts of values, what does everyone think?

        Show
        Curt Moore added a comment - I've attached an updated patch against r80131. I removed the XXX comment I'd forgotten noted by qwell and also changed the data type for astConfigCallsActive from an Integer32 to a Gauge32 as suggested by jeffg. As far as a new branch for these sorts of values, what does everyone think?
        Hide
        Curt Moore added a comment -

        call_counters_6.diff.txt is against latest trunk, r86371.

        Let me know if there is anything else still lacking to get this in trunk.

        Show
        Curt Moore added a comment - call_counters_6.diff.txt is against latest trunk, r86371. Let me know if there is anything else still lacking to get this in trunk.
        Hide
        John Todd added a comment -

        I'd be in favor of the new MIB branch for this data. It seems like that makes sense instead of trying to shoehorn it into config data.

        Show
        John Todd added a comment - I'd be in favor of the new MIB branch for this data. It seems like that makes sense instead of trying to shoehorn it into config data.
        Hide
        Digium Subversion added a comment -

        Repository: asterisk
        Revision: 91779

        U trunk/doc/asterisk-mib.txt
        U trunk/include/asterisk/pbx.h
        U trunk/main/cli.c
        U trunk/main/pbx.c
        U trunk/res/snmp/agent.c

        ------------------------------------------------------------------------
        r91779 | qwell | 2007-12-07 10:08:14 -0600 (Fri, 07 Dec 2007) | 5 lines

        Add count of total number of calls processed by asterisk during it's lifetime.
        Add number of total calls and current calls to SNMP.

        Closes issue ASTERISK-9754, patch by jcmoore.

        ------------------------------------------------------------------------

        http://svn.digium.com/view/asterisk?view=rev&revision=91779

        Show
        Digium Subversion added a comment - Repository: asterisk Revision: 91779 U trunk/doc/asterisk-mib.txt U trunk/include/asterisk/pbx.h U trunk/main/cli.c U trunk/main/pbx.c U trunk/res/snmp/agent.c ------------------------------------------------------------------------ r91779 | qwell | 2007-12-07 10:08:14 -0600 (Fri, 07 Dec 2007) | 5 lines Add count of total number of calls processed by asterisk during it's lifetime. Add number of total calls and current calls to SNMP. Closes issue ASTERISK-9754 , patch by jcmoore. ------------------------------------------------------------------------ http://svn.digium.com/view/asterisk?view=rev&revision=91779

          People

          • Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development