All Apps and Add-ons

Plotting on Google Map based on name of place (Not IP address based)

melonman
Motivator

Hi,

I am trying to plot count data based on place (e.g. city name).
My data does not include IP address or latitude/longitude data.

Does anyone know how to plot count data based on place using Google Map apps?

Thank you in advance.

1 Solution

ziegfried
Influencer

You need to map those names to geographic locations (ie. latitude and longitude). Splunk builtin lookup mechanism is absolutely suited for such a use-case. A lookup table could look like this:

city,_geo
"City1","47.11,8.15"
"City2","28.77,7.99"
...

You can find more information on how to build lookups in Splunk here:
http://docs.splunk.com/Documentation/Splunk/4.3.3/Knowledge/Addfieldsfromexternaldatasources

You should be able to find sources for such lookups somewhere in the internet. For example this site: http://geocoder.ca/?freedata=1 provides a table with US City names and their geographic location.

Another option is to use geocoding services, but that probably requires a lot resources and will slow down the search significantly.

View solution in original post

ziegfried
Influencer

You need to map those names to geographic locations (ie. latitude and longitude). Splunk builtin lookup mechanism is absolutely suited for such a use-case. A lookup table could look like this:

city,_geo
"City1","47.11,8.15"
"City2","28.77,7.99"
...

You can find more information on how to build lookups in Splunk here:
http://docs.splunk.com/Documentation/Splunk/4.3.3/Knowledge/Addfieldsfromexternaldatasources

You should be able to find sources for such lookups somewhere in the internet. For example this site: http://geocoder.ca/?freedata=1 provides a table with US City names and their geographic location.

Another option is to use geocoding services, but that probably requires a lot resources and will slow down the search significantly.

ravindra_ap
Explorer

Hi,

Hope you are doing good..!!! Did you able to complete the script for geocoding lookup? If Yes , can you please provide more details how we can use that script in Splunk?

Many Thanks

0 Karma

melonman
Motivator

Hi ziegfried,

I was trying to write some geocoding lookup script so any place or address can be changed into _geo. (or put google map API into map module so search results of names of place/addresses can be plotted on the map)

This works pretty good for me now, so I will go with this solution.

Thank you!

0 Karma
Get Updates on the Splunk Community!

Index This | I am a number, but when you add ‘G’ to me, I go away. What number am I?

March 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with another ...

What’s New in Splunk App for PCI Compliance 5.3.1?

The Splunk App for PCI Compliance allows customers to extend the power of their existing Splunk solution with ...

Extending Observability Content to Splunk Cloud

Register to join us !   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to ...