Using qualify=yes guarantees failure on iax2 behind NAT (was: RE: [Asterisk-Users] Using frequent keepalives to eliminate need forNAT port forwarding?)

Tom Engleward engleward at yahoo.com
Tue May 2 06:47:41 MST 2006


--- Damon Estep <damon at suburbanbroadband.net> wrote:
> Qualify=yes will send a SIP OPTIONS periodically and
> keep the NAT open,
> if you use 1 to 1 NAT (versus PAT where it is "many
> to one NAT") it will
> work because port 5060 on the private address will
> still be port 5060 on
> the public address.
Tried that, and it just turned an intermittent failure
into a permanent failure. I added:
qualify=yes
qualifyfreqnotok=15000
qualifyfreqok=20000
qualifysmoothing=yes
to the peer details for the iax trunk in asterisk at home
and hit the big red "reload" line at the top. Then
"iax2 show peers" on the console showed under status
that the peer was indeed being monitored and was ok
and had a ping of about 100ms, and "iax2 debug" showed
all the keepalive messages every 20 seconds, as
intended. And calling to my assigned DID using my PSTN
provider's own outbound termination (so that the call
was both outbound and inbound on my iax2 trunk), the
call worked as usual. But calling from an external
phone (so that my iax2 trunk would see only the
inbound connection), my asterisk system failed to ever
answer at all, and "iax2 debug" showed no indication
that it ever even noticed any incoming call.
So I deleted those four "qualify" lines and hit
asterisk at home's big red "reload", yet "iax2 show
peers" STILL showed the peer being monitored! And
asterisk still refused to answer external incoming
calls.
So I did "restart gracefully" and asterisk finally
actually honored my deletion of the "qualify" lines
("sip show peers" now once again shows status as
"Unmonitored", as before), and once again asterisk
notices and answers incoming calls placed not only
from my PSTN provider's own termination but also from
external phones... though of course it's probably
going to start failing intermittently again, as usual.

So now I have a new question (besides my original,
about how to ensure that asterisk _always_ answers the
phone): why would enabling "qualify" cause an
immediate and consistent failure to ever answer
incoming external phone calls?


__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 



More information about the asterisk-users mailing list