How to Install Analytics Applications
Note: Do not confuse this Elasticsearch instance with your Elasticsearch search index (backend The search engine your SmartHub instance uses to perform queries. SmartHub can be configured to use more than one search engine.), if you are using an Elasticsearch search index.
Tip: The Elasticsearch instance described in this topic is required by the SmartHub application and can be either the same or a separate instance of Elasticsearch.
This is the search engine The search engine your SmartHub instance uses to perform queries. SmartHub can be configured to use more than one search engine. where all the recorded user activity is stored.
- Documentation: To see the Elastic documentation, go to Elasticsearch Documentation.
To run the installation operation:
- Go to Elasticsearch Downloads page and download the .msi package of Elasticsearch.
- Follow the steps from the installation Elasticsearch page to install Elasticsearch as a Windows service.
- Set the following properties in the YML file
\config\elasticsearch.yml
:- network.host: 0.0.0.0
Set the value to one of the following:- An IP address attached to an individual network device such as NIC.
- This IP address must resolve to your elastic server (or a DNS The system that converts website domain names (hostnames) into numerical values (IP address) so they can be found and loaded into your web browser. which does).
- Once set, you can only access Elastic through this network interface device.
- 127.0.0.1 to make elastic accessible from this server only by using "localhost"
- 0.0.0.0 to make elastic accessible from any address/IP.
- http.port: 9200: Leave this set at the default value of 9200
- discovery.type: single-node: Set this property if you are using a single server for your elastic instance.
- network.host: 0.0.0.0
- Go to Windows services and start the Elastic service, which is running as a Local System service.
-
Verify the Elastic node status by going to http://localhost:9200.
Note: You must have an instance of Elasticsearch up and running.
Make sure that JSON is loaded.
See the following graphic as an example only.Note: Keep the Elastic window open while you install Kibana.
-
BA Insight clients often run Kibana as a Linux service or from a Linux machine.
-
If you do not have Kibana installed or running and want to do so on a Windows machine, use the topics and steps below:
How to Install Kibana as a Windows Service
- Kibana v7.6.0 is the data visualization engine for Elasticsearch.
- SmartHub Analytics uses reports that are built on top of Elastic Kibana.
Use the Elastic prerequisites to install Elastic Kibana on the same server or a different server from where you installed the SmartHub Analytics Reporting Site. For more information, go to the Kibana page.
To install Kibana as a Windows service, follow these steps:
-
Download and unzip Kibana
-
Go to NSSM Download page, download and unzip the file.
-
Use the command prompt with administrator permissions to navigate to the folder which contains nssm.exe:
cd path_to_nssm/nssm-2.24/win64
orpath_to_nssm/nssm-2.24/win32
-
Run the command:
nssm install kibana-7.6.0
In the "NSSM service installer" window:
-
Application tab: Set kibana.bat as Application Path
-
Details tab: enter display name, description, startup type
- Dependencies tab: enter Elasticsearch service name
- Click the "Install Service" button.
-
- You receive a service "installed successfully!" message.
- Update the port, host information, and the Elastic node URL in the kibana.yml file found at <path_to_kibana>\config\kibana.yml.
For more information see Configuring Kibana.- server.port:
5601
- server.host:
"localhost" or "0.0.0.0"
- elasticsearch.hosts:
- Set the URL of your Elasticsearch instance between square brackets.
- For example [
http://localhost:9200"]
- kibana.index:
".kibana"
Note: If your SmartHub is configured to use HTTPS, Kibana must also be set to use HTTPS.
To do this, follow the steps in the section "How to Set Kibana to HTTPS," below.
- server.port:
- Go to the Windows services application and start the Kibana service.
- Verify Kibana by going to http://localhost:5601/.
- If you already have both a stand-alone instance of Elasticsearch and the Elasticsearch instance for Kibana running, or if you have installed either of these applications, you can continue to use these Elasticsearch applications.
SmartHub Analytics creates a new Elasticsearch index.
- If you already have both a stand-alone instance of Elasticsearch and the Elasticsearch instance for Kibana running, or if you have installed either of these applications, you can continue to use these Elasticsearch applications.
How to Set Kibana to HTTPS
To encrypt traffic between the browser and Kibana, follow these steps:
-
Obtain a server certificate and private key for Kibana:
Note: If you already have an SSL certificate SSL certificates use a key pair: a public and a private key. These keys work together to establish an encrypted connection. The certificate also contains what is called the “subject,” which is the identity of the certificate/website owner. and its private key, skip this step.
Generate a certificate and private key using the elasticsearch-certutil tool:
- Open a command prompt as administrator.
- Navigate to the bin folder of Elasticsearch.
- Run the following command:
elasticsearch-certutil cert --name <name_of_certificate> --pem
- When asked "Please enter the desired output file [certificate-bundle.zip]" provide a name for your certificate .zip file, for example:
kibanaCertificate.zip
- Extract the files from the newly created .zip file.
- Copy the <name_of_certificate> folder to your Kibana config folder.
- Update the SSL enable setting, server certificate, private key and host information in the kibana.yml file found at <path_to_kibana>\config\kibana.yml:
- server.ssl.enabled: true
- server.ssl.certificate: "/path/to/kibana-server.crt"
- server.ssl.key: "/path/to/kibana-server.key"
- server.host: (optional) enter a host name that matches the host name (host names) associated with the SSL certificate.
NOTE: When configuring windows paths in Kibana's configuration file, you must use a double-backslash.
Example: server.ssl.certificate: C:\\Elastic\\Certificates\\server.crt
- Restart the Kibana service.
- Access SmartHub Administration page at https://<hostname>:<port>/_admin.
- Go to the Additional Settings Configuration page and replace the Kibana Server Address with the new address shown in the screenshot below:
For more information see Encrypting communications in Kibana.