Reinstall MAAS

Reinstall MAASΒΆ

If your MAAS instance is lost or broken, you can reinstall it. This section describes how to install MAAS from the Ubuntu Server 16.04 qcow2 image.

To reinstall MAAS:

  1. Create a cloud-config disk:

    1. For example, create a configuration file named config-drive.yaml:

      debug: True
      ssh_pwauth: True
      disable_root: false
        list: |
        expire: False


      You must change the default password.

    2. Create the configuration drive:

      export VM_CONFIG_DISK="/var/lib/libvirt/images/maas/maas-config.iso"
      cloud-localds  --hostname maas01 --dsmode local ${VM_CONFIG_DISK}  config-drive.yaml
  2. Create a VM system disk using the preloaded qcow2 image. For example:

    wget -O \
    export VM_SOURCE_DISK="/var/lib/libvirt/images/maas/maas-system.qcow2"
    qemu-img create -b /var/lib/libvirt/images/maas/maas-system-backend.qcow2 -f qcow2 ${VM_SOURCE_DISK} 100G
  3. Create a VM using the predefine-vm script. For example:

    export MCP_VERSION="master"
    chmod 0755
    export VM_NAME="maas01.[CLUSTER_DOMAIN]"


    You may add other optional variables that have default values and set them according to your deployment configuration. These variables include:

    • VM_MGM_BRIDGE_NAME="br-mgm"
    • VM_CTL_BRIDGE_NAME="br-ctl"
    • VM_MEM_KB="8388608"
    • VM_CPUS="4"

    The br-mgm and br-ctl values are the names of the Linux bridges. See MCP Deployment Guide: Prerequisites to deploying MCP DriveTrain for details. Custom names can be passed to a VM definition using the VM_MGM_BRIDGE_NAME and VM_CTL_BRIDGE_NAME variables accordingly.

  4. Boot the created VM.

  5. Log in to the VM using the previously defined password.

  6. Proceed with installing MAAS:

    sudo apt-get install maas
  7. Configure MAAS as required to complete the installation.

  8. Verify the installation by opening the MAAS web UI:

  9. If you have installed MAAS from the packages, create an initial (administrative) user first to log in to the MAAS web UI:

    sudo maas createadmin --username=<PROFILE> --email=<EMAIL_ADDRESS>