Help with registering Cisco 7940s in FreePBX

Hello all! Please bear with me as I’m new to FreePBX and IP Telephony in general.

Two days ago I received 4 Cisco 7940 IP Phones. I have converted two of them to SIP and have configured them each with an extension in FreePBX, but strangely enough, every time I try to make a phone call from Phone 1 to Phone 2, the phone I’m calling from says the other is busy (just a busy tone for a few seconds, then it disconnects) even though both phones are sitting right next to me and the other is not in use.

Can anybody offer any advice on where to start troubleshooting?

Thank you in advance for any/all help you can offer!

What version of Asterisk and FreePBX are you using? Which SIP stack are you using - pjsip or chan_sip?

Thanks for your reply. I am running FreePBX version 12.0.74 and I’m not sure how to figure out which SIP stack I’m using. How can I get this information for you?

Go into an extension and about midway down the page under Device Options it should have something like;

“This device uses PJSIP technology listening on 0.0.0.0:5060”

And an option to change SIP driver…

If you’re using PJSIP, have a look at this forum post where I went through various problems I had with PJSIP and Cisco 794x’s

Let me know if you need any more assistance.

Sorry for the late reply. I had originally created the Phones’ extensions using the “None (virtual extension)” option. I recreated the extensions using CHAN SIP and it now says “This device uses CHAN_SIP technology listening on 0.0.0.0:5060” but I still get the dial tone on both lines no matter what. Any ideas? I appreciate all your help.

I found these error messages on the Phones themselves:

E600 REG send failure
REGISTER
W350 invalid proxy_backup
W351 invalid proxy_emergency
W310 6 Error(s) Parsing:
SIPDefault.cnf
W320 9 Error(s) Parsing: ./
SIP[macaddress].cnf

What SIP firmware version are you running? I had a lot of trouble with my 7940s registering until I upgraded all of them to latest which I believe is 8.12.

Thanks for your reply. Unfortunately I’m already using firmware 8.12.

Here’s a copy of my phone configuration for your reference, this is the SIP[MAC].cnf file;

phone_label: "John Smith "

line1_name: "100"
line1_shortname: "100"
line1_displayname: "John Smith"
line1_authname: "100"
line1_password: "s0m3p4ssw0rd"

messages_uri: "*97"

proxy1_address: "192.168.0.1" 
proxy1_port:"5060"

proxy_emergency: "" 
proxy_emergency_port: "5060" 
proxy_backup: "" 
proxy_backup_port: "5060" 
outbound_proxy: "" 
outbound_proxy_port: "5060" 

proxy_register: "1"
timer_register_expires: "120"
preferred_codec: "none"
tos_media: "5"
enable_vad: "0"
dial_template: "dialplan"
network_media_type: "auto"
autocomplete: "0"
telnet_level: "2"

nat_enable: "0" 
nat_address: "" 
voip_control_port: "5060" 
start_media_port: "16348" 
end_media_port:  "20134" 
nat_received_processing: "0" 
dyn_dns_addr_1: ""
dyn_dns_addr_2: ""
dyn_tftp_addr: "192.168.0.1"
tftp_cfg_dir: "./"

services_url: ""
directory_url: ""               
logo_url: "http://192.168.0.1/logo.bmp"

telnet_level: "2" 
phone_prompt: "Cisco7940"
phone_password: "ph0n3p4ssw0rd" 
enable_vad: "0" 
network_media_type: "auto" 
user_info: phone

So, in the example above 192.168.0.1 is the FreePBX IP address.

I get a few errors with my phones as well, the Error Parsing Config type errors - somewhere must tell you what it’s having trouble parsing but I’ve never worried too much about it as I have all the functionality I need.

Can you dial any of the internal features to FreePBX, say *60 for the speaking clock?

Also, if you go to Asterisk Info > Chan_SIP or Peers do you see the extensions actually registering?

The default passwords created in FreePBX are one character longer than these phones support. Try deleting the last character from the password, update the phone’s config to match and reset the phone.

Also, you can telnet to the phone and issue the command “show reg” to show the registration status. It can be handy when troubleshooting problems such as this.

Tom

1 Like

Sorry about the late reply–we were having other technology issues. I copied your sip[mac].cnf file exactly and modified it to fit my environment–still no dice. I noticed that, when I run the command “sip show peers”, it says both phones are offline. What line1_authname are you using? I’m starting to think it’s actually an authentication problem; maybe I’m using the wrong username/password combo?

the line1_authname I use is the same as the extension number. Same as you would specify the “username” portion in a soft client.

You should see failed auth in the Asterisk Logfiles.

As Tim Rymes says, the default password generated by FreePBX is too long. I didn’t know this, but I shorten the passwords to 10 characters for ease of use as well.

Another handy tool that I go to all the time for troubleshooting SIP is ngrep. It’s a linux CLI tool, you’ll need to get it from the EPEL repo’s but it sure is handy…

ngrep -W byline host [phone_IP] and port 5060

You could get the same out of tcpdump and using Wireshark to analyse the pcap files, if that’s your preference…

I am new to SIP sorry for bothering you as i have same Cisco 7940G phone but i am having a hard time converting them to SIP. If you dont mind can you please tell me how you converted your phones to SIP if you can provide me with those files if you have them on you would be highly appreciated.

Thanks
Syed

If you would consider an alternative game plan, you might consider adding “chan-sccp-b” to your system and leaving the phones as SCCP (Skinny) phones. With a couple of exceptions (places where people have deliberately set up services as “SIP Only”, mostly) the performance of the phones in SCCP mode is excellent. I wrote the FreePBX Wiki page on the Chan-SCCP-b website and I maintain it regularly.

It’s not “plug and play” and it is also not something you can maintain through the GUI (the old SCCP Manager I wrote is just too full of security flaws to make it a workable solution) but once you get the hang of setting up the configuration, it’s actually pretty simple to keep going.