Elasticsearch failed to start on macos - elasticsearch

I've installed Elasticsearch using brew on macos Monterey
brew install elasticsearch
But I can't start the service
brew services start elasticsearch
brew info elasticsearch
This are the log
warning: no-jdk distributions that do not bundle a JDK are deprecated and will be removed in a future release
warning: no-jdk distributions that do not bundle a JDK are deprecated and will be removed in a future release
Exception in thread "main" java.lang.UnsupportedOperationException: The Security Manager is deprecated and will be removed in a future release
at java.base/java.lang.System.setSecurityManager(System.java:416)
at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:82)

If you run:
brew info elasticsearch
You will see:
Deprecated because it is switching to an incompatible license. Check out opensearch instead!
So you should either use opensearch, which is:
a community-driven, open source search and analytics suite derived from Apache 2.0 licensed Elasticsearch 7.10.2 & Kibana 7.10.2.
or if you want to stay with Elasticsearch use the official installation method for macOS which consists of using a tar.gz:
wget https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-8.1.2-linux-x86_64.tar.gz
wget https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-8.1.2-linux-x86_64.tar.gz.sha512
shasum -a 512 -c elasticsearch-8.1.2-linux-x86_64.tar.gz.sha512
tar -xzf elasticsearch-8.1.2-linux-x86_64.tar.gz
cd elasticsearch-8.1.2/
alternatively you can use an official Docker image.

Just adding something which might be useful for someone.
If you're running elastic on a Mac M1 architecture, depending on how you run elastic, you might need to setup this property:
xpack.ml.enabled=- false

For Mac Users
System Settings > Privacy & Security > Developer Tools
Check/Add the terminal and start the elastic search from the terminal.

Related

Elasticsearch failed to install multiple plugins in one command

As stated in documentation, plugins can be installed through the following command:
$ sudo bin/elasticsearch-plugin install analysis-icu
However, when installing with more than one plugins, the system prompted the followings
$ sudo bin/elasticsearch-plugin install analysis-icu repository-s3
ERROR: Found multiple arguments for option [arguments], but you asked for only one
https://github.com/elastic/elasticsearch/blob/master/docs/plugins/plugin-script.asciidoc
As of the latest version ES 7.5.2, you can only install one plugin at a time.
The ability to install multiple plugins at once has been added very recently and will only be available from ES 7.6 onwards, which has not yet been released. 7.6 should be coming out anytime now since there are only 2 issues and 4 PRs left open. Stay tuned...

fatal error: 'libcouchbase/cbft.h' file not found

