Splunk Search

geoip lookup script fails with error code 1

responsys_cm
Builder

I'm trying to use the geoip external lookup script, the one that uses the MAXMIND database.

When I run my search, I get the "Script for lookup table 'geoip' returned error code 1. Results may be incorrect."

The search is:

sourcetype=logentry action=login NOT accountname=SysAdmin NOT accountname=ops* NOT username=SYS* NOT src_ip=NULL NOT src_ip=10.* | stats count by accountname,src_ip,username | lookup geoip clientip AS src_ip OUTPUT client_country client_org

I get the same error if I remove the stats command from the pipeline. I can pipe that to something like | search NOT client_country=* to try and find the first result that had a failed lookup. But if I then narrow the initial search to capture that event, it will do the resolution fine.

How can I troubleshoot this? We have a fair number of scheduled searches that do geoip lookups. What happens if two searches try and execute that python script at the same time? It seems to me that the problem happens when the volume of events in the search results are high rather than some kind of bad data screwing up the script.

I'm on Splunk 4.3.2, build 123586.

Thx.

C

Tags (2)

cramasta
Builder

what happens if you run

sourcetype=logentry action=login NOT accountname=SysAdmin NOT accountname=ops NOT username=SYS NOT src_ip=NULL NOT src_ip=10.* | stats count by accountname,src_ip,username | lookup local=true geoip clientip AS src_ip OUTPUT client_country client_org

0 Karma

mlulmer
Explorer

It sounds like you are using distributed search. It seems that the app needs to be installed on all the indexers as well. Please also reference the following link: http://splunk-base.splunk.com/answers/75598/google-maps-where-to-install

0 Karma

responsys_cm
Builder

Nope... not using distributed search.

0 Karma
Got questions? Get answers!

Join the Splunk Community Slack to learn, troubleshoot, and make connections with fellow Splunk practitioners in real time!

Meet up IRL or virtually!

Join Splunk User Groups to connect and learn in-person by region or remotely by topic or industry.

Get Updates on the Splunk Community!

Event Series: Splunk Observability Metrics Cost Optimization

Balancing Scale and Spend: Gaining Control Over High-Volume Metrics in Splunk Observability Cloud As ...

Kick the Tires Before You Commit: A Hands-On Tour of the Splunk Observability Cloud ...

Evaluating an enterprise observability platform usually goes like this: fill out a form, get a free trial with ...

Deep insights, no barriers: Splunk Observability Cloud Free Edition

As software delivery cycles continue to accelerate, observability shouldn’t be a luxury — it should be a ...