On this server, we now want to update the war file, the database, and Java 11. Please let me know if this is feasible. If yes then how can we do that.
Also, what if we want to add postgres extension btree_gin and pg_trgm along with postgis.
Welcome back to the community. Many in the community have experience with servers so hopefully you’ll get a complete answer from your fellow community members.
May I ask what version of dhis2 are you upgrading from and to which version?
You can also try out the newly developed dhis2-server-tools, which are based on Ansible. However, please follow Gerald’s instructions closely. We have a video recording of one of our Thursday server admin calls that you might find helpful:
To ensure a smooth upgrade of your entire stack, the recommended approach would be to create a database backup first. Once the backup is secure, you can proceed with deleting the existing components and then build the stack anew. While you could perform these tasks manually, it might become more complex. It’s best to handle the database upgrade first and then proceed with upgrading the DHIS2 instance. This way, you can minimize any potential risks and ensure a seamless upgrade process.
Manually upgrading database
Here are some general recommendations and steps to follow when upgrading your PostgreSQL database, specifically to version 13, which has been tested with DHIS2:
Backup your database: Take a complete backup of your existing database to ensure you have a copy of the data in case anything goes wrong during the upgrade process. Test the backup to ensure it works fine and consider saving it offsite as a fallback option
Create a new database container: Set up a new database container running PostgreSQL 13 on your server. Make sure your storage can accommodate running two databases in parallel.
Plan for downtime: Prepare for the required downtime during the upgrade process. Inform users and stakeholders about the scheduled maintenance window and the expected duration of the upgrade.
Disable external connections: Temporarily disable external connections to the database during the upgrade. This prevents unwanted interactions or data inconsistencies while the upgrade is in progress.
Restore the backup: Follow the official PostgreSQL documentation or upgrade guides to perform the upgrade. Install the new version, migrate the data, and configure the updated database by restoring the backup you created earlier.
Connect your DHIS2 instance: Once the database is upgraded, connect your DHIS2 instance to the new database.
Test and validate: Thoroughly test the functionality and performance of your applications against the upgraded database. Validate that all critical operations are functioning as expected.
You can easily create the btree_gin and pg_trgm extensions by executing the following SQL commands: CREATE EXTENSION IF NOT EXISTS btree_gin; CREATE EXTENSION IF NOT EXISTS pg_trgm;
These steps should help guide you through the upgrade process. Make sure to consult the official PostgreSQL documentation and any relevant upgrade guides specific to your environment for detailed instructions and best practices.
To manually upgrade your dhis2 instance, you can follow these steps:
Access the LXD container by executing the following command:
I’m looking for opinions on which items should be on a DHIS 2 Server Administration handover checklist. I will be taking over the job as DHIS 2 System Administrator and I am about to do a course on DHIS 2 Server Administration to gain skills.
I have experience in DHIS 2 System Administration, but I have no experience in DHIS 2 Server Administration.
I would be happy if you could share an example of a server handover document.