CDR Not Working

Just got my asterisk 1.2 server with freepbx 2.1.2 up and running (on debian) but can’t access the CDR. I get the following errors:

Warning: mysql_real_escape_string(): Access denied for user: ‘[email protected]’ (Using password: NO) in /var/www/debiansj/htdocs/admin/cdr/cdr.php on line 26

Warning: mysql_real_escape_string(): A link to the server could not be established in /var/www/debiansj/htdocs/admin/cdr/cdr.php on line 26

Still being a noob, I’m not sure how to get round this - any help is much appreciated.

Cheers

Steve

I have the same problem, I checked that the usernames and passwords you mentioned match, and they do.

“using password: NO” feels like something wrong here maybe?

I notice all the permissions in the mysql users db are set to N for the asterisk user. Is that right?

the problem is with the mysql_real_escape_string call, removing it seems to be a work-around

in the var/www/admin/cdr/cdr.php file, make the section look like this, like the previous version.

    foreach($test_vars as $test_var) {
            if (isset($_POST[$test_var])) {
                    global $$test_var;
                    $$test_var = $_POST[$test_var];
            } elseif (isset($_GET[$test_var])) {
                    global $$test_var;
                    $$test_var = $_GET[$test_var];
            }
    }

[quote=“jonmansey”]the problem is with the mysql_real_escape_string call, removing it seems to be a work-around

in the var/www/admin/cdr/cdr.php file, make the section look like this, like the previous version.

    foreach($test_vars as $test_var) {
            if (isset($_POST[$test_var])) {
                    global $$test_var;
                    $$test_var = $_POST[$test_var];
            } elseif (isset($_GET[$test_var])) {
                    global $$test_var;
                    $$test_var = $_GET[$test_var];
            }
    }[/quote]

Thanks, that solved the problem!

superb, thats got it. Thanks very much :smiley:

[quote=“SteveJ”]Just got my asterisk 1.2 server with freepbx 2.1.2 up and running (on debian) but can’t access the CDR. I get the following errors:

Warning: mysql_real_escape_string(): Access denied for user: ‘[email protected]’ (Using password: NO) in /var/www/debiansj/htdocs/admin/cdr/cdr.php on line 26

Warning: mysql_real_escape_string(): A link to the server could not be established in /var/www/debiansj/htdocs/admin/cdr/cdr.php on line 26

Still being a noob, I’m not sure how to get round this - any help is much appreciated.

Cheers

Steve[/quote]

Got the same problem over here. Fortunately for me I had a backup of the old 2.1.1 /var/www directory, and all you have to do is to temporarily restore /var/www/admin/cdr to the old version until there is a fix released for this.

Hi Steve,

SteveJ wrote:

[quote] Just got my asterisk 1.2 server with freepbx 2.1.2 up and running (on debian) but can’t access the CDR. I get the following errors:

Warning: mysql_real_escape_string(): Access denied for user: ‘[email protected]’ (Using password: NO) in /var/www/debiansj/htdocs/admin/cdr/cdr.php on line 26

Warning: mysql_real_escape_string(): A link to the server could not be established in /var/www/debiansj/htdocs/admin/cdr/cdr.php on line 26
[/quote]
please check if username and password of the AMPDBUSER in
/etc/amportal.conf matches the one in /etc/asterisk/cdr_mysql.conf.

Have fun,
Carsten.


Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642


Amportal-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/amportal-users

Post generated using Mail2Forum (http://www.mail2forum.com)