install-elasticsearch-on-apple-silicon

How to Install Elasticsearch on Mac Apple Silicon Without Password

Elasticsearch is a powerful, open-source search engine used widely in analytics, logging, and search-driven applications. If you’re on a Mac M1, M2, M3 or M4 with macOS , and you want to install Elasticsearch without password or TLS, this guide is for you.

We’ll use the native aarch64 build for Apple Silicon — no need for Rosetta, Docker, or Homebrew.

🧰 Prerequisites

  • Mac M1, M2, M3 or M4 running macOS
  • Terminal access
  • Basic shell knowledge

🔽 Step 1: Download Elasticsearch (Apple Silicon Version)

Open your terminal and run:

curl -O https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-8.17.4-darwin-aarch64.tar.gz

Verify the checksum:

curl https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-8.17.4-darwin-aarch64.tar.gz.sha512 | shasum -a 512 -c -

You should see:

elasticsearch-8.17.4-darwin-aarch64.tar.gz: OK

📦 Step 2: Extract the Archive

tar -xzf elasticsearch-8.17.4-darwin-aarch64.tar.gz
cd elasticsearch-8.17.4

🛡 Step 3: Remove Quarantine Attribute

To prevent macOS security prompts:

xattr -d -r com.apple.quarantine .

🔧 Step 4: Disable Security (No Password, No TLS)

Edit the config file:

nano config/elasticsearch.yml

Add the following lines at the bottom to disable security:

xpack.security.enabled: false
xpack.security.enrollment.enabled: false

Save and exit.

▶️ Step 5: Start Elasticsearch

Run the following to start Elasticsearch:

./bin/elasticsearch

That’s it! Elasticsearch is now running without authentication or TLS.

🔍 Step 6: Test Your Installation

In a new terminal window, check if it’s working:

curl http://localhost:9200

You should see a JSON response with version info like:

{
  "name" : "Your-MacBook.local",
  "cluster_name" : "elasticsearch",
  "version" : {
    "number" : "8.17.4",
    ...
  },
  "tagline" : "You Know, for Search"
}

🧠 Bonus: Run as Background Service

To run Elasticsearch in the background:

./bin/elasticsearch -d -p pid

To stop it:

pkill -F pid

🌐 Access from Other Devices on LAN (Optional)

1. Edit config/elasticsearch.yml:

network.host: 0.0.0.0
http.port: 9200

2. Find your Mac’s IP:

ipconfig getifaddr en0

3. Access from browser or device on the network:

http://<your-ip>:9200

✅ Conclusion

You’ve now installed Elasticsearch on Mac natively, configured it to run without passwords or TLS, and verified it works locally. This is perfect for local development, experimentation, and quick prototyping.

Leave a Reply

Your email address will not be published. Required fields are marked *