Asterisk
  1. Asterisk
  2. ASTERISK-19521

chan_iax2 does not honor trunkfreq config option

    Details

    • Type: Bug Bug
    • Status: Closed
    • Severity: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.8.8.2
    • Target Release Version/s: None
    • Component/s: Channels/chan_iax2
    • Security Level: None
    • Labels:
      None
    • Frequency of Occurrence:
      Constant
    • Regression:
      Yes

      Description

      iax2 does NOT honor the trunkfreq option.

      There are actually two separate (but related) bugs here. After tracking down http://svnview.digium.com/svn/asterisk?view=revision&revision=355746 I decided that a "quick fix" would just be to set trunkfreq=50 and wait with system upgrade until after hours. It turns out this doesn't actually work.

      Firstly, in the load_module function the ast_timer_set_rate(timer, trunkfreq); call precedes the loading of the config file, and in reload_config no call to ast_timer_set_rate is made at all.

      My suggestion would be to in set_config also add a call to ast_timer_set_rate, something like:

      [edited by mjordan]

      Inline code removed - thanks for attaching it as a patch

      This of course assumes that whatever timer implementation is in use can deal with the frequency changing ... I believe I use timerfd for the most part.

      I believe that trunkfreq used to work in older versions of asterisk, unfortunately I can't remember when this change came into effect.

        Activity

        Hide
        Jaco Kroon added a comment -

        Suggested patch (inline code got all garbled).

        Show
        Jaco Kroon added a comment - Suggested patch (inline code got all garbled).

          People

          • Assignee:
            Unassigned
            Reporter:
            Jaco Kroon
            Issue Participants:
          • Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development