• Welcome to SAIL Community Supported PBX . Please login or sign up.
 
May 07, 2024, 12:18:56 PM

News:

SMF updated to 2.0


AMI - Outcall

Started by davidiwharper, October 16, 2016, 07:33:32 AM

Previous topic - Next topic

davidiwharper

Hello there

I'm trialling SAIL 4.1 on Debian 7 and am having some trouble getting OutCall, which uses the AMI interface, to work.

I can successfully connect using credentials created in /etc/asterisk/manager.conf and associate with a peer. However, when I go to dial, I get the error:

Quote
Response: Error
Message: Permission denied

I'm guessing this is related to permissions in /var/spool/asterisk, so I have fiddled a bit in there to no avail. The other possibility is that I may have the wrong context. The Outgoing Context I have set in OutCall is currently from-internal.

Any clues as to what I am doing wrong?

Many thanks
David

sysadmin

I'm afraid we don't know outcall, however it looks similar to many other Windows AMI and TAPI type products and we have no problems running with them.  Many of our users use Xtelsio and that works fine.    SARK/SAIL uses an absolutely vanilla Asterisk so I would be surprised if it had anything to do with the perms on /var/spool/asterisk.   

Have you correctly set the permissions on your AMI entry? 
Have you permitted 5038 in your SARK firewall for wherever the outcall software is running?
Have you set the bind correctly in the AMI to allow remote access?
Have you permitted the remote IP in your AMI user entry?

Usually one of these.

Good hunting.


   

davidiwharper

Yes, I imagine it's exactly the same. Is there another freebie one you use in preference?

Regarding outcall, I agree. To answer your questions:

AMI entry follows:

Quote
; added for outcall
[user_snipped]
secret = [pass_snip]
read = system,call,log,verbose,command,agent,user
write = system,call,log,verbose,command,agent,user
deny=0.0.0.0/0.0.0.0
permit=192.168.130.0/255.255.255.0

5038 is definitely allowed:

Quote
ACCEPT    net:$LAN    $FW    tcp    5038    OutCall

Here is the rest of manager.conf

Quote
[general]
enabled = yes
;webenabled = yes
port = 5038
;httptimeout = 60
bindaddr = 0.0.0.0

The weird part is this worked, randomly, exactly once, when I changed the outgoing context from "default" to "from-internal".

Very odd.

davidiwharper

Sorry, instant followup.

I meant to add that I can't figure out which log this "denied" error might show up in. I've tried tail -f /var/log/messages and also a connection to the Asterisk console while making the call. What log file might reveal more?

sysadmin

The AMI is not easy to debug.

SARK itself has a debugger but it's pretty verbose.   You can turn it on with


  dialplan set global DEBUG ON


turn it back off with

  dialplan set global DEBUG ''


If you post the output here we may be able to see something from it.

Where did you specify the outbound context?   It isn't obvious from your post.   Is this in the windows app?

SARK/SAIL has no default context (unless you've added one in a custom app).  The main outbound entry point contexts are internal and from-internal, which are the same thing, usually we would suggest you use internal.

We don't use many PC dialler apps I'm afraid so I don't have much experience with them.  In general, when asked, we recommend Xtelsio because we know it works and have a lot of users who run it.   We also use iSymphony quite a lot but that is also a paid-for add-on.  In truth, they all work much the same way so I would expect any/all of them to work as long as they are OK with vanilla Asterisk and allow you to specify the context in the app.


davidiwharper

Curiouser and curiouser! Turning on debugging shows the AMI manager logging on and off, but nothing else. When I get my "Permission denied" error in OutCall, nothing shows up in the debug.

That suggests a firewall issue or a bug in OutCall. So I will continue to explore.

Regarding the Outbound Context, this is an option one sets in the Windows user interface. According to https://github.com/bicomsystems/outcall/issues/93 this can resolve "Permission denied" type errors. The one time this randomly worked, I had just changed the Outbound Context from "default" to "from-internal".

davidiwharper

Found the problem: no "originate" permissions on the outcall AMI user in manager.conf.

I figured this out by removing OutCall and installing the Xtelsio trial version, which has much more verbose logging within the application.

The correct "Outbound Context" for OutCall is "from-internal". Without that, your outwards bound calls get directed to various Asterisk configuration menus.

sysadmin

Glad you figured it out.

:-)

Which tool did you prefer?  Xtelsio or OutCall (leaving aside price)?


davidiwharper

OutCall is basic but seems to work (Windows 7 x64; Outlook 2010 x86); I've yet to test on Windows 10 with Outlook 2016. Xtelsio is the superior product but also overkill for small deployments.