datanode 启动不了

2018-03-21 12:07:07,545 INFO org.apache.hadoop.hdfs.server.common.Storage: Lock on /workspace/hadoop/dfs/data/in_use.lock acquired by nodename 20317@cuishizhou01
2018-03-21 12:07:07,547 WARN org.apache.hadoop.hdfs.server.common.Storage: Failed to add storage directory [DISK]file:/workspace/hadoop/dfs/data/
java.io.IOException: Incompatible clusterIDs in /workspace/hadoop/dfs/data: namenode clusterID = CID-4719a68a-57bd-4eeb-82cd-e5574ab7ec3f; datanode clusterID = CID-b05d6475-635a-43af-9168-6442874aa2e8
    at org.apache.hadoop.hdfs.server.datanode.DataStorage.doTransition(DataStorage.java:775)
    at org.apache.hadoop.hdfs.server.datanode.DataStorage.loadStorageDirectory(DataStorage.java:300)
    at org.apache.hadoop.hdfs.server.datanode.DataStorage.loadDataStorage(DataStorage.java:416)
    at org.apache.hadoop.hdfs.server.datanode.DataStorage.addStorageLocations(DataStorage.java:395)
    at org.apache.hadoop.hdfs.server.datanode.DataStorage.recoverTransitionRead(DataStorage.java:573)
    at org.apache.hadoop.hdfs.server.datanode.DataNode.initStorage(DataNode.java:1362)
    at org.apache.hadoop.hdfs.server.datanode.DataNode.initBlockPool(DataNode.java:1327)
    at org.apache.hadoop.hdfs.server.datanode.BPOfferService.verifyAndSetNamespaceInfo(BPOfferService.java:317)
    at org.apache.hadoop.hdfs.server.datanode.BPServiceActor.connectToNNAndHandshake(BPServiceActor.java:223)
    at org.apache.hadoop.hdfs.server.datanode.BPServiceActor.run(BPServiceActor.java:802)
    at java.lang.Thread.run(Thread.java:745)

修改:
namenode clusterID = CID-4719a68a-57bd-4eeb-82cd-e5574ab7ec3f;
datanode clusterID = CID-b05d6475-635a-43af-9168-6442874aa2e8

复制namenode的ID到datanode

你可能感兴趣的:(大数据)