Installing OpenVPMS on Windows 10

Contents

Introduction

This tutorial describes one user's step-by-step installation of OpenVPMS 2.x on a PC with a Windows 10 32-bit or 64-bit operating system. Originally written with images for Windows 7, there have been some changes in software upgrades, appearance, links and images will be updated for Windows 10 if there's any significant difference.  Update advice: Apps are updated and links are accurate as of 18 November 2021.   This guide is not an official OpenVPMS guide.

When installing OpenVPMS you should

  • be logged in on an account with Administrator privileges;
  • consider disabling UAC will also smooth the installation process. This will become important especially when trying to configure Tomcat.

Download OpenVPMS Installation And Other Required Files

  • Download the latest openVPMS Installation files.
    Unzip the Installation Pack onto your C: drive.  This should create a C:\openvpms-release-2.n.n folder with the necessary files to install OpenVPMS.
    You don't need the version number in the folder name - it's fine to just rename the folder to "OpenVPMS". This will be useful if you have other software that accesses OpenVPMS: if you upgrade versions, you won't need to alter those other software packages.
    Create a folder called, say C:\openVPMS\Installation Files.
     
  • Download Open Office 4.1.n from openoffice.org and save in C:\OpenVPMS\Installation Files folder.
     
  • Download Java 8 SE Runtime Environment  from the Java Downloads page and save it to C:\OpenVPMS\Installation Files.
    You only need the RunTime Environment version (64-bit or 32-bit).
    Java 11 can be installed however there are a number of locale changes in Java 11, compared to Java 8.  This causes differences in formatting for date functions that use the LONG, MEDIUM and SHORT date formats.
    From my reading of the Oracle Binary Code License for Java 8 "Oracle grants you a non-exclusive, non-transferable, limited license without license fees to reproduce and use internally the Software complete and unmodified for the sole purpose of running Programs".
     
  • Download the Windows MySQL 5.5.62 installation file from the MySQL archives site.site. Scroll down and select highest 5.5.nn version.
    Select Windows Essentials (x86 for 32-bit or x64 for 64-bit) and download into C:\OpenVPMS\Installation Files
     
  • Download the MYSQL GUI Tools from the MySQL archive site.
    Select the Windowsx86 for 32-bit or x64 for 64-bit and save into C:\OpenVPMS\Installation Files folder. Yes I know this is deprecated but has the MySQL Administrator which makes for simple (and essential) admin connection and setup and is quicker to install (no requirement for MS Visual C++) than MySQL Workbench (however for running SQL queries and other tasks, Workbench is the accessory app of choice).
     
  • Download the MYSQL Java Connector 8.0.nn from the MySQL site: click on Archives, then select 8.0.27 and Platform Independent .ZIP file and save into C:\OpenVPMS\Installation Files folder.
     
  • Download Apache Tomcat (at time of writing current version is 9.0.x) from the Apache Software Foundation site.
    Select the Core | 32/64-bit Windows Service Installer option and save into C:\OpenVPMS\Installation Files folder.

Start Installation

0. Back Up

Consider taking a System Image of  your server before you start - sometimes timewise it's easier to revert to "start over" rather than fix recalcitrant errors.

1. Install Java8 (updated)

Execute jre-8u281-windows-x64 (or x86 for 32-bit).exe and accept all defaults.

2. Set Java 8 Environment Variable (updated)

Right-Click on Computer icon on desktop, then click "Properties".

 

Click on Advanced System Settings (1), Advanced (2) and then Environment Variables (3):

Under System Variables (lower box - upper box is for User Variables), click on New(4), then enter JAVA_HOME and browse to the Java folder and press OK
 

The end result should look like this:

Click OK, OK, then close the remaining window.

3. Open Port 3306 in your Windows Firewall

 

Click Start | Control Panel | System And Security:

Click on Windows Defender Firewall:

Click on Advanced Settings, then follow images as below:








You've confirmed the new rule, so close the window (click on red x).

If you're going to access OpenVPMS from other computers on a network within the clinic, you'll also need to allow port 8080.
Repeat the steps above, this time typing in 8080 as the TCP Port to allow and name it Openvpms.

4. Install MySQL

Double-click on the "mysql-essential-5.5.nn-win32.msi" file you have downloaded and follow the images below:


Be patient: at this point, it may take some time for the progress bar to start moving (on one of my PCs, over three minutes), so just leave the PC to do its work: the following screens should be self-explanatory: press Next when prompted to do so:

