Upgrading dhis2 steps

Dear team,

I installed dhis2 using the latest tools on GitHub - dhis2/dhis2-server-tools: Tools to support installation and management of DHIS2, the default version installed is 2.38, now I want t upgrade to 2.40. I followed the following instructions as suggested by @Ulanbek to do the upgrade:

Basically what you need:

  • installed and running DHIS2.36
  • download version 40 of DHIS
  • stop your instance (tomcat)
  • create database backup
  • replace existing war file with new one
  • run tomcat
  • the rest will be done by DHIS2.40. It may take some time to upgrade and amend your existing DB

Open your local DHIS2 instance and login. Check if anything wrong on dashboards, open each report, charts, tables, custom reports. Run your programs and dataSets.
If everything is fine and you have not faced any problems\bugs then you can start upgrade on your live server.

I upgraded successfully by changing the war file address in the hosts file. BUT

MY QUESTION IS HOW DO I REPLACE THE WAR FILE ONLY WITHOUT RUNNING THE WHOLE DEPLOY SCRIPT

Thank you for your help.

@arnold, yes you just need to replace war file and startup Tomcat. In order to replace old war file, copy new one, delete old one, and rename new one with old name.

@Ulanbek thank you so much. Can you help me where I can locate this file, I am using Ubuntu.

I setup the server using LXD containers, dhis2 is on its container

@arnold , I believe in order to upgrade LXD container, either you should get ready container with DHIS2.40, or rebuild it manually.

In normal case the WAR file should be placed inside tomcat\webapps folder with respective name. I usually name it ROOT.war

I never used LXD containers, therefore please ask community who could provide you more details on it.

Good luck!

Thanks @Ulanbek. @tkipkurgat can you assist.

1 Like