Title: Database Connection Issue
Last modified: August 20, 2016

---

# Database Connection Issue

 *  Resolved [DigitalMcGrath](https://wordpress.org/support/users/digitalmcgrath/)
 * (@digitalmcgrath)
 * [14 years, 4 months ago](https://wordpress.org/support/topic/database-connection-issue-2/)
 * My situation is this…
 * I have 2 cloud servers with RackSpace. 1 is my web server and the other is my
   database server. I can connect from my web server to my data server in WordPress
   just fine when using the public IP address of the data server.
 * I would like to change this to the Private IP and when I do, I get a Error establishing
   database connection.
 * I have ran a few tests and it seems to be an issue with just my existing WordPress
   site.
 * I can connect to the data server on the private IP from outside of WP using the
   same login credentials and database as my current WP installation.
 * I have created a brand new WP installation using the same login credentials with
   a new database and it works.
 * Any idea why my existing site would have issues?

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

 *  [danhgilmore](https://wordpress.org/support/users/danhgilmore/)
 * (@danhgilmore)
 * [14 years, 4 months ago](https://wordpress.org/support/topic/database-connection-issue-2/#post-2424418)
 * Maybe a Access Denied issue? Does the private IP have privileges in the mysql.
   user table?
 *  Thread Starter [DigitalMcGrath](https://wordpress.org/support/users/digitalmcgrath/)
 * (@digitalmcgrath)
 * [14 years, 4 months ago](https://wordpress.org/support/topic/database-connection-issue-2/#post-2424423)
 * Yes it does. I can connect using the same credentials and IP outside of WP.
 *  Thread Starter [DigitalMcGrath](https://wordpress.org/support/users/digitalmcgrath/)
 * (@digitalmcgrath)
 * [14 years, 4 months ago](https://wordpress.org/support/topic/database-connection-issue-2/#post-2424462)
 * I think I know what the issue is. I am trying to connect my development site 
   to my production database. The WP site is a multi site installation and the primary
   blog names don’t match between production and development.
 * I think the error is coming from WP not being able to find the development primary
   blog. I am running some tests to see if this is true. If it is, I will close 
   this post.
 *  [danhgilmore](https://wordpress.org/support/users/danhgilmore/)
 * (@danhgilmore)
 * [14 years, 4 months ago](https://wordpress.org/support/topic/database-connection-issue-2/#post-2424465)
 * Ah, yes, I have had that problem in the past. Check the .htaccess file and make
   sure the RewriteBase is same as $base in wp-config.php. Will also need to change
   the path in the DB.
 *  Thread Starter [DigitalMcGrath](https://wordpress.org/support/users/digitalmcgrath/)
 * (@digitalmcgrath)
 * [14 years, 4 months ago](https://wordpress.org/support/topic/database-connection-issue-2/#post-2424485)
 * So it was the data in the database that was the issue.
 * Thanks for the replies.

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

The topic ‘Database Connection Issue’ is closed to new replies.

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 5 replies
 * 2 participants
 * Last reply from: [DigitalMcGrath](https://wordpress.org/support/users/digitalmcgrath/)
 * Last activity: [14 years, 4 months ago](https://wordpress.org/support/topic/database-connection-issue-2/#post-2424485)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
