MITEL 5220 Dual MODE phone

Hello all,
Try not to laugh to hard on this issue because of the phones that I am using.
I am using FreePBX 2.8.0.2 and MITEL’s 5220 IP DUAL PORT model 5003791 in SIP MODE. Currently I have the firmware 01.00.00.06 with the boot firmware 01.00.02.32. SIPSTATION is my phone provider and I have just 1 DID with my trunk. MY X-Light Soft-phone work great.

ASTERISK: 192.168.1.3
DNS: 192.168.1.251
Phone IP: 192.168.1.137

So here is my problem. I cannot dial in or out or make internal calls on the MITEL phone at all. FreePBX sometimes will show the IP Phones Online. Sometime it won’t. In either case the 5220 always displays NO REG where the date is. Strange thing to me is that If I dial a number FreePBX shows a “Total active calls” and “Total active channels” I have included my the phone setup and will be happy to include any other details that any of you might need to help me get running.

802_priority= -1
addr_type= 0
adminId= admin
admin_dispname= Administrator
admin_passwd= 29c4a0e4ef7d1969a94a5f4aadd20690
always_fwd_addr= 
always_fwd_mode= 0
audio_codec= 5
audio_pkt_size= 20
auth_method= 2
auto_answer= 0
autopickup= 0
beep_on_hold= 1
bksrvtm= 3
boot_version= 01.00.02.32
busy_fwd_addr= 
busy_fwd_mode= 0
callCountIn= 0
callCountOut= 9
dhcpLease= 0
dhcpSrv= 0.0.0.0
dhcpT1= 0
dhcpT2= 0
dhcpenable= 0
dialpl= 
discovery= 1
disp_name= My Name
do_not_disturb= 0
domain= it911now.com
dsday= 1
dseday= 1
dsemonth= 10
dseweek= 4
dsmode= 1
dsmonth= 4
dsweek= 1
dtimer= 4
dtmf_payload= 96
dtmf_type= 0
email= [email protected]
emerg_ip= 255.255.255.255
emerg_number= 
emerg_port= 5060
end_port= 20998
facDef= 1074397274
flashVer= 201
fwEnable= 1
fwMode= 0
fwWanDurl= 
fwWanurl= External IP Address
gtEnable= 1
host_ip= 192.168.1.137
host_name= My Name
hot_addr_type= 0
hot_address= 
hot_line= 0
http_download= sipdnld.mitel.com
http_task_enable= 1
http_upgrade= 1
image_version= 01.00.00.06
ipadr= 192.168.1.137
ipdns= 192.168.1.251
ipgateway= 192.168.1.3
ipmask= 255.255.255.0
ipscddns= 0.0.0.0
keysys_enable= 0
lancode= en_US
lanport= 0
lcd= 6
local_sip_port= 5060
multi_user_enable= 0
noans_fwd_addr= 
noans_fwd_mode= 0
on_hold_alert= 60
other_reason= 
outbound_ip= 192.168.1.3
outbound_port= 5060
outbound_state= 1
password= ******
pbIndex= 0
pbName1= 
pbName10= 
pbName11= 
pbName12= 
pbName13= 
pbName14= 
pbName15= 
pbName16= 
pbName17= 
pbName18= 
pbName19= 
pbName2= 
pbName20= 
pbName21= 
pbName22= 
pbName23= 
pbName24= 
pbName25= 
pbName26= 
pbName27= 
pbName28= 
pbName29= 
pbName3= 
pbName30= 
pbName31= 
pbName32= 
pbName33= 
pbName34= 
pbName35= 
pbName36= 
pbName37= 
pbName38= 
pbName39= 
pbName4= 
pbName40= 
pbName41= 
pbName42= 
pbName43= 
pbName44= 
pbName45= 
pbName46= 
pbName47= 
pbName48= 
pbName49= 
pbName5= 
pbName50= 
pbName51= 
pbName52= 
pbName53= 
pbName54= 
pbName55= 
pbName56= 
pbName57= 
pbName58= 
pbName59= 
pbName6= 
pbName60= 
pbName7= 
pbName8= 
pbName9= 
pbaddr1= 
pbaddr10= 
pbaddr11= 
pbaddr12= 
pbaddr13= 
pbaddr14= 
pbaddr15= 
pbaddr16= 
pbaddr17= 
pbaddr18= 
pbaddr19= 
pbaddr2= 
pbaddr20= 
pbaddr21= 
pbaddr22= 
pbaddr23= 
pbaddr24= 
pbaddr25= 
pbaddr26= 
pbaddr27= 
pbaddr28= 
pbaddr29= 
pbaddr3= 
pbaddr30= 
pbaddr31= 
pbaddr32= 
pbaddr33= 
pbaddr34= 
pbaddr35= 
pbaddr36= 
pbaddr37= 
pbaddr38= 
pbaddr39= 
pbaddr4= 
pbaddr40= 
pbaddr41= 
pbaddr42= 
pbaddr43= 
pbaddr44= 
pbaddr45= 
pbaddr46= 
pbaddr47= 
pbaddr48= 
pbaddr49= 
pbaddr5= 
pbaddr50= 
pbaddr51= 
pbaddr52= 
pbaddr53= 
pbaddr54= 
pbaddr55= 
pbaddr56= 
pbaddr57= 
pbaddr58= 
pbaddr59= 
pbaddr6= 
pbaddr60= 
pbaddr7= 
pbaddr8= 
pbaddr9= 
pcport= 0
phone_num= 6193778911
pk1= 
pk2= 
pk3= 
pk4= 837
pk5= 239
pk6= 287
pk7= 725
pkDescription= 25|5|Line selection key|26|0||27|5|Line selection key|28|0||29|5|Line selection key|30|0||31|5|Line selection key|32|0||33|4|Headset on/off|34|0||35|3|Advisory Message on/off|36|0||37|2|Call logs|38|0|
pppoe_enable= 0
pppoe_login= 
pppoe_passwd= ******
proxy_addr= 0.0.0.0
proxy_port= 5060
rdblock1= 0
rdblock2= 0
rdblock3= 0
rdkw1= 
rdkw2= 
rdkw3= 
rdringtype1= 0
rdringtype2= 0
rdringtype3= 0
rdvmail1= 0
rdvmail2= 0
rdvmail3= 0
reasons= 0
register_expire= 7200
registrar= 192.168.1.3
registrar_port= 5060
ringPitch= 0
sca_config= /////-1//////-1//////-1//////-1//////-1//////-1//////-1//////0
sca_enable= 0
snmp= 192
sntp= 192.168.1.251
srtp= 0
start_port= 20000
sym_udp= 0
system_mode= 0
telnet_task_enable= 1
tftp= 255.255.255.255
tftp_config= 0
tftp_task_enable= 1
tftp_upgrade= 1
time_zone= -7
tonecode= CA
tos= 0
trans_protocol= 2
try_ring_nums= 10
upgip= 0.0.0.0
upgrade= 0
upgurl= sipdnld.mitel.com
user_id= My Name
user_name= 137
video_codec= 0
video_ip= 192.168.1.137
vlan_id= -1
voice_mail_srv= SIP:*[email protected]
voice_srv_port= 5060
voicemail_ringnum= 4

