Splunk Search

restful search not working

kml_uvce
Builder

I am running this

curl -u admin:changeme -k 8089/services/search/jobs/1329299816.358/results -d output_mode=csv

and getting this error:

<?xml version='1.0' encoding='UTF-8'?>
Method Not Allowed

kamal singh bisht
Tags (2)

the_wolverine
Champion

I have to believe there are serious flaws in the documented example which use -d for setting the output_mode. In all the answers I've seen here, you have to actually use "--get" instead of "-d".

0 Karma

Damien_Dallimor
Ultra Champion

Try issuing as a GET request by using the --get flag

curl -k -u admin:changeme https://yourhost:8089/services/search/jobs/1329299816.358/results
--get -d output_mode=csv
0 Karma

kml_uvce
Builder

Yes this serch give me output on splunk ui...

kamal singh bisht
0 Karma

Damien_Dallimor
Ultra Champion

Does the command for search job you posted for that ID actually return any data ?

0 Karma

kml_uvce
Builder

This is not giving me any output

curl -k -u admin:changeme2 https://:8089/services/search/jobs/1329299816.358
/results --get -d output_mode=csv

kamal singh bisht
0 Karma
Get Updates on the Splunk Community!

Community Content Calendar, November Edition

Welcome to the November edition of our Community Spotlight! Each month, we dive into the Splunk Community to ...

October Community Champions: A Shoutout to Our Contributors!

As October comes to a close, we want to take a moment to celebrate the people who make the Splunk Community ...

Stay Connected: Your Guide to November Tech Talks, Office Hours, and Webinars!

What are Community Office Hours? Community Office Hours is an interactive 60-minute Zoom series where ...