[Home]

Summary:ASTERISK-15308: asterisk is not able to register with SIP server
Reporter:Salman Khan (sam chan)Labels:
Date Opened:2009-12-13 11:14:38.000-0600Date Closed:2011-06-07 14:01:01
Priority:MajorRegression?No
Status:Closed/CompleteComponents:Channels/chan_sip/Registration
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:
Description:HI,
I have installed ViCiDialNow 2.0.5 with Asterisk version of 1.2.30.2 for OUTBOUND dialing. This server is not able to register with SIP server as SIP SHOW REGISTRY shows unregistered. Also, I continuously recieves following messages on the "vici*CLI>" CLI

...

Dec 13 12:50:16 NOTICE[2586]: chan_sip.c:5529 sip_reg_timeout:    -- Registration for 'USER ID@69.1.224.14' timed out, trying again (Attempt ASTERISK-55)
Dec 13 12:50:36 NOTICE[2586]: chan_sip.c:5529 sip_reg_timeout:    -- Registration for 'USER ID@69.1.224.14' timed out, trying again (Attempt ASTERISK-56)
Dec 13 12:50:57 NOTICE[2586]: chan_sip.c:5529 sip_reg_timeout:    -- Registration for 'USER ID@69.1.224.14' timed out, trying again (Attempt ASTERISK-57)
Dec 13 12:51:17 NOTICE[2586]: chan_sip.c:5529 sip_reg_timeout:    -- Registration for 'USER ID@69.1.224.14' timed out, trying again (Attempt ASTERISK-58)
 == Refreshing DNS lookups.
...

My Asterisk Server Configurations are as follows:

Network Configuration:
IPTables are configured and IP Forwarding is all set as the LAN PC's are able to browse INTERNET through this server.

/etc/asterisk/sip.conf:
[general]
context=default                 ; Default context for incoming calls
;allowguest=no                  ; Allow or reject guest calls (default is yes, this can also be set to 'osp'
;realm=mydomain.tld             ; Realm for digest authentication
bindport=5744               ; UDP Port to bind to (SIP standard port is 5060)
bindaddr=0.0.0.0                ; IP address to bind to (0.0.0.0 binds to all)
srvlookup=yes                   ; Enable DNS SRV lookups on outbound calls
;domain=mydomain.tld            ; Set default domain for this host
;domain=mydomain.tld,mydomain-incoming
;domain=1.2.3.4                 ; Add IP address as local domain
;allowexternalinvites=no        ; Disable INVITE and REFER to non-local domains
;autodomain=yes                 ; Turn this on to have Asterisk add local host
;pedantic=yes                   ; Enable slow, pedantic checking for Pingtel
;tos=184                        ; Set IP QoS to either a keyword or numeric val
tos=lowdelay                    ; lowdelay,throughput,reliability,mincost,none
maxexpiry=3600                  ; Max length of incoming registration we allow
defaultexpiry=300               ; Default length of incoming/outgoing registration
;notifymimetype=text/plain      ; Allow overriding of mime type in MWI NOTIFY
;checkmwi=10                    ; Default time between mailbox checks for peers
;vmexten=voicemail      ; dialplan extension to reach mailbox sets the
;videosupport=yes               ; Turn on support for SIP video
;recordhistory=yes              ; Record SIP history by default
disallow=all                    ; First disallow all codecs
allow=ulaw                      ; Allow codecs in order of preference
allow=gsm                       ;
musicclass=default              ; Sets the default music on hold class for all SIP calls
language=en                     ; Default language setting for all users/peers
relaxdtmf=yes                   ; Relax dtmf handling
rtptimeout=60                   ; Terminate call if 60 seconds of no RTP activity
;rtpholdtimeout=300             ; Terminate call if 300 seconds of no RTP activity
trustrpid = no                  ; If Remote-Party-ID should be trusted
sendrpid = yes                  ; If Remote-Party-ID should be sent
progressinband=no               ; If we should generate in-band ringing always
;useragent=Asterisk PBX         ; Allows you to change the user agent string
promiscredir = no       ; If yes, allows 302 or REDIR to non-local SIP address
;usereqphone = no               ; If yes, ";user=phone" is added to uri that contains
dtmfmode = rfc2833              ; Set default dtmfmode for sending DTMF. Default: rfc2833
;compactheaders = yes           ; send compact sip headers.
;sipdebug = yes                 ; Turn on SIP debugging by default, from
;subscribecontext = default     ; Set a specific context for SUBSCRIBE requests
;notifyringing = yes            ; Notify subscriptions on RINGING state
;alwaysauthreject = yes         ; When an incoming INVITE or REGISTER is to be rejected,
;regcontext=sipregistrations
;registertimeout=20             ; retry registration calls every 20 seconds (default)
;registerattempts=10            ; Number of registration attempts before we give up
callevents=no                   ; generate manager events when sip ua performs events (e.g. hold)
externip = MY PUBLIC STATIC IP     ; Address that we're going to put in outbound SIP messages
;externhost=foo.dyndns.net      ; Alternatively you can specify an
;externrefresh=10               ; How often to refresh externhost if
localnet=192.168.0.0/255.255.0.0; All RFC 1918 addresses are local networks
localnet=10.0.0.0/255.0.0.0     ; Also RFC1918
localnet=172.16.0.0/12          ; Another RFC1918 with CIDR notation
localnet=169.254.0.0/255.255.0.0 ;Zero conf local network
nat=yes                         ; Global NAT settings  (Affects all peers and users)
canreinvite=no
;rtcachefriends=yes             ; Cache realtime friends by adding them to the internal list
;rtupdate=yes                   ; Send registry updates to database using realtime? (yes|no)
;rtautoclear=yes                ; Auto-Expire friends created on the fly on the same schedule
;ignoreregexpire=yes            ; Enabling this setting has two functions:
; domain=myasterisk.dom
; domain=customer.com,customer-context
; autodomain=yes
; fromdomain=mydomain.tld ; When making outbound SIP INVITEs to

#include sip-vicidial.conf

; register SIP account on remote machine if using SIP trunks
; register => testSIPtrunk:test@10.10.10.16:5060

register => VOIP SWITCH ID:VOIP SWITCH PASSWORD@69.1.224.14:5744
; setup account for SIP trunking:
[SIPtrunk]
disallow=all
allow=ulaw
allow=alaw
type=friend
username= VOIP SWITCH ID
secret= VOIP SWITCH PASSWORD
host=69.1.224.14
dtmfmode=inband
qualify=1000









Following is the dial plan in /etc/asterisk/extensions.conf:

...

; dial a long distance outbound number through a SIP provider

exten => _91NXXNXXXXXX,1,AGI(agi://127.0.0.1:4577/call_log)
exten => _91NXXNXXXXXX,2,Dial(${SIPtrunk}/${EXTEN:1},55,o)
exten => _91NXXNXXXXXX,3,Hangup

...


I would appreciate if I recieve help over this issue of registration time out.

Thank you.

Sam
Comments:By: Leif Madsen (lmadsen) 2009-12-14 09:27:54.000-0600

Please either utilize the ViciDial support forums, or the asterisk-users mailing lists for support issues.