On this page

Skip to content

Kibana Installation Guide for Windows

I previously wrote an installation guide for a single-node Elasticsearch on Windows (Elasticsearch Installation Guide for Windows). After spending 2–3 days researching, I finally managed to set up the Kibana environment as well. I wanted to write down these notes while they were still fresh in my mind, although I got stuck on SSL for a while and it took me two weeks to finally finish this post.

Download and Installation

Directory Structure Explanation

  • bin: Directory for executable files.
  • config: Directory for configuration files.
  • node: Contains the Node.js runtime environment; Kibana uses Node.js as its runtime.
  • node_modules: Stores the Node.js packages required by Kibana.
  • packages: Core libraries and dependency packages.
  • plugins: Directory for plugins.
  • src: Kibana source code.
  • x-pack: Paid features of the Elastic Stack.
  • .i18nrc.json: Internationalization (i18n) configuration file for language localization.

YAML Configuration File (config/kibana.yml)

Network Settings

yaml
# Network settings
network.host: 0.0.0.0 # localhost is for local access only, 0.0.0.0 allows all connections. If you only want specific network interfaces to accept connections, you can specify a concrete IP address.
http.port: 5601       # Default is 5601; only set this if you need to use a different port.

Elasticsearch Settings

  • Kibana connects to Elasticsearch using the kibana_system account. I was stuck here for a while because I kept trying to connect using the credentials I manually created in Elasticsearch, which caused Kibana to fail to start.

  • When setting up Elasticsearch, three system accounts are generated: elastic, kibana_system, and logstash_system, along with their corresponding random passwords. If, like me, you didn't notice or save the random passwords during service setup, you can reset them by running the following command in the Elasticsearch bin folder. The password will be displayed on the console.

    bash
    elasticsearch-reset-password -u kibana_system
  • When I previously created the SSL certificates for Elasticsearch, the elasticsearch-ssl-http.zip contained a kibana folder. I placed that folder under the Kibana bin directory.

    yaml
    # Set the URL of the Elasticsearch node to connect to. Use an IP or Domain here, not localhost.
    elasticsearch.hosts: ["https://127.0.0.1:9200"]
    # Username and password for connecting to Elasticsearch
    elasticsearch.username: "kibana_system"
    elasticsearch.password: "pass"
    # If ELK has SSL enabled, place the previously generated certificates under the Kibana directory
    elasticsearch.ssl.certificateAuthorities: [ "certs/kibana/elasticsearch-ca.pem" ]

Language Settings

yaml
# Supported languages are the following: English (default) "en", Chinese "zh-CN", Japanese "ja-JP", French "fr-FR".
i18n.locale: "zh-CN"

Configuring SSL Certificates

I took a shortcut here and simply copied the http.p12 file from Elasticsearch to the Kibana directory.

yaml
server.ssl.enabled: true
server.ssl.keystore.path: "certs/elasticsearch/http.p12"

Just like with Elasticsearch, you can store sensitive information in the keystore.

  • Run the following command in the bin folder to create a keystore:

    bash
    kibana-keystore create
  • If created successfully, you will see the following message:

    bash
    Created Kibana keystore in D:\ELK\kibana-8.17.1\config\kibana.keystore
  • Add the SSL certificate password to the keystore:

    bash
    kibana-keystore add server.ssl.keystore.password
  • When you see the following message, enter the password for http.p12:

    bash
    Enter value for server.ssl.keystore.password:

Starting the Service

Manual Startup

  • Open Command Prompt with administrator privileges.

  • Switch to the bin directory:

    bash
    cd D:\ELK\kibana-8.17.1\bin
  • Execute:

    bash
    kibana.bat
  • Wait for the startup to complete, then open your browser to test: http://localhost:5601 or https://localhost:5601.

  • Note: During the first execution, after the CMD shows the message below, it will continue to load other information. If it doesn't appear, there might be an error. You can check the Kibana or Elasticsearch logs to see if there is an issue with Kibana or if the connection to Elasticsearch failed. It is normal for the CMD to stay at this line once started:

bash
Native global console methods have been overridden in production environment.

Logging into Kibana

  • To log into Kibana, use the elastic account. This is the default superuser account for Elasticsearch and has full permissions.

  • If you forget the password, you can reset it by running the following command in the Elasticsearch bin folder:

    bash
    elasticsearch-reset-password -u elastic
  • Using the elastic account, you can create other user accounts in the Kibana Management interface:

    • Find Stack Management -> Security -> Users in the left menu.
    • Click the Create user button to create a new user.
    • Set the username, password, and appropriate role permissions.

Registering as a Windows Service

I looked into this, but unlike Elasticsearch, Kibana does not have a built-in .bat file to assist with Windows service installation. I see people online using NSSM, but I am not familiar with that tool, so I won't write about it for now. I will write a separate note once I have researched it.

Change Log

  • 2025-03-18 Initial version created.