trino on alluxio报java.lang.NoClassDefFoundError: Could not initialize class alluxio.metrics.MetricsS

Caused by: java.lang.NoClassDefFoundError: Could not initialize class alluxio.metrics.MetricsSystem
	at alluxio.client.file.FileSystemContext.initContext(FileSystemContext.java:316)
	at alluxio.client.file.FileSystemContext.init(FileSystemContext.java:305)
	at alluxio.client.file.FileSystemContext.create(FileSystemContext.java:256)
	at alluxio.client.file.FileSystemContext.create(FileSystemContext.java:225)
	at alluxio.client.file.FileSystem$Factory.create(FileSystem.java:146)
	at alluxio.hadoop.AbstractFileSystem.initialize(AbstractFileSystem.java:541)
	at alluxio.hadoop.AbstractFileSystem.initialize(AbstractFileSystem.java:480)
	at io.trino.hdfs.TrinoFileSystemCache.createFileSystem(TrinoFileSystemCache.java:155)
	at io.trino.hdfs.TrinoFileSystemCache$FileSystemHolder.createFileSystemOnce(TrinoFileSystemCache.java:293)
	at io.trino.hdfs.TrinoFileSystemCache.getInternal(TrinoFileSystemCache.java:135)
	at io.trino.hdfs.TrinoFileSystemCache.get(TrinoFileSystemCache.java:91)
	at org.apache.hadoop.fs.ForwardingFileSystemCache.get(ForwardingFileSystemCache.java:39)
	at org.apache.hadoop.fs.FileSystem.get(FileSystem.java:557)
	at org.apache.hadoop.fs.Path.getFileSystem(Path.java:365)
	at io.trino.hdfs.HdfsEnvironment.lambda$getFileSystem$0(HdfsEnvironment.java:103)
	at io.trino.hdfs.authentication.NoHdfsAuthentication.doAs(NoHdfsAuthentication.java:25)
	at io.trino.hdfs.HdfsEnvironment.getFileSystem(HdfsEnvironment.java:102)
	at io.trino.hdfs.HdfsEnvironment.getFileSystem(HdfsEnvironment.java:96)
	at io.trino.plugin.hive.BackgroundHiveSplitLoader.loadPartition(BackgroundHiveSplitLoader.java:434)
	at io.trino.plugin.hive.BackgroundHiveSplitLoader.loadSplits(BackgroundHiveSplitLoader.java:396)
	at io.trino.plugin.hive.BackgroundHiveSplitLoader$HiveSplitLoaderTask.process(BackgroundHiveSplitLoader.java:310)
	... 6 more

错误原因

根据官网需将alluxio-2.9.3-client.jar放在{Trino_HOME}/plugin/hive/ 下(我的trino版本是423)。但是在{Trino_HOME}/plugin/hive/已经有了alluxio-shaded-client-2.9.3.jar包,两者冲突。

解决办法

先看自己{Trino_HOME}/plugin/hive/下是否存在alluxio的client jar包,如存在就不必按照官网要求将alluxio的client jar包拷贝到{Trino_HOME}/plugin/hive/中。

你可能感兴趣的:(Presto,presto,alluxio)