[asterisk-bugs] [JIRA] (ASTERISK-26248) chan_pjsip: Error when calling PJSIP client with domain specified

Norbert Varga (JIRA) noreply at issues.asterisk.org
Mon Aug 1 05:11:56 CDT 2016


    [ https://issues.asterisk.org/jira/browse/ASTERISK-26248?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=231648#comment-231648 ] 

Norbert Varga commented on ASTERISK-26248:
------------------------------------------

The original problem still persist, and currently I'm using call queues and I couldn't make a workaround. I have the following call queue:
{code}
[pbxtest-sales]
member => PJSIP/1000 at mypbx.com
member => PJSIP/1001 at mypbx.com
{code}

Queue show command shows the members correctly. Extensions.conf:
{code}
[pbxtest]
exten => 2000,1,Answer()
same => n,Queue(pbxtest-sales)
same => n,Hangup()

; exten => 1000,1,Dial(PJSIP/@1000 at mypbx.com)
exten => 1000,1,Dial(PJSIP/1000 at mypbx.com)
; exten => 1001,1,Dial(PJSIP/@1001 at mypbx.com)
exten => 1001,1,Dial(PJSIP/1001 at mypbx.com)
{code}

The result is:
{code}
 Executing [2000 at pbxtest:1] Answer("PJSIP/1000 at mypbx.com-00000025", "") in new stack
       > 0x7ff0e8009470 -- Probation passed - setting RTP source address to 92.249.245.153:4012
    -- Executing [2000 at pbxtest:2] Queue("PJSIP/1000 at mypbx.com-00000025", "pbxtest-sales") in new stack
    -- Started music on hold, class 'default', on channel 'PJSIP/1000 at mypbx.com-00000025'
[2016-08-01 11:59:47] ERROR[7165]: chan_pjsip.c:1915 request: Unable to create PJSIP channel - endpoint 'mypbx.com' was not found
{code}

I tried both versions in extension.conf (commented out). I think the reason behind this when the members are called, it's called directly bypassing routing. So it seems the original problem in chan_pjsip.c should be fixed...

> chan_pjsip: Error when calling PJSIP client with domain specified
> -----------------------------------------------------------------
>
>                 Key: ASTERISK-26248
>                 URL: https://issues.asterisk.org/jira/browse/ASTERISK-26248
>             Project: Asterisk
>          Issue Type: Bug
>      Security Level: None
>          Components: Channels/chan_pjsip, Resources/res_pjsip
>    Affects Versions: 13.9.1
>            Reporter: Norbert Varga
>            Severity: Minor
>
> I'd like to use endpoint with different domains in my system. I have the following config in pjsip.conf:
> {code}
> [1000 at mypbx.com]
> type = endpoint
> transport = transport-udp-nat
> disallow = all
> allow = ulaw
> direct_media = no
> rtp_symmetric = yes
> force_rport = yes
> rewrite_contact = yes
> context = test
> auth = 1000
> aors = 1000
> [1000]
> type = auth
> auth_type = userpass
> username = test
> password = xy
> [1000]
> type = aor
> max_contacts = 1
> remove_existing = yes
> {code}
> In extensions.conf I have:
> {code}
> [test]
> exten => _ZXXX,1,Dial(PJSIP/${EXTEN}@mypbx.com)
> {code}
> Register works. When I try to dial 1000 from another extensions, I get this:
> {code}
> ERROR[38010]: chan_pjsip.c:1907 request: Unable to create PJSIP channel - endpoint 'mypbx.com' was not found
> WARNING[38308][C-00000002]: app_dial.c:2429 dial_exec_full: Unable to create channel of type 'PJSIP' (cause 3 - No route to destination)
> {code}
> The problem is that in the dialplan I have to specify the full name of the endpoint (1000 at mypbx.com), but in chan_pjsip above line 1907 the host part is taken as endpoint. The only workaround which is worked, but it looks ugly, and I had to look in the code how to workaround this:
> {code}
> exten => _ZXXX,1,Dial(PJSIP/@${EXTEN}@mypbx.com)
> {code}



--
This message was sent by Atlassian JIRA
(v6.2#6252)



More information about the asterisk-bugs mailing list