• Welcome to SAIL Community Supported PBX . Please login or sign up.
 

Issues with trunk pre-select etc

Started by compsos, February 20, 2022, 07:29:20 AM

Previous topic - Next topic

compsos

Debian 10.11
sail   6.2.0-16+deb10u1 all
We have a trunk with a code of 91. The extension passes it through but asterisk fails to strip it off before dialing. Is it a bug or another way the debug it?

    -- Launched AGI Script /usr/share/asterisk/agi-bin/sarkhpe
<SIP/510-00000002>AGI Tx >> agi_request: sarkhpe
<SIP/510-00000002>AGI Tx >> agi_channel: SIP/510-00000002
<SIP/510-00000002>AGI Tx >> agi_language: en_AU
<SIP/510-00000002>AGI Tx >> agi_type: SIP
<SIP/510-00000002>AGI Tx >> agi_uniqueid: 1645338564.3
<SIP/510-00000002>AGI Tx >> agi_version: 16.2.1~dfsg-1+deb10u2
<SIP/510-00000002>AGI Tx >> agi_callerid: 510
<SIP/510-00000002>AGI Tx >> agi_calleridname: House
<SIP/510-00000002>AGI Tx >> agi_callingpres: 0
<SIP/510-00000002>AGI Tx >> agi_callingani2: 0
<SIP/510-00000002>AGI Tx >> agi_callington: 0
<SIP/510-00000002>AGI Tx >> agi_callingtns: 0
<SIP/510-00000002>AGI Tx >> agi_dnid: 9140551605
<SIP/510-00000002>AGI Tx >> agi_rdnis: unknown
<SIP/510-00000002>AGI Tx >> agi_context: internal
<SIP/510-00000002>AGI Tx >> agi_extension: 9140551605
<SIP/510-00000002>AGI Tx >> agi_priority: 1
<SIP/510-00000002>AGI Tx >> agi_enhanced: 0.0
<SIP/510-00000002>AGI Tx >> agi_accountcode:
<SIP/510-00000002>AGI Tx >> agi_threadid: 140223913465600
<SIP/510-00000002>AGI Tx >> agi_arg_1: OutCos
<SIP/510-00000002>AGI Tx >> agi_arg_2: 9140551605
<SIP/510-00000002>AGI Tx >> agi_arg_3:
<SIP/510-00000002>AGI Tx >> agi_arg_4:
<SIP/510-00000002>AGI Tx >>
  == Extension Changed 510[extensions] new state InUse for Notify User Reception
<SIP/510-00000002>AGI Rx << GET VARIABLE DEBUG
<SIP/510-00000002>AGI Tx >> 200 result=0
<SIP/510-00000002>AGI Rx << GET VARIABLE EXTLEN
<SIP/510-00000002>AGI Tx >> 200 result=1 (3)
<SIP/510-00000002>AGI Rx << GET VARIABLE ASTDLIM
<SIP/510-00000002>AGI Tx >> 200 result=1 (,)
<SIP/510-00000002>AGI Rx << GET VARIABLE ABSTIMEOUT
<SIP/510-00000002>AGI Tx >> 200 result=1 (14400)
<SIP/510-00000002>AGI Rx << DATABASE GET "STAT" "OCSTAT"
<SIP/510-00000002>AGI Tx >> 200 result=0
<SIP/510-00000002>AGI Rx << DATABASE GET "default" "OCSTAT"
<SIP/510-00000002>AGI Tx >> 200 result=0
<SIP/510-00000002>AGI Rx << SET PRIORITY 1
<SIP/510-00000002>AGI Tx >> 200 result=0
<SIP/510-00000002>AGI Rx << SET EXTENSION 9140551605
<SIP/510-00000002>AGI Tx >> 200 result=0
<SIP/510-00000002>AGI Rx << SET CONTEXT 510closedcos
<SIP/510-00000002>AGI Tx >> 200 result=0
    -- <SIP/510-00000002>AGI Script sarkhpe completed, returning 0
    -- Executing [9140551605@510closedcos:1] AGI("SIP/510-00000002", "sarkhpe,OutCluster,9140551605,,") in new stack
    -- Launched AGI Script /usr/share/asterisk/agi-bin/sarkhpe
