Moving Continua CI's PostgreSQL to a dedicated server

Hi Guys,

Lately we’ve been experiencing some issues with our underlying storage hosting (among other things) our Continua CI and VCS.

Due to suspicions regarding top hitters for the storage -
Among other actions we’re taking - It has been suggested to Split the Continua CI Application
And its DataBase to different servers.

We’re using the built in PostgreSQL DB
Is it possible to migrate it to a separate server?
If so what would be the steps?
More importantly, is it possible to have the Continua CI Updates - handle a such a split case where the App and the DB are not on the same server?

Thank you!

Hi Arik,

Here’s some detailed instructions on migrating the database to a separate PostgreSQL service.

  1. Shut down the Continua CI service.

  2. Back up the bundled PostgreSQL database:

  3. Take a backup copy of C:\Program Files\VSoft Technologies\ContinuaCI\Server\Continua.Server.Service.exe.config.

  4. Optionally take a snapshot of the VM for safety (just in case).

  5. Restore the backup to the new PostgreSQL server (as described in step 2).

  6. Test the new database:

    • Update the connection string in C:\Program Files\VSoft Technologies\ContinuaCI\Server\Continua.Server.Service.exe.config (under hibernate-configurationsession-factoryproperty name="connection.connection_string").
    • Start the Continua CI service.
    • Check that the server is working correctly.

At this point, the server is running on the new database server, but the installer doesn’t recognize it, so the next installation will try to back up and upgrade the bundled PostgreSQL server. Also, the bundled PostgreSQL server is still active and taking up space.


To get everything running smoothly, run the uninstaller and reinstall

  1. Ensure you know all the installation options you used before. You may want to run through the installer, choosing “Update existing settings” to verify the options.

  2. Go to Add or Remove Programs in Windows Settings and uninstall the Continua CI Server.

    • When the Uninstallation Options dialog appears, ensure that only the following options are ticked:
      • Remove "ContinuaCI" IIS web site and "ContinuaCI" app pool
      • Delete the Continua CI PostgreSQL data folder at "C:\ProgramData\VSoft\ContinuaCI\PostgreSQLDB"

  1. Run the latest Continua CI installer:
    • Install to the existing destination folder.
    • Enter your service user and ports.
    • Select the existing share.
    • On the Database page:
      • Select “Use your own existing PostgreSQL installation” and enter the new connection string.
    • Continue with the previous IIS and Authentication settings and complete the installation.

Everything should now be running as before using the new database server.


If the folders C:\ProgramData\VSoft\ContinuaCI\PostgreSQLDB or C:\Program Files\VSoft Technologies\ContinuaCI\Server\PostgreSQL still exist, you can safely delete them.


Notes:

You will need to manage backups and upgrades to the separate PostgreSQL service - the ContinuaCI installer only upgrades the bundled PostgreSQL service.

Changes to the database schema are always migrated by the Continua CI service on start-up - not during the installation.

Please let us know how this works out for you.

Hi Dave, Thank you so much for the quick and detailed response as always!

Regarding PostgreSQL upgrades:
Will it be mandatory for us to upgrade our PostgreSQL server before installing any Continua CI updates where the release notes mention:

Also, does it matter if we host our PostgreSQL on a Linux server?

Thanks again!
Arik

Hi Arik,

Continua CI does not rely on commands specific to a single PostgreSQL version, so any supported version, such as 13 to 17, should work without issue.

Likewise, Continua CI should have no compatibility issues running with a PostgreSQL service hosted on Linux.

If we introduce any functionality in the future that isn’t backward-compatible, we will make sure to communicate this clearly in the release notes.

So, no it is not mandatory for you to upgrade our PostgreSQL server before installing any Continua CI updates. That said, upgrading PostgreSQL will often improve performance and security.