How To Install maas-region-controller on Ubuntu 18.04

In this tutorial we learn how to install maas-region-controller on Ubuntu 18.04. maas-region-controller is Region Controller for MAAS

Introduction

In this tutorial we learn how to install maas-region-controller on Ubuntu 18.04.

What is maas-region-controller

maas-region-controller is:

The MAAS region controller (maas-regiond) is the REST API server for all MAAS clients, and the postgres database that maintains machine state for the entire data centre (or “region”). The region controller an be scaled-out and highly available given the appropriate postgres setup and additional API servers.

This package installs the postgres database and the API server, so it is appropriate for the initial installation of a new MAAS region. To scale out the controller or make it highly available, install maas-region-controller-api on additional servers and ensure the postgres database is HA too.

There are three methods to install maas-region-controller on Ubuntu 18.04. We can use apt-get, apt and aptitude. In the following sections we will describe each method. You can choose one of them.

Install maas-region-controller Using apt-get

Update apt database with apt-get using the following command.

sudo apt-get update

After updating apt database, We can install maas-region-controller using apt-get by running the following command:

sudo apt-get -y install maas-region-controller

Install maas-region-controller Using apt

Update apt database with apt using the following command.

sudo apt update

After updating apt database, We can install maas-region-controller using apt by running the following command:

sudo apt -y install maas-region-controller

Install maas-region-controller Using aptitude

If you want to follow this method, you might need to install aptitude first since aptitude is usually not installed by default on Ubuntu. Update apt database with aptitude using the following command.

sudo aptitude update

After updating apt database, We can install maas-region-controller using aptitude by running the following command:

sudo aptitude -y install maas-region-controller

How To Uninstall maas-region-controller on Ubuntu 18.04

To uninstall only the maas-region-controller package we can use the following command:

sudo apt-get remove maas-region-controller

Uninstall maas-region-controller And Its Dependencies

To uninstall maas-region-controller and its dependencies that are no longer needed by Ubuntu 18.04, we can use the command below:

sudo apt-get -y autoremove maas-region-controller

Remove maas-region-controller Configurations and Data

To remove maas-region-controller configuration and data from Ubuntu 18.04 we can use the following command:

sudo apt-get -y purge maas-region-controller

Remove maas-region-controller configuration, data, and all of its dependencies

We can use the following command to remove maas-region-controller configurations, data and all of its dependencies, we can use the following command:

sudo apt-get -y autoremove --purge maas-region-controller

References

Summary

In this tutorial we learn how to install maas-region-controller package on Ubuntu 18.04 using different package management tools: apt, apt-get and aptitude.