Created
August 8, 2021 22:09
-
-
Save kosso/af36a77717fdd5e72a00de9cb424fd65 to your computer and use it in GitHub Desktop.
Setting up ElasticSearch 7.4.0 on a Raspberry Pi 4
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Setting up ElasticSearch 7.4.0 on Raspberry Pi 4 | |
================================================ | |
sudo apt-get install default-jre | |
sudo nano /etc/profile | |
export JAVA_HOME=/usr/lib/jvm/default-java export PATH=$JAVA_HOME/bin:$PATH | |
sudo reboot | |
sudo mkdir /usr/share/elasticsearch/jdk | |
sudo cp -R /usr/lib/jvm/default-java/* /usr/share/elasticsearch/jdk | |
cd ~/Downloads | |
wget https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-7.4.0-no-jdk-amd64.deb | |
sudo dpkg -i --force-all --ignore-depends=libc6 elasticsearch-7.4.0-no-jdk-amd64.deb | |
sudo nano /var/lib/dpkg/status (and do a search for elasticsearch) | |
See something like: | |
Package: elasticsearch | |
Status: install ok installed | |
Priority: optional | |
Section: web | |
Installed-Size: 198434 | |
Maintainer: Elasticsearch Team [email protected] | |
Architecture: amd64 | |
Source: elasticsearch | |
Version: 7.4.0 | |
Depends: bash (>= 4.1), lsb-base (>= 4), libc6, adduser, coreutils (>= 8.4) | |
Edit the last line, removing: "libc6, " | |
sudo mv /usr/share/elasticsearch/lib/jna-4.5.1.jar /usr/share/elasticsearch/lib/jna-4.5.1.jar.old | |
sudo wget -P /usr/share/elasticsearch/lib http://repo1.maven.org/maven2/net/java/dev/jna/jna/4.5.1/jna-4.5.1.jar | |
echo 'xpack.ml.enabled: false' | sudo tee -a /etc/elasticsearch/elasticsearch.yml | |
echo 'bootstrap.system_call_filter: false' | sudo tee -a /etc/elasticsearch/elasticsearch.yml | |
sudo nano /etc/elasticsearch/elasticsearch.yml | |
(to access over local network) I added: | |
http.host: 0.0.0.0 | |
- and also opened up port 9200 & 9300 | |
sudo systemctl enable elasticsearch | |
sudo systemctl start elasticsearch | |
Check to see if it's running: | |
curl http://localhost:9200 | |
Should see something like: | |
{ | |
"name" : "raspberrypi", | |
"cluster_name" : "elasticsearch", | |
"cluster_uuid" : "VV9iwXSrR1aIaYJwlBpFMQ", | |
"version" : { | |
"number" : "7.4.0", | |
"build_flavor" : "default", | |
"build_type" : "deb", | |
"build_hash" : "22e1767283e61a198cb4db791ea66e3f11ab9910", | |
"build_date" : "2019-09-27T08:36:48.569419Z", | |
"build_snapshot" : false, | |
"lucene_version" : "8.2.0", | |
"minimum_wire_compatibility_version" : "6.8.0", | |
"minimum_index_compatibility_version" : "6.0.0-beta1" | |
}, | |
"tagline" : "You Know, for Search" | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment