Splunk Search

How to develop custom python scripts ?

sunrise
Contributor

Hi Splunkers,

I wanna develop custom python scripts as a search command whose input data is search fields,
output data is processed data by itself.

Now I have a question that what is the best way of developing custom python scripts.
I know that logger.info() method can write to python.log, but not do how to debug and so on.
Is there anything way ?

Thank you for your help.

Tags (3)
0 Karma
1 Solution

chris
Motivator

If you want to debug the running script you could use PyDev PyDev (& Eclipse ).

View solution in original post

0 Karma

chris
Motivator

If you want to debug the running script you could use PyDev PyDev (& Eclipse ).

0 Karma

sunrise
Contributor

I'm sure Pydev and eclipse environment is pretty good for remote debug.
Thank you, chris.

0 Karma

nmistry_splunk
Splunk Employee
Splunk Employee

This is a broad question. Can you elaborate on what you wan to debug? Look at other scripts under SPLUNK_HOME/etc/apps/search/bin as examples on how to.

0 Karma
Get Updates on the Splunk Community!

Detecting Remote Code Executions With the Splunk Threat Research Team

REGISTER NOWRemote code execution (RCE) vulnerabilities pose a significant risk to organizations. If ...

Observability | Use Synthetic Monitoring for Website Metadata Verification

If you are on Splunk Observability Cloud, you may already have Synthetic Monitoringin your observability ...

More Ways To Control Your Costs With Archived Metrics | Register for Tech Talk

Tuesday, May 14, 2024  |  11AM PT / 2PM ET Register to Attend Join us for this Tech Talk and learn how to ...