Sitemap

Database Backup and Restore

Website Documentation for your KeePass client and Pleasant Password Server

(Versions 7.2.3+ and Enterprise or higher license)

Automatic database backups and database restoration (through the web client) have been added to Pleasant Password Server.  With the addition of database backup and restoration easy database migration is now also available.

Have Questions?  Contact Us

Sections:

 

Note: These features have moved in the web client, and can now be accessed from the Settings tab (in versions 7.9.7+). Previously they were located in the Advanced tab.

Database Backups

Note: Without the backup encryption key, you will not be able to restore your database from a backup.

This page allows you to set how often the backup is run, how many backups are kept, the key used to encrypt the backup, the name of the folder where the backups will be stored, and the prefix given to backup filenames.

Reference: items included in Database Backups

Important Usage Notes

  • Store this Encryption Key: You will need this same encryption key to restore from files backed up with this process.
  • Recommend Daily Backups (after work hours): This backup process can be intensive, and it is best to run after hours if possible, recommended daily on weekdays. Running more than this (i.e. hourly) on the default database may cause performance problems.
  • Backup to a Network Path
    • Network path formats:
      • \\servername\folder 
      • \\server.example.org\share\path
    • Account that runs the "Pleasant Password Service" needs permissions to that network share.
  • Other Notes:
    • Test the Connection:
      • By using the "Backup Now" button
    • Keep a Sufficient number of backup files:
      • We recommend keeping a sufficient number of backups, and periodically archiving in another secure location.

 configure database backups

Backup Settings

  • Enable Automatic Database Backup: Enables the automatic database backup to run.
  • Schedule: How often and what times the backup process runs. By default the database backups are configured to run every Saturday night at 2300 (11:00 p.m.).
    • Older versions: are configured using CRON Expressions
  • Number of Backups: The number of backups kept in storage. New backups created by the process will cause the oldest backup file (with the same prefix in the backup folder) to be overwritten.
    • Note: Reducing the number of backups will remove the older backup files.

  • Encryption Key: The key used to encrypt the backups (32 character maximum).
    • Special characters are not allowed in this character sequence.
    • Note: This key is needed when Restoring a Backup.
  • Folder Path: The name of the folder where the backups will be stored. By default:
    • C:\ProgramData\Pleasant Solutions\Password Server\<FolderName>
    • Changing the folder name will not delete the old folder, but will create a new folder with the specified name the next time a backup occurs.
  • Filename Prefix: Backup files will have names with the following format:
    • <FilenamePrefix>_<Time of Backup>_<Random Suffix>
    • where the Time format is:  <Year>_<Month>_<Day>_<Hour>_<Minute>_<Second>
    • The <Random Suffix> ensures backup files are uniquely named.
    • Changing the Filename Prefix will prevent backups with the old prefix from being overwritten.

 

Note: While it is possible to run the database backup process while the server is actively being used, best practice is to only run backups when no one is using Password Server.

Note: The Save button is only enabled when there have been changes made to the database backup form.

Viewing Backup Results

Logging of this Backup event is stored in the Audit logs:

  • Navigation menu > Logging > Logged Events

The log will indicate Success or Failure and the filename of the newly created backup file:

  • Backup Triggered
  • Backup Occurred - "User <Backup Restore Service> backing up database to <\\networkShare\yourFolder...>"

Error details may be found by following: these instructions.

Manual Database Backups 

After saving a backup configuration, trigger a manual database backup by clicking on the Backup Now button.

 

If there are pending changes to the backup configuration the Backup Now button will be disabled.

You will see a notification message:

  • Started manual Backup using the saved configuration. This may take several minutes to complete

Backup progress can be seen from the Logging page.

Restore Database

This page lets you pick a backup to restore.

Warning: Restoring a backup overwrites the current database - if it has not been backed up, it will be gone for good.  Also note that you will not be able to use Password Server while the database is being restored.

Restoration steps

1. (Optional) Click Backup Now (see above, in Database Backups).

2. Enter the same Encryption Key used to create the backup file (under Advanced tab > Database Backups > in the Encryption Key field), to restore the database.

3. Select a backup file stored on the server: click the backup file you wish to restore.

4. Click Restore

  • Confirmation message: "Are you sure you want to overwrite your current database? This action cannot be undone."
    • Click Ok

5. Possible messages:

  • Succeeded: The database has been successfully restored.
    • If you have restored a database from a previous version of Password Server, it is recommended you restart your Password Server service (or IIS site) after the restoration is complete.
  • Failed: Could not restore database from
    • This means no file was selected. Click to select a file and try again.
  • Failed: Could not restore database from Backup_####-##-##_##_##_##_######.db
    • Ensure your Encryption key matches the Encryption key used to create the Backup file (see the Database Backups page)

6. Restart the service/site:

  • Wait for the service/site to start, then restart the service/site one more time.

Restore-database

Note: Uploading a file will remove your ability to pick an existing backup until the uploaded file is removed

Event Logs

Logging of this Restore event is stored in the Audit logs and can be found on:

  • Navigation menu > Logging > Logged Events

The log will indicate Success or Failure and the filename of the newly created backup file.

Any additional error details may be found by following: these instructions.

Troubleshooting

If you run into any issues with the restore, contact us by email (link is on the right-hand side) and include:

  • A brief Description of the situation
  • Your Detailed Log files

Database Migration

Database migration is possible through the following steps:

  1. Back up the current database
    • Copy the Backup to a separate location
    • Store a copy of the encryption key, used to make the Backup file
  2. Stop Pleasant Password Server and change the database to the one you want to migrate to.
  3. Ensure the server is properly connected to the target database.
    • Change the connection string as necessary in Service Config Utility
  4. Start Pleasant Password Server
  5. Restore from the Database Backup file that was previously saved.
  6. Restart the service/site
    • First wait for the service/site to finish, then restart the service/site.