When Hadoop reboots, HDFs is not closed, no namenode to Stop__hadoop

Source: Internet
Author: User

1. HDFs machine Migration, implementation sbin/stop-dfs.sh

Error:

Dchadoop010.dx.momo.com:no Namenode to stop
Dchadoop009.dx.momo.com:no Namenode to stop


Dchadoop010.dx.momo.com:no Datanode to stop
Dchadoop009.dx.momo.com:no Datanode to stop
Dchadoop011.dx.momo.com:no Datanode to stop
Stopping journal nodes [dchadoop009.dx.momo.com dchadoop010.dx.momo.com dchadoop011.dx.momo.com]
Dchadoop010.dx.momo.com:no Journalnode to stop
Dchadoop009.dx.momo.com:no Journalnode to stop
Dchadoop011.dx.momo.com:no Journalnode to stop
Stopping ZK Failover controllers on NN hosts [dchadoop009.dx.momo.com dchadoop010.dx.momo.com]
Dchadoop010.dx.momo.com:no Journalnode to stop
Dchadoop009.dx.momo.com:no ZKFC to stop


Cannot close

The reason for this is that Hadoop is based on the PID that is saved to the PID file at stop time. While the default process number is kept in/TMP, Linux defaults to deleting files from this directory at regular intervals (typically one months or about 7 days). Therefore, after the deletion of hadoop-dc-namenode.pid files, Namenode naturally can not find the datanode on this process. (The process ID file name for different processes will change)


Solve:

For this cluster shutdown, what we need to do is: first to ensure that the cluster is not loaded, then go to kill DATANODE/JOURNALNODE/ZKFC manually and finally kill Namenode (note order)

Permanent Solution:

Configuring Export Hadoop_pid_dir in the configuration file hadoop_env.sh resolves this problem.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.