<html>
<head>
    <base href="https://wiki.asterisk.org/wiki">
            <link rel="stylesheet" href="/wiki/s/en/2166/18/9/_/styles/combined.css?spaceKey=AST&amp;forWysiwyg=true" type="text/css">
    </head>
<body style="background: white;" bgcolor="white" class="email-body">
<div id="pageContent">
<div id="notificationFormat">
<div class="wiki-content">
<div class="email">
    <h2><a href="https://wiki.asterisk.org/wiki/display/AST/Calling+using+Google?focusedCommentId=18416017#comment-18416017">Calling using Google</a></h2>
        <h4>Page
        <b>comment added</b> by              <a href="https://wiki.asterisk.org/wiki/display/~chathuragune">Chathura Gunarathane</a>
    </h4>
    <br/>
    <div class="notificationGreySide">
       <p>I am trying to connect to setup Google Voice calling:</p>

<p>In <b>gtalk.conf</b> file</p>

<p><span class="error">&#91;general&#93;</span><br/>
context=local<br/>
allowguests=yes<br/>
bindaddr=0.0.0.0<br/>
externip=216.208.246.1 ; SERVER IP??</p>

<p><span class="error">&#91;guest&#93;</span><br/>
disallow=all<br/>
allow=ulaw<br/>
context=local<br/>
connection=asterisk</p>

<p><b>jabber.conf</b> </p>

<p><span class="error">&#91;general&#93;</span><br/>
autoregister=yes</p>

<p><span class="error">&#91;asterisk&#93;</span><br/>
type=client<br/>
serverhost=talk.google.com<br/>
username=your_google_username@gmail.com/Talk<br/>
secret=your_google_password<br/>
port=5222<br/>
usetls=yes<br/>
usesasl=yes<br/>
statusmessage="I am an Asterisk Server"<br/>
timeout=100</p>


<p>sip.conf</p>

<p><span class="error">&#91;malcolm&#93;</span><br/>
type=peer<br/>
secret=my_secure_password<br/>
host=dynamic<br/>
context=local</p>

<p><b>extensions.conf</b></p>

<p>exten =&gt; s,1,Answer()<br/>
exten =&gt; s,n,Wait(2)<br/>
exten =&gt; s,n,SendDTMF(1)<br/>
exten =&gt; s,n,Dial(SIP/malcolm,20)</p>

<p>I am running asterisk 1.8.  On the SIP client first i am trying to connect to user malcom, secret password and asterist server IP (without port number).  I tried to connect using Xlite 4, i am getting a 408 timeout error after attempting to connect for a long time.</p>

<p>So, i gave up try the Google voice connection. I just wanted to test my SIP connect to my asterisk server</p>

<p>For the <b>sip.conf</b> i added additional users </p>

<p><span class="error">&#91;12345&#93;</span></p>

<p>type=friend<br/>
secret=blah<br/>
auth=md5<br/>
nat=yes<br/>
host=dynamic<br/>
reinvite=no<br/>
canreinvite=no<br/>
qualify=1000<br/>
dtmfmode=inband<br/>
callerid="Test" &lt;1111&gt;<br/>
disallow=all<br/>
allow=gsm<br/>
context=theflintstones</p>


<p>in extensions.conf i added context</p>

<p><span class="error">&#91;theflintstones&#93;</span><br/>
exten =&gt; _<span class="error">&#91;123456789&#93;</span>XXXX,1,NoOp("call for "$</p>
<div class="error"><span class="error">Unknown macro: {EXTEN}</span> <p>)<br/>
exten =&gt; _<span class="error">&#91;123456789&#93;</span>XXXX,2,Dial(SIP/$</p></div>
<p>,60,tr)<br/>
exten =&gt; _<span class="error">&#91;123456789&#93;</span>XXXX,3,Congestion</p>

<p>Why is Xlite or other SIP client cannot connect to the 12345 extension?  Where can i find out about SIP connection logs? It would be great if someone explains where and how to trouble shoot SIP by looking at the log file.  I read somewhere that if your SIP client is located in different machine from asterisk server i need to configure <b>sip_nat.conf</b></p>

<p>nat=yes<br/>
externip=10.0.0.2 ; Is this SIP clients IP? explain<br/>
localnet=asterisk_server_ip/255.255.255.0</p>

<p>I tried with and without the sip_nat.conf still my SIP client (Xlite) cannot connect to the asterisk server assuming if i get connected in the CLI&gt; prompt it will show up.  Can someone have a test commands to see if asterisk server is running properly.</p>

<p>Please help.  Please, I really appreciate if you could give my some pointers. I am getting frustrated with Asterisk unable to get basic SIP connections to work.</p>
    </div>

        
    <div id="commentsSection" class="wiki-content pageSection">
      <div style="float: right;" class="grey">
                        <a href="https://wiki.asterisk.org/wiki/users/removespacenotification.action?spaceKey=AST">Stop watching space</a>
            <span style="padding: 0px 5px;">|</span>
                <a href="https://wiki.asterisk.org/wiki/users/editmyemailsettings.action">Change email notification preferences</a>
</div>
       <a href="https://wiki.asterisk.org/wiki/display/AST/Calling+using+Google?focusedCommentId=18416017#comment-18416017">View Online</a>
              |
       <a id="reply-18416017" href="https://wiki.asterisk.org/wiki/display/AST/Calling+using+Google?replyToComment=18416017#comment-18416017">Reply To This</a>
           </div>

</div>
</div>
</div>
</div>
</body>
</html>