fping_log索引自动创建后
delay的字段类型是text,现在要修改成float,如何修改呢?我把索引删除后,都没法修改。索引数据不重要!!
{
"fping_log": {
"aliases": {},
"mappings": {
"doc": {
"properties": {
"@timestamp": {
"type": "date"
},
"@version": {
"type": "text",
"fields": {
"keyword": {
"type": "keyword",
"ignore_above": 256
}
}
},
"delay": {
"type": "text",
"fields": {
"keyword": {
"type": "keyword",
"ignore_above": 256
}
}
},
"localhost": {
"type": "text",
"fields": {
"keyword": {
"type": "keyword",
"ignore_above": 256
}
}
},
"message": {
"type": "text",
"fields": {
"keyword": {
"type": "keyword",
"ignore_above": 256
}
}
},
"remotehost": {
"type": "text",
"fields": {
"keyword": {
"type": "keyword",
"ignore_above": 256
}
}
},
"time": {
"type": "text",
"fields": {
"keyword": {
"type": "keyword",
"ignore_above": 256
}
}
}
}
}
},
"settings": {
"index": {
"creation_date": "1578896819804",
"number_of_shards": "5",
"number_of_replicas": "1",
"uuid": "ZhR0-OmyTb2U4y4flvMkuA",
"version": {
"created": "6020499"
},
"provided_name": "fping_log"
}
}
}
}
delay的字段类型是text,现在要修改成float,如何修改呢?我把索引删除后,都没法修改。索引数据不重要!!
4 个回复
zriplj
赞同来自:
设置mapping报错
Charele - Cisco4321
赞同来自:
zriplj
赞同来自:
PUT fping_log
{
"aliases": {},
"mappings": {
"doc": {
"properties": {
"delay": {
"type": "float"
},
"localhost": {
"type": "text",
"fields": {
"keyword": {
"type": "keyword",
"ignore_above": 256
}
}
},
"message": {
"type": "text",
"fields": {
"keyword": {
"type": "keyword",
"ignore_above": 256
}
}
},
"remotehost": {
"type": "text",
"fields": {
"keyword": {
"type": "keyword",
"ignore_above": 256
}
}
},
"time": {
"type": "text",
"fields": {
"keyword": {
"type": "keyword",
"ignore_above": 256
}
}
}
}
}
},
"settings": {
"index": {
"number_of_shards": "5",
"number_of_replicas": "1"
}
}
}
森 - Elasticsearch,php
赞同来自: