<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Is good to separate them anyway for monitoring the number of different connections to various databases.<div><br></div><div>Adrian</div><div> <br><div><div>On Jun 1, 2011, at 9:16 PM, Duane Larson wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite">Thanks Adrian. Took a little while to figure out, but it's probably best to use different credentials anyway from a security standpoint. Got to love bugs.<br><br>
<div class="gmail_quote">On Wed, Jun 1, 2011 at 2:14 PM, Adrian Georgescu <span dir="ltr"><<a href="mailto:ag@ag-projects.com">ag@ag-projects.com</a>></span> wrote:<br>
<blockquote style="BORDER-LEFT: #ccc 1px solid; MARGIN: 0px 0px 0px 0.8ex; PADDING-LEFT: 1ex" class="gmail_quote">Seems to be a php bug that cannot correctly identify the different connections in a mysql pool. Work around it by using different credentials/database combinations.<br>
<br>Adrian<br><br>On Jun 1, 2011, at 9:05 PM, osiris123d wrote:<br><br>> Figured out the issue but it doesn't make sense. From my last post it<br>> appeared that when mysql was querying for the radacct201106 table it was<br>
> looking in the cdrtool database. Well when I set up cdrtool's global.inc<br>> config I made it so that cdradmin mysql user was used to log into the<br>> cdrtool database and also the radius database. Here is an example of what I<br>
> had<br>><br>> class DB_CDRTool extends DB_Sql {<br>> var $Host = "127.0.0.1";<br>> var $Database = "cdrtool";<br>> var $User = "cdradmin";<br>> var $Password = "*";<br>
> var $Halt_On_Error ="yes";<br>> }<br>><br>> class DB_Locker extends DB_Sql {<br>> var $Host = "127.0.0.1";<br>> var $Database = "cdrtool";<br>> var $User = "locker";<br>
> var $Password = "*";<br>> var $Halt_On_Error ="yes";<br>> }<br>><br>> class DB_radius extends DB_Sql {<br>> var $Host = "127.0.0.1";<br>> var $Database = "radius";<br>
> var $User = "cdradmin";<br>> var $Password = "*";<br>> var $Halt_On_Error ="yes";<br>> }<br>><br>> class DB_opensips extends DB_Sql {<br>> var $Host = "127.0.0.1";<br>
> var $Database = "opensips";<br>> var $User = "opensips";<br>> var $Password = "*";<br>> var $Halt_On_Error ="yes";<br>> }<br>><br>> class DB_mediaproxy extends DB_Sql {<br>
> var $Host = "127.0.0.1";<br>> var $Database = "mediaproxy";<br>> var $User = "cdradmin";<br>> var $Password = "*";<br>> var $Halt_On_Error ="yes";<br>
><br>><br>><br>> Originally I had the radius database user as "radius", but when I tried to<br>> create that user in mysql it wouldn't let me (maybe because there is a<br>> database called radius, not sure). So I figured I would just use the<br>
> cdradmin user for everything except for opensips database. Well when I<br>> changed the cdrtool config to the following it is now about to do CDR<br>> searches<br>><br>><br>> class DB_CDRTool extends DB_Sql {<br>
> var $Host = "127.0.0.1";<br>> var $Database = "cdrtool";<br>> var $User = "cdradmin";<br>> var $Password = "*";<br>> var $Halt_On_Error ="yes";<br>
> }<br>><br>> class DB_Locker extends DB_Sql {<br>> var $Host = "127.0.0.1";<br>> var $Database = "cdrtool";<br>> var $User = "locker";<br>> var $Password = "*";<br>
> var $Halt_On_Error ="yes";<br>> }<br>><br>> class DB_radius extends DB_Sql {<br>> var $Host = "127.0.0.1";<br>> var $Database = "radius";<br>> var $User = "radadmin";<br>
> var $Password = "*";<br>> var $Halt_On_Error ="yes";<br>> }<br>><br>> class DB_opensips extends DB_Sql {<br>> var $Host = "127.0.0.1";<br>> var $Database = "opensips";<br>
> var $User = "opensips";<br>> var $Password = "*";<br>> var $Halt_On_Error ="yes";<br>> }<br>><br>> class DB_mediaproxy extends DB_Sql {<br>> var $Host = "127.0.0.1";<br>
> var $Database = "mediaproxy";<br>> var $User = "cdradmin";<br>> var $Password = "*";<br>> var $Halt_On_Error ="yes";<br>><br>><br>> So it all appears to be good now, but I figured I should have still been<br>
> able to use the cdradmin user for both databases. For some reason CDRTool<br>> was looking in the cdrtool database for the radacct201106.<br>><br>><br>><br>> --<br>> View this message in context: <a href="http://opensips-open-sip-server.1449251.n2.nabble.com/CDRTool-MySQL-Database-error-Invalid-SQL-tp6427865p6428379.html" target="_blank">http://opensips-open-sip-server.1449251.n2.nabble.com/CDRTool-MySQL-Database-error-Invalid-SQL-tp6427865p6428379.html</a><br>
> Sent from the OpenSIPS - Users mailing list archive at <a href="http://Nabble.com">Nabble.com</a>.<br>><br>> _______________________________________________<br>> Users mailing list<br>> <a href="mailto:Users@lists.opensips.org">Users@lists.opensips.org</a><br>
> <a href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users" target="_blank">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a><br>><br><br><br>_______________________________________________<br>Users mailing list<br>
<a href="mailto:Users@lists.opensips.org">Users@lists.opensips.org</a><br><a href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users" target="_blank">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a><br>
</blockquote></div><br><br clear="all"><br>-- <br>--<br>*--*--*--*--*--*<br>Duane<br>*--*--*--*--*--*<br>--<br>
_______________________________________________<br>Users mailing list<br><a href="mailto:Users@lists.opensips.org">Users@lists.opensips.org</a><br><a href="http://lists.opensips.org/cgi-bin/mailman/listinfo/users">http://lists.opensips.org/cgi-bin/mailman/listinfo/users</a><br></blockquote></div><br></div></body></html>