If you are running an old version of Splunk where the iplocation command does not yet exist then you have two options based on old Splunk applications which you can install and leverage their functionality:
Geo Location Lookup Script: https://splunkbase.splunk.com/app/291/
Google Maps Add-on: https://splunkbase.splunk.com/app/368/
I am on splunk 5.0,
as seen a new feature in 6.1.2 is that including IP we can get IP loaction too powered by maxmind db
so how can i generate one like that, check the below URL, i need to get data like that way