Title: Direct Admin problem connecting to database
Last modified: August 20, 2016

---

# Direct Admin problem connecting to database

 *  [C D](https://wordpress.org/support/users/coltonday/)
 * (@coltonday)
 * [15 years ago](https://wordpress.org/support/topic/direct-admin-problem-connecting-to-database/)
 * I am getting “Error establishing a database connection” when trying to set-up
   WordPress.
    My hosting control panel is Direct Admin. Web server is Apache/2.
   PhpMyAdmin version 3.4.1. MySQL server version 5.1.48. I’ve checked the WP-config
   file many times and it gives me the same error, I even tried leaving the file
   as WP-config-sample and set it up through my browser, which allowed to enter 
   all the info but gave me the same error after hitting submit. I use “localhost”
   for the MySQL hostname. I don’t know why it’s doing this and I don’t know what
   else to try. I access Direct Admin through an IP address followed by a port number
   and I read in the Codex to add the port number to localhost:**** in WP-config
   for the DB Host but it didn’t work. I’ve tried a bunch of things, I even started
   again with a test.
 * Any help would be greatly appreciated.
    Thanks!

Viewing 3 replies - 1 through 3 (of 3 total)

 *  [fonglh](https://wordpress.org/support/users/fonglh/)
 * (@fonglh)
 * [15 years ago](https://wordpress.org/support/topic/direct-admin-problem-connecting-to-database/#post-2112924)
 * ask your hosts for the database details.
 *  Thread Starter [C D](https://wordpress.org/support/users/coltonday/)
 * (@coltonday)
 * [15 years ago](https://wordpress.org/support/topic/direct-admin-problem-connecting-to-database/#post-2112939)
 * Thanks…. But I have all that info properly configured in my config file… I checked
   it over and over but it’s still giving me an error. I also have access to the
   direct admin control panel… If there’s something I need to check.
 *  [esmi](https://wordpress.org/support/users/esmi/)
 * (@esmi)
 * [15 years ago](https://wordpress.org/support/topic/direct-admin-problem-connecting-to-database/#post-2113044)
 * > “Error establishing a database connection”
 * This is a host/server issue – not a WordPress one.

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Direct Admin problem connecting to database’ is closed to new replies.

 * In: [Installing WordPress](https://wordpress.org/support/forum/installation/)
 * 3 replies
 * 3 participants
 * Last reply from: [esmi](https://wordpress.org/support/users/esmi/)
 * Last activity: [15 years ago](https://wordpress.org/support/topic/direct-admin-problem-connecting-to-database/#post-2113044)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
