MapR 5.0 Documentation : Shutting Down a Cluster

When you shut down a cluster, follow this sequence to preserve your data and replication:

  1. Verify that recent data has finished processing.
  2. Shut down any NFS servers.
  3. Shut down any ecosystem components that are running.
  4. Shut down the job and task trackers.
  5. Shut down the ResourceManager and NodeManager services.
  6. Shut down Warden on all nodes that are not running CLDB.
  7. Shut down Warden on the CLDB nodes.
  8. Shut down ZooKeeper on the ZooKeeper nodes.

To shut down the cluster:

Before you start, make sure there are no active MapReduce or HBase processes, and that no data is being loaded to the cluster or being persisted within the cluster.

  1. Change to the root user (or use sudo for the following commands).
  2. Before shutting down the cluster, you will need a list of NFS nodes, CLDB nodes, and all remaining nodes. Once the CLDB is shut down, you cannot retrieve a list of nodes; it is important to obtain this information at the beginning of the process. Use the node list command as follows:
    • Determine which nodes are running the NFS gateway. Example:

      /opt/mapr/bin/maprcli node list -filter "[rp==/*]and[svc==nfs]" -columns id,h,hn,svc, rp
      id                   service                                             hostname             health  ip            
      6475182753920016590  fileserver,tasktracker,nfs,hoststats       0  
      8077173244974255917  tasktracker,cldb,fileserver,nfs,hoststats  0  
      5323478955232132984  webserver,cldb,fileserver,nfs,hoststats,jobtracker 0 
    • Determine which nodes are running the CLDB. Example:

      /opt/mapr/bin/maprcli node list -filter "[rp==/*]and[svc==cldb]" -columns id,h,hn,svc, rp
    • List all non-CLDB nodes. Example:

      /opt/mapr/bin/maprcli node list -filter "[rp==/*]and[svc!=cldb]" -columns id,h,hn,svc, rp
  3. Shut down all NFS instances. Example:

    /opt/mapr/bin/maprcli node services -nfs stop -filter [svc=="nfs"]
  4. If your cluster is running any ecosystem components, shut down those components on all nodes.
  5. Shut down all JobTracker and TaskTracker services on all nodes. Example:

    # maprcli node services -jobtracker stop
    # maprcli node services -tasktracker stop
  6. If you are running in YARN mode, shut down all ResourceManager and NodeManager services on all nodes. To shut down ResourceManager and NodeManager services, specifiy the maprcli node services command with the name parameter and either the filter or the node parameter. Example:

    # maprcli node services -name resourcemanager -filter <filter> -action stop
    # maprcli node services -name nodemanager -nodes <node> -action stop
  7. SSH into each node that is not running CLDB and stop Warden. Example:

    # service mapr-warden stop
  8. SSH into each CLDB node and stop Warden. Example:

    # service mapr-warden stop
  9. SSH into each Zookeeper node and stop Zookeeper. Example:

    # service mapr-zookeeper stop
  10. (Optional) Shut down the nodes using the Linux halt command.