I'm able to connect through the command line - but when trying to access through a cms like mambo it gives me this error.
using fedora 3,
I tried what it said to try for "cant connect" @ the middle of mysql -->
http://dev.mysql.com/doc/mysql/en/ca...to-server.html
[root@localhost ~]# mysqladmin -h `hostname` version
mysqladmin: connect to server at 'localhost.localdomain' failed
error: 'Host 'localhost.localdomain' is not allowed to connect to this MySQL server'
I get that error for some of the other test. I know mysql is running:
Server version 3.23.58
Protocol version 10
Connection Localhost via UNIX socket
UNIX socket /var/lib/mysql/mysql.sock
Uptime: 5 days 36 min 38 sec
Threads: 1 Questions: 3654 Slow queries: 0 Opens: 370 Flush tables: 1 Open tables: 63 Queries per second avg: 0.008
[root@localhost ~]# mysqladmin -h host_ip version
mysqladmin: connect to server at 'host_ip' failed
error: 'Unknown MySQL Server Host 'host_ip' (1)'
Check that mysqld is running on host_ip and that the port is 3306.
You can check this by doing 'telnet host_ip 3306'
( yes i changed the host_ip above )
any ideas?
someone groovy made a php db connex tester and thats where im getting the error, the script is made to debug why my mambo site isnt connecting to the db.:
Code:
<?php
$mosConfig_host = 'WWWW'; // Replace as appropriate.
$mosConfig_db = 'XXXX'; // Replace as appropriate.
$mosConfig_user = 'YYYY'; // Replace as appropriate.
$mosConfig_password = 'ZZZZ'; // Replace as appropriate.
// Can we connect to the database server?
$dbh = @mysql_connect($mosConfig_host, $mosConfig_user, $mosConfig_password)
or die('Failed to connect to MySQL.<br><b>' . mysql_error() .'</b>');
// Can we attach to our selected database?
mysql_select_db($mosConfig_db, $dbh)
or die('Failed selecting database: ' . $mosConfig_db . '<br/><b>'
. mysql_error() .'</b>');
// If we get here then all is well.
echo "Connected to $mosConfig_db on $mosConfig_host successfully.";
?>