Hi all,<br>
<br>
I'm trying to register an extension but when I do so I get the following mesage:<br>
<br>
Sep 24 06:22:46 WARNING[18152]: res_config_mysql.c:135 realtime_mysql:
MySQL RealTime: Failed to query database. Check debug for more info.<br>
Sep 24 06:22:46 NOTICE[18152]: chan_sip.c:10774
handle_request_register: Registration from '1001
&lt;<a href="mailto:sip:1001@10.8.4.239">sip:1001@10.8.4.239</a>&gt;' failed for '<a href="http://10.8.5.51">10.8.5.51</a>' - Username/auth
name mismatch<br>
<br>
I checked wether asterisk was connected to the MySQL database and it appears to be connected.<br>
<br>
asterisk1*CLI&gt; realtime mysql status <br>
Connected to asterisk@localhost, port 3306 with username **blahblah** for 2 days, 12 hours, 33 minutes, 42 seconds.<br>
<br>
My database looks like this<br>
<br>
<h1><font size="1">sip-peers</font></h1>



<table style="border-collapse: collapse; background-color: white;" border="1" width="95%">

<tbody><tr>
    <th width="50"><font size="1">Field</font></th>
    <th width="80"><font size="1">Type</font></th>
    
    <th width="40"><font size="1">Null</font></th>
    <th width="70"><font size="1">Default</font></th>
    
    
    <th><font size="1">Links to</font></th>
    <th><font size="1">Comments</font></th>
    <th><font size="1">MIME</font></th>
</tr>

    
<tr>
    <td class="print" nowrap="nowrap" width="50"><font size="1">
        id&nbsp;
    </font></td>
    <td class="print" nowrap="nowrap" width="80"><font size="1">int(11)<bdo dir="ltr"></bdo></font></td>
    
    <td class="print" width="40"><font size="1">No&nbsp;</font></td>
    <td class="print" nowrap="nowrap" width="70"><font size="1">&nbsp;</font></td>
    
    
    <td class="print"><font size="1">&nbsp;</font></td>
    <td class="print"><font size="1">&nbsp;</font></td>
    <td class="print"><font size="1">&nbsp;</font></td>
</tr>
        
<tr>
    <td class="print" nowrap="nowrap" width="50"><font size="1">
        name&nbsp;
    </font></td>
    <td class="print" nowrap="nowrap" width="80"><font size="1">varchar(80)<bdo dir="ltr"></bdo></font></td>
    
    <td class="print" width="40"><font size="1">No&nbsp;</font></td>
    <td class="print" nowrap="nowrap" width="70"><font size="1">&nbsp;</font></td>
    
    
    <td class="print"><font size="1">&nbsp;</font></td>
    <td class="print"><font size="1">&nbsp;</font></td>
    <td class="print"><font size="1">&nbsp;</font></td>
</tr>
        
<tr>
    <td class="print" nowrap="nowrap" width="50"><font size="1">
        type&nbsp;
    </font></td>
    <td class="print" nowrap="nowrap" width="80"><font size="1">varchar(6)<bdo dir="ltr"></bdo></font></td>
    
    <td class="print" width="40"><font size="1">No&nbsp;</font></td>
    <td class="print" nowrap="nowrap" width="70"><font size="1">friend&nbsp;</font></td>
    
    
    <td class="print"><font size="1">&nbsp;</font></td>
    <td class="print"><font size="1">&nbsp;</font></td>
    <td class="print"><font size="1">&nbsp;</font></td>
</tr>
        
<tr>
    <td class="print" nowrap="nowrap" width="50"><font size="1">
        username&nbsp;
    </font></td>
    <td class="print" nowrap="nowrap" width="80"><font size="1">varchar(80)<bdo dir="ltr"></bdo></font></td>
    
    <td class="print" width="40"><font size="1">No&nbsp;</font></td>
    <td class="print" nowrap="nowrap" width="70"><font size="1">&nbsp;</font></td>
    
    
    <td class="print"><font size="1">&nbsp;</font></td>
    <td class="print"><font size="1">&nbsp;</font></td>
    <td class="print"><font size="1">&nbsp;</font></td>
</tr>
        
<tr>
    <td class="print" nowrap="nowrap" width="50"><font size="1">
        secret&nbsp;
    </font></td>
    <td class="print" nowrap="nowrap" width="80"><font size="1">varchar(80)<bdo dir="ltr"></bdo></font></td>
    
    <td class="print" width="40"><font size="1">No&nbsp;</font></td>
    <td class="print" nowrap="nowrap" width="70"><font size="1">&nbsp;</font></td>
    
    
    <td class="print"><font size="1">&nbsp;</font></td>
    <td class="print"><font size="1">&nbsp;</font></td>
    <td class="print"><font size="1">&nbsp;</font></td>
</tr>
        
<tr>
    <td class="print" nowrap="nowrap" width="50"><font size="1">
        qualify&nbsp;
    </font></td>
    <td class="print" nowrap="nowrap" width="80"><font size="1">char(3)<bdo dir="ltr"></bdo></font></td>
    
    <td class="print" width="40"><font size="1">No&nbsp;</font></td>
    <td class="print" nowrap="nowrap" width="70"><font size="1">&nbsp;</font></td>
    
    
    <td class="print"><font size="1">&nbsp;</font></td>
    <td class="print"><font size="1">&nbsp;</font></td>
    <td class="print"><font size="1">&nbsp;</font></td>
</tr>
        
<tr>
    <td class="print" nowrap="nowrap" width="50"><font size="1">
        callerid&nbsp;
    </font></td>
    <td class="print" nowrap="nowrap" width="80"><font size="1">varchar(80)<bdo dir="ltr"></bdo></font></td>
    
    <td class="print" width="40"><font size="1">No&nbsp;</font></td>
    <td class="print" nowrap="nowrap" width="70"><font size="1">&nbsp;</font></td>
    
    
    <td class="print"><font size="1">&nbsp;</font></td>
    <td class="print"><font size="1">&nbsp;</font></td>
    <td class="print"><font size="1">&nbsp;</font></td>
</tr>
        
<tr>
    <td class="print" nowrap="nowrap" width="50"><font size="1">
        host&nbsp;
    </font></td>
    <td class="print" nowrap="nowrap" width="80"><font size="1">varchar(31)<bdo dir="ltr"></bdo></font></td>
    
    <td class="print" width="40"><font size="1">No&nbsp;</font></td>
    <td class="print" nowrap="nowrap" width="70"><font size="1">&nbsp;</font></td>
    
    
    <td class="print"><font size="1">&nbsp;</font></td>
    <td class="print"><font size="1">&nbsp;</font></td>
    <td class="print"><font size="1">&nbsp;</font></td>
</tr>
        
<tr>
    <td class="print" nowrap="nowrap" width="50"><font size="1">
        dtmfmode&nbsp;
    </font></td>
    <td class="print" nowrap="nowrap" width="80"><font size="1">varchar(4)<bdo dir="ltr"></bdo></font></td>
    
    <td class="print" width="40"><font size="1">No&nbsp;</font></td>
    <td class="print" nowrap="nowrap" width="70"><font size="1">info&nbsp;</font></td>
    
    
    <td class="print"><font size="1">&nbsp;</font></td>
    <td class="print"><font size="1">&nbsp;</font></td>
    <td class="print"><font size="1">&nbsp;</font></td>
</tr>
        
<tr>
    <td class="print" nowrap="nowrap" width="50"><font size="1">
        ipaddr&nbsp;
    </font></td>
    <td class="print" nowrap="nowrap" width="80"><font size="1">varchar(15)<bdo dir="ltr"></bdo></font></td>
    
    <td class="print" width="40"><font size="1">No&nbsp;</font></td>
    <td class="print" nowrap="nowrap" width="70"><font size="1">&nbsp;</font></td>
    
    
    <td class="print"><font size="1">&nbsp;</font></td>
    <td class="print"><font size="1">&nbsp;</font></td>
    <td class="print"><font size="1">&nbsp;</font></td>
</tr>
        
</tbody>
</table>



    
<font size="1"><br>
<br>

&nbsp;Indexes:</font>


<table style="border-collapse: collapse; background-color: white;" border="1">

    <tbody><tr>
        <th><font size="1">Keyname</font></th>
        <th><font size="1">Type</font></th>
        <th><font size="1">Cardinality</font></th>
        <th colspan="2"><font size="1">Field</font></th>
    </tr>
        
        <tr>
        <td class="print" rowspan="1"><font size="1">
                PRIMARY
            </font></td>
        <td class="print" rowspan="1"><font size="1">
                PRIMARY
            </font></td>
        <td class="print" rowspan="1" align="right"><font size="1">
                2&nbsp;
            </font></td>
            <td class="print" colspan="2"><font size="1">
                id
            </font></td>
        </tr>

</tbody>
</table>

        
<font size="1"><br>
<br>
</font>




    
    
<table class="noborder" border="0" cellpadding="0" cellspacing="0">
<tbody><tr><td class="print" valign="top"><font size="1">
        &nbsp;Space usage:</font>
        <table style="border-collapse: collapse; background-color: white;" border="1" width="100%">
        <tbody><tr>
            <th><font size="1">Type</font></th>
            <th colspan="2" align="center"><font size="1">Usage</font></th>
        </tr>
        <tr>
            <td class="print" style="padding-right: 10px;"><font size="1">Data</font></td>
            <td class="print" align="right" nowrap="nowrap"><font size="1">112</font></td>
            <td class="print"><font size="1">Bytes</font></td>
        </tr>
            
        <tr>
            <td class="print" style="padding-right: 10px;"><font size="1">Index</font></td>
            <td class="print" align="right" nowrap="nowrap"><font size="1">2,048</font></td>
            <td class="print"><font size="1">Bytes</font></td>
        </tr>
                
        <tr>
            <td class="print" style="padding-right: 10px;"><font size="1">Total</font></td>
            <td class="print" align="right" nowrap="nowrap"><font size="1">2,160</font></td>
            <td class="print"><font size="1">Bytes</font></td>
        </tr>
                
        </tbody></table>
    </td>

    <td class="print" width="20"><font size="1">&nbsp;</font></td>

    
    <td valign="top"><font size="1">
        &nbsp;Row Statistics:</font>
        <table style="border-collapse: collapse; background-color: white;" border="1" width="100%">
        <tbody><tr>
            <th><font size="1">Statements</font></th>
            <th align="center"><font size="1">Value</font></th>
        </tr>
            
        <tr>
            <td class="print"><font size="1">Format</font></td>
            <td class="print" align="left" nowrap="nowrap"><font size="1">
                                dynamic
            </font></td>
        </tr>
                
        <tr>
            <td class="print"><font size="1">Rows</font></td>
            <td class="print" align="right" nowrap="nowrap"><font size="1">
                2
            </font></td>
        </tr>
                
        <tr>
            <td class="print"><font size="1">Row length&nbsp;ø</font></td>
            <td class="print" nowrap="nowrap"><font size="1">
                56
            </font></td>
        </tr>
                
        <tr>
            <td class="print"><font size="1"> Row size &nbsp;ø</font></td>
            <td class="print" align="right" nowrap="nowrap"><font size="1">
                1,080 Bytes
            </font></td>
        </tr>
                
        <tr>
            <td class="print"><font size="1">Next&nbsp;Autoindex</font></td>
            <td class="print" align="right" nowrap="nowrap"><font size="1">
                3
            </font></td>
        </tr>
                

        <tr>
            <td class="print"><font size="1">Creation</font></td>
            <td class="print" align="right" nowrap="nowrap"><font size="1">
                Sep 21, 2005 at 05:58 PM
            </font></td>
        </tr>
                

        <tr>
            <td class="print"><font size="1">Last update</font></td>
            <td class="print" align="right" nowrap="nowrap"><font size="1">
                Sep 21, 2005 at 05:58 PM</font></td></tr></tbody></table></td></tr></tbody>
</table>
<br>
I filled my database with 2 extension like this:<br>
<font size="1"><br>
</font>
<h1><font size="1">SQL result</font></h1>

<p>
    <font size="1"><b>Host:</b> localhost<br>
<b>Database:</b> asterisk<br>
<b>Generation Time:</b> Sep 24, 2005 at 06:27 AM<br>
<b>Generated by:</b> phpMyAdmin&nbsp;2.6.4&nbsp;/ MySQL&nbsp;4.1.14-log<br>
<b>SQL query:</b> SELECT * FROM `sip-peers`  LIMIT 0, 30 ;
    <br>
<b>Rows:</b> 2    </font>
    
    
    
    
    </p>






<table id="table_results" border="1" cellpadding="2" cellspacing="0">
<tbody><tr>
        
<th><font size="1">
    id
    </font></th>
                
<th><font size="1">
    name
    </font></th>
                
<th><font size="1">
    type
    </font></th>
                
<th><font size="1">
    username
    </font></th>
                
<th><font size="1">
    secret
    </font></th>
                
<th><font size="1">
    qualify
    </font></th>
                
<th><font size="1">
    callerid
    </font></th>
                
<th><font size="1">
    host
    </font></th>
                
<th><font size="1">
    dtmfmode
    </font></th>
                
<th><font size="1">
    ipaddr
    </font></th>
                
</tr>
        

    
<tr>
            
    <td onmousedown="setCheckboxColumn('id_rows_to_delete0');" class="nowrap" align="right" bgcolor="#ffffff" valign="top"><font size="1">1</font></td>
    <td onmousedown="setCheckboxColumn('id_rows_to_delete0');" bgcolor="#ffffff" valign="top"><font size="1">&nbsp;</font></td>
    <td onmousedown="setCheckboxColumn('id_rows_to_delete0');" bgcolor="#ffffff" valign="top"><font size="1">friend</font></td>
    <td onmousedown="setCheckboxColumn('id_rows_to_delete0');" bgcolor="#ffffff" valign="top"><font size="1">1006</font></td>
    <td onmousedown="setCheckboxColumn('id_rows_to_delete0');" bgcolor="#ffffff" valign="top"><font size="1">1006</font></td>
    <td onmousedown="setCheckboxColumn('id_rows_to_delete0');" bgcolor="#ffffff" valign="top"><font size="1">yes</font></td>
    <td onmousedown="setCheckboxColumn('id_rows_to_delete0');" bgcolor="#ffffff" valign="top"><font size="1">Extensie 1006</font></td>
    <td onmousedown="setCheckboxColumn('id_rows_to_delete0');" bgcolor="#ffffff" valign="top"><font size="1">dynamic</font></td>
    <td onmousedown="setCheckboxColumn('id_rows_to_delete0');" bgcolor="#ffffff" valign="top"><font size="1">info</font></td>
    <td onmousedown="setCheckboxColumn('id_rows_to_delete0');" bgcolor="#ffffff" valign="top"><font size="1">&nbsp;</font></td>

</tr>
            
<tr>
            
    <td onmousedown="setCheckboxColumn('id_rows_to_delete1');" class="nowrap" align="right" bgcolor="#ffffff" valign="top"><font size="1">2</font></td>
    <td onmousedown="setCheckboxColumn('id_rows_to_delete1');" bgcolor="#ffffff" valign="top"><font size="1">&nbsp;</font></td>
    <td onmousedown="setCheckboxColumn('id_rows_to_delete1');" bgcolor="#ffffff" valign="top"><font size="1">friend</font></td>
    <td onmousedown="setCheckboxColumn('id_rows_to_delete1');" bgcolor="#ffffff" valign="top"><font size="1">1001</font></td>
    <td onmousedown="setCheckboxColumn('id_rows_to_delete1');" bgcolor="#ffffff" valign="top"><font size="1">1001</font></td>
    <td onmousedown="setCheckboxColumn('id_rows_to_delete1');" bgcolor="#ffffff" valign="top"><font size="1">yes</font></td>
    <td onmousedown="setCheckboxColumn('id_rows_to_delete1');" bgcolor="#ffffff" valign="top"><font size="1">Extensie 1001</font></td>
    <td onmousedown="setCheckboxColumn('id_rows_to_delete1');" bgcolor="#ffffff" valign="top"><font size="1">dynamic</font></td>
    <td onmousedown="setCheckboxColumn('id_rows_to_delete1');" bgcolor="#ffffff" valign="top"><font size="1">info</font></td>
    <td onmousedown="setCheckboxColumn('id_rows_to_delete1');" bgcolor="#ffffff" valign="top"><font size="1">&nbsp;</font></td></tr></tbody>
</table>
<br clear="all">I think I did something wrong making the database or
filling it, might just be some missing field or something. But somehow
I can't figure out what's going wrong.<br>
<br>
Any ideas?<br>
<br>
Thanks in advance <br>
<br>
Tijmen<br>