File tree 1 file changed +35
-0
lines changed
1 file changed +35
-0
lines changed Original file line number Diff line number Diff line change
1
+ ```
2
+ PUT _template/template_geoip
3
+ {
4
+ "index_patterns": ["filebeat-*"],
5
+ "settings": {
6
+ "number_of_shards": 3,
7
+ "index.lifecycle.name": "delete_1h",
8
+ "codec": "best_compression",
9
+ "refresh_interval": "5m",
10
+ "number_of_replicas": "0"
11
+ },
12
+ "mappings": {
13
+ "properties": {
14
+ "@timestamp" : {
15
+ "type": "date"
16
+ },
17
+ "@version" : {
18
+ "type": "keyword"
19
+ },
20
+ "geoip.geo": {
21
+ "dynamic": true,
22
+ "properties": {
23
+ "location": {
24
+ "type": "geo_point"
25
+ }
26
+ }
27
+ }
28
+ }
29
+ }
30
+ }
31
+ ```
32
+ ` number_of_shards : 3 ` chia đều ra 3 node
33
+ ` "refresh_interval": "5m" ` 5m sẽ set index
34
+ ` "number_of_replicas": "0" ` replicas bằng 0 lên để 1
35
+ field vào ` geoip.geo ` và ` location ` mapping thành ` geoip.geo.location ` với value là ` geo_point `
You can’t perform that action at this time.
0 commit comments