At next screen, DO NOT CLICK "Finish" until you read the following steps:

STOP HERE! (Don't click "Finish" just yet)

Leave the above window on the screen.

Why?

You need to set read/write permissions before configuration or the Configuration Wizard will fail at execution, thus:

Open Windows Explorer, browse to ProgramFiles\MySQL\MySQL Server 5.5.

Right-click on the folder and select Properties; un-check Read-Only tab:

Click on Security tab, then Edit, then Users:

Click on Allow | Full Control then click OK:

Ensure "Apply changes..." (1) is checked and click Ok Ok.

Now go ahead and click "Finish" to load the Configuration Wizard (2).





At this screen, click on the drop-down arrow and select \Data:

Your screen should then look like this: if it does, click Next to continue:







You now need to ensure all permissions are enabled.  In previous Windows7 installation instructions, this step was placed here.  However, in indows 10 pro, if you didn't un-set the read-only flag and set Full Control permissions before configuring MySQL  the Configuration app would crash at the "Starting Service" button.  

It won't hurt to check your permissions here before continuing.

  • Click on "Computer" icon, browse to C:\Program Files\MySQL;
  • right-click on MySQL Server 5.5 (1);
  • select Properties and then click on Security (2) tab;
  • select Users (3);
  • then click Edit (4), click Users (5) and click to enable Full Control (6);
  • and press OK.

5. Install MySQL GUI Tools

Double-click on the "mysql-gui-tools-5.0-r17-win32.msi" file you have downloaded to commence installation.  Whilst this is an older app, you need this to configure MySQL in the next step.  This step is essential but is not listed in the official OpenVPMS documentation
Click "Next" all the way through to complete default installation.

 

6. MySQL Configuration

Click Start | MySql | right-click MySql Administrator | More | Run As Administrator.

Click on the button with the ellipsis (...) arrowed in image below:

Click on New Connection:

Change New Connection to localhost then fill in the fields (root, openvpms, localhost) as per image below and click Apply | Close:

You should now be back at the opening screen: select localhost from the drop-down box and click OK

On the left-hand pane, click Startup Variables (1), then click on the InnoDB Parameters (2) tab.
Scroll down to, and check Buffer Pool Size (3) and type in 1024 (recommended for OpenVPMS with minimum of 4GB RAM).
Scroll down to, and check One File Per Table (4).

Click on Advanced Networking tab (5), enable Max. packet size and set to 16 M (6), then click Apply Changes (7) and close the window (8).

 

7. Apache Installation

Double-click on the "apache-tomcat-9.0.nn.exe" file you have downloaded to commence installation (app hasn't changed in appearance from 7->8->9); click Next;

Click Next;

Fill in User Name as admin and password as openvpms click Next;

Installer should find your Java installation without any intervention by you; if you have more than one, pick highest build number, then click Next

Accept default installation folder and click Install;


 

8. Configure Apache Tomcat

At this point you would normally click Start, right-click on Configure Tomcat and select Run As Administrator:

But unfortunately you would be presented with this error message:

You need to take two additional steps:

1.  disable UAC.  Click Start | Control Panel | System and Security | Change User Account Control Settings and set UAC to "Never Notify:

2.  Browse to Tomcat 9.0\bin folder, right-click on Tomcat9w.exe and select Run As Administrator:

Click on Java tab. In Java Options, scroll down to the bottom and add the following two lines:

-XX:PermSize=128m
-Xincgc

Set Initial Memory Pool and Maximum Memory Pool to the same value, depending on the number of users; say 512 at a minimum. Try 1024 for 4GB memory or higher.
Changes required are highlighted in yellow in image below:

Click OK and close.

9. OpenOffice Installation

Double-click on the "Apache_OpenOffice_4.n.n_Win_x86_install_en-GB.exe" file you have downloaded to commence installation; accept all default values as per the following images:

Once installed, start OpenOffice, fill in details  and from the main menu select Tools | Options:

Click on On-line Update and un-check Check for updates automatically;

Click OK to close options.

Close OpenOffice.

10. Configure OpenOffice Path

Right-Click on Computer icon on desktop, then click "Properties".


Click on Advanced System Settings (1), Advanced (2) and then Environment Variables (3):

Under System Variables (lower box ), click on Path (4), then click Edit (5);


Press New (6), then Browse (7) and select c:\Program Files (x86)\OpenOffice4\program (8) and press Ok (9):


Click  OK, then close the remaining window.

Test your OpenOffice path configuration.

Click Start | Windows System |  Command Prompt:

 

Type in swriter and press Enter. OpenOffice/Writer should start. Two reasons for doing this:

  1. If it does start, you've set the path correctly.
  2. OpenVPMS starts OpenOffice in the background; if OpenOffice is waiting for questions on registration and checking for updates to be answered, letter merging etc. won't work.
    Reopening OO makes sure it is not asking for you to participate in surveys etc.


If all's well, close OpenOffice.

11. MySQL Database Driver Setup

  • Open the downloaded mysql-connector-java-8.0.nn.zip.
  • Extract connector file mysql-connector-java-8.0.nn.jar to Tomcat library folder i.e C:\Program Files\Apache Software Foundation\Tomcat 9.0\lib.
  • Extract the same connector to c:\OpenVPMS\lib folder.

So far so good, it should only have taken you eight minutes (or less) on an average >2018 PC to get to this point.

12. OpenVPMS Database Setup 

Click Start | Windows System |  Command Prompt, navigate to C:\OpenVPMS\bin.

Type in toolbox configure and press Enter.

{Note: if using Powershell instead of Command Prompt,you Right-Click-Start | WindowsPowerShell, navigate to C:\OpenVPMS\bin, you will need to type in  ./toolbox configure and press Enter .}

Type in toolbox database --create -u root -p openvpms and press Enter. 

Type in dataload setup and press Enter.  Lots of messages will scroll down the creen - first and last few shown here.


Type in toolbox template --load --size A4 --all and press Enter (type A5 if using that size of paper).  Again lots of messages  will scroll down the screen.

14. OpenVPMS Web Application Setup 

Still at the Command prompt window at c:\openvpms\bin type toolbox war and press Enter.

Copy openvpms.war from c:\openvpms\webapps to c:\Program Files\Apache Software Foundation\Tomcat 9.0\webapps.

Copy the openvpms.war file from c:\openvpms\webapps
to Tomcat Webapps folder at C:\Program Files\Apache Software Foundation\Tomcat 6.0\webapps.

 

16. Apache Tomcat Service Setup

On the desktop, right-click on Computer icon and select Manage.

In Services and Applications, click on Services, right-click on Apache Tomcat 9 and select Properties. Click on General tab and change Startup type to Automatic.

Click OK to close.

Click on Apache Tomcat 9, then click on Restart the service.

One last thing: right-click on Properties again, select General and check Startup Type: make sure it's set to Automatic, then click Ok, then Stop and then Restart the service.  (Aggravatingly, after all this setup had been completed, I got a "refused connection" at Step 17 below.  I went back to Tomcat Properties and found that the StartupType had reset itself(?) to Manual.)

17. OpenVPMS Application Test/Run

Open up your internet browser this address: http://localhost:8080/openvpms/app

Login to OpenVPMS using user 'admin' and password 'admin'

Eureka! It works!

18. OpenVPMS Application From Other PCs on Network

First, you need to establish the IPv4 address of your server (the PC that your OpenVPMS installation resides on):
Open a Command Prompt (Start | Windows System | Command Prompt) and type ipconfig and press Enter.
Look for the line IPv4 address: in the screenshot below, it's 192.168.1.101:

To start OpenVPMS on another PC on the network, you will need to type in http://IPv4_address:8080/openvpms; in example below, http://192.168.1.101:8080/openvpms:

However, there's a distinct possibility that you are told you can't connect to OpenVPMS. 

Windows 10 now throws up another gotcha just when you thought you were home free!  By default Windows sets networks as public, so when you try to log in to OpenVPMS from another PC on the network, you are denied access.

You need to set the network to Private on the PC containing OpenVPMS.  

Follow these steps.

Click Settings (gear wheel) | Network & Internet:

Click Ethernet (or whatever your network is called):

Click Network:

Select Private as your Network profile and close.  OpenVPMS should now load from your workstation machine.

Click here to move on to setting up OpenVPMS for use.

This resource is an openVPMS enduser-created tutorial. Constructive criticism and corrections welcome.


Comments

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
Username and password as suggested (ie admin) are not working at stage 17.
That should be loaded by: dataload setup from step 13. -Tim
Note that in OpenVPMS 1.5 and higher, there is no need to configure iReport to be compatible with JasperReports 1.3.2 in step 11. -Tim
Step 11 now modified to remove need to configure iReport.
Link fails to open at http://localhost:8080/openvpms/app
Syndicate content