Article ID: 111365, created on Jun 2, 2011, last review on May 3, 2014

  • Applies to:
  • Plesk Sitebuilder 4.5 for Linux/Unix


Try restoring user and site with sbrestore:

~# /usr/local/sitebuilder/utils/sbrestore user --name=<user name> --with-sites --with-site-content --input=<backup file>.xml
Processing "user"...
...<user name>
......user sites
.........<site alias>
Please wait while the permissions are being set

Note: utility sbrestore is located in directory /opt/sitebuilder/utils/sbrestore on Debian/Ubuntu.

The user was restored without the site. The following error is shown in Sitebuilder log on page Logs of admin panel:

Cannot execute query - Duplicate entry 'e4terw589kv-65608-4' for key 1, sql - UPDATE modules_Feedback_fields SET position=pos...

How to fix the error and restore the site?


The error is caused by '<position>' options of fields description in backup file. For example:

<backup file>.xml
            <caption>First name</caption>
            <position>64058</position>  <== this option causes the error


Remove all '<position>' options from the backup file. You may use the following command to remove all lines:

~# sed -i '/<position>/d' <backup file>.xml

Additional information

If you restore from compressed backup file (with --compress option) you need to uncompress the backup first. Use the following procedure to uncompress the backup.

1. Create file uncompress.php:

       $file = fopen('/PATH/TO/<backup file>.gz', 'r');
       $data = fread($file, filesize('/PATH/TO/<backup file>.gz'));
       $data = gzuncompress($data);
       print $data;

2. Uncompress the backup, save result to xml file

~# php uncompress.php > <backup file>.xml

3. After that you may restore the backup with utility sbbackup. Do not use option --compress to restore from xml backup file <backup file>.xml.

f7f840260c1591440648a375a64b5b75 fad6dc0c8e983c17ae70a51ac7952cd0 d055be4fdc562a8ecb8e6d0bf419f946 ea6a61e571a858aa6019ceb068ea403a 56797cefb1efc9130f7c48a7d1db0f0c

Email subscription for changes to this article
Save as PDF