Splunk Search

Search on Google Maps App

appleman
Contributor

下記のGoogle mapsでのサーチ文でそれぞれカウント数が違うのですが、この二つのサーチでカウントしているものの違いを詳しく教えて頂けますでしょうか。
ちなみに、ここで使っているログにはclientipはなく、latとlngがすでに定義されているので、これをGoogle Maps上でカウントすると、geo_positionというフィールドがでてくるのですが、これを使ってより簡単に地図上にマッピングする方法はありますでしょうか。

Search 1: sourcetype=external lat=* lng=* | stats count by lat lng | eval _geo=lat+","+lng

Search 2: sourcetype=external lat=* lng=* | stats count by lat lng | eval _geo=lat+","+lng | eval _geo_count=count

Hello.

I've just started using Google Maps. I made these searches but the results are different.
Can anybody tell me what is counted on my each search?
The log data doesn't have "clientip" field, but it does have "lat" and "lng" fields.
So I counted (stats count) lat and lng on google map, and as a result, "geo_position" field came out on a table.
Is there any way to put location on google map by using geo__position field?

Thank you.

Tags (3)
0 Karma
1 Solution

bananaman
Path Finder

既にお試しかも知れませんが。。。
より簡単に地図上へマッピングするということでしたら、"lat"及び"lng"フィールドの値を自動的に"_geo"としてマージする"geonormalize"はいかがでしょうか?

sourcetype=external | geonormalize

以下、やや類似のアンサーがありますのでご参考まで。

http://answers.splunk.com/answers/84671/google-maps-query-not-working

View solution in original post

bananaman
Path Finder

既にお試しかも知れませんが。。。
より簡単に地図上へマッピングするということでしたら、"lat"及び"lng"フィールドの値を自動的に"_geo"としてマージする"geonormalize"はいかがでしょうか?

sourcetype=external | geonormalize

以下、やや類似のアンサーがありますのでご参考まで。

http://answers.splunk.com/answers/84671/google-maps-query-not-working

appleman
Contributor

ご回答ありがとうございます。では、Search 2のほうが正確なマッピングのカウントと考えてよろしいでしょうか。
ちなみに、"geonormalize"を使用してサーチをしたのですが、結果がSearch 2と違う数字がでてきたのですが、この違いは何でしょうか。

0 Karma

splunkbase_japa
Splunk Employee
Splunk Employee

補足:

Search 1は stats count by lat lng の結果のcountがいくつであっても、lat-lng(_geo)ごとに1件と地図上ではカウントされますので、stats countのcountは反映されていません。

Search 2は stats count by lat lng の結果のcountを地図上のlat-lng(_geo)上にプロット(_geo_count)するので、地図上での数値はstats countの値になります。

0 Karma
Get Updates on the Splunk Community!

.conf24 | Registration Open!

Hello, hello! I come bearing good news: Registration for .conf24 is now open!   conf is Splunk’s rad annual ...

ICYMI - Check out the latest releases of Splunk Edge Processor

Splunk is pleased to announce the latest enhancements to Splunk Edge Processor.  HEC Receiver authorization ...

Introducing the 2024 SplunkTrust!

Hello, Splunk Community! We are beyond thrilled to announce our newest group of SplunkTrust members!  The ...