All Apps and Add-ons

Getting response from REST API URL but Splunk log says "503 error"

FIS1
Explorer

Hi,

I installed the REST API Modular Input app and when hitting a URL it returns this output "{"status":"DOWN"}". I would expect to see this in Splunk so I can create a dashboard, but its not in there. Looking at the logs it says the below.

08-29-2017 12:12:02.948 -0500 ERROR ExecProcessor - message from "python "C:\Program Files\Splunk\etc\apps\rest_ta\bin\rest.py"" HTTP Request error: 503 Server Error: Service Unavailable

Why can I pull the URL up in the browser and it shows that status down but the log says it received a server error? This is a local install of Splunk on my computer.

0 Karma
1 Solution

Damien_Dallimor
Ultra Champion

You received a 503 error response from the server and the error message is a JSON payload.

Only non error responses (ie: 200) get indexed.

By default , the REST Mod Input will only log error messages , not index any response data associated with them.

You would have to enable indexing of error responses in your config.

alt text

View solution in original post

0 Karma

Damien_Dallimor
Ultra Champion

You received a 503 error response from the server and the error message is a JSON payload.

Only non error responses (ie: 200) get indexed.

By default , the REST Mod Input will only log error messages , not index any response data associated with them.

You would have to enable indexing of error responses in your config.

alt text

0 Karma

khnkhurshid
New Member

Damien Dallimore,

could you please elaborate where to configure this,Itried thi but getting Unexpected character while looking for value: 'h' -

0 Karma
Career Survey
First 500 qualified respondents will receive a $20 gift card! Tell us about your professional Splunk journey.

Can’t make it to .conf25? Join us online!

Get Updates on the Splunk Community!

Can’t Make It to Boston? Stream .conf25 and Learn with Haya Husain

Boston may be buzzing this September with Splunk University and .conf25, but you don’t have to pack a bag to ...

Splunk Lantern’s Guide to The Most Popular .conf25 Sessions

Splunk Lantern is a Splunk customer success center that provides advice from Splunk experts on valuable data ...

Unlock What’s Next: The Splunk Cloud Platform at .conf25

In just a few days, Boston will be buzzing as the Splunk team and thousands of community members come together ...