Ok, so i got a big problem. I wanted to change some settings in my index template.
I have a JSON template definition file which i used to import long time ago, before there was any data and dashboards. At that time this index import definition worked.
It was imported using a command like:
curl -X POST -u USERNAME:PASSWORD http://KIBANASERVER:5601/api/saved_objects/index-pattern/elastiflow-* -H "Content-Type: application/json" -H "kbn-xsrf: true" -d @/PATH/TO/elastiflow.index_pattern.json
When i tried to do the same today: i get an error: {"statusCode":400,"error":"Bad Request","message":"child "attributes" fails because ["attributes" is required]. "template" is not allowed. "settings" is not allowed. "mappings" is not allowed. "aliases" is not allowed","validation":{"source":"payload","keys":["attributes","template","settings","mappings","aliases"]}}
It seems you can't change or upload a new index pattern, as long as one exists.
So i removed my index pattern completely in Kibana, hoping that i could then import it again -> no difference.
Then i stopped logstash, removed all daily elastiflow-* indexes in Elasticsearch using Cerebro, so that all references to data were gone.
Tried to import again -> no difference (i have no idea how this is possible, what is different when i started with a new installation when it worked ???)
Creating a new index pattern without data seems also to be impossible, so i started logstash again, which luckily imported again data to Elastic. Using this new data, i could recreate the index pattern again with the same name (elastiflow-), and now my "Discover" etc seems to work again. However, NONE of my Visualisations and Dashboards work anymore !! All fail with the error "can't find index pattern elastiflow-", however, it is shown when i go to Kibana->Index Patterns.
I have no idea how to get my Dashboards working again....
When i look at a saved object of a simple counter visualisation, i see only a references to the name of the index, so i don't understand why he doesn't find this index:
{
"index": "elastiflow-",
"query": {
"query": {
"query_string": {
"query": "",
"analyze_wildcard": true
}
},
"language": "lucene"
},
"filter": []
}
{
"title": "ElastiFlow: City Count",
"type": "metric",
"params": {
"addLegend": false,
"addTooltip": true,
"fontSize": "32",
"gauge": {
"autoExtend": false,
"backStyle": "Full",
"colorSchema": "Green to Red",
"colorsRange": [
{
"from": 0,
"to": 100
}
],
"gaugeColorMode": "None",
"gaugeStyle": "Full",
"gaugeType": "Metric",
"invertColors": false,
"labels": {
"color": "black",
"show": true
},
"orientation": "vertical",
"percentageMode": false,
"scale": {
"color": "#333",
"labels": false,
"show": false,
"width": 2
},
"style": {
"bgColor": false,
"bgFill": "#000",
"fontSize": "36",
"labelColor": false,
"subText": ""
},
"type": "simple",
"useRange": false,
"verticalSplit": false
},
"handleNoResults": true,
"type": "gauge"
},
"aggs": [
{
"id": "1",
"enabled": true,
"type": "cardinality",
"schema": "metric",
"params": {
"field": "flow.geoip.city_name",
"customLabel": "Cities"
}
}
],
"listeners": {}
}