• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Restore one site from MySQL and files backup

zooming

Regular Pleskian
Hello,

How can I restore one specific site from a MySQL and Filesystem backup?

I have the site ID, and I have found the correspondent directory in the "SB_ROOT/htdocs/sites" backup path. I have restored all the site's files and folders to it's path.

Then I have searched in the MySQL backup file for all occurrences of the Site ID and other objects ID's related to this site (modules id, etc).

I have end up with rows from the following tables:

module_instance_publication
module_instance
modules_AreaMap_google
modules_AreaMap_provider
modules_DownloadableContent_settings
modules_Feedback_fields
modules_Feedback_properties
modules_ImageGallery_settings
modules_Login_common
modules_Login_contact_info
modules_Login_notifications
modules_Script_main
site_page
site_publication
site

Then I have run the all the insert statements for these rows.

But the site does not work, I can't find it in the site list, and If I try to access this site from Plesk's integration icon, I receive this error:

Internal Sitebuilder error.
File: /usr/local/sitebuilder/include/SB/Helpers/Wizard/Site.php; Line: 159
Message: PHP Notice : Trying to get property of non-object; Code: 8

Probably I have missed some rows, but I don't know which ones.

Is there an easy way to determine which rows from the MySQL backup belongs to a specific site? Perhaps some magic query already built?

Am I missing something else?

Thank you.
Alexandre
 
I have managed to complete this restore, but it is a dauting task.
I had to follow every field in the insert clauses and mark the correspondent registers in other tables.
TextPad's bookmark feature have made the job much easier.
 
Back
Top