[asterisk-users] AVAILSTATUS always 0

Jonas Kellens jonas.kellens at telenet.be
Fri Oct 5 05:01:33 CDT 2012


If the function ChanIsAvail does not work to check if a SIP peer is 
registered or not, what function should I use then ??


Jonas.


On 04-10-12 17:05, Jonas Kellens wrote:
> On 04-10-12 16:59, Danny Nicholas wrote:
>>
>> *From:*asterisk-users-bounces at lists.digium.com 
>> [mailto:asterisk-users-bounces at lists.digium.com] *On Behalf Of *Jonas 
>> Kellens
>> *Sent:* Thursday, October 04, 2012 9:48 AM
>> *To:* Asterisk Users Mailing List - Non-Commercial Discussion
>> *Subject:* [asterisk-users] AVAILSTATUS always 0
>>
>> Hello,
>>
>> I notice that the function ChanIsAvail always returns result : 0
>>
>> It does not matter if the realtime SIP peer is registered or not.
>>
>> How come ??
>>
>> My dialplan :
>>
>> exten => s,n,ChanIsAvail(SIP/${SIPPEERNAME})
>> exten => s,n,NoOp(availstatus = ${AVAILSTATUS})
>>
>> ${SIPPEERNAME} = sip username from realtime Mysql database.
>>
>>
>>
>> Kind regards,
>> Jonas.
>>
>> Could be a realtime issue.  What do the other 3 variables return?
>>
>> -= Info about application 'ChanIsAvail' =-
>>
>> [Synopsis]
>>
>> Check channel availability
>>
>> [Description]
>>
>> This application will check to see if any of the specified channels are
>>
>> available.
>>
>> This application sets the following channel variables:
>>
>> ${AVAILCHAN}: The name of the available channel, if one exists
>>
>> ${AVAILORIGCHAN}: The canonical channel name that was used to create the
>>
>> channel
>>
>> ${AVAILSTATUS}: The device state for the device
>>
>> ${AVAILCAUSECODE}: The cause code returned when requesting the channel
>>
>>
>
> Thank you for your answer. Below the information :
>
>
> [Oct  4 17:03:26]     -- Executing [s at sub-CheckNetworkProblems:6] 
> ChanIsAvail("SIP/SipAgenT01-000054e1", "SIP/tech0") in new stack
> [Oct  4 17:03:26]     -- Executing [s at sub-CheckNetworkProblems:7] 
> NoOp("SIP/SipAgenT01-000054e1", "AVAILSTATUS = 0") in new stack
> [Oct  4 17:03:26]     -- Executing [s at sub-CheckNetworkProblems:8] 
> NoOp("SIP/SipAgenT01-000054e1", "AVAILCHAN = SIP/tech0-000054e2") in 
> new stack
> [Oct  4 17:03:26]     -- Executing [s at sub-CheckNetworkProblems:9] 
> NoOp("SIP/SipAgenT01-000054e1", "AVAILORIGCHAN = SIP/tech0") in new stack
> [Oct  4 17:03:26]     -- Executing [s at sub-CheckNetworkProblems:10] 
> NoOp("SIP/SipAgenT01-000054e1", "AVAILCAUSECODE = 0") in new stack
>
>
>
> Kind regards,
> Jonas.
>
>
>
> --
> _____________________________________________________________________
> -- Bandwidth and Colocation Provided by http://www.api-digital.com --
> New to Asterisk? Join us for a live introductory webinar every Thurs:
>                 http://www.asterisk.org/hello
>
> asterisk-users mailing list
> To UNSUBSCRIBE or update options visit:
>     http://lists.digium.com/mailman/listinfo/asterisk-users

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-users/attachments/20121005/4c865a25/attachment-0001.htm>


More information about the asterisk-users mailing list