-
Notifications
You must be signed in to change notification settings - Fork 80
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
GeoIP stopped working as before 😕 #184
Comments
I meet this problem too! Please resolve it,thanks! es logs are as below:
|
What version of the geoip are you using? (you can find with |
@jsvd The version which is bundled with Logstash 7.12.1 DEB package ... |
But It's happening about 3 months as I said above. I've created this issues when I found out that nobody cares (so maybe nobody knows about the potential bug or smth is wrong in my deployement) |
I'm trying to replicate on my side. Here's a few tests:
Logstash command used for both:
No indexing issues, mapping of the "geoip.ip" field remained type "ip":
✅ template correct, both documents indexed
then
✅ template correct, both documents indexed From there I can't replicate the template change of client.ip from "ip" to "text". is there sample data or documents that can be shared here? Are you able to replicate with a few curl requests or logstash configurations? |
The version of this plugin is also logstash configuration is as blew:
Test data
Error comes again
Check template is ok curl -k -s -XGET 'https://127.0.0.1:9200/logstash-*/_mapping' | jq ".\"logstash-log-2021.05\".mappings.properties.geoip.properties.ip"
{
"type": "ip"
} Template full {
"mappings" : {
"dynamic_templates" : [
{
"message_field" : {
"path_match" : "message",
"match_mapping_type" : "string",
"mapping" : {
"norms" : false,
"type" : "text"
}
}
},
{
"string_fields" : {
"match" : "*",
"match_mapping_type" : "string",
"mapping" : {
"fields" : {
"keyword" : {
"ignore_above" : 256,
"type" : "keyword"
}
},
"norms" : false,
"type" : "text"
}
}
}
],
"properties" : {
"@timestamp" : {
"type" : "date"
},
"@version" : {
"type" : "keyword"
},
"geoip" : {
"dynamic" : "true",
"properties" : {
"ip" : {
"type" : "ip"
},
"latitude" : {
"type" : "half_float"
},
"location" : {
"type" : "geo_point"
},
"longitude" : {
"type" : "half_float"
}
}
}
}
}
} |
This may be related to a change in the ES output related to the handling of the document_type logstash-plugins/logstash-output-elasticsearch#994 Can y'all confirm that you're explicitly setting |
After i remove the document_type setting, it works, thanks! |
I do not have explicitly set
I have trouble trying inline logstash filter bcs SSL and auth so I haven't tried that. If it's necessary I can try that but I need a bit of help with multiple options in inline filter definition. |
The elasticsearch output plugin gives mi this mapping (copied from kibana) ... no
|
@dusatvoj in ES 7.x the type won't be included in the response unless
|
So you mean output like this? https://pastebin.com/nmhpxdFX
|
Thank you can you also obtain the template with the type? e.g.
|
@jsvd
|
@dusatvoj This issue will be transferred to elasticsearch-output as the problem is not related to geoip-filter. geoip-filter gives location details of the IP address and keeps the output |
@kaisecheng ok, thank you for info |
new issue created logstash-plugins/logstash-output-elasticsearch#1050 |
Logstash information:
Please include the following information:
bin/logstash --version
) 7.12.1JVM (e.g.
java -version
): java 11.0.11If the affected version of Logstash is 7.9 (or earlier), or if it is NOT using the bundled JDK or using the 'no-jdk' version in 7.10 (or higher), please provide the following information:
java -version
)JAVA_HOME
environment variable if set.... I'm using Debian repo's openjdk-11
OS version (
uname -a
if on a Unix-like system): Linux elk-node-1 4.19.0-16-amd64 #1 SMP Debian 4.19.181-1 (2021-03-19) x86_64 GNU/LinuxDescription of the problem including expected versus actual behavior:
I have problem that cca 1/4 events from apache / nginx / haproxy have tag
_geoip_lookup_failure
(some of them are RFC 1918 IPs) but the rest of events not have that tag. Below is image of Index pattern data with data types. In past (I think ~3 months ago) there were different types of some fields (geoip.ip
changed fromip
totext
andgeoip.location
changed fromgeo_point
intoobject
). This behavior causesField type conflict
... Due toField type conflict
I can't load map layer and even on new index patterns (eg. I've recently added new haproxy into different space and pattern) I can't create map layers bcs of wrong field type for geoip mappingMy logstash setup (only these basic fields related to geoip plugin:
Expected behavior is "no change of datatype" and "working out of the box as before"
Steps to reproduce:
Provide logs (if relevant):
N/A 😕
The text was updated successfully, but these errors were encountered: