Hi, <br>first step is correct <br><blockquote style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;" class="gmail_quote"><blockquote>Hmm.. This is what I get:<br><br>[root@ubiq-serv6
~]# mysql -u root -p<br>Enter password:<br>Welcome to the MySQL monitor. Commands end with ; or \g.<br>Your MySQL connection id is 187143 to server version: 4.1.20<br><br>Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
<br></blockquote></blockquote><blockquote style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;" class="gmail_quote">You make an errore here : mysql> use asteriskcdrdb <br></blockquote>
users' information are stored in mysql db<br><br>mysql> use mysql;<br>Reading table information for completion of table and column names<br>You can turn off this feature to get a quicker startup with -A<br><br>Database changed
<br>mysql <br><br>mysql> select Host from user where User = 'asteriskcdruser' ;<br>+-----------+<br>| Host |<br>+-----------+<br>| localhost |<br>+-----------+<br>1 row in set (0.00 sec)<br><br>
mysql> <br><br>Are you sure that user 'asteriskcdruser' has the privileges to insert record in DB "asteriskcdrdb"?<br>If not...allow 'asteriskcdruser' to insert record ^_^<br><br>mysql> grant insert on asteriskcdrdb.* to
asteriskcdruser@localhost identified by 'asteriskcdruser';<br>mysql> exit<br><br>Reload asterisk and try <br><br><br><br><div><span class="gmail_quote">On 8/7/07, <b class="gmail_sendername">Adrian Marsh</b> <
<a href="mailto:Adrian.Marsh@ubiquisys.com">Adrian.Marsh@ubiquisys.com</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<br>Hmm.. This is what I get:<br><br>[root@ubiq-serv6 ~]# mysql -u root -p<br>Enter password:<br>Welcome to the MySQL monitor. Commands end with ; or \g.<br>Your MySQL connection id is 187143 to server version: 4.1.20<br>
<br>Type 'help;' or '\h' for help. Type '\c' to clear the buffer.<br><br>mysql> use asteriskcdrdb ;<br>Reading table information for completion of table and column names<br>You can turn off this feature to get a quicker startup with -A
<br><br>Database changed<br>mysql> select Host from user where User = 'asteriskcdruser' ;<br>ERROR 1146 (42S02): Table 'asteriskcdrdb.user' doesn't exist<br>mysql><br><br><br>Adrian Marsh<br>-----Original Message-----
<br>From: <a href="mailto:asterisk-users-bounces@lists.digium.com">asterisk-users-bounces@lists.digium.com</a><br>[mailto:<a href="mailto:asterisk-users-bounces@lists.digium.com">asterisk-users-bounces@lists.digium.com</a>
] On Behalf Of Forrest<br>Beck<br>Sent: 07 August 2007 02:59<br>To: Asterisk Users Mailing List - Non-Commercial Discussion<br>Subject: Re: [asterisk-users] CDR/MySQL basic config<br><br>Adrian,<br><br>What host/ip did you specify when you created the user?
<br><br>#> mysql --user=root --password<br><br>#mysql> use mysql;<br><br>#mysql> select Host from user where User = 'asteriskcdruser'<br>(this line is case sensitive)<br><br>Does it return <a href="http://127.0.0.1">
127.0.0.1</a> or localhost. Make cdr_mysql reflect that.<br><br>You should also check out cdr_odbc, asterisk can connect through an<br>ODBC connection which in turn is a connection to the MySQL database.<br>There seems to be more suport for the ODBC driver.
<br><br>Hope this helps some....<br><br><br><br>On 8/6/07, Adrian Marsh <<a href="mailto:Adrian.Marsh@ubiquisys.com">Adrian.Marsh@ubiquisys.com</a>> wrote:<br>> Hi,<br>><br>> I'm trying to add mysql CDR onto a vanilla Asterisk
1.2 install. The<br>> add-ons pack has been installed for a while, so now I'm trying to add<br>> the Mysql config.<br>><br>> I've created a mysql database, added the grants for a user acces, and<br>> can run a mysql -u asteriskcdruser -p and can connect to the database.
<br>><br>> I've been using this as a guide:<br>><br><a href="http://www.757.org/~joat/wiki/index.php/Asterisk#Viewing_CDR_Data_with_A">http://www.757.org/~joat/wiki/index.php/Asterisk#Viewing_CDR_Data_with_A</a>
<br>> sterisk:_CDR_Analyzer<br>><br>> I've created cdr_mysql.conf:<br>><br>> [global]<br>> hostname=localhost<br>> dbname=asteriskcdrdb<br>> table=cdr<br>> password=password<br>> user=asteriskcdruser
<br>> port=3306<br>> sock=/tmp/mysql.sock<br>> userfield=1<br>><br>> But when I start asterisk (1.4 on my test machine), I get:<br>><br>> == Parsing '/etc/asterisk/cdr_mysql.conf': Found<br>
> [Aug 6 21:01:14] ERROR[32512]: cdr_addon_mysql.c:436 my_load_module:<br>> Failed to connect to mysql database asteriskcdrdb on localhost.<br>> cdr_addon_mysql.so => (MySQL CDR Backend)<br>> [Aug 6 21:01:14] ERROR[32512]: res_config_mysql.c:627
<br>mysql_reconnect:<br>> MySQL RealTime: Failed to connect database server on (err 2002).<br>Check<br>> debug for more info.<br>> [Aug 6 21:01:14] WARNING[32512]: res_config_mysql.c:474 load_module:<br>> MySQL RealTime: Couldn't establish connection. Check debug.
<br>> [Aug 6 21:01:14] NOTICE[32512]: config.c:1171<br>> ast_config_engine_register: Registered Config Engine mysql<br>> MySQL RealTime driver loaded.<br>> res_config_mysql.so => (MySQL RealTime Configuration Driver)
<br>><br>><br>> I'm also looking as to what CDR viewers there are available, and which<br>> people think are best. I want to view/report on the calls made within<br>> A*k.<br>><br>> Thanks,<br>>
<br>> Adrian<br>><br>> _______________________________________________<br>> --Bandwidth and Colocation Provided by <a href="http://www.api-digital.com--">http://www.api-digital.com--</a><br>><br>> asterisk-users mailing list
<br>> To UNSUBSCRIBE or update options visit:<br>> <a href="http://lists.digium.com/mailman/listinfo/asterisk-users">http://lists.digium.com/mailman/listinfo/asterisk-users</a><br>><br><br><br>--<br>***<br>Forrest Beck
<br>IAXTEL: 17002871718<br><a href="mailto:jonforrest.beck@gmail.com">jonforrest.beck@gmail.com</a><br><a href="http://www.shift8.biz">http://www.shift8.biz</a><br><br>_______________________________________________<br>--Bandwidth and Colocation Provided by
<a href="http://www.api-digital.com--">http://www.api-digital.com--</a><br><br>asterisk-users mailing list<br>To UNSUBSCRIBE or update options visit:<br> <a href="http://lists.digium.com/mailman/listinfo/asterisk-users">
http://lists.digium.com/mailman/listinfo/asterisk-users</a><br><br>_______________________________________________<br>--Bandwidth and Colocation Provided by <a href="http://www.api-digital.com--">http://www.api-digital.com--
</a><br><br>asterisk-users mailing list<br>To UNSUBSCRIBE or update options visit:<br> <a href="http://lists.digium.com/mailman/listinfo/asterisk-users">http://lists.digium.com/mailman/listinfo/asterisk-users</a><br></blockquote>
</div><br><br clear="all"><br>-- <br><br> Alessandro R.