Tesco’s has jumped on the VOIP band wagon and have created there own VOIP service based on IAX2 tescointernetphone.com. They have they own softphones and hardware phones but getting this to work with Asterisks is going to be a bit of a pain. Outbound works fine with out any problems but inbound is a issue from doing a bit of searching I found a Asterisk user who had the same problem and found that the problem was that the iax connection was not registering it self like normal connections becuase the refreshes rate is returned as 0.
I have traced this out and can see the problem
[color=red] REFRESH : 0[/color]
*CLI> iax2 reload
== Parsing '/etc/asterisk/iax.conf': Found
== Parsing '/etc/asterisk/iax_additional.conf': Found
-- doing lookup for 'gateway.tescointernetphone.com'
-- doing lookup for 'gateway.tescointernetphone.com'
Tx-Frame Retry[000] -- OSeqno: 000 ISeqno: 000 Type: IAX Subclass: REGREQ
Timestamp: 00012ms SCall: 00002 DCall: 00000 [202.148.48.108:4569]
USERNAME : XXXXXXXXXXX
REFRESH : 60
== Loaded firmware 'iaxy.bin'
== Parsing '/etc/asterisk/iaxprov.conf': Found
-- Loaded provisioning template 'default'
Rx-Frame Retry[ No] -- OSeqno: 000 ISeqno: 001 Type: IAX Subclass: REGAUTH
Timestamp: 00005ms SCall: 00393 DCall: 00002 [202.148.48.108:4569]
AUTHMETHODS : 3
CHALLENGE : XXXXXXXXXXX
USERNAME : XXXXXXXXXXX
Tx-Frame Retry[000] -- OSeqno: 001 ISeqno: 001 Type: IAX Subclass: REGREQ
Timestamp: 00320ms SCall: 00002 DCall: 00393 [202.148.48.108:4569]
USERNAME : XXXXXXXXXXX
REFRESH : 60
MD5 RESULT : XXXXXXXXXXX
Rx-Frame Retry[ No] -- OSeqno: 001 ISeqno: 002 Type: IAX Subclass: REGACK
Timestamp: 00313ms SCall: 00393 DCall: 00002 [202.148.48.108:4569]
USERNAME : XXXXXXXXXXX
DATE TIME : 2006-10-29 12:49:58
REFRESH : 0 <--------------------------------------------------------------
APPARENT ADDRES : IPV4 58.106.XX.X:4569
-- Registered IAX2 to '202.148.48.108', who sees us as 58.106.XX.X:4569 with no messages waiting
Tx-Frame Retry[-01] -- OSeqno: 002 ISeqno: 002 Type: IAX Subclass: ACK
Timestamp: 00313ms SCall: 00002 DCall: 00393 [202.148.48.108:4569]
Comments from scots voip blog sums it up pretty well scotsvoiplog.blogspot.com/
[quote]When asterisk registers itself with Tesco, one of the parameters that gets sent back is the length of time between registration refreshes (which lets Tesco know that I’m still online and listening). If asterisk doesn’t recieve that parameter back, it assumes that it should refresh every 60 seconds. However, Tesco send back a value of 0, which gives the following little warning from asterisk:
Aug 12 21:57:19 NOTICE[3917]: sched.c:234 ast_sched_add_variable: Scheduled event in 0 ms?
A side effect of getting sent a refresh value of 0 is that Asterisk never sends out a registration refresh request, so Tesco assumes that we’ve gone offline. From what I’ve been able to gather from seaching through google and looking at the source to asterisk, there is no way to overide the setting that gets sent from the server (though I could be wrong). As such, I modified the source so that if it gets a value of 0, it changes it to 60. So far, this seems to work.[/quote]
As you can see this is not a problem of Asterisk but I dont think I can very well turn round to Tesco and say change your register refresh rate I was thinking to see if there could be a script that could be run to register the IAX trunk again after X amount of seconds or maybe some other work around like scott has done.