Deployment Architecture

GEOIP - Is there a step by step guide to getting this set up?

mlines123
New Member

I am presently running Splunk Free on my home network, collecting syslog data from my Sophos UTM. I'd like the ability to translate srcip and dstip fields in the firewall data into country names so that I can do searches and pivots however I'm looking for a step by step guide to getting this setup. Splunk is running on Ubuntu Server in a ESX VM. Have anyone put something like this together?

0 Karma
1 Solution

skoelpin
SplunkTrust
SplunkTrust

You have to use either lat/long or iplocaton before using the geostats command.

An example would be

index=firewall | iplocation srcip | geostats count by Country

You then need to select the Geolocation visualization to see it plotted on a world map

You may want to specify a certain bubble size based on the number of hits from that ip, so you could do

index=firewall | iplocation srcip | geostats count by Country | eval redCount = if(TOTAL >= 500,TOTAL,0) | eval yellowCount = if((TOTAL >= 300 AND TOTAL < 500),TOTAL,0) | eval greenCount = if(TOTAL < 300,TOTAL,0) | fields - TOTAL

You can also specify by city and state

index=firewall | iplocation srcip | geostats count by City
index=firewall | iplocation srcip | geostats count by State

View solution in original post

mlines123
New Member

Perfect, just what I needed. Thank you

0 Karma

skoelpin
SplunkTrust
SplunkTrust

You have to use either lat/long or iplocaton before using the geostats command.

An example would be

index=firewall | iplocation srcip | geostats count by Country

You then need to select the Geolocation visualization to see it plotted on a world map

You may want to specify a certain bubble size based on the number of hits from that ip, so you could do

index=firewall | iplocation srcip | geostats count by Country | eval redCount = if(TOTAL >= 500,TOTAL,0) | eval yellowCount = if((TOTAL >= 300 AND TOTAL < 500),TOTAL,0) | eval greenCount = if(TOTAL < 300,TOTAL,0) | fields - TOTAL

You can also specify by city and state

index=firewall | iplocation srcip | geostats count by City
index=firewall | iplocation srcip | geostats count by State

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 ...