admin管理员组

文章数量:1122846

I am trying to restore a full backup created by ManageWP on my local PC to use the local version for testing. I went through different guides, but I could only get the website into a half-working state.

What I did so far:

  1. Installed XAMPP, started Apache and MySQL
  2. Created a "test" folder in "htdocs" and pasted all of the contents of the ManageWP's zipped backup.
  3. Tried to open localhost/test in my browser -> doesn't work, I get "Access denied" MySQL error for the user.
  4. Went to phpmyadmin -> Import, zipped the .sql file from the mwp_db folder and uploaded it -> doesn't work, I get "#1046 - No database selected" for the query "DROP TABLE IF EXISTS inmge_actionscheduler_actions"
  5. The "no database selected" issue was because I didn't create and select a database to import the backup one into. I had to create a new database and select it on the left menu before going to Import.
  6. The import now failed because of timeout issues. I opened xampp/php/php.ini and increased the max_execution_time / max_input_time / memory_limit values. Also, I opened xampp/mysql/bin/my.ini and increased max_allowed_packet.
  7. The changes in 6) were not sufficient so I went and changed ExecTimeLimit to 0 in xampp/phpMyAdmin/libraries/config.default.php
  8. At this point the database was imported, but I had issues with the authentication. I had to add the exact user from wp-config.php to the database in phpMyAdmin and I had to name that database exactly the same.
  9. Now the database was successfully imported, but I still couldn't open the website. I had to change the siteurl and home values in the inmge_options table to localhost/test (via phpMyAdmin)
  10. localhost/test now contained my homepage, but all other links would redirect to Xampp homepage. I had to add WP_HOME and WP_SITEURL values in my wp-config.php and now I could finally open localhost/test/wp-admin and access what I needed there.

After the 10th step, I managed to get the local website into a half-working state, where I can manually enter wp-admin, but any link on the actual website still forwards me back to XAMPP homepage.

I am trying to restore a full backup created by ManageWP on my local PC to use the local version for testing. I went through different guides, but I could only get the website into a half-working state.

What I did so far:

  1. Installed XAMPP, started Apache and MySQL
  2. Created a "test" folder in "htdocs" and pasted all of the contents of the ManageWP's zipped backup.
  3. Tried to open localhost/test in my browser -> doesn't work, I get "Access denied" MySQL error for the user.
  4. Went to phpmyadmin -> Import, zipped the .sql file from the mwp_db folder and uploaded it -> doesn't work, I get "#1046 - No database selected" for the query "DROP TABLE IF EXISTS inmge_actionscheduler_actions"
  5. The "no database selected" issue was because I didn't create and select a database to import the backup one into. I had to create a new database and select it on the left menu before going to Import.
  6. The import now failed because of timeout issues. I opened xampp/php/php.ini and increased the max_execution_time / max_input_time / memory_limit values. Also, I opened xampp/mysql/bin/my.ini and increased max_allowed_packet.
  7. The changes in 6) were not sufficient so I went and changed ExecTimeLimit to 0 in xampp/phpMyAdmin/libraries/config.default.php
  8. At this point the database was imported, but I had issues with the authentication. I had to add the exact user from wp-config.php to the database in phpMyAdmin and I had to name that database exactly the same.
  9. Now the database was successfully imported, but I still couldn't open the website. I had to change the siteurl and home values in the inmge_options table to localhost/test (via phpMyAdmin)
  10. localhost/test now contained my homepage, but all other links would redirect to Xampp homepage. I had to add WP_HOME and WP_SITEURL values in my wp-config.php and now I could finally open localhost/test/wp-admin and access what I needed there.

After the 10th step, I managed to get the local website into a half-working state, where I can manually enter wp-admin, but any link on the actual website still forwards me back to XAMPP homepage.

Share Improve this question edited Feb 8, 2022 at 23:13 Sharp asked Feb 8, 2022 at 19:05 SharpSharp 1013 bronze badges
Add a comment  | 

1 Answer 1

Reset to default 1

I don't have a ton of experience with manage wp but I am going to suggest an alternative for setting up a local site based on a live site. I would suggest using the plugin "All In One Migration"

https://wordpress.org/plugins/all-in-one-wp-migration/

Install the plugin on the live, select "export" it will generate a file for you.

Then go to XAMPP and create a fresh WordPress install including a fresh DB, install the All In One plugin there, then you can drag and drop the file into the import field from the All In One plugin settings, and it should take of everything for you.

It's super easy. I never have issues with it, right now I have 50+ sites on Local By Flywheel that I transferred with this method.

Best of luck.

本文标签: mysqlLocally restoring a ManageWP full site backup