Skip to main content

Restoring User Portal to a Previous State

In scenarios where User Portal stops functioning, such as in case of failed upgrades, you can salvage the system by restoring User Portal to a previous state.

In order to restore the Key Manager system, you must have the following:

  • If restoring to another version of User Portal, you will need the installation package that contains the product and support packages of the target User Portal version.
  • A previously-taken backup of the User Portal storage.
    • For User Portal instances that use a PostgreSQL database as storage, you will need a previously- taken backup of the database.

    • For User Portal instances that use a local cache as storage: You will need previously-taken backups of local-cache data, which could be obtained by backing up the following directories and their contents from the User Portal machine:

      /etc/sshmgr-user-portal/

      /var/lib/sshmgr-user-portal/

To restore User Portal to its pre-upgrade state:

  1. If you are restoring to another version of User Portal, uninstall the current User Portal packages, then install the User Portal packages with the target version. Skip this step if you are restoring to the same version of User Portal that is currently installed.

    Uninstall the User Portal package and support packages:

    # yum erase sshmgr-user-portal meld3 supervisor nginx

    Then install the version of User Portal which you want to restore. For instructions about doing this, see the product documentation provided with the target version.

  2. Stop the User Portal services to prevent changes to the User Portal storage:

    # supervisorctl stop all
  3. Restore the User Portal storage using a previously-taken backup.

    • If your User Portal instance uses a PostgreSQL database, see the database vendor documentation for instructions about restoring the database from a backup.
    • If your User Portal instance uses a local cache, copy the backed-up local-cache-data files back to their former filesystem locations.
  4. Restart the User Portal services to apply the changes:

    # supervisorctl start all

    Your User Portal is now restored to a previous state.