Error establishing a database connection
-
Hi
I am not able to get WordPress up and running on my local pc.I had Php, Apache and Mysql installed
——————-
MYSQL
——————-mysql> show databases;
+———–+
| Database |
+———–+
| blog |
| mysql |
| test |
| wordpress |
+———–+
mysql> show grants for blog@localhost;
+—————————————————+
| Grants for blog@localhost |
+—————————————————+
| GRANT ALL PRIVILEGES ON *.* TO ‘blog’@’localhost’ |
+—————————————————+
1 row in set (0.00 sec)mysql> select Host,User,Password from user;
+———–+———–+———-+
| Host | User | Password |
+———–+———–+———-+
| localhost | root | |
| localhost | | |
| localhost | wordpress | |
| % | wordpress | |
| localhost | blog | |
+———–+———–+———-+
5 rows in set (0.00 sec)———————
wp-config.php
——————–
<?php
// ** MySQL settings ** //
define(‘DB_NAME’, ‘blog’); // The name of the database
define(‘DB_USER’, ‘blog’); // Your MySQL username
define(‘DB_PASSWORD’, ”); // …and password
define(‘DB_HOST’, ‘localhost’); // 99% chance you won’t need to change this value// Change the prefix if you want to have multiple blogs in a single database.
$table_prefix = ‘wp_’; // example: ‘wp_’ or ‘b2’ or ‘mylogin_’// Change this to localize WordPress. A corresponding MO file for the
// chosen language must be installed to wp-includes/languages.
// For example, install de.mo to wp-includes/languages and set WPLANG to ‘de’
// to enable German language support.
define (‘WPLANG’, ”);/* Stop editing */
define(‘ABSPATH’, dirname(__FILE__).’/’);
require_once(ABSPATH.’wp-settings.php’);
?>I have no idea why it is failing to connect to the database. (I had already tried “root” intead of blog
Is their any place where wordpress prints the error messages to help debug the problem
from – /var/log/httpd/error_log
[Sat Jul 09 17:56:43 2005] [notice] LDAP: Built with OpenLDAP LDAP SDK
[Sat Jul 09 17:56:43 2005] [notice] LDAP: SSL support unavailable
[Sat Jul 09 17:56:43 2005] [notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec)
[Sat Jul 09 17:56:43 2005] [notice] Digest: generating secret for digest authentication …
[Sat Jul 09 17:56:43 2005] [notice] Digest: done
[Sat Jul 09 17:56:43 2005] [notice] LDAP: Built with OpenLDAP LDAP SDK
[Sat Jul 09 17:56:43 2005] [notice] LDAP: SSL support unavailable
[Sat Jul 09 17:56:44 2005] [notice] Apache/2.0.51 (Fedora) configured — resuming normal operations
[Sat Jul 09 17:57:01 2005] [error] [client 127.0.0.1] File does not exist: /var/www/html/favicon.icoFrom – /var/log/mysqld.log
050709 17:56:37 mysqld started
050709 17:56:37 InnoDB: Started; log sequence number 0 43634
/usr/local/mysql/bin/mysqld: ready for connections.
Version: ‘4.1.10a-max’ socket: ‘/var/tmp/mysql.sock’ port: 3306 MySQL Community Edition – Experimental (GPL)Am I missing something.
Thanks
Sumit
- The topic ‘Error establishing a database connection’ is closed to new replies.