Elasticsearch的安装
- 0
#讨论区
00条评论
实时对话
loading...
bash
重置密码
bash
bash
bash
update-alternatives --config java
export JAVA_HOME=/usr/lib/jvm/java-1.8.0-openjdk-1.8.0.292.b10-1.el7_9.aarch64
export PATH=$JAVA_HOME/bin:$PATH
export CLASSPATH=.:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar
javac
不能安装在root目录,会权限不足启动失败
yum -y install wget
wget https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-7.10.0-linux-x86_64.tar.gz
tar -zxvf elasticsearch-7.10.0-linux-x86_64.tar.gz -C /usr/local/
adduser es
passwd es
chown -R es elasticsearch-7.10.0
su es
vi config/elasticsearch.yml
network.host: 0.0.0.0
discovery.type: single-node
jvm.options改内存
./bin/elasticsearch -d
curl http://localhost:9200/
https://github.com/medcl/elasticsearch-analysis-ik
用root账户安装
bash
smartcn分词器
bash
bash
-Xms512m
-Xmx512m
https://www.elastic.co/guide/en/elasticsearch/client/javascript-api/current/get_examples.html https://blog.csdn.net/UbuntuTouch/article/details/122874932
docker run -d --name elasticsearch -p 9200:9200 -p 9300:9300 --restart=always -e "discovery.type=single-node" -e ES_JAVA_OPTS="-Xms128m -Xmx512m" docker.elastic.co/elasticsearch/elasticsearch:7.10.1
bin/elasticsearch-reset-password -u elastic
bin/elasticsearch-setup-passwords interactive
yum install -y java-1.8.0-openjdk
./bin/elasticsearch-plugin install https://github.com/medcl/elasticsearch-analysis-ik/releases/download/v7.10.0/elasticsearch-analysis-ik-7.10.0.zip
bin/elasticsearch-plugin install analysis-smartcn
docker run -p 11111:11111 --name canal -m 512M --memory-swap -1 canal/canal-server
docker update --restart=always canal