After reach maxcalls, ast sends 480 and BYE

I want to use Asterisk to limit the number of incoming calls. So, I set maxcalls in asterisk.conf

The problem is : Asterisk sends 480 Temporarily Unavailable after reaching the number of maxcalls (which is ok). The SIP client sends ACK. Then, Asterisk sends BYE, which is not expected.

Does anyone know how to prevent Asterisk from sending out BYE after 480 Temporarily Unavailable ?

Thanks in advance !

== pcap =======
Time abs Source Destination Protocol Length Info
0.0 192.168.3.79 192.168.3.217 SIP/SDP 824 Request: INVITE sip:513@192.168.3.217:6061, with session description
0.0 192.168.3.217 192.168.3.79 SIP 544 Status: 100 Trying
0.0 [color=#FF0000] 192.168.3.217 192.168.3.79 SIP 537 Status: 480 Temporarily Unavailable[/color]
0.0 192.168.3.79 192.168.3.217 SIP 354 Request: ACK sip:513@192.168.3.217:6061
0.0 [color=#FF0000]192.168.3.217 192.168.3.79 SIP 464 Request: BYE [/color]sip:1234567@192.168.3.79:6763
0.0 192.168.3.79 192.168.3.217 SIP 361 Status: 481 Call/Transaction Does Not Exist

== ast debug output =======

Maximum call limit of 1 calls exceeded by ‘SIP/sip_incoming-00000002’!
Failed to start PBX (call limit reached)
Trying to put [color=#FF0000]‘SIP/2.0 480’[/color] onto UDP socket destined for 192.168.3.79:6763
Hanging up channel 'SIP/sip_incoming-00000002’
Hangup call SIP/sip_incoming-00000002, SIP callid 954837550a18de12@YWxleGNoYW4tcGM.
Setting RTCP address on RTP instance '0x10bfe478’
No provider found, checking channel drivers for SIP - sip_incoming
Checking device state for peer sip_incoming
Changing state for SIP/sip_incoming - state 1 (Not in use)
device ‘SIP/sip_incoming’ state '1’
No provider found, checking channel drivers for SIP - sip_incoming
Checking device state for peer sip_incoming
Changing state for SIP/sip_incoming - state 1 (Not in use)
device ‘SIP/sip_incoming’ state '1’
Setting the marker bit due to a source update
Setting the marker bit due to a source update
Setting the marker bit due to a source update
**** Received ACK (devil) - Command in SIP ACK
Stopping retransmission on ‘954837550a18de12@YWxleGNoYW4tcGM.’ of Response 1: Match Found
Trying to put[color=#FF0000] ‘BYE sip:852’ [/color]onto UDP socket destined for 192.168.3.79:6763

The procedure depends on whether you are using the latest sub-version of the 1.8 or 11 series, or the latest trunk version.

If you are not using one of these, update to one of them and see if the problem still exists.

If you are using one of them, raise an issue on issues.asterisk.org/jira/, including all the required information and wait for someone to fix it. As this will only casue a minor nuisance to a very small number of people, that may take a long time.

Alternatively fix the source code yourself, and, preferably, submit a bug report, to issues.asterisk.org/jira/, including the patch. (Even just identifying the specific flaw in the actual code, can speed resolution, even without providing a correction.)

In any case, Asterisk General is a discussion group, not a support group.

Thanks for the reply.

I am using 1.8-r389676.
I will report the issue to issues.asterisk.org/jira/