ubuntu 上的 Elastic Enterprise/App 搜索安装问题
Elastic Enterprise/App search installation problem on ubuntu
我正在 运行ning 一个 vag运行t 盒子,它 运行s ubuntu 在虚拟机中(使用 Laravel Homestead 盒子)
我正在尝试安装 Elastic App-search 产品。
第一个要求是安装Elasticsearch,我已经安装过很多次了。我做了以下步骤:
https://www.elastic.co/guide/en/elasticsearch/reference/current/deb.html
wget -qO - https://artifacts.elastic.co/GPG-KEY-elasticsearch | sudo apt-key add -
sudo apt-get install apt-transport-https
echo "deb https://artifacts.elastic.co/packages/7.x/apt stable main" | sudo tee -a /etc/apt/sources.list.d/elastic-7.x.list
sudo apt-get update && sudo apt-get install elasticsearch
我正在使用 systemd 配置:
sudo /bin/systemctl daemon-reload
sudo /bin/systemctl enable elasticsearch.service
我是 运行ning curl localhost:9200,一切正常。
接下来我尝试安装elastic app search。
https://www.elastic.co/guide/en/app-search/current/installation.html#installation-self-managed。
其中没有针对 debian 系统的说明。但它确实有一个 .deb 安装文件。我下载了文件并把它放在我的项目路径中。
I 运行 dpkg -i 在文件上,它似乎已经安装。当我 运行 检查文件位置的命令时,它显示如下:
dpkg -L enterprise-search
/.
/etc
/etc/init.d
/etc/init.d/enterprise-search
/var
/var/log
/var/log/enterprise-search
/usr
/usr/share
/usr/share/enterprise-search
/usr/share/enterprise-search/README.md
/usr/share/enterprise-search/bin
/usr/share/enterprise-search/bin/vendor
/usr/share/enterprise-search/bin/vendor/filebeat
/usr/share/enterprise-search/bin/vendor/filebeat/filebeat-linux-x86_64
/usr/share/enterprise-search/bin/enterprise-search
/usr/share/enterprise-search/filebeat
/usr/share/enterprise-search/filebeat/ecs-template.json
/usr/share/enterprise-search/filebeat/filebeat-ecs.yml
/usr/share/enterprise-search/lib
/usr/share/enterprise-search/lib/require_java_version.sh
/usr/share/enterprise-search/lib/enterprise-search.war
/usr/share/enterprise-search/jetty
/usr/share/enterprise-search/jetty/webserver-ssl.xml
/usr/share/enterprise-search/jetty/webserver-ssl-with-redirect.xml
/usr/share/enterprise-search/jetty/webserver.xml
/usr/share/enterprise-search/LICENSE
/usr/share/enterprise-search/config
/usr/share/enterprise-search/config/env.sh
/usr/share/enterprise-search/config/enterprise-search.yml
/usr/share/enterprise-search/NOTICE.txt
/usr/share/doc
/usr/share/doc/enterprise-search
/usr/share/doc/enterprise-search/changelog.gz
/usr/lib
/usr/lib/systemd
/usr/lib/systemd/system
/usr/lib/systemd/system/enterprise-search.service
我不确定这是不是正确的位置?我希望它和我的 elasticsearch 安装在同一个地方,但实际上我不确定。我完成了安装过程的所有后续步骤 运行:
./usr/share/enterprise-search/bin/elasticsearch
但这给了我错误:
Could not find java in PATH
我对此感到非常困惑,因为主要的 elasticsearch 安装工作正常并且还需要 java?我还希望它也 运行 具有 systemd 自动启用功能,并且我希望它在企业搜索启动/停止时可用。不确定如何处理。
看起来像是 Debian 软件包,因此可以安装在 ubuntu 上,但有些地方可能有所不同。
我会说你可以:
- 只需切换到使用 debian VM(在这里你可以得到一个 vagrant:https://app.vagrantup.com/debian/boxes/stretch64)
- 调试。据我所知,该包在运行之前先运行 elasticsearch-env 。 Java 是这样查找的:
if [ ! -z "$JAVA_HOME" ]; then
JAVA="$JAVA_HOME/bin/java"
JAVA_TYPE="JAVA_HOME"
else
if [ "$(uname -s)" = "Darwin" ]; then
# macOS has a different structure
JAVA="$ES_HOME/jdk.app/Contents/Home/bin/java"
else
JAVA="$ES_HOME/jdk/bin/java"
fi
JAVA_TYPE="bundled jdk"
fi
if [ ! -x "$JAVA" ]; then
echo "could not find java in $JAVA_TYPE at $JAVA" >&2
exit 1
fi
所以我建议在启动脚本中设置 JAVA_HOME(或在 运行 二进制文件之前),看看是否有帮助。
我通过添加另一个版本的 Java 解决了这个问题,Elastichsearch 有一个 java 安装 build-in 而不是分开的,所以 app-search 安装无法达到那个版本。感觉很脏,但能用!
我正在 运行ning 一个 vag运行t 盒子,它 运行s ubuntu 在虚拟机中(使用 Laravel Homestead 盒子)
我正在尝试安装 Elastic App-search 产品。
第一个要求是安装Elasticsearch,我已经安装过很多次了。我做了以下步骤: https://www.elastic.co/guide/en/elasticsearch/reference/current/deb.html
wget -qO - https://artifacts.elastic.co/GPG-KEY-elasticsearch | sudo apt-key add -
sudo apt-get install apt-transport-https
echo "deb https://artifacts.elastic.co/packages/7.x/apt stable main" | sudo tee -a /etc/apt/sources.list.d/elastic-7.x.list
sudo apt-get update && sudo apt-get install elasticsearch
我正在使用 systemd 配置:
sudo /bin/systemctl daemon-reload
sudo /bin/systemctl enable elasticsearch.service
我是 运行ning curl localhost:9200,一切正常。
接下来我尝试安装elastic app search。 https://www.elastic.co/guide/en/app-search/current/installation.html#installation-self-managed。 其中没有针对 debian 系统的说明。但它确实有一个 .deb 安装文件。我下载了文件并把它放在我的项目路径中。
I 运行 dpkg -i 在文件上,它似乎已经安装。当我 运行 检查文件位置的命令时,它显示如下:
dpkg -L enterprise-search
/.
/etc
/etc/init.d
/etc/init.d/enterprise-search
/var
/var/log
/var/log/enterprise-search
/usr
/usr/share
/usr/share/enterprise-search
/usr/share/enterprise-search/README.md
/usr/share/enterprise-search/bin
/usr/share/enterprise-search/bin/vendor
/usr/share/enterprise-search/bin/vendor/filebeat
/usr/share/enterprise-search/bin/vendor/filebeat/filebeat-linux-x86_64
/usr/share/enterprise-search/bin/enterprise-search
/usr/share/enterprise-search/filebeat
/usr/share/enterprise-search/filebeat/ecs-template.json
/usr/share/enterprise-search/filebeat/filebeat-ecs.yml
/usr/share/enterprise-search/lib
/usr/share/enterprise-search/lib/require_java_version.sh
/usr/share/enterprise-search/lib/enterprise-search.war
/usr/share/enterprise-search/jetty
/usr/share/enterprise-search/jetty/webserver-ssl.xml
/usr/share/enterprise-search/jetty/webserver-ssl-with-redirect.xml
/usr/share/enterprise-search/jetty/webserver.xml
/usr/share/enterprise-search/LICENSE
/usr/share/enterprise-search/config
/usr/share/enterprise-search/config/env.sh
/usr/share/enterprise-search/config/enterprise-search.yml
/usr/share/enterprise-search/NOTICE.txt
/usr/share/doc
/usr/share/doc/enterprise-search
/usr/share/doc/enterprise-search/changelog.gz
/usr/lib
/usr/lib/systemd
/usr/lib/systemd/system
/usr/lib/systemd/system/enterprise-search.service
我不确定这是不是正确的位置?我希望它和我的 elasticsearch 安装在同一个地方,但实际上我不确定。我完成了安装过程的所有后续步骤 运行: ./usr/share/enterprise-search/bin/elasticsearch
但这给了我错误:
Could not find java in PATH
我对此感到非常困惑,因为主要的 elasticsearch 安装工作正常并且还需要 java?我还希望它也 运行 具有 systemd 自动启用功能,并且我希望它在企业搜索启动/停止时可用。不确定如何处理。
看起来像是 Debian 软件包,因此可以安装在 ubuntu 上,但有些地方可能有所不同。 我会说你可以:
- 只需切换到使用 debian VM(在这里你可以得到一个 vagrant:https://app.vagrantup.com/debian/boxes/stretch64)
- 调试。据我所知,该包在运行之前先运行 elasticsearch-env 。 Java 是这样查找的:
if [ ! -z "$JAVA_HOME" ]; then
JAVA="$JAVA_HOME/bin/java"
JAVA_TYPE="JAVA_HOME"
else
if [ "$(uname -s)" = "Darwin" ]; then
# macOS has a different structure
JAVA="$ES_HOME/jdk.app/Contents/Home/bin/java"
else
JAVA="$ES_HOME/jdk/bin/java"
fi
JAVA_TYPE="bundled jdk"
fi
if [ ! -x "$JAVA" ]; then
echo "could not find java in $JAVA_TYPE at $JAVA" >&2
exit 1
fi
所以我建议在启动脚本中设置 JAVA_HOME(或在 运行 二进制文件之前),看看是否有帮助。
我通过添加另一个版本的 Java 解决了这个问题,Elastichsearch 有一个 java 安装 build-in 而不是分开的,所以 app-search 安装无法达到那个版本。感觉很脏,但能用!