Kibana Installation Guide (Linux)

Kibana is a core component of the Elastic Stack, designed to provide visual data exploration, dashboard creation, and log analysis capabilities. Successfully installing and running Kibana on a Linux server requires ensuring the system environment meets specific requirements and completing the correct service startup procedure. This article details the standard deployment steps based on the systemd manager, helping developers quickly build local development or production testing environments.
Before proceeding with the installation, it is mandatory to confirm that the server's operating system is a Linux distribution supporting RPM/YUM (such as CentOS, RHEL) or APT/DEB (such as Ubuntu, Debian). Additionally, Kibana has specific minimum configuration requirements for system resources: at least 2GB of RAM is required for memory caching, and sufficient disk space is needed to store logs and configuration files.

It is recommended to first check the status of the current system's package manager and verify if the Java runtime environment version complies with Kibana's official recommendations (typically JDK 8 or OpenJDK 17+). If the system does not come pre-installed with necessary dependency libraries, they can be automatically initialized via the installation scripts provided by the official documentation; otherwise, missing components can be manually supplemented one by one using yum install or apt-get update && apt-get install commands.

Downloading and Extracting Kibana Installation Packages

Visit the Elastic.co official website to obtain the binary packages (.rpm or .deb) corresponding to your specific Linux distribution, or directly use the official installation script for automated deployment. Taking CentOS 7 as an example, you can start the automatic installation process directly using the following command:

curl -Os https://artifacts.elastic.co/downloads/kibana/8.x.kibana-install.sh && chmod +x kibana-install.sh
./kibana-install.sh --yes

This script will automatically handle dependencies, download the compressed archive, and extract it to the default path /usr/share/kibana. If a custom installation location is required, you can specify the target directory by adding the --install-path=/opt/kibana parameter during execution. After extraction is complete, verify the integrity of the file structure using ls -l /usr/share/kibana/.

Configuring Core Parameters and Starting Services

Kibana's default configuration files are located at /etc/elasticsearch/opensearch.yml (for OpenSearch) or /etc/xpack/security/config/admin.pem (when security modules are included). For most users, no advanced options need to be modified for normal operation. However, key parameters can be adjusted according to actual requirements:

  • server.host: Set the listening address to 0.0.0.0 to allow external access;
  • xpack.security.enabled: Enable or disable the security authentication mechanism (default is enabled);

It is recommended to use the systemd manager to start the Kibana service. Execute the following command:

systemctl enable kibana.service && systemctl start kibana.service

At this point, you can view real-time log output via journalctl -u kibana. If port conflicts or insufficient memory errors occur, please check if the configuration items in /etc/systemd/system/kibana.conf.d/ are reasonable and adjust the JVM heap size (e.g., -Xms1g -Xmx2g).

Verifying Installation Status and Network Connectivity

After the service starts successfully, you can access the Kibana Web UI by visiting http://localhost:5601 in a web browser. If you cannot connect to the local port, ensure that firewall rules allow TCP/5601 traffic (e.g., using firewalld to execute firewall-cmd --add-port=5601/tcp --permanent && firewall-cmd --reload).

Additionally, the status of background processes can be verified via command-line tools:

systemctl status kibana.service
curl -I http://localhost:5601/api/status/health

A response of HTTP 200 indicates that the service is running normally. You can then log in to the default administrator account (username admin, password empty) to begin creating your first dashboard and test whether data source connections and visualization functions are operating correctly.

Upon completing the above steps, Kibana is ready for stable deployment within the Linux environment. Subsequently, you can expand cluster nodes or integrate with Elasticsearch/OpenSearch based on business needs for large-scale data analysis processing.