Fix elastic search not working in macOS 13 Ventura

Fix elastic search not working in macOS 13 Ventura

any one got this error after upgrade to macOS Ventura.
“jdk is damaged and can’t be opened. You should move it to the Trash.”here is a quick fix. Until Elastic search company makes an updatein terminal install the latest version of openjdk with Homebrew

brew install openjdk 
echo 'export PATH="/opt/homebrew/opt/openjdk/bin:$PATH"' >> ~/.zshrc
source ~/.zshrc

if you still using old bash terminal change this to

echo 'export PATH="/opt/homebrew/opt/openjdk/bin:$PATH"' >> ~/.bash_profile
source ~/.bash_profile

in terminal

nano /opt/homebrew/Cellar/elasticsearch-full/7.17.4/homebrew.mxcl.elasticsearch-full.plist

add the following lines:


Right after this line:


If you got permission error like this

MacBook-Pro ~ % brew services start elastic/tap/elasticsearch-full
Bootstrap failed: 5: Input/output error
Try re-running the command as root for richer errors.
Error: Failure while executing; `/bin/launchctl bootstrap gui/501 /Users/mohd/Library/LaunchAgents/homebrew.mxcl.elasticsearch-full.plist` exited with 5.

Fix permission of the folder by doing these commands

sudo chown -R $(whoami) /Library/Java/JavaVirtualMachines/jdk-19.0.1.jdk
sudo chmod -R 755 /Library/Java/JavaVirtualMachines/jdk-19.0.1.jdk

Then restart elastic search or start it right away.

brew services start elastic/tap/elasticsearch-full


brew services restart elastic/tap/elasticsearch-full

Test if elastic search is working.

curl http://localhost:9200

You should get something like this

  "name" : "Mohameds-MacBook-Pro",
  "cluster_name" : "elasticsearch",
  "cluster_uuid" : "",
  "version" : {
    "number" : "7.17.4",
    "build_flavor" : "default",
    "build_type" : "tar",
    "build_hash" : "",
    "build_date" : "",
    "build_snapshot" : false,
    "lucene_version" : "8.11.1",
    "minimum_wire_compatibility_version" : "6.8.0",
    "minimum_index_compatibility_version" : "6.0.0-beta1"
  "tagline" : "You Know, for Search"

Add a comment if you need any help!

Have a great day!

Share this post

    السلة فارغةالعودة للمتجر