Re: [asterisk-users] Trouble with originating a call through Asterisk Manager Interface

2009-07-14 Thread Matt Riddell
On 13/7/09 2:23 PM, eric weaver wrote:
 I am doing a little application to originate a call through Asterisk via
 AMI (Perl Asterisk::Manager).
 It logs in successfully, does an originate command with
 Exten: 0020 (which is set up to answer and wait for 60 then hang up)
 Channel: SIP/5101234...@test-host  (which comes to my desktop machine
 also running Asterisk).

 At the target machine I see only a CANCEL to which it immediately
 responds with a No Transaction.  Except for every nth try, when I see an
 INVITE; but only that often.

 It looks like AstMan is asking for a Slin-format connection and the
 channel is set up only for Slin or Ulaw but it says joint capabilities
 0x0.  Don't know if that's a red herring.
 Any advice welcome.

The Asterisk Manager won't have any idea about codecs etc.

I suggest the best way to tackle this is to make sure you can make the 
same call using the dialplan first, then move to the manager - settings 
like codecs will therefore show up in the initial testing.

-- 
Cheers,

Matt Riddell
Director
___

http://www.venturevoip.com/news.php (Daily Asterisk News)
http://www.venturevoip.com/st.php (SmoothTorque Predictive Dialer)
http://www.venturevoip.com/c3.php (ConduIT3 PABX Systems)

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] Trouble with originating a call through Asterisk Manager Interface

2009-07-14 Thread eric weaver
Turns out I was using the wrong units in the TIMEOUT parameter to the
Manager Originate  command...   It was supposed to be milliseconds and I put
15.  D'o   Was  timing out before it got started.

Now it connects but odd things happen.  But there are two NATting firewalls
between the two Asterices.  I think I need to set up some kind of UDP
tunneling or use a NAT-free instance for one of them...

Thanks
___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Trouble with originating a call through Asterisk Manager Interface

2009-07-14 Thread Matt Riddell
On 15/7/09 1:34 PM, eric weaver wrote:

 Turns out I was using the wrong units in the TIMEOUT parameter to the
 Manager Originate  command...   It was supposed to be milliseconds and I
 put 15.  D'o   Was  timing out before it got started.

 Now it connects but odd things happen.  But there are two NATting
 firewalls between the two Asterices.  I think I need to set up some kind
 of UDP tunneling or use a NAT-free instance for one of them...

You should probably be right with the externip/localnet settings

-- 
Cheers,

Matt Riddell
Director
___

http://www.venturevoip.com/news.php (Daily Asterisk News)
http://www.venturevoip.com/st.php (SmoothTorque Predictive Dialer)
http://www.venturevoip.com/c3.php (ConduIT3 PABX Systems)

___
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


[asterisk-users] Trouble with originating a call through Asterisk Manager Interface

2009-07-12 Thread eric weaver
I am doing a little application to originate a call through Asterisk via AMI
(Perl Asterisk::Manager).
It logs in successfully, does an originate command with
Exten: 0020 (which is set up to answer and wait for 60 then hang up)
Channel: SIP/5101234...@test-host  (which comes to my desktop machine also
running Asterisk).

At the target machine I see only a CANCEL to which it immediately responds
with a No Transaction.  Except for every nth try, when I see an INVITE; but
only that often.

It looks like AstMan is asking for a Slin-format connection and the channel
is set up only for Slin or Ulaw but it says joint capabilities 0x0.  Don't
know if that's a red herring.
Any advice welcome.

SIP debug follows:

[Jul 12 19:08:58] DEBUG[11552] manager.c: Manager received command
'Challenge'
[Jul 12 19:08:58] DEBUG[11552] manager.c: Manager received command 'Login'
[Jul 12 19:08:58] DEBUG[11552] config.c: Parsing /etc/asterisk/manager.conf
[Jul 12 19:08:58] DEBUG[11552] acl.c: 0.0.0.0/0.0.0.0/0.0.0.0 appended to
acl for peer
[Jul 12 19:08:58] DEBUG[11552] acl.c:
127.0.0.1/255.255.255.255/255.255.255.255 appended to acl for peer
[Jul 12 19:08:58] DEBUG[11552] acl.c: # Testing 127.0.0.1 with 0.0.0.0
[Jul 12 19:08:58] DEBUG[11552] acl.c: # Testing 127.0.0.1 with 127.0.0.1
[Jul 12 19:08:58] DEBUG[11552] manager.c: Manager received command
'Originate'
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Asked to create a SIP channel
with formats: 0x40 (slin)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Allocating new SIP dialog for (No
Call-ID) - INVITE (With RTP)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Setting NAT on RTP to Off
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: *** Our native formats are 0x4
(ulaw)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: *** Joint capabilities are 0x0
(nothing)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: *** Our capabilities are 0x44
(ulaw|slin)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: *** AST_CODEC_CHOOSE formats are
0x4 (ulaw)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: *** Our preferred formats from
the incoming channel are 0x40 (slin)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: This channel will not be able to
handle video.
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Outgoing Call for 5101234567
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Updating call counter for
outgoing call
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Our T38 capability (0), joint T38
capability (0)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: ** Our capability: 0x44
(ulaw|slin) Video flag: False
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: ** Our prefcodec: 0x40 (slin)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: -- Done with adding codecs to SDP
[Jul 12 19:08:58] DEBUG[11552] channel.c: Internal timing is disabled
(option_internal_timing=0 chan-timingfd=-1)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Done building SDP. Settling with
this capability: 0x44 (ulaw|slin)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Header 0: INVITE
sip:5101234...@209.204.152.219 sip%3a5101234...@209.204.152.219 SIP/2.0
(45)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Header 1: Via: SIP/2.0/UDP
192.168.253.35:5060;branch=z9hG4bK23a50508;rport (65)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Header 2: From: asterisk 
sip:aster...@192.168.253.35 sip%3aaster...@192.168.253.35;tag=as1826f152
(61)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Header 3: To: 
sip:5101234...@209.204.152.219 sip%3a5101234...@209.204.152.219 (36)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Header 4: Contact: 
sip:aster...@192.168.253.35 sip%3aaster...@192.168.253.35 (38)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Header 5: Call-ID:
16ba645535fc8f7157940d6226192...@192.168.253.35 (56)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Header 6: CSeq: 102 INVITE (16)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Header 7: User-Agent: Asterisk
PBX (24)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Header 8: Max-Forwards: 70 (16)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Header 9: Date: Mon, 13 Jul 2009
02:08:58 GMT (35)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Header 10: Allow: INVITE, ACK,
CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY (66)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Header 11: Supported: replaces
(19)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Header 12: Content-Type:
application/sdp (29)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Header 13: Content-Length: 213
(19)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Header 14:  (0)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Line: v=0 (3)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Line: o=root 11287 11287 IN IP4
192.168.253.35 (40)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Line: s=session (9)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Line: c=IN IP4 192.168.253.35
(23)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Line: t=0 0 (5)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Line: m=audio 15220 RTP/AVP 10 0
(26)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Line: a=rtpmap:10 L16/8000 (20)
[Jul 12 19:08:58] DEBUG[11552] chan_sip.c: Line: