Queues / calls not distributed if ringinuse=no

Hi

I have a very basic queue:
> [myqueue]
> setqueuevar=yes
> strategy=leastrecent
> ringinuse=no
> member=sip/13579

I am placing a call to a external number (currently simulated via a local channel), with AMI Originate, and it is sent to a context simply queuing the call.

When set with ringinuse = no, first call is correctly routed to the sip device, but later calls are not distributed - they stay in queue and receive the moh music - the sip member appears as OK with sip show peers (qualify=yes), and it can really be called directly by another extension.

Running debug, i see on the second call:
app_queue.c:6546 try_calling: Local/0123456789@outgoing-00000002;1 is trying to call a queue member.
app_queue.c:4465 ring_one: Trying ‘sip/13579’ with metric 999982
app_queue.c:4250 can_ring_entry: sip/13579 has another call trying, can’t receive call
app_queue.c:4451 ring_one: Nobody left to try ringing in queue
app_queue.c:4781 wait_for_answer: Everyone is busy at this time

Yet, during the first call, I see:

app_queue.c:6914 try_calling: Marked member sip/13579 as in_call

app_queue.c:5485 update_queue: Marked member sip/13579 as NOT in_call. Lastcall time: 1478634197

(full log: http://pastebin.com/Jgs1a3r9 showing a first successfull call then a failed call presented twice to the device)

When I set ringinuse=yes, no issues, but it is not the way I want it to work,

What could be wrong ?

Thanks for the help, I am asking a lot today !

J.

ringinuse works on the local device, and does not use any SIP protocol. If the local device is a “trunk”, any call over it will make it “in use”.

thank you for looking into this. I am not sure I follow you fully.

The queue member is a static sip device, not a local device. after a first call is successfully handled, a core show channels shows nothing. then comes another call, and it is not passed to the static member, the sip device. I fail to understand why.

J.

What do you mean by “static SIP device”? If your queue entry is SIP/number@peer, any call to peer will make that entry in-use.

That is the way it is defined - sip/13579

Yet, there are no calls to this device, and the queue can not distribute the call. However, as a test, if I dial this sip/13579 from another extension (before or after trying to queue a call), there is no problem, the call is answered. The sip/13579 is not being used, the queue show command reports it as not in use, and yet, the app_queue fails delivering the call to it.

do you have callcounters = yes in the general section of your sip.conf along with setting a busylevel and a call-limit on your 13579 peer?

:smiley: Yes !!

The callcounter directive solved it…

Many thanks !!! :+1:

and it also solves the fact that during a call received through the queue, a queue show was reporting the agent as: (in call) (Not in use) - it now shows logically (in call) (In use)

J.

@johnkiniston please help where to set callcounter using Asterisk Realtime?

@cerien.jean
please help where to set callcounter using Asterisk Realtime?

in the [general] section of your sip.conf.

@johnkiniston Tried in Asterisk realtime but not working although it is working in static configuration files.