Ambari Database

Ambari Database support is part of TECHNICAL PREVIEW. It may not be suitable for production use.

By default, Ambari uses an embedded database to store data. However, Ambari and Cloudbreak don't perform backups of this database, so although this database is sufficient for ephemeral or test clusters, it is not be sufficient for long-running production clusters. Therefore, you may need to configure a remote database for Ambari in Cloudbreak.

You have two options for configuring a remote database: you can set up a supported database on your own or use a cloud provider's database service. Next, you need to pass the details to Cloudbreak during cluster creation, and Cloudbreak will configure Ambari to connect to that remote database.

Cloudbreak supports out of the box PostgreSQL, MariaDB and MySQL. This means that if you are using any of these databases, you only need to create the database itself and configure user permissions to create the cluster. Cloudbreak will initialize database tables, relations, default values, and will download JDBC driver for Ambari. For other databases, you have to execute create SQL on your database and deliver JDBC driver to /opt/jdbc-drivers directory on Ambari server node.

Important Considerations

Consider these constraints when setting up your remote datatabse:

Configure Database with the Web UI

You can find database configuration in the Configure Ambari Database tab, under Advanced options:

Full size here.

Configure Database with the Shell

To configure a remote database for Ambari with Cloudbreak shell, use database configure command before cluster create command. The syntax is:

database configure --vendor [vendor] --host [host-or-ip] --port [port] --name [database-name] --username [user-name] --password [password]

Accepted vendor values are:

Upgrade the JDBC Driver

During installation, Cloudbreak distributes the JDBC driver for Ambari to different locations. If you want to upgrade the driver or use a different one, you have to perform these steps:

  1. Copy the driver to the /var/lib/ambari-server/jdbc-drivers directory.
  2. Symlink the driver to /usr/share/java, /usr/lib/jvm/java/jre/lib/ext directories.
  3. Reconfigure Ambari by executing the ambari-server setup --jdbc-db=[db-vendor] --jdbc-driver=[driver-location] command.
Edit on GitHub