<SIP/510-00000002>AGI Tx >> agi_request: sarkhpe
<SIP/510-00000002>AGI Tx >> agi_channel: SIP/510-00000002
<SIP/510-00000002>AGI Tx >> agi_language: en_AU
<SIP/510-00000002>AGI Tx >> agi_type: SIP
<SIP/510-00000002>AGI Tx >> agi_uniqueid: 1645338564.3
<SIP/510-00000002>AGI Tx >> agi_version: 16.2.1~dfsg-1+deb10u2
<SIP/510-00000002>AGI Tx >> agi_callerid: 510
<SIP/510-00000002>AGI Tx >> agi_calleridname: House
<SIP/510-00000002>AGI Tx >> agi_callingpres: 0
<SIP/510-00000002>AGI Tx >> agi_callingani2: 0
<SIP/510-00000002>AGI Tx >> agi_callington: 0
<SIP/510-00000002>AGI Tx >> agi_callingtns: 0
<SIP/510-00000002>AGI Tx >> agi_dnid: 9140551605
<SIP/510-00000002>AGI Tx >> agi_rdnis: unknown
<SIP/510-00000002>AGI Tx >> agi_context: 510closedcos
<SIP/510-00000002>AGI Tx >> agi_extension: 9140551605
<SIP/510-00000002>AGI Tx >> agi_priority: 1
<SIP/510-00000002>AGI Tx >> agi_enhanced: 0.0
<SIP/510-00000002>AGI Tx >> agi_accountcode:
<SIP/510-00000002>AGI Tx >> agi_threadid: 140223913465600
<SIP/510-00000002>AGI Tx >> agi_arg_1: OutCluster
<SIP/510-00000002>AGI Tx >> agi_arg_2: 9140551605
<SIP/510-00000002>AGI Tx >> agi_arg_3:
<SIP/510-00000002>AGI Tx >> agi_arg_4:
<SIP/510-00000002>AGI Tx >>
<SIP/510-00000002>AGI Rx << GET VARIABLE DEBUG
<SIP/510-00000002>AGI Tx >> 200 result=0
<SIP/510-00000002>AGI Rx << GET VARIABLE EXTLEN
<SIP/510-00000002>AGI Tx >> 200 result=1 (3)
<SIP/510-00000002>AGI Rx << GET VARIABLE ASTDLIM
<SIP/510-00000002>AGI Tx >> 200 result=1 (,)
<SIP/510-00000002>AGI Rx << GET VARIABLE ABSTIMEOUT
<SIP/510-00000002>AGI Tx >> 200 result=1 (14400)
<SIP/510-00000002>AGI Rx << SET PRIORITY 1
<SIP/510-00000002>AGI Tx >> 200 result=0
<SIP/510-00000002>AGI Rx << SET EXTENSION 9140551605
<SIP/510-00000002>AGI Tx >> 200 result=0
<SIP/510-00000002>AGI Rx << SET CONTEXT qrxvtmny
<SIP/510-00000002>AGI Tx >> 200 result=0
    -- <SIP/510-00000002>AGI Script sarkhpe completed, returning 0
    -- Executing [9140551605@qrxvtmny:1] AGI("SIP/510-00000002", "sarkhpe,OutTrunk,WDP_House,,") in new stack
    -- Launched AGI Script /usr/share/asterisk/agi-bin/sarkhpe

So it dials and fails with the trunk-preselect. Is it in sarkhpe that it removes the code?

Have also tried to manually update to 6.2.0.24 & 25 and get back on both.

<pre>root@pbx:~# dpkg -i sail_6.2.0-24+deb10u1_all.deb
<b>dpkg-deb:</b> <font color="#EF2929"><b>error:</b></font> &apos;sail_6.2.0-24+deb10u1_all.deb&apos; is not a Debian format archive
<b>dpkg:</b> error processing archive sail_6.2.0-24+deb10u1_all.deb (--install):
 dpkg-deb --control subprocess returned error exit status 2
Errors were encountered while processing:
 sail_6.2.0-24+deb10u1_all.deb
</pre>

sysadmin

SARK won't automatically strip a preselect or prefix that isn't recognised by the upstream carrier, you have to tell it to do so. 

You do this in the Trunk definition of the trunk which will carry the call (WD_House) in the Transformation Mask.  To strip 91 you would enter the following in the field:-

91:
I also wonder why you are using a preselect at all.  Such cases are quite rare. you can usually delineate just by using a suitable dialplan in the route.

Finally, regarding your question about the failed installation of the -24 release.  -24 is not yet on our repos, our last stable release is -19 so I assume you are install a downloaded version.  If this is the case then you need to tell dpkg where the package is locally e.g.

dpkg -i /home/{someuser}/sail_6.2.0-24+deb10u1_all.deb
Hope this helps

compsos

Hi
The description says
"Optional: 1 or 2 digit pre-select code which you can use to seize a specific trunk (must be systemwide unique)"
And I see you have a ":" after the number but that also did not work.
The pre-select and the dial plan in the phone worked fine on earlier versions of Sark. Doing a snGrep during a call it does not select the correct trunk. Why pre-select? To get the right DiD associated to the call for the called party to ring back on the correct line. Unless there is another way to do it?

As for the dpkg I was in the same directory but did not try the full path.

compsos

The issue with the deb file is solved as I was wget from the wrong section of github and got a deb file which was really a html file. No wonder it complained it was not a debian file. When dpkg -i to run it , got another dependency error on sailhpe required 6.0.0.7 but had 6.0.0.6. Will let that one go for the moment and concentrate on the preselect.

sysadmin

Answering your first reply:-

QuoteThe description says
"Optional: 1 or 2 digit pre-select code which you can use to seize a specific trunk (must be systemwide unique)"
And I see you have a ":" after the number but that also did not work.
The pre-select and the dial plan in the phone worked fine on earlier versions of Sark. Doing a snGrep during a call it does not select the correct trunk. Why pre-select? To get the right DiD associated to the call for the called party to ring back on the correct line. Unless there is another way to do it?

Either method should work, however, it looks as tho' a bug crept in in -6 and we missed it.   I'm looking at it now and will get back with you as soon as I know more.   Hopefully, we should be able to squash it fairly quickly.

Thank you for your help with this, it's much appreciated.




sysadmin

Further to my last post, you will find new dpkgs on sailpbx.com at

http://www.sailpbx.com/sail/sail-6.0/debs/

There are both amd64 and arm64 packages for sailhpe_6.0.0-8.

Please download and install the correct one for your architecture and let me know if it works for you.  We've tested it here and it works for both preselect and transformation mask.

Before you begin, ensure you have backed up the existing image, just in case of accidents or further issues.

Regards

compsos

Thanks Guys
The HPE (6.0.0-8) file seems to have fixed it. Worked straight away.