Updated on 2024-10-26 GMT+08:00

Elasticsearch Cluster Access Methods

There are many ways to connect to an Elasticsearch cluster. Select the most appropriate access method based on the programming language you prefer. The various access methods support different types of network configurations. The cluster access addresses vary depending on the network configuration you choose. Select an appropriate network configuration method based on your network environment.

Access Methods

Table 1 Cluster access methods

Access Method

Scenario

Details

Kibana (recommended)

  • A graphical user interface
  • Instance monitoring
  • Data management

Language-irrelevant

Logging In to an Elasticsearch Cluster Using Kibana

Cerebro

Logging In to an Elasticsearch Cluster Through Cerebro

Open-source Elasticsearch API

Run Curl commands to access and manage Elasticsearch clusters.

Accessing an Elasticsearch Cluster Using cURL Commands

Java

Use Java to access and manage Elasticsearch clusters.

To avoid compatibility issues, use the Java client that matches your Elasticsearch cluster version.

Accessing an Elasticsearch Cluster Through the Rest High Level Client

Accessing an Elasticsearch Cluster Through the Rest Low Level Client

Accessing an Elasticsearch Cluster Through the Transport Client

Accessing an Elasticsearch Cluster Using Spring Boot

Python

Use Python to access and manage Elasticsearch clusters.

Accessing an Elasticsearch Cluster Using Python

MRS Hive

Use the Elasticsearch-Hadoop (ES-Hadoop) connector of MRS to access and manage Elasticsearch clusters using Hive.

Accessing an Elasticsearch Cluster Through the MRS Hive Client

Go

Use Go to access and manage Elasticsearch clusters.

Accessing an Elasticsearch Cluster Using Go

LDAP Authentication

Enable Lightweight Directory Access Protocol (LDAP) authentication for an Elasticsearch cluster.

Accessing an Elasticsearch Cluster Using LDAP

Network Configuration

Configure the network of the Elasticsearch cluster, and ensure that you have a server that can connect to the cluster's network. Obtain the cluster access address. With the exception of Kibana and Cerebro, which support one-click cluster access so there is no need to provide the cluster address, the cluster address needs to be provided for all other access methods.

Table 2 Network configuration for the cluster

Network Environment

Access Method

Scenario

Details

Private network

Private IP address

Obtain the IP address of each node from the cluster information page, and access the cluster by connecting to one of these IP addresses directly.

How to obtain:

  1. In the navigation pane on the left, choose Clusters.
  2. In the cluster list, obtain the IP address of the cluster you want to access from the Private Network Address column. Generally, the IP address format is <host>:<port> or <host>:<port>,<host>:<port>.

    If the cluster has only one node, the IP address and port number of this one node are displayed, for example, 10.62.179.32:9200. If the cluster has multiple nodes, the IP addresses and port numbers of all nodes are displayed, for example, 10.62.179.32:9200,10.62.179.33:9200.

This is the default method.

Private network

IP address or private domain name of the VPC endpoint

Configure a VPC endpoint to access the cluster from a different VPC over an internal network. Do not use this method if high performance standards are used.

How to obtain:

  1. In the navigation pane on the left, choose Clusters.
  2. On the Clusters page, click the name of the cluster you want to access. The Cluster Information page is displayed.
  3. In the navigation pane, choose VPC Endpoint Service. Record the service address or private domain name of the VPC endpoint.

Configuring VPC Endpoint Service for an Elasticsearch Cluster

Private network

Private IP address of a dedicated load balancer

Access the cluster through a dedicated load balancer. Use this method if high performance standards are used.

How to obtain:

  1. In the navigation pane on the left, choose Clusters.
  2. On the Clusters page, click the name of the cluster you want to access. The Cluster Information page is displayed.
  3. In the navigation pane, choose Load Balancing. Record the private IP address of the load balancer.

Configuring a Dedicated Load Balancer for an Elasticsearch Cluster

Public network

Public IP address

Configure a whitelist to control public network access to the cluster. Use this method only for security-mode clusters that use HTTPS.

How to obtain:

  1. In the navigation pane on the left, choose Clusters.
  2. On the Clusters page, click the name of the cluster you want to access. The Cluster Information page is displayed. Record the cluster's public network address.
NOTE:

Use this method only for security-mode clusters that use HTTPS.

Configuring Public Network Access for an Elasticsearch Cluster

Public network

Public IP address of a dedicated load balancer

Access the cluster through a dedicated load balancer. Use this method if high performance standards are used.

  1. In the navigation pane on the CSS console, choose Clusters.
  2. On the Clusters page, click the name of the cluster you want to access. The Cluster Information page is displayed.
  3. In the navigation pane, choose Load Balancing. Record the public IP address of the load balancer.

Configuring a Dedicated Load Balancer for an Elasticsearch Cluster