解决Zookeeper出现Error: Could not find or load main class org.apache.zookeeper.server.quorum.QuorumPeerM

Posted 老王同鞋

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了解决Zookeeper出现Error: Could not find or load main class org.apache.zookeeper.server.quorum.QuorumPeerM相关的知识,希望对你有一定的参考价值。

Error: Could not find or load main class org.apache.zookeeper.server.quorum.QuorumPeerMain

1. 安装maven

# 安装
wget http://mirrors.hust.edu.cn/apache/maven/maven-3/3.6.3/binaries/apache-maven-3.6.3-bin.tar.gz

  # 解压

 tar -zxvf apache-maven-3.6.3-bin.tar.gz

 # 添加环境变量

 vim /etc/profile

export MAVEN_HOME=/usr/local/maven-3.6.3

export PATH=$PATH:$JAVA_HOME/bin:$MAVEN_HOME/bin

  

  # 重新加载环境变量

 source /etc/profile

 # 查看是否安装成功

 mvn -v

2. 重新编译zookeeper代码即可

cd /usr/local/zookeeper

cd /zookeeper-server
mvn package -Dmaven.test.skip=true
 

 

以上是关于解决Zookeeper出现Error: Could not find or load main class org.apache.zookeeper.server.quorum.QuorumPeerM的主要内容,如果未能解决你的问题,请参考以下文章

Error: could not find java.dll如何解决

error: could not read CFBundleIdentifier from Info.plist (null)解决方法之一

解决ERROR: Could not find a version that satisfies the requirement 问题及 ERROR: Exception:Traceback

显存不足完美解决方案Could not create cudnn handle: CUDNN_STATUS_INTERNAL_ERROR

显存不足完美解决方案Could not create cudnn handle: CUDNN_STATUS_INTERNAL_ERROR

网站部署后Parser Error Message: Could not load type 的解决方案