Splunk Search

Outuplookup update fields other than primary key

karthikmalla
Explorer

I am using | from datamodel:somedatamodel | fields username, IPaddress | outputlookup append=true filename.csv to append the data. Username is always unique but IPaddress changes based on what computer user logins from.

The method I am using is creating duplicate usernames and IP addresses. I can't use append=false because that will delete old data (if users didn't login according to the cron time schedule). I need a way not to delete existing usernames but just update the IP address of the username (without appending additional rows with the same username).

Is there a way to do this? Thanks

0 Karma

nikita_p
Contributor

Hi @karthikmalla,
Can you try summary index to update the IP address of the username. Because lookup will die at some time but in summary index you can save it for as much time you want to.
For summary index you will just have to create a search which will save data in other index which will provide you your desired data.
You can configure summary index with the help of below splunk docs.
http://docs.splunk.com/Documentation/Splunk/7.0.1/Knowledge/Configuresummaryindexes

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

Splunk is officially part of Cisco

Revolutionizing how our customers build resilience across their entire digital footprint.   Splunk ...

Splunk APM & RUM | Planned Maintenance March 26 - March 28, 2024

There will be planned maintenance for Splunk APM and RUM between March 26, 2024 and March 28, 2024 as ...