Two ideas here…
You might find a copy of your database in the file directory used by your backup plugin (you did have a good backup plugin installed didn’t you?). If so it might be there in your files copy and you can use that.
If not then maybe your old host has a backup copy still on hand. It won’t hurt to ask.
Barring the above…
You might try setting the IP to your old host in place of the ‘localhost’ in WP-config… that’s a very long shot… if your database is still there you might be able to access it… if it will allow remote access even.
If that works then do a database backup immediately because it won’t last long once the account is closed or gone.
Barring that…
You might find some of your old content (possibly all) still present over at the Wayback Machine. https://archive.org/web/.
I have rebuilt websites using the Wayback Machine… It’s not fun but it can be done.
]]>On my new web server I do have phMyAdmin and MySQL Databases. They are both working. In fact, phpMyAdmin already had the database available on the left side. I didn’t do any import, it was there automatically. (Did it do some auto-scan, I don’t know?)
The instruction page I mentioned says that I should add a user in MySQL Databases. I tried, but it accepts only 8 letters for the username. And there is a prefix xxxxxxx_ (name changed). But in my wp-config.php the username is much longer than what MySQL Databases accepts.
There is already one user in MySQL Databases but it’s a different user than defined in wp-config.php.
What to try next?
]]>But, nothing seem to have changed. I changed the DNS earlier and I think that has already updated and ok (the error message shown to visitors changed after chaging that). The site’s error message is still “Error establishing a database connection”. I also changed the wp-config.php to match a new user added by me in MySQL Databases. It does say: Current Databases, my_databasename, 17 MB, my_user (with all privileges). What might be wrong?
]]>One of the DB parameters in your wp-config.php file is incorect.
]]>I can go to mysite.com/wp-admin and it now gives “503 Service Temporarily Unavailable”. It now tries accessing the WP redirections which is good.
I don’t know how to fix this error. Deactivating plugins and switching to default theme was suggested, but I can’t access the backend. Before using my webhotel’s expensive support for this, is there something I can do to troubleshoot that error? Any logs or additional information would be very useful.
]]>Meantime, enable wp_debug and wp_debug_log and after an error, look at wp-content/debug.log to see if anything gets logged there. https://codex.www.ads-software.com/Debugging_in_WordPress
You can also try this: Please attempt to disable all plugins, and use one of the default (Twenty*) themes. If the problem goes away, enable them one by one to identify the source of your troubles.
If you cannot access wp-admin, there are other ways to deactivate plugins.
]]>