MAAS is an acronym for Metal As A Service. It is an open-source tool from Canonical that helps you deploy data centers from raw metal servers. This tool is very useful for normal enterprises in managing virtualized infrastructure. MAAS is supported on Ubuntu, CentOS, Windows, and RedHat operating systems.
Here at Ibmi Media, as part of our Server Management Services, we regularly help our Customers to perform related Server Monitoring queries and tasks.
In this context, we shall look into how to install MAAS on Ubuntu 20.04.
1. Perform system update
You can Update packages by using the apt command:
$ sudo apt update2. Install MAAS
You can install MAAS by running the below command:
$ sudo snap install maasFor production, we need to Initialize MAAS. Firstly, we must check for updates:
$ sudo apt update -yThen we will install PostgreSQL:
$ sudo apt install -y postgresqlNext, we will create a database for MAAS. Here the database is called maas, user named maasuser, the password is maas123:
$ sudo -u postgres psqlcreate user maasuser with encrypted password 'maas123';
create database maas;
grant all privileges on database maas to maasuser;
\qNow, we need to edit the file /etc/postgresql/10/main/pg_hba.conf:
$ sudo nano /etc/postgresql/10/main/pg_hba.confNote: Change maas for your maas DB name, and change maaszeljko for your maas DB user. I added line to the bottom of the file. Then add the following line:
host maas maaszeljko 0/0 md5Save it and exit.
Now we will start initializing MAAS:
$ sudo maas init region+rack --database-uri "postgres://maasuser:maas123@localhost/maas"Replace maasuser with your username just created, maas123 by your password.
To create the admin account for the web interface, run:
$ sudo maas createadminTo check MAAS service status, run:
$ sudo maas statusTo do this, simply Open your browser and access your MAAS URL. For example:
http://10.0.0.101:5240/MAAS This article covers how to install MAAS on Ubuntu 20.04. In fact, Metal as a Service – MAAS – lets you treat physical servers like virtual machines in the cloud. Rather than having to manage each server individually, MAAS turns your bare metal into an elastic cloud-like resource.