Registration expiring due to devices not sync

Hi Guys,

i have a device which registers with asterisk to expire in 1800, however i see in asterisk that registration times out for a few seconds and says device is UNREACHABLE, then device re-registers:

May 17 13:06:04 VERBOSE[1671] logger.c: – Registered SIP ‘MYPEER’ at x.x.x.x port 5060 expires 1800
May 17 13:07:08 NOTICE[1671] chan_sip.c: Peer ‘MYPEER’ is now UNREACHABLE! Last qualify: 12
May 17 13:07:18 NOTICE[1671] chan_sip.c: Peer ‘MYPEER’ is now REACHABLE! (9ms / 2000ms)

I’m guessing this can be due to any reason putting either asterisk or the devices timing off a little.

how do i get asterisk to allow a few seconds ontop of the registered amount before claiming device is unreachable.?

This might be a network problem in combination with the use of qualify=2000 in sip.conf

What (maybe) happens is that the latency goes, for a short period, above what has been set as the qualify value. If this happens registration of the device will end. As soon as the latency falls back to normal level the device will get a registrered again.

As a first indication you can ping from the Asterisk box to the device and see if there is a variation in the ping times.

I hope this is useful.