Search Type:
Search for:

Language:

Product:
Category:
No categories for selected product

[How to] How to migrate Plesk and Sitebuilder content retaining Plesk and Sitebuilder integration

Article ID: 5882 
Last Review: Sep,5 2009
Author: Bezborodova Anastasiya
Last updated by: Bezborodova Anastasiya APPLIES TO:
  • Parallels Plesk Sitebuilder for Linux/Unix
  • Plesk 8.6 for Linux/Unix

Symptoms

Integration of Parallels Plesk Sitebuilder and Parallels Plesk Panel means that:

1. Sitebuilder submenu exists in left menu of Plesk Contorl Panel;
2. Sitebuilder support is enabled for Plesk domains via {Plesk -> Domains -> DOMAIN.NAME -> Setup -> Create and publish Web site using Sitebuilder -> Ok}. When enabled new site with same name is created in Parallels Plesk Sitebuilder that is configured to be published to domain's httpdocs directory;
3. button Sitebuilder Wizard opens domain for editing in Sitebuilder wizard.

How to migarte the data to enviroment retaining Plesk and Sitebuilder integration?

Resolution

Use the steps below to migrate Plesk and Sitebuilder content retaining Plesk and Sitebuilder integration.

1. Setup new Parallels Plesk server and migrate whole Plesk data using Plesk Manager Manager {Server -> Migration Manager} or Import Mode migration (http://kb.parallels.com/en/1152). The server should be migrated as a whole.

2. Setup new Parallels Plesk Sitebuilder with all modules, templates and locales of the same version that are installed on source Parallels Plesk Sitebuilder. Migrate sites directory, configuration file and database to new server. Refer to this article for details about Sitebuilder migration procedure: http://kb.parallels.com/en/5512.

3. Register new Parallels Plesk Sitebuilder in new Parallels Plesk Panel through {Plesk -> Server -> Sitebuilder Support}. Enter valid credentials of Sitebuilder administrator and click OK.

This creates new Sitebuilder plan "Plan for all user creating from PLESK.FULL.HOSTNAME" that will be assigned to all Plesk clients when Sitebuilder support is enabled for them.
Also submenu Sitebuilder appear in Plesk left menu.

4. Enabled Sitebuilder support for all Plesk clients usual way: {Plesk -> Clients -> CLIENT.NAME -> Preferences -> Create a corresponding user account in Sitebuilder -> OK}

This creates new Sitebuilder resellers with names:

@CLIENT1.LOGIN@PLESK.FULL.HOSTNAME
@CLIENT2.LOGIN@PLESK.FULL.HOSTNAME
@CLIENT3.LOGIN@PLESK.FULL.HOSTNAME
...


Where CLIENT1.LOGIN is login of client CLIENT.NAME and PLESK.FULL.HOSTNAME is full hostname of new Parallels Plesk Panel.

5. To restore links between Plesk domains and Sitebuilder sites it is needed to activate Sitebuilder support for Plesk domains usual way.
However Sitebuilder site with name DOMAIN.NAME already exists and so Sitebuilder support cannot be activated for Plesk domain DOMAIN.NAME anew usual way. Check that site with name DOMAIN.NAME already exists in Sitebuilder database:

mysql> select site_id, alias, user_id from sitebuilder3.site where alias ='DOMAIN.NAME';
+----------------------------------+-------------+---------+
| site_id                          | alias       | user_id |
+----------------------------------+-------------+---------+
| a0293da2f54fef29e22c1a894df4ba4e | DOMAIN.NAME |      35 |
+----------------------------------+-------------+---------+
1 row in set (0.00 sec)

mysql>

6. Sitebuilder site DOMAIN.NAME was copied during migration. However it is not linked to Plesk domain DOMAIN.NAME. With instructions below we are going to rename Sitebuilder site, activate Sitebuilder support for Plesk domain usual way and restore the link between domain and site.

Rename site DOMAIN.NAME to DOMAIN.NAME.old in Sitebuilder database.

mysql> update sitebuilder3.site set alias='DOMAIN.NAME.old' where site_id='a0293da2f54fef29e22c1a894df4ba4e';
Query OK, 1 row affected (0.01 sec)
Rows matched: 1  Changed: 1  Warnings: 0

mysql>

Activate Sitebuilder support for Plesk domain DOMAIN.NAME usual way {Plesk -> Domains -> DOMAIN.NAME -> Setup -> Create and publish Web site using Sitebuilder -> Ok}. That is possible because site with name DOMAIN.NAME does not exist now, it was renamed to DOMAIN.NAME.old.

When Sitebuilder support is activated for Plesk domain DOMAIN.NAME this creates new Sitebuilder site (9fc19c1531dc647deb60a7232a7e2b33) with name DOMAIN.NAME. You may check this with the command below.

mysql> select site_id, alias, user_id  from sitebuilder3.site where alias like 'DOMAIN.NAME%';
+----------------------------------+-----------------+---------+
| site_id                          | alias           | user_id |
+----------------------------------+-----------------+---------+
| a0293da2f54fef29e22c1a894df4ba4e | DOMAIN.NAME.old |      35 |
| 9fc19c1531dc647deb60a7232a7e2b33 | DOMAIN.NAME     |      35 |
+----------------------------------+-----------------+---------+
2 rows in set (0.00 sec)

mysql>

Configuration of Plesk domain and Sitebuilder site integration is stored in table SBSites of Plesk database. Here is configuration of Sitebuilder support for domain DOMAIN.NAME in Plesk database:

mysql> select domains.name, SBSites.id, SBSites.sb_site_id from psa.domains, psa.SBSites where virtualHost_id=domains.id;
+-------------+----+----------------------------------+
| name        | id | sb_site_id                       |
+-------------+----+----------------------------------+
| DOMAIN.NAME |  3 | 00fe1f8af6d2bebfdd13f770bfbff04b |
+-------------+----+----------------------------------+
1 rows in set (0.00 sec)

mysql>

In Sitebuilder database site DOMAIN.NAME has id a0293da2f54fef29e22c1a894df4ba4e, however in Plesk database domain DOMAIN.NAME is linked to Sitebuilder site with id 00fe1f8af6d2bebfdd13f770bfbff04b.

7. Correct site id for domain DOMAIN.NAME in Plesk database:

mysql> update psa.SBSites set sb_site_id='a0293da2f54fef29e22c1a894df4ba4e' where id=3;
Query OK, 1 row affected (0.00 sec)
Rows matched: 1  Changed: 1  Warnings: 0

mysql>

Where 3 is SBSites.id and a0293da2f54fef29e22c1a894df4ba4e is uuid of old Sitebuilder site.

Now when you click button Sitebuilder Wizard in Parallels Plesk Panel {Plesk -> Domains -> DOMAIN.NAME -> Sitebuilder wizard} site DOMAIN.NAME is opened in Sitebuilder wizard.

8. Delete new site DOMAIN.NAME from Parallels Plesk Sitebuilder usual way {Plesk -> Sitebuilder -> Sites -> *locate and mark enabled site DOMAIN.NAME* -> Delete}

9. Rename site DOMAIN.NAME.old to DOMAIN.NAME in Sitebuilder database:

mysql> update sitebuilder3.site set alias='DOMAIN.NAME' where site_id='a0293da2f54fef29e22c1a894df4ba4e';
Query OK, 1 row affected (0.00 sec)
Rows matched: 1  Changed: 1  Warnings: 0

mysql>

Integration of Plesk domain DOMAIN.NAME and Sitebuilder site DOMAIN.NAME has been corrected.

Additional information

You may get name of Sitebuilder database with utility sb_config:

~# sb_config --help | grep sb_db_name
 --sb_db_name         Sitebuilder database name [sitebuilder3]
~#

By default the name is sitebuilder3.

To connect to Sitebuilder database:

~# mysql -uUSER -pPASSWD sitebuilder3

Where USER and PASSWD is user and password of mysql administrator. If Parallels Plesk Sitebuilder is installed on the same server with Parallels Plesk Panel then USER is admin and PASSWD is stored in file /etc/psa/.psa.shadow. You may use the following command:

~# mysql -uadmin -p`cat /etc/psa/.psa.shadow` sitebuilder3

Use the following command to connect to Plesk database:

~# mysql -uadmin -p`cat /etc/psa/.psa.shadow` psa




Subscription for changes to this article Subscription for changes to this article

Please provide feedback on this article

Did this article help you solve your issue?
Yes
No
Partially
I do not know yet
 
Strongly Agree   Strongly Disagree
  9 8 7 6 5 4 3 2 1
The article is easy to understand
The article is accurate
Additional Comments:
*Please provide us with your email address in case we need to contact you.
* - required fields
 
 
 
 
 
 
For Home
For Business
For Hosters
For SaaS
For Developers
 
Desktop Virtualization
- Parallels Desktop Switch to Mac Edition
- Parallels Desktop for Mac
- Parallels Desktop 4 for Windows & Linux
- Parallels Workstation Extreme
- Parallels Solution for Windows 7
Server Virtualization
- Parallels Server for Mac
- Parallels Server 4 Bare Metal
- Parallels Virtuozzo Containers
Automation
- Parallels Operations Automation
- Parallels Business Automation
- Parallels Virtual Automation
- Parallels Plesk Panel Suite
More Products