IBM BigInsights

Reverting Ambari in case of a failure

This topic describes how to apply a patch to the Ambari server and Ambari agent. You can use this procedure revert from 2.1 and 2.1.y.

Before you begin

You must have:
  • Already installed IBM® Open Platform with Apache Hadoop
  • Root access to the Ambari server host and all servers in the cluster
  • An Ambari repo file (this file points to the upgrade or downgrade RPM location)

Procedure

  1. Halt the Ambari server with the command ambari-server stop.
  2. Halt the Ambari agent on each node by running the command ambari-agent stop on each node.
  3. Download the Ambari repository file on each node and replace /etc/yum.repos.d/ambari.repo (the repo used in the previous IOP version) with the Ambari repository file you saved during the upgrade (Step 4).
  4. Revert the Ambari server node with the commands yum clean all and then yum downgrade ambari-server ambari-log4j. If the Ambari server node is also an Ambari agent node, run the command yum downgrade ambari-agent.
  5. Revert the Ambari agent on each node where it is running with the command yum clean all and then yum downgrade ambari-agent ambari-log4j.
  6. Verify the Ambari server and agent have reverted with the command rpm -qa | grep ambari. If the list of Ambari services show the correct version ID, your reversion was successful.
  7. Replace the Ambari server configuration file /etc/ambari-server/conf/ambari.properties with the copy made during Ambari upgrade.
  8. Restore the Ambari database from the backup created during the Ambari upgrade:
    1. If your Ambari server uses PostgreSQL, run the following command as the root user on the PostgreqSQL node (db user, db name, and password are all default values): pg_dump -U ambari ambari < /full/path/to/db_backup.sql (Enter bigdata when asked for the password).
    2. If the Ambari server uses MySQL/MariaDB, run the following command as the root user on the node where MySQL/MariaDB is installed (db user, db name, and password are all default values): mysqldump -u ambari -pbigdata ambari < /full/path/to/db_backup.sql
  9. Restart the Ambari server with the command ambari-server start.
  10. Restart the Ambari agent on each Ambari agent node with the command ambari-agent start.


Feedback