Installing ElasticSearch and Kibana on Linux on Power (ppc64le)
ElasticSearch and Kibana don't support ppc64le architecture officially. But with some tricks you can install and use it on our favourite platform. Be warned - it is not a supported way of installation and usage and you will not get support from Elastic for doing it.
What do you need to make it possible:
- Linux. We tested it on Red Hat Enterprise Linux 7/ppc64le. But there is nothing distribution specific in this howto.
- Java. We have standard OpenJDK 1.8 from Red Hat Enterprise Linux. ElasticSearch moans, that it would have Java 11, but works with Java 8.
- Node.JS 14.15.4. Kibana requires this version. May be it runs ok with earlier versions, may be even with newer versions. But if you try to start it with Node.JS 10 or 12 you will get an error.
- gcc-c++ and make. You must rebuild one binary package to start Kibana.
I will run all the commands under user "root". It is ok for testing purposes, but please don't do it in production.
It is the easiest part of the installation. Download the latest x86_64 version from the official site.
# curl -L -O https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-7.11.1-linux-x86_64.tar.gz
# tar xf elasticsearch-7.11.1-linux-x86_64.tar.gz # mv elasticsearch-7.11.1 /srv/elastic
Disable machine learning. It doesn't work on ppc64le.
# echo "xpack.ml.enabled: false" >>/srv/elastic/config/elasticsearch.yml
If you want to make ElasticSearch available on some IP address (not loopback), add the following 2 strings into config:
# echo "network.host: 192.168.1.1" >>/srv/elastic/config/elasticsearch.yml # echo "discovery.type: single-node" >>/srv/elastic/config/elasticsearch.yml
All possible configuration directives you can find in ElasticSearch reference.
Now create a small script to start ElasticSearch:
#!/bin/bash export ELASTIC_HOME=/srv/elastic export JAVA_HOME=/usr cd $ELASTIC_HOME ./bin/elasticsearch
Start the script and in a second or two you can see ElasticSearch running and can connect to it. Depending on your hardware it can take longer ;-)
The same way - first download and unpack the official x86_64 version of Kibana.
# curl -L -O https://artifacts.elastic.co/downloads/kibana/kibana-7.11.1-linux-x86_64.tar.gz # tar xf kibana-7.11.1-linux-x86_64.tar.gz # mv kibana-7.11.1-linux-x86_64 /srv/kibana
The next step is Node.JS installation.
# curl -L -O https://nodejs.org/download/release/v14.15.4/node-v14.15.4-linux-ppc64le.tar.xz # tar xf node-v14.15.4-linux-ppc64le.tar.xz # mv node-v14.15.4-linux-ppc64le /srv/node
Now let's go into /srv/kibana/bin and change the scripts. Find in every script the following line:
and change it to your node:
It was the easiest part of Kibana installation. Now we need to be a little bit developers. Set your PATH variable to Node.JS and try to install re2 module:
$ cd $HOME $ export PATH=/srv/node/bin:$PATH $ npm i email@example.com
As for me I'm getting a lot of warning during the compilation, but I just ignore them ;-) The most important result of the compilation is in node_modules directory right now:
$ ls -l node_modules/re2/build/Release/re2.node -rwxrwxr-x 1 user group 9548184 Mar 3 11:54 node_modules/re2/build/Release/re2.node
If you compile the package as root, you may have permission errors. If you have them, create a separate subdirectory and change NPM config before building the re2 module:
# mkdir ~/ttt # npm config set prefix '~/ttt'
Now you can copy the file re2.node to kibana:
# cp /home/user/node_modules/re2/build/Release/re2.node /srv/kibana/node_modules/re2/build/Release/
Add your server name into /srv/kibana/config/kibana.yml:
If you changed the address of the ElasticSearch instance during its installation, you must change the address in Kibana configuration too. Otherwise Kibana searches for ElasticSearch on 127.0.0.1 and can't start:
Now you are ready to start:
# cd /srv/kibana # ./bin/kibana --allow-root
Now you can use ElasticSearch and Kibana on your Linux on IBM Power Systems.
If you want, you can use (almost) the same process to install it even on IBM AIX.