Elasticsearch is a powerful search engine tool for any application that needs relevance search, which simply can't be done using relational databases query. For learning purpose you can setup elasticsearch on your local computer.
Ideally for production, your elasticsearch should be hosted somewhere online, but for learning purpose why don't we just install elasticsearch on our ubuntu. Installing elasticsearch on ubuntu is pretty easy.
For this tutorial i'm going to install elasticsearch version 2.3.3 on ubuntu 16.04.
Step by step how to install elasticsearch on ubuntu 16.04
- Make sure you have java installed on your system, you can use either oracle JDK or open JDK
- Download elasticsearch debian package version 2.3.3
- Install the debian package with this command:
- Start the elasticsearch service
- Make sure the service is up and running
- Run your first elasticsearch request
sudo dpkg -i elasticsearch-2.3.3.deb
sudo service elasticsearch start
sudo service elasticsearch status
curl 'http://localhost:9200/?pretty'
Now that you have elasticsearch running on your ubuntu, you can use curl on the command line to run the query or use tool like sense if you prefer to do it on graphical mode.
No comments:
Post a Comment