Offline and Manual Upgrade

The offline, manual upgrade procedure is suitable for upgrading small clusters. On large clusters, these steps are commonly performed on all nodes in parallel using scripts and/or remote management tools.

This procedure assumes you have planned and prepared for the upgrade as described earlier, and the cluster meets prerequisites, including the correct JDK for the version you are upgrading to. See the JDK Support Matrix for more information.

Note: An offline upgrade is performed as the root user or with sudo.

At the end of this procedure, you use yum update or zypper update on RHEL/CentOS or SUSE to upgrade packages. Ignore any warnings that certain packages are not installed. Packages will be upgraded correctly and no additional packages will be installed.

  1. Notify stakeholders of the impending upgrade, and then stop accepting new jobs and applications. Terminate running jobs and applications by running maprcli commands on appropriate nodes in the cluster.
    • MapReduce jobs:
      # mapred job -list
      # mapred job -kill <job-id>
      # mapred job -kill-task <task-id>
    • YARN applications:
      # yarn application -list
      # yarn application -kill <ApplicationId>
  2. Disconnect NFS mounts. Unmount the MapR NFS share from all clients connected to it, including other nodes in the cluster. This allows all processes accessing the cluster via NFS to disconnect gracefully.
    For example, if the cluster is mounted at /mapr: # umount /mapr
  3. Display the services on each node in the cluster, and stop ecosystem component services on the nodes.
    # maprcli node list -columns hostname,csvc
    # maprcli node services -multi '[{ "name": "hue", "action": "stop"}, { "name": "oozie", "action": "stop"}, { "name": "hs2", "action": "stop"}]' -nodes <hostnames>
  4. Determine where CLDB and ZooKeeper services are installed.
  5. Stop Warden on CLDB nodes first, and then on all remaining nodes.
  6. Stop ZooKeeper on all nodes where it is installed.
  7. Ensure that no stale MapR processes are running. If so, stop the processes:
    ps -ef | grep mapr
    pkill -u mapr 
  8. Remove any existing patches.
    1. Run one of the following commands to determine if a patch is installed.
      • RHEL/CentOS and SUSE: rpm -qa mapr-patch
      • Ubuntu: dpkg l | grep mapr-patch
      If the command displays no output, no patch is installed.
    2. If one or more patches are installed, run one of the following commands to remove the patches:
      • RHEL/CentOS or SUSE: sudo rpm -e mapr-patch
      • Ubuntu: sudo apt-get -y remove mapr-patch
  9. Upgrade MapR core packages by installing the appropriate MapR package key.
    • RHEL/CentOS: sudo rpm --import http://package.mapr.com/releases/pub/maprgpg.key
    • SUSE: No package key needed.
    • Ubuntu: wget -O - http://package.mapr.com/releases/pub/maprgpg.key | sudo apt-key add -
  10. Upgrade these MapR core component and MapR hadoop common packages on all nodes where packages exist.
    Components to upgrade are:
    • mapr-cldb
    • mapr-core
    • mapr-core-internal
    • mapr-fileserver
    • mapr-hadoop-core
    • mapr-historyserver
    • mapr-jobtracker
    • mapr-mapreduce1
    • mapr-mapreduce2
    • mapr-metrics
    • mapr-nfs
    • mapr-nodemanager
    • mapr-resourcemanager
    • mapr-tasktracker
    • mapr-webserver
    • mapr-zookeeper
    • mapr-zk-internal
    When using yum update or zypper update, do not use a wildcard such as "mapr-*" to upgrade all MapR packages, which could erroneously include Hadoop ecosystem components such as mapr-hive and mapr-pig.
    • RHEL/CentOS:
      yum update mapr-cldb mapr-core mapr-core-internal mapr-fileserver mapr-hadoop-core mapr-historyserver mapr-jobtracker mapr-mapreduce1 mapr-mapreduce2 mapr-metrics mapr-nfs mapr-nodemanager mapr-resourcemanager mapr-tasktracker mapr-webserver mapr-zookeeper mapr-zk-internal
    • SUSE:
      zypper update mapr-cldb mapr-compat-suse mapr-core mapr-core-internal mapr-fileserver mapr-hadoop-core mapr-historyserver mapr-jobtracker mapr-mapreduce1 mapr-mapreduce2 mapr-metrics mapr-nfs mapr-nodemanager mapr-resourcemanager mapr-tasktracker mapr-webserver mapr-zookeeper mapr-zk-internal
    • Ubuntu: First get a list of the MapR packages installed on the node, and then run apt-get install on the listed packages.
      dpkg --list | grep "mapr" | grep -P "^ii"| awk '{ print $2}'|tr "\n" " "
                                  apt-get install <package-list>
  11. Verify that packages were installed successfully on all nodes. Confirm that there were no errors during installation, and check that /opt/mapr/MapRBuildVersion contains the expected value.
    For example:
    # cat /opt/mapr/MapRBuildVersion
    5.2.0.xxxxx.GA
See Post-Upgrade Steps for MapR Core