Skip to content

Contact sales

By filling out this form and clicking submit, you acknowledge our privacy policy.

Getting started with the Elastic Stack

New to the Elastic Stack? Learn how to create a basic single-node Elastic Stack and load it up with sample data, visualizations, and dashboards.

Jun 08, 2023 • 5 Minute Read

Please set an alt value for this image...
  • Software Development
  • Data

The Elastic Stack has come a long way in a few years when it comes to making it easy for beginners to get started. With sensible defaults across each of the Elastic Stack services, standing up a working stack and using it has been greatly simplified. Let's go ahead and demonstrate this by creating a basic single-node Elastic Stack and loading it up with sample data, visualizations, and dashboards.


Keys

Your keys to a better career

Get started with ACG today to transform your career with courses and real hands-on labs in AWS, Microsoft Azure, Google Cloud, and beyond.


Elasticsearch

First and foremost, let’s get Elasticsearch installed. I’m going to deploy my Elastic Stack to a 64-bit CentOS 8 host on our Cloud Playground so I’ll be downloading and installing the x86_6.rpm package:

wget https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-7.16.3-x86_64.rpm
sudo rpm --install elasticsearch-7.16.3-x86_64.rpm

You can download other Linux, MacOS, or Windows distributions for x86_64 or aarch systems from Elastic.

Now since we are just going to deploy a single-node cluster, we can just start Elasticsearch without any configuration:

sudo systemctl start elasticsearch

We can check Elasticsearch startup with curl localhost:9200 to get some basic cluster information:

{
  "name" : "9d995fe8ce1c.mylabserver.com",
  "cluster_name" : "elasticsearch",
  "cluster_uuid" : "AoP-d-faTdCJYgHHBscm7g",
  "version" : {
    "number" : "7.16.3",
    "build_flavor" : "default",
    "build_type" : "rpm",
    "build_hash" : "4e6e4eab2297e949ec994e688dad46290d018022",
    "build_date" : "2022-01-06T23:43:02.825887787Z",
    "build_snapshot" : false,
    "lucene_version" : "8.10.1",
    "minimum_wire_compatibility_version" : "6.8.0",
    "minimum_index_compatibility_version" : "6.0.0-beta1"
  },
  "tagline" : "You Know, for Search"
}

Kibana

With Elasticsearch up and running, let's get Kibana deployed and connected to it. On the same node that I installed Elasticsearch, I’m going to download and install the x86_64.rpm package:

wget https://artifacts.elastic.co/downloads/kibana/kibana-7.16.3-x86_64.rpm
sudo rpm --install kibana-7.16.3-x86_64.rpm

Just like Elasticsearch, you can download Kibana for other Linux, MacOS, or Windows distributions for x86_64 or aarch systems from Elastic.

Now, because I’m deploying this to a cloud server, in order to access Kibana from my local machine’s web browser, I need to make two small configuration changes in the /etc/kibana/kibana.yml file. Firstly, because ACG’s Cloud Playground does not have Kibana’s default port 5601 open to the public, I’m going to set the server.port parameter to 8080 instead. Secondly, I’m going to set the server.host parameter to 0.0.0.0 so that Kibana can be accessed from any of the host’s addresses. Your configuration should look something like this:

# Kibana is served by a back end server. This setting specifies the port to use.
server.port: 8080

# Specifies the address to which the Kibana server will bind. IP addresses and host names are both valid values.
# The default is 'localhost', which usually means remote machines will not be able to connect.
# To allow connections from remote users, set this parameter to a non-loopback address.
server.host: "0.0.0.0"

With those Kibana configuration changes saved, we need to open port 8080 in our local firewall and start Kibana:

sudo firewall-cmd --add-port=8080/tcp --permanent
sudo firewall-cmd --reload
sudo systemctl start kibana

Now we can navigate to the public IP address of our server and port 8080 in our local web browser (example: http://public_ip_here:8080).

Sample Data

From the Kibana home page, you can select “Try sample data” to load data, visualizations, and dashboards for the eCommerce, flight, and web log sample datasets.

elastic sample data guide
add data elastic stack

From there, you can view the sample data dashboards and start asking the data questions with filters and queries. 

elastic dashboard
elastic stack dashboard screenshot 2
elastic stack dashboard screenshot

Once you get a feel for it, you can upload your own sample data from a CSV, TSV, ND-JSON, or log file and then create some visualizations of your own!

screenshot of elastic stack file log

Learn more about Elastic Stack

Want to learn more about the Elastic Stack and its other amazing features? Check out our Elastic Stack Essentials and Elasticsearch Deep Dive courses. Want to take it even further and get certified? Check out our Elastic Certified Engineer and Elastic Certified Analyst preparation courses. All of our Elastic content is loaded with hands-on demonstrations that you can follow along with using the Cloud Playground and scenario-based hands-on labs.

Keep up with all things tech skills by following Twitter, Facebook, subscribing to A Cloud Guru on YouTube, or joining the conversation in our Discord Community.