3. Performing a Manual Upgrade

  1. Perform the Manual Upgrade to HDP 2.2.4.2

  2. Log in to Ambari.

  3. Browse to Admin > Stack and Versions.

  4. Click on the Versions tab.

  5. Under the newly registered and installed version HDP-2.2.4.2, is the actual software repository version in parenthesis (Ambari determined this repository version during the install). For example, in the picture below the display name is HDP-2.2.4.2 and the repository version 2.2.4.2-2. Record this repository version. You will use it later in the manual upgrade process.

  6. Stop all services from Ambari. On the Services tab, in the Service navigation area Actions button, select Stop All to stop all services.

    [Note]Note

    If you are upgrading a NameNode HA configuration, keep your JournalNodes running while performing this upgrade procedure. Upgrade, rollback and finalization operations on HA NameNodes must be performed with all JournalNodes running.

  7. Go to the command line on each host and move the current HDP version to the newly installed version using the hdp-select utility and repository version number (obtained in Step 4).

    hdp-select set all {repository-version}

    For example:

    hdp-select set all 2.2.4.2-2
  8. Restart all services from Ambari. One by one, browse to each Service in Ambari Web, and in the Service Actions menu select Restart All.

    Do Not, for example, browse to Ambari Web > Services > HDFS and select Restart All.

  9. During a manual upgrade, it is necessary for all components to advertise the version that they are on. This is typically done by Restarting an entire Service. However, client-only services (e.g., Pig, Tez and Slider) do not have a Restart command. Instead, they need an API call that will trigger the same behavior. For each of services installed that are client-only issue an Ambari REST API call that will cause the hosts running these clients to advertise their version. Perform this REST API call for each client-only service configured in your cluster:

    curl -X POST -u username:password -H 'X-Requested-By:ambari' http://ambari.server:8080/api/v1/clusters/MyCluster/requests ‘{ "RequestInfo":
     { "command":"RESTART", "context":"Restart all components for TEZ_CLIENT", "operation_level": { "level":"SERVICE", "cluster_name":"MyCluster", "service_name":"TEZ"
     }
     }, "Requests/resource_filters": [{ "service_name":"TEZ", "component_name":"TEZ_CLIENT", "hosts":"c6401.ambari.apache.org,c6402.apache.ambari.org"}]
    }’

    Replace the Ambari Server username + password, Ambari Server hostname, your cluster name, service name + component name (see the following table), and the list of hosts in your cluster that are running the client.

    Service

    service_name

    component_name

    Tez

    TEZ

    TEZ_CLIENT

    Pig

    PIG

    PIG

    Slider

    SLIDER

    SLIDER

    Sqoop

    SQOOP

    SQOOP

  10. After all the services are confirmed to be started and healthy, go to the command line on the Ambari Server and run the following to finalize the upgrade, which will move the current version to the new version.

    ambari-server set-current --cluster-name=MyCluster --version-display-name=HDP-2.2.4.2
    
     Ambari Admin login: admin
     Ambari Admin password: *****
  11. If the ambari-server set-current command is not successful, try restarting the Ambari Server and waiting for all agents to re-register before trying again.