Backing up remote databases

Use the following procedure to back up your remote databases. This procedure includes a maintenance strategy for the use of the transaction logs by SQL Remote. Do not use this procedure and run the SQL Remote Message Agent (dbremote) with the -x option.

 Back up remote databases using the Backup utility (dbbackup)
  1. Make a full backup of the remote database.

    1. Connect to the database as a user with DBA authority.

    2. Run dbbackup with the -r and -n options.

      For example, assume that the backup directory is e:\archive, the database file is located in the c:\live directory and its corresponding transaction log file is located in the d:\live directory:

      dbbackup -r -n -c "UID=DBA;PWD=sql;DBF=c:\live\remotedatabase.db" e:\archive

      The transaction logs in the d:\live directory are not altered by the full backup.

    3. Copy the backup files located in the e:\archive directory to an off-site drive or to a DVD.

    4. Run the SQL Remote Message Agent (dbremote) with access to the current transaction log files using the following command:

      dbremote -c "UID=DBA;PWD=sql;DBF=c:\live\remotedatabase.db" d:\live
    Caution

    Do not run the SQL Remote Message Agent (dbremote) with the -x option on a database that is being backed up.

  2. Set up the Backup utility (dbbackup) to make incremental backups of the remote database's transaction log.

    1. Connect to the database as a user with DBA authority.

    2. Run dbbackup with the -r, -n, and -t options.

      For example:

      dbbackup -r -n -t -c "UID=DBA;PWD=sql;DBF=c:\live\remotedatabase.db" e:\archive
    3. Run the SQL Remote Message Agent (dbremote) with access to the current transaction log files using the following command:

      dbremote -c "UID=DBA;PWD=sql;DBF=c:\live\remotedatabase.db" d:\live