Connecting to an External Kibana
Considerations when you configure an External Kibana:
Ensure the Kibana version is compatible with the Elasticsearch version as Kibana and Elasticsearch have a one-to-one mapping. For details on version compatibility, see
Support Matrix.
Turn off Kibana auto start in one of the following ways:
By setting the property
apigw.kibana.autostart to
false located in
C:\API Gateway instance\profiles\IS_default\apigateway\config\uiconfiguration.properties.
You can have one of the following Kibana configurations:
Default Kibana connected to
API Gateway Data Store.
External Kibana connected to
API Gateway Data Store.
You can configure this setup as follows:
For an external Kibana to connect to API Gateway Data Store you have to configure the following properties in the kibana.yml file where you have installed the external Kibana.
Property | Description |
server.port: port number Example: 9405 | Specifies which server port to use. |
server.host: server host IP address Example: "0.0.0.0" | Specifies the host to bind the server to. |
server.basePath: server path of the proxy Example: "/apigatewayui/dashboardproxy" | Specifies the proxy setting to render the charts from the external Kibana in API Gateway UI. |
elasticsearch.hosts: http://hostname:port Example: "http://localhost:9240" | Specifies the Elasticsearch instance to use for all your queries. |
kibana.index: gateway_tenant_name_dashboard Example: "gateway_default_dashboard" | Specifies the index in Elasticsearch, which Kibana uses to store saved searches, visualizations, and dashboards. It creates a new index if it does not exist. |
You can find these values in the kibana.yml file of the internal Kibana installed location C:\API Gateway instance\profiles\IS_default\apigateway\dashboard\config. You can copy these values in the kibana.yml file of the external Kibana in the respective installed location.
If you are using a Kibana version different than the one shipped with
API Gateway that is compatible with the Elasticsearch version, you have to specify the Kibana version in the
config.json file located at
C:\API Gateway instance\IntegrationServer\instances\default\packages\WmAPIGateway\config\resources\kibana\config\7\. For details on version compatibility, see
Support Matrix.
Default Kibana connected to External Elasticsearch.
If the external Elasticsearch is used to store all API Gateway assets then configure the following:
Open the kibana.yml file located at C:\API Gateway instance\profiles\IS_default\apigateway\dashboard\config and specify the external Elasticsearch host and port details, which the Kibana has to connect to, as follows:
# The Elasticsearch instance to use for all your queries.
elasticsearch.hosts: "http://host_name:port"
If the external Elasticsearch is used to store only the analytics and the core configuration is stored in the API Gateway Data Store, then configure the following:
Copy the kibana.index (gateway_tenant-name_dashboard) from the Elasticsearch that stores the core configurations to the Elasticsearch that stores the analytics data. This can be achieved by using the reindex API. Reindex supports reindexing from a remote Elasticsearch cluster. The sample payload is as follows:
POST _reindex
{
"source": {
"remote": {
"host": "https://host:port",
"username": "username",
"password": "password"
},
"index": "gateway_tenant-name_dashboard",
},
"dest": {
"index": "gateway_target-tenant-name_dashboard"
}
}
The host parameter must contain a scheme, host, and port. The username and password parameters are optional, and when they are present _reindex connects to the remote Elasticsearch node using basic auth.
Remote hosts have to be explicitly allowed in elasticsearch.yml using the reindex.remote.whitelist property. It can be set to a comma delimited list of allowed remotehost and port combinations. Scheme is ignored, only the host and port are used. The list of allowed hosts must be configured on the target node where the index is being copied.
External Kibana connected to External Elasticsearch.