fatal error: 'libcouchbase/cbft.h' file not found
Error while installing couchbase.
command used: sudo pip install couchbase.
installing libcouchbase is required.
(in my case, updating libcouchbase did the trick)
For Mac:
brew unlink libcouchbase
brew install libcouchbase
sudo pip install couchbase
libcouchbase/cbft.h is a C header file recently added to libcouchbase in order to support the Couchbase Full Text (cbft) Search developer preview in Couchbase Server 4.5. It appears in this instance that you have previously installed an older version of libcouchbase without full text support and you are trying to install a new version of the Couchbase Python client with full text support. The Couchbase Python client relies on libcouchbase to handle the full-text queries and needs the cbft.h header file to allow it to call into libcouchbase.
The answer in the case (as you identified yourself) is to update your version of libcouchbase. On OSX this can be done using brew, on supported Linux platforms you can add our package repositories & install using apt-get/yum, and on Windows you can download our prebuilt binaries - you can find details on how to do this in the documentation (http://developer.couchbase.com/documentation/server/current/sdk/c/start-using-sdk.html).

Elasticsearch 2.2 : Cant install marvel plugin

I am trying to install the marvel sense plugin for ES and Kibana on windows. I have ES version 2.2.0 and Kibana version 4.4.0
Here is what i tried to do
For ES
plugin install license
i get
-> Installing license...
Trying https://download.elastic.co/elasticsearch/release/org/elasticsearch/plugi
n/license/2.2.0/license-2.2.0.zip ...
ERROR: failed to download out of all possible locations..., use --verbose to get
detailed information
i also tried
plugin install marvel-agent
but i get
-> Installing marvel-agent...
Trying https://download.elastic.co/elasticsearch/release/org/elasticsearch/plugi
n/marvel-agent/2.2.0/marvel-agent-2.2.0.zip ...
ERROR: failed to download out of all possible locations..., use --verbose to get
detailed information
For Kibana, i knew it wasn't going to work but still
i tried
plugin --install elasticsearch/marvel/latest
and i get
Installing marvel
Attempting to transfer from https://download.elastic.co/elasticsearch/marvel/mar
vel-latest.tar.gz
Error: Client request error: connect ETIMEDOUT
Plugin installation was unsuccessful due to error "Client request error: connect
ETIMEDOUT"
has anyone faced similar issues? Any help would be appreciated. I did not face these problems for ES 2.1 and Kibana 4.3
I downloaded everything from the ES website.
Edit
The offline installation as mentioned on
https://www.elastic.co/guide/en/marvel/current/installing-marvel.html#offline-installation
works for ES but not for Kibana. It complains of an invalid url.
For each of your failures in which it recommends using --verbose, upon doing so you should see FileNotFoundException for the URL from which it attempts to download.
However, I just now installed Marvel for Elasticsearch 2.2.0 on a Windows machine, using the same command as you:
...\elasticsearch-2.2.0\bin>plugin install license
As you can see, the URL it attempts to use matches yours, so the package should be available.
-> Installing license...
Trying https://download.elastic.co/elasticsearch/release/org/elasticsearch/plugin/license/2.2.0/license-2.2.0.zip ...
Downloading .......DONE
Verifying https://download.elastic.co/elasticsearch/release/org/elasticsearch/plugin/license/2.2.0/license-2.2.0.zip checksums if available ...
Downloading .DONE
Installed license into C:\Elasticsearch\elasticsearch-2.2.0\plugins\license
Are you issuing the command from \bin?
This command doesn't seem to work well behind a proxy and the usual http_proxy environment variable doesn't seem to take here.
According to this link, there are parameters you can set to specify proxy settings, but the command there is setup for marvel 1.x. The command below worked for me:
./bin/plugin -DproxyPort=port_number -DproxyHost=hostname install license
More information can also be found in the elasticsearch documentation here

How could I install Elasticsearch 1.2.1 with homebrew

I need old Elasticsearch for my work. but I couldn't install Elasticsearch 1.2.1 with brew
Development environment
$ brew --version
Homebrew 0.9.5 (git revision 567b; last commit 2015-12-23)
The procedure I tried
I tried the following process
$ brew search elasticsearch
elasticsearch ✔ homebrew/versions/elasticsearch20
homebrew/versions/elasticsearch17 ✔
There is no elasticsearch10.
So, I tracked down this guidance.
Homebrew install specific version of formula?
And typed this command.
$ brew info elasticsearch
elasticsearch: stable 2.1.1, HEAD
Distributed search & analytics engine
https://www.elastic.co/products/elasticsearch
/usr/local/Cellar/elasticsearch/2.1.1 (52 files, 31M)
Built from source
From: https://github.com/Homebrew/homebrew/blob/master/Library/Formula/elasticsearch.rb
==> Caveats
Data: /usr/local/var/elasticsearch/elasticsearch_kent/
Logs: /usr/local/var/log/elasticsearch/elasticsearch_kent.log
Plugins: /usr/local/Cellar/elasticsearch/2.1.1/libexec/plugins/
Config: /usr/local/etc/elasticsearch/
To have launchd start elasticsearch at login:
ln -sfv /usr/local/opt/elasticsearch/*.plist ~/Library/LaunchAgents
Then to load elasticsearch now:
launchctl load ~/Library/LaunchAgents/homebrew.mxcl.elasticsearch.plist
Or, if you don't want/need launchctl, you can just run:
elasticsearch
And also typed this command, however couldn't find out a key to installing elasticsearch version 1.2.1
$ brew versions elasticsearch
Error: The `versions` command is no longer supported.
You can use the homebrew-versions tap instead:
https://github.com/Homebrew/homebrew-versions
Or use `brew log` to browse the git history.
I need some help to bridge myself to installing elasticsearch 1.2.1 with brew.
Could you steer my steps?
If you're just trying to do this for local development, then it's probably easier to just download and untar Elasticsearch into a directory.
$ cd /path/to/install/at
$ wget https://download.elastic.co/elasticsearch/elasticsearch/elasticsearch-1.2.1.tar.gz
$ tar -xf elasticsearch-1.2.1.tar.gz
$ cd elasticsearch-1.2.1
Once untarred, you can optionally delete the tarball:
$ rm elasticsearch-1.2.1.tar.gz
From there, it's just a matter of configuring (as desired) and starting Elasticsearch.
$ vi config/elasticsearch.yml
$ bin/elasticsearch
Note: Elasticsearch 1.2.1 is an extremely old version. I strongly recommend that you upgrade to a more recent release to gain reliability and security. For example, ES 1.2.1 uses MVEL scripting, which is bad at best.
For your production scenario (after New Years, of course), you can easily perform a rolling restart from ES 1.2.1 to ES 1.7.4 to gain a lot of features and stability without much risk. If you have dedicated master nodes, then I recommend starting with them first to get a few extra benefits upfront.

Cannot find a way to install SAP/Build from GIT to my windows system

I am trying to install SAP/BUILD from GitHub. But I could not find a way to install it. There is no proper guides available online for installation. So please guide me.
https://github.com/SAP/BUILD
1.0 Install MongoDB 2.6.x according to your platform ( for windows : https://docs.mongodb.org/v2.4/tutorial/install-mongodb-on-windows/ )
making sure that you create a directory for the dbms, using the default C:\data\db or an alternate one as described.
1.1. Install NodeJs v0.10.38
test the install with the cmdline
node --version
returns
v0.10.38
1.2 Install SapBuild with npm:
npm install -g sap-build-cli#0.3.3
1.3 Start MongoDB as per above document
1.4 Start SapBuild (node daemon running)
1.5 Go to Chrome Browser and type the url
localhost:9000
then Join
That's it.

Resources