I need to have multiple values passed in search box in grafana application logs dashboard

1.3k Views Asked by At

I need to have multiple values passed in search box in grafana application logs dashboard. currently i am using below query to search for a keyword in logs panel.

kubernetes.namespace:$namespace AND kubernetes.pod.name:$pod AND stream:$log_stream AND message:/.*$search.*/

Datasource: Elasticsearch 7.6.1attaching image of k8s logs dashboard

This will take only single string and does not accept multiple strings. I need regex to search for anything (includes special character, alphanumeric etc) in the logs.

1

There are 1 best solutions below

1
On

Use advance variable format in the query, which is suitable for Lucene - Elasticsearch. E.g.:

${variable:lucene}

Doc: https://grafana.com/docs/grafana/latest/variables/advanced-variable-format-options/#lucene---elasticsearch