ERROR: User defined in HDFS_DATANODE_SECURE_USER (yarn) does not exist. Aborting.

4902 단어 Hadoop

잘못


4개의 서버에 고가용 Hadoop을 설치할 때 DataNode를 시작하면서 다음 오류를 계속 보고했습니다. Google에서 반나절을 보냈지만 원인을 찾지 못했습니다.
[root@node01 hadoop]# start-all.sh 
Starting namenodes on [node01 node02]
Starting datanodes
node02: ERROR: User defined in HDFS_DATANODE_SECURE_USER (yarn) does not exist. Aborting.
node03: ERROR: User defined in HDFS_DATANODE_SECURE_USER (yarn) does not exist. Aborting.
node04: ERROR: User defined in HDFS_DATANODE_SECURE_USER (yarn) does not exist. Aborting.
Starting journal nodes [node01 node02 node03]
2019-04-26 15:14:39,251 WARN util.NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable
Starting ZK Failover Controllers on NN hosts [node01 node02]
Starting resourcemanagers on [ node03 node04]
node04: WARNING: /opt/hadoop-3.1.2/logs does not exist. Creating.
Starting nodemanagers


해결 방법:

  • hadoop-env.sh 안의 캐릭터를 모두 주석에 분배
    #JAVA
    export JAVA_HOME=/usr/java/jdk1.8.0_201-amd64
    # HDFS
    # export HDFS_NAMENODE_USER=root
    # export HDFS_DATANODE_USER=root
    # export HDFS_SECONDARYNAMENODE_USER=root
    # export HDFS_ZKFC_USER=root
    # export HDFS_JOURNALNODE_USER=root
    # export HADOOP_SECURE_DN_USER=hdfs
    # export HDFS_DATANODE_SECURE_USER=hdfs
    
    #YARN
    #export YARN_RESOURCEMANAGER_USER=root
    # export HADOOP_SECURE_DN_USER=yarn 
    #export HDFS_DATANODE_SECURE_USER=yarn
    #export YARN_NODEMANAGER_USER=root
    
    
  • start-dfs.sh, stop-dfs.sh에 다음과 같은 내용을 추가
    #!/usr/bin/env bash
    
    HDFS_DATANODE_USER=root
    HDFS_DATANODE_SECURE_USER=hdfs
    HDFS_NAMENODE_USER=root
    HDFS_SECONDARYNAMENODE_USER=root
    
    # Licensed to the Apache Software Foundation (ASF) under one or more
    # contributor license agreements.  See the NOTICE file distributed with
    # this work for additional information regarding copyright ownership.
    # The ASF licenses this file to You under the Apache License, Version 2.0
    ...........
    
  • start-yarn.sh, stop-yarn.sh에 다음과 같이 추가
    #!/usr/bin/env bash
    
    YARN_RESOURCEMANAGER_USER=root
    HDFS_DATANODE_SECURE_USER=yarn
    YARN_NODEMANAGER_USER=root
    
    # Licensed to the Apache Software Foundation (ASF) under one or more
    # contributor license agreements.  See the NOTICE file distributed with
    # this work for additional information regarding copyright ownership.
    # The ASF licenses this file to You under the Apache License, Version 2.0
    ............
    
  • 좋은 웹페이지 즐겨찾기