Hi All,
Can someone explain me how to add the format byte to my index template, because i need each day change each index to specify that OUT_BYTES and IN_BYTES is a byte field, here is my template. Another, all my new template is created at 02:00, i check the server time and is ok a solution for that ?
Thank you in advance for your help
PUT _template/template1
{
"index_patterns" : ["data-"],
"order" : 0,
"settings": {
"index.refresh_interval": "10s"
},
"mappings": {
"_doc": {
"dynamic_templates": [{
"geo_fields": {
"match": "_IP_LOCATION",
"mapping": {
"type": "geo_point",
"norms": false
}
}
}, {
"ip_fields": {
"match": "IPV4",
"match_mapping_type": "string",
"mapping": {
"type": "ip",
"norms": false
}
}
}, {
"port_fields": {
"match": "*PORT",
"match_mapping_type": "long",
"mapping": {
"type": "integer",
"norms": false
}
}
}, {
"timestamp_fields": {
"match": "*timestamp",
"match_mapping_type": "string",
"mapping": {
"type": "date",
"norms": false,
"format": "D-M-YYYY, HH:mm:ss"
}
}
}, {
"bytes_fields": {
"match": "*BYTES",
"match_mapping_type": "long",
"mapping": {
"type": "integer",
"norms": false
}
}
}, {
"vlan_fields": {
"match": "VLAN",
"match_mapping_type": "long",
"mapping": {
"type": "short",
"norms": false
}
}
}, {
"tos_fields": {
"match": "TOS",
"match_mapping_type": "long",
"mapping": {
"type": "text",
"norms": false
}
}
}, {
"protocol_fields": {
"match": "PROTOCOL",
"match_mapping_type": "long",
"mapping": {
"type": "short",
"norms": false
}
}
}, {
"l7proto_fields": {
"match": "L7_PROTO",
"match_mapping_type": "long",
"mapping": {
"type": "short",
"norms": false
}
}
}, {
"pkts_fields": {
"match": "PKTS",
"match_mapping_type": "long",
"mapping": {
"type": "integer",
"norms": false
}
}
}, {
"ipprotocol_fields": {
"match": "IP_PROTOCOL_VERSION",
"match_mapping_type": "long",
"mapping": {
"type": "short",
"norms": false
}
}
}, {
"strings_as_keywords": {
"match_mapping_type": "string",
"unmatch": "IPV4",
"mapping": {
"type": "text",
"norms": false,
"fields": {
"keyword": {
"type": "keyword",
"ignore_above": 256
}
}
}
}
}]
}
}
}