GNU Health/The Demo database

From Wikibooks, open books for an open world
Jump to: navigation, search

Introduction to the Demo Database[edit]

GNU Health default installation comes with no data. It's interesting, for academic and training purposes to have some demo data that exemplifies concepts and improves the learning curve.

The demo database is an ongoing project and it will be adapting to the each new GNU Health version. The clinical history will also grow with time.

For consistency sake, it's important to have the main characters information constant (family members name, birth dates and place, health centers, family doctors etc.). The information and characters are fictitious and we should try to make it valid for different cultures.

The Zenon-Betz Family[edit]

The story goes around the Betz family, and the main character, Ana Betz, a primary school teacher.

  • Health Center: GNU Solidario Hospital in Las Palmas, Spain
  • Family Doctor: Cameron Cordara
    • ID: 765870
    • Speciality: Family Medicine
    • Institution: GNU Solidario Hospital
  • Family: Zenon-Betz family
    • John Zenon (SSN: 40556644)
    • Ana Betz (SSN: 55567890) born October 4th, 1985, the main character
    • Matt (SSN: 97234436), born March 15th 2010, their son

Demographics Information[edit]

  • Sex: Female
  • Marital Status: Married
  • Profession: School teacher
  • Education Level: University
  • Domiciliary Unit
    • Housing Conditions: Comfortable and good sanitary conditions

Patient Information[edit]

  • Socio-Economic Status: Middle class
  • Allergies: β-lactam hypersensitivity
  • Diseases: Type 1 Diabetes diagnosed on November 10th 1993
  • Medication: Insulin since November 10th 1993
  • Genetic Information
    • Family history
      • Maternal Grandfather: Marfan's Syndrome (Q87.4)
      • Father: Essential (primary) hypertension (I10)
    • Disease Genes
      • BRCA1: breast cancer 1, early onset
  • Obstetric Information: G1P1A0
    • Newborn: Matt, epidural, vaginal birth
  • Lifestyle
    • Ex-smoker
    • Addictions: No recreational drugs
    • Sexuality: Heterosexual, monogamous, practices safe sex
    • Safety: Motorcycle rider, uses helmet

Other Information[edit]

  • Family information (Family functionality level, members, operational sectors...)
  • Imaging (X-rays, CTs, MRIs...)
  • Genetic info / risks
  • Lab orders and results
  • Clinical history of the family

Online Demo Database[edit]

We have a community server available in the Internet so you can connect and try the latest GNU Health. This is probably the simplest way to check out GNU Health for the first time.

To use the GNU Health Demo Database, please proceed as follows:

1. Download and install the Tryton client application, according to your operating system:

GNU/Linux, FreeBSD or other *NIX
Please note that the version of the Tryton client must match the version of the Tryton server. Otherwise you will not be able to connect to the community server ("Network Error: Connection refused!"). So if you have already installed the Tryton client, please verify the version number before continuing. Currently, the community server runs on Tryton 3.4.

2. Set the correct tabs position as described in "Setting the Tryton client Tabs position for GNU Health"

3. Connect to the GNU Health Demo Database using the following information:

Local Demo Database[edit]

Manual Installation[edit]

This method should give the most up-to-date demo database with the fewer issues in the future.

First, as gnuhealth user, we download the newest demo database (2.8.1) and unzip it

$ wget
$ gunzip gnuhealth-2.8.1-demo.sql.gz

Second, we create an empty database to import the demo database into

$ psql -d template1 -c "create database gnuhealth_demo"

Third, we import the database

$ psql gnuhealth_demo < gnuhealth-2.8.1-demo.sql [1]

Now enter the database through Tryton client (as non-gnuhealth user)

Database: gnuhealth_demo
Username: admin
Password: gnusolidario

There is a user "admin_es" that uses the Spanish language.

Installation Using Proteus Demo Script[edit]

We use the proteus engine to install the demo database.

First we need to install proteus in your local environment

$ pip install --user proteus

Alternatively, and if you're using any Debian GNU/Linux system, you can also install proteus from a repository.

$ apt-get install tryton-proteus

Warning, do not install proteus using pip and then apt-get as well. Most likely difference version of proteus will be installed and the demo database installation will fail.

Now, look for the demo directory. You can run the script from anywhere, but make sure your tryton libraries are in the python search path. This is important, specially if you use the manual installation.


So, for example, if you installed the GNU Health sever with the standard method, then your variable declaration for PYTHONPATH for Tryton 3.2.3 would be something like :

$ export PYTHONPATH="/home/gnuhealth/gnuhealth/tryton/server/trytond-3.2.3/"

Next, run the script :

$ cd <demo_directory>
$ python

So, for example, if you installed the GNU Health sever with the standard method, the demo directory would ~/gnuhealth-2.6.4/scripts/demo (or whatever version number yours is) and you use:

$ cd ~/gnuhealth-2.6.4/scripts/demo
$ python

This script will create a new database called gnuhealth_demo with the demo information. Be patient, it can take some time.

User name: admin
Password: admin


  1. Optionally 1>/tmp/log 2>/tmp/err may be added at the end of the line. For large databases and not so large computers, it could accelerate the load, while providing some clues just in case.

Different ways to test GNU Health · The Live-CD