Giter VIP home page Giter VIP logo

lookup-editor_scripts's Introduction

lookup-editor_scripts

  • Simple script using splunk application lookup-editor (renamed Splunk App for Lookup File Editing ) endpoint to upload multiple lookups at once: 2022-12-24 08_37_55-Windows 10 and later x64 - VMware Workstation
  • script using splunk application lookup-editor endpoint to update part of a lookup or multiple lookups:

Example of using the -p option (can be done with multiple lookups at once)

The lookup we have on splunk search app: 2022-12-26 23_09_01-Windows 10 and later x64 - VMware Workstation

Execution of the script (script asked for input, we paste the content in the terminal and typed 'ok' to confirm (can be done on multiple lookups at once): 2022-12-26 23_10_35-Windows 10 and later x64 - VMware Workstation 2022-12-26 23_11_05-Windows 10 and later x64 - VMware Workstation

result: 2022-12-26 23_11_27-Windows 10 and later x64 - VMware Workstation


Example of using the -i option (can be done with multiple lookups at once)

The lookup we have on splunk search app:

2022-12-26 22_32_47-Windows 10 and later x64 - VMware Workstation

Execution of the script (script asked for each input, can be done on multiple lookups at once):

2022-12-26 22_56_19-Windows 10 and later x64 - VMware Workstation

result: image


Example of merging two csv files with option -f

(not limited to 2 files, we can merge demo_file_to_merge to all the lookups we want on splunk):

The lookup we have on splunk search app:

image

The csv file on our desktop we want to merge to the lookup test.csv:

2022-12-26 21_48_00-Windows 10 and later x64 - VMware Workstation

Execution of the script to merge both files:

2022-12-26 21_54_20-Windows 10 and later x64 - VMware Workstation

result:

image


Example of merging tree csv files with option -f:

The lookups we have on splunk search app:

2022-12-26 22_18_27-Windows 10 and later x64 - VMware Workstation 2022-12-26 22_18_36-Windows 10 and later x64 - VMware Workstation

The csv file on our desktop we want to merge to the lookup test.csv and test2.csv:

2022-12-26 22_22_57-Windows 10 and later x64 - VMware Workstation

Execution of the script to the files:

2022-12-26 22_25_22-Windows 10 and later x64 - VMware Workstation 2022-12-26 22_25_57-Windows 10 and later x64 - VMware Workstation 2022-12-26 22_26_08-Windows 10 and later x64 - VMware Workstation

result:

2022-12-26 22_27_01-Windows 10 and later x64 - VMware Workstation 2022-12-26 22_27_12-Windows 10 and later x64 - VMware Workstation

  • Simple script using splunk application lookup-editor endpoint to download lookup(s) from splunk:

no arguments (use default values declared in the script) 2022-12-27 19_04_48-Windows 10 and later x64 - VMware Workstation

with arguments: 2022-12-27 19_10_50-Windows 10 and later x64 - VMware Workstation

[update 2023/05] you can also check out the script https://github.com/beckyburwell/splunk_rest_upload_lookups using the same endpoint API

lookup-editor_scripts's People

Contributors

mthcht avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.