Splunk Search

Read character data where <results> or <response> was expected

Skrub
New Member

Hi

I'm using .Net (Splunk.Client) to search splunk data (firewall logs). Code is similar to this:

 

 

using (SearchResultStream stream = await service.SearchOneShotAsync(search))
{
  foreach (SearchResult searchResult in stream)
  {
     string src_ip = searchResult.GetValue(searchResult.FieldNames[0]);
     string dst_ip = searchResult.GetValue(searchResult.FieldNames[1]);
     string port = searchResult.GetValue(searchResult.FieldNames[2]);
     string protocol = searchResult.GetValue(searchResult.FieldNames[3]);
     result += src_ip + "," + dst_ip + "," + port + "," + protocol + "\r\n";
   }
Console.WriteLine("\r\n");
}

 

 

My query takes the expected time to complete (around 75 minutes) but when parsing the result it throws an exception: "Read character data where <results> or <response> was expected".

I'm using the same query string on different search indexes. Only one of them fails, the others are working just fine.

Any idea what could be causing this? What's the meaning of this error? Can't find it documented anywhere.

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