Cisco 7911G: Retransmissions Packet timed out after 6398ms with no response


(Hawk McDuck) #1

FreePBX 15.0.17.24 / Current Asterisk Version: 16.15.1 / all modules up to date

I have an issue with Cisco 7911G phones. I realize these are ancient phones and some would recommend tossing them in the trash. Be that as it may, but I am a nostalgic old fogey.

Some months ago I upgraded from FreePBX 14 to FreePBX 15. Although I had been running FreePBX 14 on a physical computer, some time before I upgraded to 15, I moved 14 over to a Virtualbox virtual machine for the convenience. If I remember correctly, I used the Backup & Restore module in FreePBX 14 to make a backup, downloaded the FreePBX 15 distro, and then restored the FreePBX backup files to FreePBX 15. As far as I recall, the process worked great, and there were no obvious glitches. I have a number of older IP phones, Cisco Linksys SPAs, Yealinks, Aastras, Cisco 8861s, Cisco 7911s, 7912s, a 7945, a 7975, all of which worked flawlessly (to my mind) in FreePBX 14. Note that as many of the phones as possible are or have been converted to chan_pjsip, the Cisco 7911G and 7912 extensions are chan_sip (I recall that there are problems with the latter phones with chan_pjsip). When I brought these out of storage after upgrading to FreePBX 15, they all registered, and worked great.

All that is, except the Cisco 7911G phones, of which I have five, extensions 1181, 1182, 1183, 1184, and 1185.
The first problem I noticed after upgrading to FreePBX 15 was that the phones would register, and I could see from the Reports==>Asterisk Info==>Peers that, for example, ext. 1183 was registered:

1183/EXT_NUMBER 172.16.0.83 D No No A 5060 OK (1914 ms)

and I could successfully dial ext. 1183 from another extension, say 7525, when I dial ext. 7525 from ext. 1183 I get Allison Smith’s voice saying “Your call cannot be completed as dialed. Please check the number and dial again.”

Here is the corresponding entry from the /var/asterisk/log/full

[2021-03-28 10:56:05] WARNING[4355] chan_sip.c: Retransmission timeout reached on transmission 001d7060-1f690005-b6a6a465-f88b4f0b@172.16.0.83 for seqno 102 (Critical Response) – See https://wiki.asterisk.org/wiki/display/AST/SIP+Retransmissions
Packet timed out after 6399ms with no response

SET SIP DEBUG ON: pastebin for more detail in the logs https://pastebin.com/iAbe7BVZ

Note that I can dial ext. 7525 from ext. 4501 and from ext. 4501 to ext. 7525. Note both ext. 4501 and 7245 are chan_pjsip, while as I mentioned ext. 1183 is chan_sip.


(Hawk McDuck) #2

I have changed the chan_sip extension from 1183 to 7913 to avoid a possible issue with dialing “11…”. Here is the Cisco 7911 SIP config file SEP[MAC].cnf.xml: https://pastebin.com/T9tE56sn

SIP SHOW PEER 7913 https://pastebin.com/wuJveV7d


(Hawk McDuck) #3

After all these weeks, and with the assistance of a friendly person on the internet, I have finally figured out this issue. The key to the solution, when making an outgoing call to a local extension (or to an external number) is the following:

[2021-04-10 18:36:51] VERBOSE[20147][C-0000004e] pbx.c: Executing [4501#@from-internal:1] Macro(“SIP/8965-00000008”, “user-callerid,LIMIT”) in new stack
[2021-04-10 18:36:51] VERBOSE[20147][C-0000004e] pbx.c: Executing [4501#@from-internal:2] Set(“SIP/8965-00000008”, “ROUTEUSER=8965”) in new stack
[2021-04-10 18:36:51] VERBOSE[20147][C-0000004e] pbx.c: Executing [4501#@from-internal:3] Set(“SIP/8965-00000008”, “ROUTEUSER=8965”) in new stack
[2021-04-10 18:36:51] VERBOSE[20147][C-0000004e] pbx.c: Executing [4501#@from-internal:4] GotoIf(“SIP/8965-00000008”, “1?notblind”) in new stack
[2021-04-10 18:36:51] VERBOSE[20147][C-0000004e] pbx_builtins.c: Goto (from-internal,4501#,7)
[2021-04-10 18:36:51] VERBOSE[20147][C-0000004e] pbx.c: Executing [4501#@from-internal:7] GotoIf(“SIP/8965-00000008”, “1?restrictedroute-aca29e065c1c525fbdc9c7627db62bc1,4501#,2:outbound-allroutes,4501#,2”) in new stack
[2021-04-10 18:36:51] VERBOSE[20147][C-0000004e] pbx_builtins.c: Goto (restrictedroute-aca29e065c1c525fbdc9c7627db62bc1,4501#,2)
[2021-04-10 18:36:51] VERBOSE[20147][C-0000004e] pbx.c: Channel ‘SIP/8965-00000008’ sent to invalid extension: context,exten,priority=restrictedroute-aca29e065c1c525fbdc9c7627db62bc1,4501#,2

Note that I have an ingrained habit when I dial out to use the ‘#’ as the send character. For example, if I want to dial ext. 4501, I would physically dial “4501#” (without quotes of course). This works for all IP phones I use, except for older Cisco phones, such as Cisco 7911Gs, 7945Gs, 7961Gs, 7975Gs and 8961s. (Note that this doesn’t apply to the Cisco 7912Gs, which are able to dial local extensions using the ‘#’ character as the ‘send’ key.)

As someone pointed out, not all Cisco phones support using the ‘#’ key as a ‘send’ key, and it would appear that this applies to all of the Cisco phones that are configured using a tftp server to upload SEP[MAC].cnf.xml files. One characteristic of these particular older Cisco phones is that they all appear to have a “Dial” option once you start dialing, so you don’t really have to use a ‘send’ character. Another option is to dial the number and wait for a specific number of seconds for a timeout period and the dialed number will be sent to FreePBX, and the call will be successful.

I can confirm that this works for these older Cisco phones: 7911G, 7945G, 7961G, and 7975G.

Here is the dialplan.xml file that these older Cisco phones are using:

$ cat dialplan.xml
<DIALTEMPLATE>
<TEMPLATE MATCH=“91…” Timeout=“0”/>
<TEMPLATE MATCH=“911” Timeout=“0”/>
<TEMPLATE MATCH="*…" Timeout=“0”/>
<TEMPLATE MATCH="[1-8]…" Timeout=“1”/>
<TEMPLATE MATCH="*" Timeout=“5”/>
< /DIALTEMPLATE>
$

If anyone has suggestions for modifying the dialplan.xml to strip a trailing ‘#’ let me know. Otherwise I will be following the link to the document below that I believe should work:

https://freeswitch.org/confluence/display/FREESWITCH/XML+Dialplan