Incoming Google Talk call not being answered

I have done some poking around and have not found an answer to this one, however my gut tells me that this is a complete noob question.


I have configured a single asterisk server (Asterisk 11) to take an incoming call from Google Voice, answer it and play back a soundfile.

By watching the debugs, I can:

  1. See the call arrive via the XMPP debugs
  2. See the call get mapped to the correct context and the extension get matched
  3. See the answer and playback functions invoked.

However, all I hear is ringing on my end, and ultimately I get the Google Voice message that the “subscriber is not available”. If I log into my personal account (which is buddies with my account on which I am doing the testing), I can see my available status and my status message. If I have my test gmail account up, I get ringing in the chat window and can answer the call there.

Why can’t Asterisk answer the call?

Relevant configs below


; Dialplan file
exten => 100,1,Dial(SIP/smp2)
exten => 200,1,Answer()
same => n,Playback(zombies)
same => n,Hangup()
exten => 300,1,Dial(motif/google/,r)
same => n,Hangup()
exten => 400,1,Dial(motif/google/,r)
same => n,Hangup()
exten => _1XXXXXXXXXX,1,Dial(motif/google/${EXTEN},r)
same => n,Hangup()
;Added by MLA
exten => s,1,Answer()
same => n,Wait(2)
; same => n,SendDTMF(2)
same => n,Playback(you-sound-cute)
; same => n,Dial(SIP/200@netscaler)
same => n,Hangup()


debug=yes ; Enable debugging (disabled by default).
;autoprune=yes ; Auto remove users from buddy list. Depending on your
; setup (ie, using your personal Gtalk account for a test)
; you might lose your contacts list. Default is ‘no’.
;autoregister=yes ; Auto register users from buddy list.
;collection_nodes=yes ; Enable support for XEP-0248 for use with
; distributed device state. Default is ‘no’.
;pubsub_autocreate=yes ; Whether or not the PubSub server supports/is using
; auto-create for nodes. If it is, we have to
; explicitly pre-create nodes before publishing them.
; Default is ‘no’.
auth_policy=accept ; Auto accept users’ subscription requests (default).
; Set to deny for auto denial.
type=client ; Client or Component connection ; Route to server for example,
; ; Node to use for publishing events via PubSub ; Username with optional resource.
secret=REDACTED ; Password
priority=1 ; Resource priority
port=5222 ; Port to use defaults to 5222
usetls=yes ; Use tls or not
usesasl=yes ; Use sasl or not ; Manual addition of buddy to list.
; For distributed events, these buddies are
; automatically added in the whitelist as
; ‘owners’ of the node(s).
;distribute_events=yes ; Whether or not to distribute events using
; this connection. Default is ‘no’.
status=available ; One of: chat, available, away, xaway, or dnd
statusmessage=“In da house!” ; Have custom status message for Asterisk
timeout=5 ; Timeout (in seconds) on the message stack, defaults to 5.
; Messages stored longer than this value will be deleted by Asterisk.
; This option applies to incoming messages only, which are intended to
; be processed by the JABBER_RECEIVE dialplan function.
sendtodialplan=yes ; Send incoming messages into the dialplan. Off by default.
context=incoming-motif ; Dialplan context to send incoming messages to. If not set,
; “default” will be used.


; Default template for endpoints, to be included in their definition
context=incoming-motif ; Default context that incoming sessions will land in

;maxicecandidates = 10 ; Maximum number of ICE candidates we will offer
;maxpayloads = 30 ; Maximum number of payloads we will offer

; Sample configuration entry for Jingle
;transport=ice-udp ; Change the default protocol of outgoing sessions to Jingle ICE-UDP
;allow=g722 ; Add G.722 as an allowed format since the other side may support it
;connection=local-jabber-account ; Connection to accept traffic on and send traffic out
;accountcode=jingle ; Account code for CDR purposes
; Sample configuration entry for Google Talk

; Sample configuration entry for Google Voice
;transport=google-v1 ; Google Voice uses the original Google Voice protocol


; RTP Configuration
; RTP start and RTP end configure start and end addresses
; Defaults are rtpstart=5000 and rtpend=31000
; Whether to enable or disable UDP checksums on RTP traffic
; The amount of time a DTMF digit with no ‘end’ marker should be
; allowed to continue (in ‘samples’, 1/8000 of a second)
; rtcpinterval = 5000 ; Milliseconds between rtcp reports
;(min 500, max 60000, default 5000)
; Enable strict RTP protection. This will drop RTP packets that
; do not come from the source of the RTP stream. This option is
; enabled by default.
; strictrtp=yes
; Number of packets containing consecutive sequence values needed
; to change the RTP source socket address. This option only comes
; into play while using strictrtp=yes. Consider changing this value
; if rtp packets are dropped from one or both ends after a call is
; connected. This option is set to 4 by default.
; probation=8
; Whether to enable or disable ICE support. This option is disabled by default.
; Hostname or address for the STUN server used when determining the external
; IP address and port an RTP session can be reached at. The port number is
; optional. If omitted the default value of 3478 will be used. This option is
; disabled by default.
; e.g.
; stunaddr=
; Hostname or address for the TURN server to be used as a relay. The port
; number is optional. If omitted the default value of 3478 will be used.
; This option is disabled by default.
; e.g.
; turnaddr=
; Username used to authenticate with TURN relay server.
; turnusername=
; Password used to authenticate with TURN relay server.
; turnpassword=

I should also add this little configuration detail.

Asterisk 11, built from source and running on Ubuntu 12.04 in a VMware Fusion 5 VM running on MacOS 10.8.

Network looks like:

Internet------------Home Router with NAT--------MacBook Pro------VMWare Fusion NAT-----Asterisk

I will reiterate that the Google Talk signalling is getting to Asterisk and Asterisk seems to be interpreting it correctly, as it is finding the right place in the dialplan.

So, I solved this - at least partially. I fixed the google voice connection problem by simply moving my VM from behind the VMWare NAT (i.e. I took it off the VMNet8 network and made a separate IP address for it on my home network), and everything worked fine after that. I am not sure I want to spend the time untangling the whys and wherefores now, but the double NAT through my home network and again through VMWare was definitely the problem.

Onto what is sure to be another Asterisk battle.