geomesa配置

fnx2tebb  于 2021-06-02  发布在  Hadoop
关注(0)|答案(2)|浏览(463)

我将hadoop 2.7与geoserver 2.8.0配合使用,但在尝试配置GeoESA 1.2.0时,收到以下错误消息:

$ geomesa
Using GEOMESA_HOME = /usr/local/geomesa/dist/tools/geomesa-tools-1.2.0

Warning: you have not set ACCUMULO_HOME and/or HADOOP_HOME as environment variables.
GeoMesa tools will not run without the appropriate Accumulo and Hadoop jars in the tools classpath.
Please ensure that those jars are present in the classpath by running 'geomesa classpath' .
To take corrective action, please place the necessary jar files in the lib directory of geomesa-tools.

Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/accumulo/core/client/TableNotFoundException
    at org.locationtech.geomesa.tools.commands.TableConfCommand.<init>(TableConfCommand.scala:32)
    at org.locationtech.geomesa.tools.Runner$.createCommand(Runner.scala:50)
    at org.locationtech.geomesa.tools.Runner$.main(Runner.scala:21)
    at org.locationtech.geomesa.tools.Runner.main(Runner.scala)
Caused by: java.lang.ClassNotFoundException: org.apache.accumulo.core.client.TableNotFoundException
    at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
    at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:425)
    at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:358)
    ... 4 more

我怎样才能解决这个问题?

ovfsdjhp

ovfsdjhp1#

验证相应的jar文件是否存在于类路径中,您可以借助command:- geomesa 类路径
如果jar不存在,则在geomesa目录中复制jar在我的情况下,它位于以下路径中:
/*/geomesa-1.2.4/dist/tools/geomesa-tools-1.2.4/lib/common/

ecfdbz9o

ecfdbz9o2#

geomesa工具需要hadoop和acumulo jars才能连接到acumulo。
一个快速的选择是从平板服务器或其他已经配置为hadoop集群一部分的机器上运行geomesa工具。如果您正在使用另一台机器,可以镜像 $HADOOP_HOME 以及 $ACCUMULO_HOME 本地从群集节点删除目录。
作为另一种选择,您可以下载 install-hadoop-accumulo.sh 中的脚本 geomesa-tools/bin 目录下载一套hadoop和acumulo jar。

相关问题