elasticsearch-plugin¶
Installs, lists and removes Elasticsearch plugins, for example additional language analyzers.

Syntax¶
sudo /usr/share/elasticsearch/bin/elasticsearch-plugin list | install [--batch] PLUGIN | remove PLUGIN
Options¶
| Command | Description |
|---|---|
list |
Installed plugins |
install PLUGIN |
Install an official plugin by name, or from a URL or file:// path |
install --batch |
Don't ask about extra permissions |
remove PLUGIN |
Remove a plugin |
remove --purge |
Also delete its configuration |
Plugins must have exactly the version of Elasticsearch, and every node needs the same plugins. Changes take effect after sudo systemctl restart elasticsearch. OpenSearch: opensearch-plugin with the same commands.
Examples¶
Install a plugin:
sudo /usr/share/elasticsearch/bin/elasticsearch-plugin install --batch analysis-icu
-> Installing analysis-icu
-> Downloading analysis-icu from elastic
-> Installed analysis-icu
-> Please restart Elasticsearch to activate any plugins installed
Installed plugins:
sudo /usr/share/elasticsearch/bin/elasticsearch-plugin list
analysis-icu
Activate it and check:
sudo systemctl restart elasticsearch
curl --cacert /etc/elasticsearch/certs/http_ca.crt -u elastic https://localhost:9200/_cat/plugins?v
Enter host password for user 'elastic':
name component version
tuxdex-srv analysis-icu 9.1.0
A typo in the name:
sudo /usr/share/elasticsearch/bin/elasticsearch-plugin install analysis-foo
ERROR: Unknown plugin analysis-foo, did you mean any of [analysis-nori, analysis-icu]?, with exit code 64
Remove a plugin:
sudo /usr/share/elasticsearch/bin/elasticsearch-plugin remove analysis-icu
-> removing [analysis-icu]...
When do I need it?¶
- For better search in a language, e.g.
analysis-icuoranalysis-kuromoji - Before an upgrade: which plugins must be upgraded as well?
- To find out why a node doesn't start after an upgrade
Plugins on servers without internet
Download the ZIP on another machine and install it with
elasticsearch-plugin install file:///tmp/analysis-icu-9.1.0.zip.
Upgrade plugins together with Elasticsearch
After a package upgrade a node with an old plugin version refuses to start. Remove the plugin before the upgrade and install it again afterwards, in the new version.
Distribution differences¶
| Debian | Ubuntu | RHEL | Arch | |
|---|---|---|---|---|
| Installation | APT repository of Elastic | APT repository of Elastic | YUM repository of Elastic | AUR or container |
| Path | /usr/share/elasticsearch/bin/ |
/usr/share/elasticsearch/bin/ |
/usr/share/elasticsearch/bin/ |
depends on the package |
Related commands¶
elasticsearch-keystore · elasticsearch-reset-password · systemctl