I am surprised that the default gateway and you Asterisk box are the same IP.

I doub’t that is the issue. Have you grabbed any SIP debugs? I know the Mitel phones work great.

I have not grabbed any SIP debugs. How do I do that? My actual gateway (router) is 192.168.1.1 but I got no dial tone when I did it that way. I was not sure if that gateway meant where the calls through. I guess that your saying that this is not the case.

I don’t know that phone, however the variable is IPGATEWAY, one would think that is the default gateway.

Can you ping the phones from the trixbox? Do they register?

In the post “how to ask for help” and the Asterisk documentation covers SIP debug commands.

For brevity.

Turn off dial plan debug ‘core set verbose 0’ and the ‘sip set debug peer xxx’ where xxx is the extension of your phone.

Please use the [code][/code] tags when posting debug or better yet pastebin.ca

From within Asterisk “I puttied into the server” I can ping the phone. They just Don’t register ."sip show peers " gives me:

Name/username              Host            Dyn Nat ACL Port     Status     
137/137                    192.168.1.100    D   N   A  55998    OK (102 ms) 
169/169                    192.168.1.31     D   N   A  21822    OK (9 ms)  
187/187                    (Unspecified)    D   N   A  5060     UNKNOWN    
fpbx-1-bc260839/bc260839   216.82.225.24        N      5060     OK (27 ms) 
fpbx-2-bc260839/bc260839   216.82.231.10        N      5060     OK (106 ms) 
5 sip peers [Monitored: 4 online, 1 offline Unmonitored: 0 online, 0 offline

Here is what I could get from from the “Asterisk Logfiles” tool in 2.8.0.2

User-Agent: FreePBX Trunking
Allow: INVITE, ACK, BYE, CANCEL, OPTIONS, PRACK, MESSAGE, SUBSCRIBE, NOTIFY, REFER, UPDATE, REGISTER, INFO, PUBLISH
Supported: timer, precondition, path, replaces
Content-Length: 0


<------------->
[Sep 13 18:52:43] VERBOSE[2485] chan_sip.c: --- (12 headers 0 lines) ---
[Sep 13 18:52:43] VERBOSE[2485] chan_sip.c: Scheduling destruction of SIP dialog '[email protected]' in 32000 ms (Method: REGISTER)
[Sep 13 18:52:43] NOTICE[2485] chan_sip.c: Outbound Registration: Expiry for trunk2.freepbx.com is 120 sec (Scheduling reregistration in 105 s)
[Sep 13 18:52:43] VERBOSE[2485] chan_sip.c:
<--- SIP read from UDP:216.82.231.10:5060 --->
NOTIFY sip:[email protected] SIP/2.0
Via: SIP/2.0/UDP 216.82.231.10;rport;branch=z9hG4bKgK7ZHU6aQ953K
Max-Forwards: 70
From: <sip:[email protected]>;tag=eFU11K88H5Drj
To: <sip:[email protected]>
Call-ID: 099316e1-3a46-122e-82ad-001372fb8c08
CSeq: 1878610 NOTIFY
Contact: <sip:[email protected]:5060>
User-Agent: FreePBX Trunking
Allow: INVITE, ACK, BYE, CANCEL, OPTIONS, PRACK, MESSAGE, SUBSCRIBE, NOTIFY, REFER, UPDATE, REGISTER, INFO, PUBLISH
Supported: timer, precondition, path, replaces
Event: message-summary
Allow-Events: talk, presence, dialog, call-info, sla, include-session-description, presence.winfo, message-summary, refer
Subscription-State: terminated;reason=timeout
Content-Type: application/simple-message-summary
Content-Length: 74

Messages-Waiting: no
Message-Account: sip:[email protected]


<------------->
[Sep 13 18:52:43] VERBOSE[2485] chan_sip.c: --- (16 headers 3 lines) ---
[Sep 13 18:52:43] VERBOSE[2485] chan_sip.c:
<--- Transmitting (NAT) to 216.82.231.10:5060 --->
SIP/2.0 489 Bad event
Via: SIP/2.0/UDP 216.82.231.10;branch=z9hG4bKgK7ZHU6aQ953K;received=216.82.231.10;rport=5060
From: <sip:[email protected]>;tag=eFU11K88H5Drj
To: <sip:[email protected]>;tag=as6d268452
Call-ID: 099316e1-3a46-122e-82ad-001372fb8c08
CSeq: 1878610 NOTIFY
Server: Asterisk PBX 1.6.2.11
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO
Supported: replaces, timer
Content-Length: 0


<------------>

I really hate that I don’t know a whole lot about PBX systems and stuff. If any has the time I would like to use crossloop free addition and you can show me where to go and what is going on with my system. I can still receive and place calls using X-Light but is a no go with my MITEL 5220 phones

Please reread my instructions. You sent a debug of your trunk. I want the phones debug when it tries to register.

You may have to wait a while for the phone to try and register.

Also, don’t solicit for people to log into your system. The folks that no what they are doing are not going to do that (liability, time etc.). The trolls that will hack you might.

If you need support the FreePBX support staff stands ready. I am fairly sure one of the guys knows the Mitel phones. This also helps support this great project and the people that make it happen.

I have run the “Asterisk CLI command”, but all I get is

"Unable to get IP address of peer '137'.
The phone some what works now for some odd reason. I can dial out (only local and to other extensions). I can check the voice mail, and use all other call features.
2nd. No calls come through MITEL phone, even with the soft phone not running. The calls are all routed to my cell phone still.I used to have all calls forwarded it before I get the MITEL(s)5220. Odd thing is that FreePBX UI showed 2 phones registered for hours, but I only have this MITEL 5220 plugged in.
During that time I ran sip set debug peer 137
and

"Unable to get IP address of peer '137' was displayed.
Now there are no phones registered and I still get

,but I can still call out.
Here are the ping results from the Asterisk server

[code][[email protected] ~]# ping 192.168.1.137 -c3 PING 192.168.1.137 (192.168.1.137) 56(84) bytes of data.
64 bytes from 192.168.1.137: icmp_seq=1 ttl=60 time=1.55 ms
64 bytes from 192.168.1.137: icmp_seq=2 ttl=60 time=1.85 ms
64 bytes from 192.168.1.137: icmp_seq=3 ttl=60 time=2.01 ms

— 192.168.1.137 ping statistics —
3 packets transmitted, 3 received, 0% packet loss, time 2000ms
rtt min/avg/max/mdev = 1.551/1.809/2.017/0.193 ms

[/code]
Any ideas?

After 4 hours, I ran amportal restart using putty and I got the data.
The “System status screen” now shows the 1 MITEL 5220 Phone now as registered, as it’s supposed to. I then ran the command sip show peer 137on the extension 137 that am trying to configure and got this reply:

* Name : 137 Secret : MD5Secret : Remote Secret: Context : from-internal Subscr.Cont. : Language : Accountcode : 5337 AMA flags : Unknown Transfer mode: open CallingPres : Presentation Allowed, Not Screened Callgroup : Pickupgroup : Mailbox : [email protected] VM Extension : *97 LastMsgsSent : 32767/65535 Call limit : 2147483647 Dynamic : Yes Callerid : "device" <137> MaxCallBR : 384 kbps Expire : 3498 Insecure : no Nat : Always ACL : Yes T.38 support : No T.38 EC mode : Unknown T.38 MaxDtgrm: -1 DirectMedia : Yes PromiscRedir : No User=Phone : No Video Support: No Text Support : No Ign SDP ver : No Trust RPID : No Send RPID : No Subscriptions: Yes Overlap dial : Yes Forward Loop : Yes DTMFmode : rfc2833 Timer T1 : 500 Timer B : 32000 ToHost : Addr->IP : 192.168.1.137 Port 5060 Defaddr->IP : 0.0.0.0 Port 5060 Prim.Transp. : UDP Allowed.Trsp : UDP Def. Username: 137 SIP Options : (none) Codecs : 0x1fff (g723|gsm|ulaw|alaw|g726|adpcm|slin|lpc10|g729|speex|ilbc|g726aal2|g722) Codec Order : (ulaw:20,alaw:20,gsm:20,lpc10:20,speex:20,g722:20,adpcm:20,g723:30,slin:20,g726:20,g729:20,ilbc:30,g726aal2:20) Auto-Framing : No 100 on REG : No Status : OK (43 ms) Useragent : Reg. Contact : sip:[email protected] Qualify Freq : 60000 ms Sess-Timers : Accept Sess-Refresh : uas Sess-Expires : 1800 secs Min-Sess : 90 secs Parkinglot :

Bad news is that “All” outgoing calls including call features like *97 say: “Forbidden”.
What does this CLI command tell us that I can use to fix this problem? Is this Reg. Contact : sip:[email protected]
correct? This is my external IP address.

Calls features work now except for calls requiring an area code. It will only let me dial 7 digits. Second thing is that I have to keep using the Re-Registration button in the within the Web Configuration Tool every so often.
Please help.

I am sorry that I don’t know this phone specifically. Looks like you fiugred out that secret=password.

If I had to guess the pkdescription contains some sort of digit map/dial plan.

Make sure qualify is on in the extension and the phone should stay registered.

I still cannot get the phone to stay registered. can someone please help me figure this out?

This is the freepbx [2.8.0.2 ]extension device options.

secret= kb5337
dtmfmode= rfc2833	
canreinvite= yes
context= from-internal	
host= dynamic
type= friend	
nat= Yes
port=5060
qualify= yes	
callgroup	
pickupgroup
disallow 
allow 
dial= SIP/137
accountcode=
[email protected]	
vmexten 	
deny=0.0.0.0/0.0.0.0
permit=0.0.0.0/0.0.0.0

Here is the phone setup.

802_priority= -1
addr_type= 0
adminId= admin
admin_dispname= Administrator
admin_passwd= 29c4a0e4ef7d1969a94a5f4aadd20690
always_fwd_addr= 
always_fwd_mode= 0
audio_codec= 5
audio_pkt_size= 20
auth_method= 2
auto_answer= 0
autopickup= 0
beep_on_hold= 1
bksrvtm= 3
boot_version= 01.00.02.32
busy_fwd_addr= 
busy_fwd_mode= 0
callCountIn= 5
callCountOut= 46
dhcpLease= 0
dhcpSrv= 0.0.0.0
dhcpT1= 0
dhcpT2= 0
dhcpenable= 0
dialpl= 1xxxxxxxxxx/0/0/|/192.168.1.3/|/copied fro/xxxxxxx/0/0/|/192.168.1.3/|/longDist/1NXXNXXXXXX/0/0/|/192.168.1.3/|/longDist2/
discovery= 1
disp_name= Keith Buckner
do_not_disturb= 0
domain= it911now
dsday= 1
dseday= 1
dsemonth= 10
dseweek= 4
dsmode= 1
dsmonth= 4
dsweek= 1
dtimer= 4
dtmf_payload= 96
dtmf_type= 0
email= Email address
emerg_ip= 255.255.255.255
emerg_number= 
emerg_port= 5060
end_port= 20998
facDef= 1074397274
flashVer= 201
fwEnable= 1
fwMode= 0
fwWanDurl= External IP address
fwWanurl= External IP address
gtEnable= 1
host_ip= External IP address
host_name= User name
hot_addr_type= 0
hot_address= 
hot_line= 0
http_download= sipdnld.mitel.com
http_task_enable= 1
http_upgrade= 1
image_version= 01.00.00.06
ipadr= 192.168.1.137
ipdns= 192.168.1.251
ipgateway= 192.168.1.3
ipmask= 255.255.255.0
ipscddns= 0.0.0.0
keysys_enable= 0
lancode= en_US
lanport= 0
lcd= 4
local_sip_port= 5060
multi_user_enable= 0
noans_fwd_addr= 
noans_fwd_mode= 0
on_hold_alert= 60
other_reason= 
outbound_ip= 192.168.1.3
outbound_port= 5060
outbound_state= 1
password= ******
[omitted for space]
phone_num= 6193778911
pk1= 
pk2= 
pk3= 
pk4= 
pk5= 
pk6= 
pk7= 
pkDescription= 25|5|Line selection key|26|0||27|5|Line selection key|28|0||29|5|Line selection key|30|0||31|5|Line selection key|32|0||33|4|Headset on/off|34|0||35|3|Advisory Message on/off|36|0||37|2|Call logs|38|0|
pppoe_enable= 0
pppoe_login= 
pppoe_passwd= ******
proxy_addr= 0.0.0.0
proxy_port= 5060
rdblock1= 0
rdblock2= 0
rdblock3= 0
rdkw1= 
rdkw2= 
rdkw3= 
rdringtype1= 0
rdringtype2= 0
rdringtype3= 0
rdvmail1= 0
rdvmail2= 0
rdvmail3= 0
reasons= 0
register_expire= 180
registrar= 192.168.1.3
registrar_port= 5060
ringPitch= 1
sca_config= /////-1//////-1//////-1//////-1//////-1//////-1//////-1//////-1
sca_enable= 0
snmp= 192
sntp= 192.168.1.251
srtp= 0
start_port= 20000
sym_udp= 0
system_mode= 0
telnet_task_enable= 1
tftp= 255.255.255.255
tftp_config= 0
tftp_task_enable= 1
tftp_upgrade= 1
time_zone= -5
tonecode= CA
tos= 0
trans_protocol= 2
try_ring_nums= 10
upgip= 0.0.0.0
upgrade= 0
upgurl= sipdnld.mitel.com
user_id= 137
user_name= 137
video_codec= 0
video_ip= 192.168.1.137
vlan_id= -1
voice_mail_srv= *[email protected]
voice_srv_port= 5060
voicemail_ringnum= 4