nebula-bench部署失败ldbc_snb_datagen-0.3.3-jar-with-dependencies.jar

---------------------------------------------------
Exception in thread "main" java.lang.NoClassDefFoundError: com/google/common/collect/ImmutableSet
	at com.google.inject.internal.Errors.<clinit>(Errors.java:105)
	at com.google.inject.internal.InternalInjectorCreator.<init>(InternalInjectorCreator.java:61)
	at com.google.inject.Guice.createInjector(Guice.java:87)
	at com.google.inject.Guice.createInjector(Guice.java:69)
	at com.google.inject.Guice.createInjector(Guice.java:59)
	at org.codehaus.plexus.DefaultPlexusContainer.addPlexusInjector(DefaultPlexusContainer.java:481)
	at org.codehaus.plexus.DefaultPlexusContainer.<init>(DefaultPlexusContainer.java:206)
	at org.apache.maven.cli.MavenCli.container(MavenCli.java:635)
	at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:281)
	at org.apache.maven.cli.MavenCli.main(MavenCli.java:192)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:566)
	at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:282)
	at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:225)
	at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:406)
	at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:347)
Caused by: java.lang.ClassNotFoundException: com.google.common.collect.ImmutableSet
	at org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy.loadClass(SelfFirstStrategy.java:50)
	at org.codehaus.plexus.classworlds.realm.ClassRealm.unsynchronizedLoadClass(ClassRealm.java:271)
	at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:247)
	at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:239)
	... 18 more
JAR does not exist or is not a normal file: /root/nebula-bench/target/data/ldbc_snb_datagen/target/ldbc_snb_datagen-0.3.3-jar-with-dependencies.jar
mv: 无法获取'test_data' 的文件状态(stat): 没有那个文件或目录

/root/nebula-bench/target/data/ldbc_snb_datagen路径是存在的,但没有之后的target

# ls /root/nebula-bench/target/data/ldbc_snb_datagen
base-docker-image                             check-md5sums-ttl.sh          params-csv-basic.ini                    params-ttl.ini       src
CHANGELOG.txt                                 Dockerfile                    params-csv-composite.ini                pom.xml              test
check-md5sums-csv-basic.sh                    docker_run.sh                 params-csv-composite-merge-foreign.ini  README.md            test_params.ini
check-md5sums-csv-composite-merge-foreign.sh  graphalytics-generate-old.sh  params-csv-merge-foreign.ini            rename.sh            tools
check-md5sums-csv-composite.sh                LICENSE.txt                   params-graphalytics.ini                 run.sh
check-md5sums-csv-merge-foreign.sh            paramgenerator                params.ini                              snb-generate-old.sh

报错提醒时说错误的文件是从网络中下载的,你可以试试把 target 目录删掉,然后再执行下 python3 run.py data 。

nebula-bench下的target是运行python后才生成的,源码中并不存在这个目录。在nebula-bench/target/data中python下载了hadoop-3.2.1.tar.gz和v0.3.3.tar.gz,ldbc_snb_datagen是v0.3.3.tar.gz解压生成的,里面没有target子目录。

# ls /root/nebula-bench/target/data/
hadoop-3.2.1  hadoop-3.2.1.tar.gz  ldbc_snb_datagen  v0.3.3.tar.gz
[root@iZj6c907tyvb0lpst0zq9dZ data]# ls /root/nebula-bench/target/data/ldbc_snb_datagen/
base-docker-image                             check-md5sums-ttl.sh          params-csv-basic.ini                    params-ttl.ini       src
CHANGELOG.txt                                 Dockerfile                    params-csv-composite.ini                pom.xml              test
check-md5sums-csv-basic.sh                    docker_run.sh                 params-csv-composite-merge-foreign.ini  README.md            test_params.ini
check-md5sums-csv-composite-merge-foreign.sh  graphalytics-generate-old.sh  params-csv-merge-foreign.ini            rename.sh            tools
check-md5sums-csv-composite.sh                LICENSE.txt                   params-graphalytics.ini                 run.sh
check-md5sums-csv-merge-foreign.sh            paramgenerator                params.ini                              snb-generate-old.sh

问题找到了,通过yum安装maven在guava库上和java有冲突。删除maven后从官网下载了3.8.8版本的bin包并设置环境变量后解决。
除此之外还有几个坑,一起填了。

  1. 报错Failed to collect dependencies at ca.umontreal.iro:ssj:jar:2.5 → dsol:dsol-xml:jar:1.6.9: Failed to read artifact descriptor for dsol:dsol-xml:jar:1.6.9的解决方案是将ldbc升级到0.3.8。应该是dsol的远程连接出了问题,maven2的网站要求https访问,http会被拒绝
    *注意不要使用0.3.5,该版本run.sh中jar包名称有误
  2. 报错No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK?的解决方法是yum在安装jdk时把对应版本的所有库全都安装,应该是需要devel,懒得折腾就都安装了
1 个赞

此话题已在最后回复的 7 天后被自动关闭。不再允许新回复。