Getting Data In

HTTP event collector client AJAX error "readyState 0, status 0, statusText error"

cafissimo
Communicator

Hello,
while trying to send messages to Splunk HTTP event collector through javascript inside a web page, I sometimes get this erro:

readyState 0, status 0, statusText error

It seems, but I am not sure, that this error is related to the volume of HTTP POSTS that are concurrently made.
Is there any kind of limit to HTTP POSTS that a single HEC is able to handle at a time?
If yes, what is this limit? I cannot find a sizing guide for HECV, other than what is suggested in this page " http://dev.splunk.com/view/event-collector/SP-CAAAE73 ", but there are no clues about volumes.

Thanks in advance.

0 Karma

logloganathan
Motivator

You can override this automatic configuration by making changes to server.conf. Increasing the number of threads can increase the amount of memory that the Splunk Enterprise instance uses.

In the $SPLUNK_HOME\etc\system\local, create or edit server.conf.
In the [httpServer] stanza, set the maxThreads attribute to specify the number of threads for REST HTTP operations that Splunk Enterprise should use.
Set the maxSockets attribute to specify the number of sockets that should be available for REST HTTP operations.
Save the file.
Restart Splunk Enterprise. The changes should take effect immediately

Please find the default value
maxThreads=100000
maxSockets=50000

0 Karma

Anam
Community Manager
Community Manager

Hi logloganathan

This is an exact copy of the Splunk Documentation: https://docs.splunk.com/Documentation/Splunk/7.0.2/Troubleshooting/HTTPthreadlimitissues
You cannot copy answers from Splunk Documentation and post them as your own, that is plagiarism.

0 Karma

logloganathan
Motivator

Hi asiddique,
user don't know about the document so copied and posted here.
Any suggestion will be helpful for posting these kind of things in future.
Please provide the guidelines

0 Karma

Elsurion
Communicator

Well you should add your source to the copied section, then it would not be a problem.
This has to do with the respect of the original writer...

http://www.uticaod.com/x1177024386/Internet-Etiquette-10-Rules-of-Netiquette
Rule 2

logloganathan
Motivator

sure got it

0 Karma

livehybrid
SplunkTrust
SplunkTrust

Are you getting this error after executing an AJAX request from a click or keystroke action?
If so, are you doing a return false or e.preventDefault(); (Where e is your event).

function onClick(sender, e) {
  e.preventDefault();
  $.ajax({
    type: 'POST',
    url: 'http://yoursplunk.com:8088'
  });
}
0 Karma
Got questions? Get answers!

Join the Splunk Community Slack to learn, troubleshoot, and make connections with fellow Splunk practitioners in real time!

Meet up IRL or virtually!

Join Splunk User Groups to connect and learn in-person by region or remotely by topic or industry.

Get Updates on the Splunk Community!

Build the Future of Agentic AI: Join the Splunk Agentic Ops Hackathon

AI is changing how teams investigate incidents, detect threats, automate workflows, and build intelligent ...

[Puzzles] Solve, Learn, Repeat: Character substitutions with Regular Expressions

This challenge was first posted on Slack #puzzles channelFor BORE at .conf23, we had a puzzle question which ...

Splunk Community Badges!

  Hey everyone! Ready to earn some serious bragging rights in the community? Along with our existing badges ...