How to Restore a SiteWorx Account Backup

Prerequisites

Last Updated for InterWorx-CP version 2.1.0

The server must have at least one SiteWorx account on the system.

Purpose

From the NodeWorx interface administrators will be able backups of SiteWorx accounts, both partial backups and full backups.

Procedure - NodeWorx Web Interface

If you prefer to use the web interface, follow the steps below.

  1. Click on the SiteWorx menu if it is not already expanded.
  2. Click on the ♦    Backup / Restore item.
  3. You should now be looking at the Backup / Restore controls in the main content area.
  4. You will see a list of all the SiteWorx accounts on the server, with a checkbox next to each. If you are logged in with a NodeWorx Reseller account, you will only see the SiteWorx accounts that belong to you.
    1. If the SiteWorx account currently has no backups, you will see No Backups in the Status column.
    2. If the SiteWorx account does have backups you will see a [ Manage ] link in the Status column. Click the [ Manage ] link corresponding to the SiteWorx account you would like to restore.
  5. You will see a list of all the backup files for that SiteWorx account with [ Restore ] links on the far right of each backup. Click the [ Restore ] link corresponding the the backup file you would like to restore.
  6. Because a restore will overwrite existing data in the SiteWorx account, you will be asked to confirm. Click the Restore button to restore the account.

Procedure - Command Line Interface

The command line backup interface is less user-friendly, but you have a lot more options at your disposal. Using the command line interface is most useful when you want to automate (e.g., via CRON) the creation of SiteWorx account backups.

  1. SSH into the server
  2. su to the iworx system user. You may need to switch to the root user first (if you’re not already logged in as the root user) and then switch to the iworx user.

The command you will be running is, as the iworx user:

[iworx@test-box ~]$ /home/interworx/bin/import.pex

import.pex has several command line parameters:

Required Parameters
Parameter Description
--archive=filePath and filename of backup file to restore.
--ip-address=ip-addressIP address to use for the restored account. The IP address must be a valid shared or unused IP address. The special value inifile indicates that the IP address should be taken from the SiteWorx backup file.
--control-panel=siteworxTells import.pex that this a SiteWorx backup file.
Optional Parameters
Parameter Description
--forceTells import.pex to force the restore which will delete any existing SiteWorx account, without a confirmation prompt, before restore proceeds.
--reseller-id=id numberTells import.pex to assign the account to a particular reseller account. If this parameter isn’t used the account will be assigned to the NodeWorx administrator.
--create-resellerTells import.pex to create the reseller that’s stored in the backup file. If the reseller in the backup file already exists, the account will automatically be imported under this reseller.
Note: this option is only valid for SiteWorx 3.0+ backups

To restore SiteWorx backup file /tmp/backup.tar.gz on IP address 192.168.1.10, with a prompt to confirm deletion of the existing SiteWorx account:

[iworx@test-box ~]$ /home/interworx/bin/import.pex \
                    --archive=/tmp/backup.tar.gz \
                    --control-panel=siteworx \
                    --ip-address=192.168.1.10

To restore SiteWorx backup file /tmp/backup.tar.gz, with the IP provided within the backup, with a prompt to confirm deletion of the existing SiteWorx account:

[iworx@test-box ~]$ /home/interworx/bin/import.pex \
                    --archive=/tmp/backup.tar.gz \
                    --control-panel=siteworx \
                    --ip-address=inifile

To restore SiteWorx backup file /tmp/backup.tar.gz, with the IP provided within the backup, without a prompt to confirm deletion of the existing SiteWorx account:

[iworx@test-box ~]$ /home/interworx/bin/./import.pex \
                    --archive=/tmp/backup.tar.gz \
                    --control-panel=siteworx \
                    --ip-address=inifile --force

Troubleshooting

COPYRIGHT © InterWorx L.L.C. 2004-2008 PRIVACY POLICYEULA