Koozali.org: home of the SME Server

Trunk State

Offline gippsweb

  • *****
  • 232
  • +0/-0
    • Wots I.T.?
Trunk State
« on: April 09, 2008, 06:44:19 AM »
Hi Jeff

I have 2 trunks setup with one of our local providers. Only one of them is working properly.
If I click on trunk state, the first trunk is showing the fromuser= of the second trunk.
I've checked sip.conf and all seems OK in there. The trunk definitions are correct, although the state for both shows a red cross.
sip show registry show them both correctly. sip show peers only lists the second line as well as various extensions.

This is sail 594 and 2.something *

Offline SARK devs

  • *****
  • 2,806
  • +1/-0
    • http://sarkpbx.com
Re: Trunk State
« Reply #1 on: April 09, 2008, 07:21:28 AM »
Something is amiss...

All the status buttton does is issue a sip show peer <peername> to asterisk and display the result in a window. You can manually type the same command at the asterisk console and see the same output.

If sip show peers is only displaying one of the trunks then the other is probably not properly defined.  Without seeing the definitions its hard to comment.  you might want to try deleting and redefining the one which is giving problems.

best

Jeff

Offline gippsweb

  • *****
  • 232
  • +0/-0
    • Wots I.T.?
Re: Trunk State
« Reply #2 on: April 09, 2008, 08:12:49 AM »
Turns out it is something to do with the peer stanza label being the same on both trunks. It looks like it may be confusing asterisk.
I have tried a different peer stanza label but it causes other problems because it's not what the provider expects.....

Definately due to the peer stanza label being the same. Now just gotta figure out how to get around it.
« Last Edit: April 09, 2008, 08:49:31 AM by gippsweb »

Offline gippsweb

  • *****
  • 232
  • +0/-0
    • Wots I.T.?
Re: Trunk State
« Reply #3 on: April 09, 2008, 09:27:16 AM »
It may just be a bug in the way the sip show peer is read. If I swap them around in sip.conf the issue swaps around.

I think that because the peer stanza is the same for both extensions, when you click the state button or do a sip show peer from the cli it reads from the bottom up and stops at the first one with that name.

Offline SARK devs

  • *****
  • 2,806
  • +1/-0
    • http://sarkpbx.com
Re: Trunk State
« Reply #4 on: April 09, 2008, 10:18:07 AM »
I don't think asterisk can handle two peer stanzas with the same name.  There is no need for them to be the same, they don't effect the carrier settings, it's just a way to tell asterisk which trunk to use on outbound.  I think you should change one or the other.

Best

S   

Offline soprom

  • *
  • 589
  • +0/-0
    • www.logiciel-libre.org
Re: Trunk State
« Reply #5 on: April 09, 2008, 03:48:10 PM »
I had this problem with stanzas. They must be different. If the same, I think it's only the last one that will be used by asterisk
Sophie from Montréal

Offline gippsweb

  • *****
  • 232
  • +0/-0
    • Wots I.T.?
[SOLVED] Re: Trunk State
« Reply #6 on: April 10, 2008, 01:28:51 AM »
Made them different again. It seems to be working properly now.
Must have been to tired when I was messing about with it last night..