Running multiple openXdata servers on the same tomcat installation is easy.

You may want to do this for a variety of reasons. For example, you have two teams running two completely seperate data collection projects with two different sets of users and two project administrators. If you run these on one openXdata server, which is perfectly possible you would need to give both of the project administrators permissions to manage users and they could accidentally modify a user of the other project. To avoid this we just give them their own kingdom.

To install a new openXdata instance the steps are exactly the same as for installing your first openXdata instance.

The main change is that before you start, you should rename your openxdata.war file to the name you would like for your new instance.  For example if you would like to run 3 instances at:

  • http://my-public-ip:8080/project1
  • http://my-public-ip:8080/project2
  • http://my-public-ip:8080/project3

make 3 new openXdata.wars called project1.war, project2.war, project3.war

You must create seperate MySQL databases for each openXdata instance and, ideally, seperate users for each database (to enhance security).

Then when it comes to editing your file, you will find the file under each instances webapps folder.  For instance, in Ubuntu linux: the properties file for project1 would be found at /var/lib/tomcat6/webapps/project1/; for project 2 at /var/lib/tomcat6/webapps/project2/ and so on.