Skip to content

Latest commit

 

History

History
104 lines (70 loc) · 3.42 KB

ubuntu.md

File metadata and controls

104 lines (70 loc) · 3.42 KB

Installing the OpenQuake Engine on Ubuntu Linux

The OpenQuake Engine stable tree is available in the form of deb binary packages for the following Ubuntu releases:

  • Ubuntu 16.04 LTS (Xenial)
  • Ubuntu 14.04 LTS (Trusty)

Packages may work on Ubuntu derivatives (i.e. Mint Linux) and Debian, but this setup in not supported by GEM. See the FAQ.

The software and its libraries will be installed under /opt/openquake. Data will be stored under /var/lib/openquake.

Install packages from the OpenQuake repository

If you want to upgrade an existing installation see upgrading.

The following commands add the official stable builds package repository:

sudo add-apt-repository -y ppa:openquake/ppa
sudo apt-get update

If you want to install a nightly build please read the guide about installing the nightly build packages on Ubuntu.

Then to install the OpenQuake Engine and its libraries run

sudo apt-get install python-oq-engine

Upgrade from a previous release

As soon as a new version of the OpenQuake Engine and libraries are released you can upgrade it using apt or a graphical package manager:

sudo apt update
sudo apt install python-oq-engine

If a full upgrade is performed on the system, the OpenQuake software is upgraded to the latest version too:

sudo apt update
sudo apt upgrade

Configure the system services

The package installs three system service managed through supervisord:

  • openquake-dbserver: provides the database for the OpenQuake Engine and must be started before running any oq engine command
  • openquake-webui: provides the WebUI and is optional
  • openquake-celery: used only on a multi-node setup, not used in a default setup

openquake-dbserver and openquake-webui are started by default at boot.

To manually start, stop or restart a service run

sudo supervisorctl <start|stop|restart> openquake-dbserver openquake-webui

To check the status of a service run

sudo supervisorctl status openquake-dbserver openquake-webui

Run the OpenQuake Engine

Continue on How to run the OpenQuake Engine

Test the installation

To run the OpenQuake Engine tests see the testing page.

Uninstall the OpenQuake Engine

To uninstall the OpenQuake Engine and all its components run

sudo apt-get remove python-oq-*

If you want to remove all the dependencies installed by the OpenQuake Engine you may then use the apt autoremove function and run

sudo apt-get autoremove

Data cleanup

To reset the database oq reset command can be used:

sudo supervisorctl stop openquake-dbserver
sudo -u openquake oq reset
sudo supervisorctl start openquake-dbserver

To remove all the data produced by the OpenQuake Engine (including datastores) you must also remove ~/oqdata in each users' home. The reset-db bash script is provided, as a reference, in /usr/share/openquake/engine/utils.

If the packages have been already uninstalled, it's safe to remove /var/lib/openquake.


Getting help

If you need help or have questions/comments/feedback for us, you can: