If you want to send data to Splunk via HTTPS, click the Enable SSL check box. Click the Enabled button for the All Tokens option. Go to Settings > Data Inputs > HTTP Event Collector > Global Settings. See the Get Metrics page in the Splunk Enterprise manual for more information. To send data with Splunk HTTP Event Collector (Splunk HEC), complete the following steps. This example demonstrates how to send JSON-formatted events with multiple metrics using HEC. The example is formatted according to the HEC event data format specification. It includes the Splunk platform instance address, port, and REST endpoint, as well as the authentication token, event data, and metadata. This example demonstrates basic HEC usage. You can use any tool or application that is compatible with the HTTP and REST specifications. There's no requirement to use the curl command to submit events to HEC. Don't use this argument in a production environment or where security is necessary. The -k argument is insecure, so don't use it to check security certificates. The header is how you include the HEC token. You must supply a header to submit events to HEC whether you use HTTP authentication or basic authentication. This argument is required when you use basic authentication. You can send raw text or text in JSON format to HEC. Use this argument to supply events to HEC. Typically, the example commands use the following arguments: The examples on this page use the curl command. You can use these examples to model how to send your own data to HEC in either Splunk Cloud Platform or Splunk Enterprise. Your decision earlier of ACK vs No ACK determines your configuration for Enable indexer acknowledgment. Next select New Token to create a new HEC endpoint and token. Choose Global Settings, ensure All tokens is enabled and then choose Save. They also show how you must send data to the HEC input. From Splunk Web, go to the Settings menu, choose Data inputs and choose HTTP Event Collector. The following examples show how you can use HEC to index streams of data. The HTTP Event Collector (HEC) input has a myriad of use cases.
0 Comments
Leave a Reply. |