How to resolve the "file is not a database" error during the initial setup of CubeBackup for Google Workspace.


Error message: createTable(…) failed:file is not a database

The file is not a database error usually indicates a decryption error when trying to connect to the same backup repository or data index on a second installation of CubeBackup.

When you reinstall CubeBackup on a different location or server, a new encryption key pair is generated, which is different than the pair used to encrypt your data originally. Therefore, your old backups cannot be accessed and decrypted by the new installation. For more information about data encryption and the encryption key, please visit How is the backup encrypted in CubeBackup.

Solutions

Restore with the original CubeBackup encryption key

If you've got a copy of the encryption key file or your original CubeBackup installation directory is still available, please follow the instructions below to replace the encryption key:

  1. Replace the encryption key file <installation directory>/db/keys.json on the new CubeBackup server with the copy of your original one.

    By default, the installation directory is C:\Program Files\CubeBackup4 on Windows, and /opt/cubebackup on Linux.

  2. Restart the CubeBackup service using the following command.

    Please run this command.

    sudo /opt/cubebackup/bin/cbsrv restart

    Open a Command Prompt as Administrator, and run this command.

    "C:\Program Files\CubeBackup4\bin\cbsrv.exe" restart

    Open the Windows PowerShell as Administrator, and run this command.

    & "C:\Program Files\CubeBackup4\bin\cbsrv.exe" restart

    Please run this command to restart the container.

    sudo docker restart <container-name>

  3. CubeBackup should now work with the new encryption key without any error. You can now go ahead and configure the new CubeBackup instance based on your original backups.

Start from scratch on the second instance

If you've already removed the original installation directory, please use the instructions below to clear the original backup data.

  1. Empty the backup storage and data index directory for the new CubeBackup instance, or simply select a new path or cloud storage bucket.
  2. Restart the CubeBackup service using the following command.

    Please run this command.

    sudo /opt/cubebackup/bin/cbsrv restart

    Open a Command Prompt as Administrator, and run this command.

    "C:\Program Files\CubeBackup4\bin\cbsrv.exe" restart

    Open the Windows PowerShell as Administrator, and run this command.

    & "C:\Program Files\CubeBackup4\bin\cbsrv.exe" restart

    Please run this command to restart the container.

    sudo docker restart <container-name>

  3. Refresh the configuration wizard, and select the new backup storage and data index path. Please make sure that they are both empty without any remaining data synced from previous installations.

  4. Go ahead and complete the CubeBackup configuration.

Contact the CubeBackup support team

If any other error message pops up or you need further assistance, please do not hesitate to contact [email protected].