Yes, ElasticSearch can be now installed and used much easier (that’s probably not a breaking news because I’m writing about it after one month since I have got a confirmed info) but summer is not the best time for writing a blog’s post 😉.)!
In this post I will focus on the dilemma – when exactly a .msi file can be useful and when it is better to stick to the old fashioned command line. At the end of the post I also added some personal experiences with ElasticSearch logs when working with ES as a service and when running it from a command line.
ElasticSearch Windows Installer – how to get it?
You just go to the ElasticSearch download page and click on the msi link.
Installation is easy and if you don’t change the default options, you will get a fresh ES version, working as a service. But if you tend to be a curious person :P, you can read what the settings mean, just by clicking the question mark button.
And the additional pane with more info appears!
Quite useful, especially when you are new to the ElasticSearch. Good job ES team!
What does the installer do for you?
If you are not a devoted nerd who uses console even for sending an e-mail (trust me, I know at least one person like this), the installer will make the first steps in ES world more intuitive. Below I listed some situations when it is better to use it:
- The installer will set up a ElasticSearch service for you (so you don’t have to do it manually or call the ‘elasticsearch.bat’ from the command line every time you need ES running)
- It will make configuration easier and will list you the most popular plugins so you don’t have to search the whole Internet when you need one.
- Panels with additional information are just great for the beginners – if you haven’t read any tutorials yet, you get the basic knowledge
- When you work on a project with people that have an allergy for black console screen, you just send them installer and receive no complains on how complicated life you created for them. I would count it as developing a new soft skill, what do you think?
When the installer is useless?
Although the idea of providing a .msi is just great, there are situations when you need a standard .zip pack with ElasticSearch. Below I listed the ones that came to my mind:
- You need to set up ElasticSearch on Docker or other similar platform with no GUI
- You prefer to watch the ElasticSearch logs appear on the console instantaneously instead of checking (refreshing/reopening) the log file (more about it – below).
When the ES log file grows too fast – a drawback of using ElasticSearch as a service
You can add a ElasticSearch service both when you got the search engine from the .zip pack or installed it with .msi installer. But there is one ‘service solution’ drawback that annoy me slightly 😉.
You know, when you learn ES and something goes wrong (from time to time, of course, because we all are programming mastah and our code never produce errors, that’s obviousness), the log file gains on weight quite fast. Imagine the situation when you need to check just a few recent lines of, let’s say 200 MB, log. Not a pleasant thing, right? You can of course delete/rename the log file, and perform the code that will regenerate the log you need to check, but hey! You cannot delete the log file while the ES is still running! So what to do? When you use ElasticSearch as a service, you go to the Services in Windows, turn off the ElasticSearch service, delete the ES log and turn on the service again. OMG, I got bored in the middle of the sentence!
And what would you do, when you run ElasticSearch from the command line? You would just have a peek at the console window 😊.