Package Details: elasticsearch2 2.4.6-2

Git Clone URL: (read-only, click to copy)
Package Base: elasticsearch2
Description: Distributed RESTful search engine built on top of Lucene
Upstream URL:
Licenses: Apache
Conflicts: elasticsearch
Provides: elasticsearch
Submitter: lautat
Maintainer: None
Last Packager: lautat
Votes: 9
Popularity: 0.000000
First Submitted: 2016-11-03 13:45 (UTC)
Last Updated: 2022-01-27 14:42 (UTC)

Required by (20)

Sources (7)

Latest Comments

lautat commented on 2022-01-27 14:53 (UTC)

@Synthead, I applied your patch. I am disowning the package since I haven't needed this for a while. Elasticsearch 2 has reached EOL in February 2018, so if possible, I'd recommend switching to the latest version or OpenSearch, which is a fork of Elasticsearch with Apache 2.0 license. Elastic changed the license in version 7.11.

Synthead commented on 2020-12-03 00:00 (UTC) (edited on 2020-12-03 00:01 (UTC) by Synthead)

Here's a patch for this package to make elasticsearch2 to always use JVM 8:

diff --git a/PKGBUILD b/PKGBUILD
index ec1b7ec..294af21 100644
@@ -11,7 +11,7 @@ pkgdesc="Distributed RESTful search engine built on top of Lucene"
-depends=('java-runtime-headless' 'systemd')
+depends=('jre8-openjdk-headless' 'systemd')
@@ -30,7 +30,7 @@ sha256sums=('5f7e4bb792917bb7ffc2a5f612dfec87416d54563f795d6a70637befef4cfc6f'
-            'bb74e5fb8bc28f2125e015395ab05bea117b72bfc6dadbca827694b362ee0bf8')
+            '3a27010e3e88d49e8b60f0630e81ac60974300b128ec99be8c937f6e682fcf60')

diff --git a/elasticsearch.default b/elasticsearch.default
index ade7ae9..ae75737 100644
--- a/elasticsearch.default
+++ b/elasticsearch.default
@@ -1,4 +1,4 @@

 # Heap Size (defaults to 256m min, 1g max)

Synthead commented on 2019-12-30 17:27 (UTC)

Looks like this package requires jre8-openjdk-headless to run. This should probably be updated to require this package and use its $JAVA_HOME in /usr/lib/systemd/system/elasticsearch.service.

Also, I see this in the logs when starting elasticsearch.service:

systemd[1]: elasticsearch.service: Can't open PID file /run/elasticsearch/ (yet?) after start: Operation not permitted

Synthead commented on 2019-12-30 17:08 (UTC) (edited on 2019-12-30 17:09 (UTC) by Synthead)

I'm getting this error when trying to start elasticsearch2.service:

systemd[1]: Starting Elasticsearch...
elasticsearch[16638]: Unrecognized VM option 'UseParNewGC'
elasticsearch[16638]: Error: Could not create the Java Virtual Machine.
elasticsearch[16638]: Error: A fatal exception has occurred. Program will exit.
systemd[1]: elasticsearch.service: Control process exited, code=exited, status=1/FAILURE
systemd[1]: elasticsearch.service: Failed with result 'exit-code'.
systemd[1]: Failed to start Elasticsearch.

phcerdan commented on 2017-11-16 06:42 (UTC) (edited on 2017-11-16 06:43 (UTC) by phcerdan)

Getting not found config error when executing `elasticsearch`: (service is enabled). I have the config files (yml) in /etc/elasticsearch, but all the rest is in /usr/share/elasticsearch. Exception in thread "main" ElasticsearchException[Failed to load logging configuration]; nested: NoSuchFileException[/usr/share/elasticsearch/config]; Likely root cause: java.nio.file.NoSuchFileException: /usr/share/elasticsearch/config at sun.nio.fs.UnixException.translateToIOException( at sun.nio.fs.UnixException.rethrowAsIOException( at sun.nio.fs.UnixException.rethrowAsIOException( at sun.nio.fs.UnixFileAttributeViews$Basic.readAttributes( at sun.nio.fs.UnixFileSystemProvider.readAttributes( at sun.nio.fs.LinuxFileSystemProvider.readAttributes( at java.nio.file.Files.readAttributes( at java.nio.file.FileTreeWalker.getAttributes( at java.nio.file.FileTreeWalker.visit( at java.nio.file.FileTreeWalker.walk( at java.nio.file.Files.walkFileTree( at org.elasticsearch.common.logging.log4j.LogConfigurator.resolveConfig( at org.elasticsearch.common.logging.log4j.LogConfigurator.configure( at org.elasticsearch.bootstrap.Bootstrap.init( at org.elasticsearch.bootstrap.Elasticsearch.main( Refer to the log for complete error details.