Topic: MySQL connection

Enano version - 1.0.6
PHP version - 5.2.9
web server - Apache 2.2.10
MySQL version - 5.0.77
When installing Enano everything is fine (including database connection check), but at the end I get the following message: "Error: couldn't connect to MySQL"
Actually, the database tables are created, but enano can't connect to the database !
The screen dump can  be sent by request (I can't attach it to this message).


Thank you for help.

Re: MySQL connection

Do you get the error during the installation or after it finishes? Does your database information (specifically database name and login) contain any special characters including a dash?

--Dan

Re: MySQL connection

Dan wrote:

Do you get the error during the installation or after it finishes? Does your database information (specifically database name and login) contain any special characters including a dash?

--Dan

I get the error on the last screen of the installation process ( The step on the left side of the screen is "Database Installation")

My DB password contains slash.

Re: MySQL connection

I'll test this on stable tonight.

--Dan

Re: MySQL connection

Tested, I couldn't reproduce the problem. If you can post a screenshot (use ImageShack or equivalent) that would be very helpful.

--Dan

Re: MySQL connection

The screen snapshot is at  http://yfrog.com/63enanoxj

Re: MySQL connection

See if you can install Enano 1.1.5 and get it to load. There might be a problem with your PHP configuration or possibly an issue with an outdated MySQL client library. Also try installing another web application - phpBB is a good one to test with - and see if it throws any errors.

I'm not sure what's happening here because there's only one situation under which Enano throws this error:

dbal.php, line 173 wrote:
$this->_conn = @mysql_connect($dbhost, $dbuser, $dbpasswd);
unset($dbuser);
unset($dbpasswd); // Security

if ( !$this->_conn )
{
  grinding_halt('Enano is having a problem', '<p>Error: couldn\'t connect to MySQL.<br />'.mysql_error().'</p>');
}

If the MySQL connection resource is bad, it dies out. The thing that confuses me is, where is the MySQL error string? Something is returning a nonstandard value and thus preventing Enano from figuring out if its connection works or not.

Also try removing the "if ( !$this->_conn ) { ... }" part, and post back here with the result.

--Dan