How to Become a WordPress Expert Overnight!

All site owners know the need for backups but it could occur to forget to make regular copies WordPress Error Establishing A Database Connection.

Frequently we understand the importance of the copy when it would be very useful to really have the info to recover when it’s too late, ie.

There are loads of plugins offered to copy your site. Install your favourite copy plugin as soon as you possibly can.

Below the steps I made to reestablish a WordPress back-up.

I inadvertently deleted the entire WordPress database. I have gotten this error: “error creating a database connection “.

Perhaps it is more difficult recover only parts of a database, although it might seem like the worst possible scenario.

wordpress error establishing a database connection

With a File Manager or an Ftp client:

1) Duplicate the backup file. As of this time the backup file is important.

2) Recover some fundamental information in the file wp-config.php. Open the file using a text editor and take note of those 3 settings:

DB_NAME

DB_USER

DB_PASSWORD

Using cPanel database administration tool:

4) Produce a user named as in DB_USER, with password as in DB_PASSWORD

5) Associate now the newest user to the brand new db and provide it all rights.

Now that we’ve an empty database with the settings that are proper, we could repopulate the data using the backup file.

freelance wordpress developer

Using PhpMyAdmin tool:

Place yourself by selecting in the left column in the recently created database.

Click on the “Import” thing at the top right.

This can open a page where you are able to load our backup files, either in Sql format or in a compressed format.

Normally the other values might be left set to defaults.

6) Support the operation by simply clicking the Import button in the bottom of the page.

Only at that point your PhpMyAdmin should reveal the repopulated tables in the left column

PhpMyAdmin can be closed by you, cPanel and attempt to get in your blog. The blog is up and running, although you might have lost the changes since the last copy.

This is merely one potential scenario, likely the most straightforward, and certainly there are several other methods to recoup data lost.

I do believe anyhow this simple article might be useful even as a list of measures needed to be done to then adapt it to your scenario.