Back up a docbase using a script (for Windows)

The TEXTML Server provides a script to back up your docbases as a background task.

Note: Content Store data is stored in a TEXTML Server docbase. To back up a Content Store, you back up the TEXTML Server docbase that stores the Content Store data.
This script, called BackupDocbaseAuto.vbs, is stored in the following location:
<textml_install_dir>\AdminScripts\vbs

Where <textml_install_dir> is the directory where the TEXTML Server is installed. For example:

C:\Program Files\IxiaSoft\TextmlServer\AdminScripts\vbs
  1. Open a command prompt and navigate to the vbs directory:

    For example:

    cd C:\Program Files\IxiaSoft\TextmlServer\AdminScripts\vbs
  2. Run the script as follows:
    cscript BackupDocbaseAuto.vbs <servername[:port]> <docbase name> <targetDirectory> [<backupflag> <username> <password>]

    Where:

    OptionDescription
    <servername[:port]> Name and port of the TEXTML Server that contains the docbase to back up; default value is localhost:2500
    <docbasename> Name of the docbase to back up
    <targetDirectory> Full path to the folder where you want to back up the docbase. The user that is running the TEXTML Server service *must* have write privileges to the target directory.

    For example: C:\docbase_backups\4.4\docbaseA

    <backupflag> Type of backup; enter one of the following values:
    • 0: The script runs synchronously (that is, it runs completely before returning to the command prompt). If the specified target directory exists, the script aborts with the "The destination path is not empty" error message and the docbase is not backed up.
    • 1 (or TEXTML_BACKUP_OVERWRITE): The script runs synchronously and, if the specified target directory exists, it deletes it before backing up the docbase.
    • 2 (or TEXTML_BACKUP_ASYNC): The script runs asynchronously (that is, it immediately returns to the command prompt). If the specified target directory exists, the script aborts with the "The destination path is not empty" error message and the docbase is not backed up.
    • 3 (or TEXTML_BACKUP_OVERWRITE+TEXTML_BACKUP_ASYNC): The script runs asynchronously and, if the specified target directory exists, it deletes it before backing up the docbase.
    Default value is 0.
    <username> <password>] TEXTML Server admin role's user name and password used for running the backup.

    For example:

    cscript BackupDocbaseAuto.vbs localhost:2500 SportsStories c:\docbase_backups\4.4\SportsStories TEXTML_BACKUP_OVERWRITE 
    When the backup starts, the TEXTML Server creates a file called backuperror.tmp in the target directory. This file is replaced with the backup.info file if the backup completes successfully.
  3. To confirm that the backup was successful, look in your target directory:
    • If the backup.info file is present, then the backup was successful.
    • It the backup is completed but the backuperror.tmp is present, then an error occurred and the backup is corrupted.

    If an error occurs, or to get more information about the backup operation, look at the logs. They are available in the log directory.

    %program_data%\IxiaSoft\TextmlServer[version]\Log

    For example:

    C:\ProgramData\IxiaSoft\TextmlServer[version]\Log