<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic HEC Curl Command Not Working? in Getting Data In</title>
    <link>https://community.splunk.com/t5/Getting-Data-In/HEC-Curl-Command-Not-Working/m-p/422683#M74240</link>
    <description>&lt;P&gt;Hello all! I have a weird problem occurring that I would like to get some feedback on. I currently am running a Splunk Enterprise instance on my local machine. Using the curl command and sending data via the HTTP Event Collector is given me some unexpected behavior. If I'm doing something wrong, please let me know!&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;Command #1:&lt;/STRONG&gt;&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;curl -k "https://localhost:8088/services/collector/raw?source=fakelog" -H "Authorization: Splunk fb920744-d924-413b-9c60-4593f152c3d5" -d '127.0.0.1 - admin [28/Sep/2016:09:05:26.875 -0700] "GET /servicesNS/admin/launcher/data/ui/views?count=-1 HTTP/1.0" 200 126721 - - - 6ms'
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;It gives me a {"text":"Success","code":0}; however, when I search in the main index, it does not show the log.&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;Command #2:&lt;/STRONG&gt;&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;curl -k "https://localhost:8088/services/collector/raw?source=fakelog" -H "Authorization: Splunk fb920744-d924-413b-9c60-4593f152c3d5" -d '1, 2, 3... Hello, World!'
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;It gives me {"text":Success", "code":0} and displays it in the main index.&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;Command #3:&lt;/STRONG&gt;&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;curl -k "https://localhost:8088/services/collector/raw?source=fakelog" -H "Authorization: Splunk fb920744-d924-413b-9c60-4593f152c3d5" -d '127.0.0.1 - admin "GET /servicesNS/admin/launcher/data/ui/views?count=-1 HTTP/1.0" 200 126721 - - - 6ms'
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;The difference between Command #1 and this one is the fact that I removed the timestamp. When I check Splunk, this log did come through on the main index.&lt;/P&gt;

&lt;P&gt;Does anyone know what could be happening here?&lt;/P&gt;

&lt;P&gt;Thanks!&lt;/P&gt;</description>
    <pubDate>Tue, 21 Aug 2018 17:38:37 GMT</pubDate>
    <dc:creator>thomastaylor</dc:creator>
    <dc:date>2018-08-21T17:38:37Z</dc:date>
    <item>
      <title>HEC Curl Command Not Working?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/HEC-Curl-Command-Not-Working/m-p/422683#M74240</link>
      <description>&lt;P&gt;Hello all! I have a weird problem occurring that I would like to get some feedback on. I currently am running a Splunk Enterprise instance on my local machine. Using the curl command and sending data via the HTTP Event Collector is given me some unexpected behavior. If I'm doing something wrong, please let me know!&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;Command #1:&lt;/STRONG&gt;&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;curl -k "https://localhost:8088/services/collector/raw?source=fakelog" -H "Authorization: Splunk fb920744-d924-413b-9c60-4593f152c3d5" -d '127.0.0.1 - admin [28/Sep/2016:09:05:26.875 -0700] "GET /servicesNS/admin/launcher/data/ui/views?count=-1 HTTP/1.0" 200 126721 - - - 6ms'
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;It gives me a {"text":"Success","code":0}; however, when I search in the main index, it does not show the log.&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;Command #2:&lt;/STRONG&gt;&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;curl -k "https://localhost:8088/services/collector/raw?source=fakelog" -H "Authorization: Splunk fb920744-d924-413b-9c60-4593f152c3d5" -d '1, 2, 3... Hello, World!'
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;It gives me {"text":Success", "code":0} and displays it in the main index.&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;Command #3:&lt;/STRONG&gt;&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;curl -k "https://localhost:8088/services/collector/raw?source=fakelog" -H "Authorization: Splunk fb920744-d924-413b-9c60-4593f152c3d5" -d '127.0.0.1 - admin "GET /servicesNS/admin/launcher/data/ui/views?count=-1 HTTP/1.0" 200 126721 - - - 6ms'
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;The difference between Command #1 and this one is the fact that I removed the timestamp. When I check Splunk, this log did come through on the main index.&lt;/P&gt;

&lt;P&gt;Does anyone know what could be happening here?&lt;/P&gt;

&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Tue, 21 Aug 2018 17:38:37 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/HEC-Curl-Command-Not-Working/m-p/422683#M74240</guid>
      <dc:creator>thomastaylor</dc:creator>
      <dc:date>2018-08-21T17:38:37Z</dc:date>
    </item>
    <item>
      <title>Re: HEC Curl Command Not Working?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/HEC-Curl-Command-Not-Working/m-p/422684#M74241</link>
      <description>&lt;P&gt;@thomastaylor,&lt;/P&gt;

&lt;P&gt;Just a quick check - your timestamp says &lt;CODE&gt;28/Sep/2016:09:05:26.875 -0700&lt;/CODE&gt; which is around 2 years back. Have you selected your time range in search head to cover last two years ? Select &lt;CODE&gt;All Time&lt;/CODE&gt; and check if you are able to see the event.&lt;/P&gt;</description>
      <pubDate>Wed, 22 Aug 2018 04:03:19 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/HEC-Curl-Command-Not-Working/m-p/422684#M74241</guid>
      <dc:creator>renjith_nair</dc:creator>
      <dc:date>2018-08-22T04:03:19Z</dc:date>
    </item>
    <item>
      <title>Re: HEC Curl Command Not Working?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/HEC-Curl-Command-Not-Working/m-p/422685#M74242</link>
      <description>&lt;P&gt;A bit of my pride has been taken away from me, haha. Yep, that was it. If you convert your a comment to an answer, I will certainly approve it.&lt;/P&gt;</description>
      <pubDate>Wed, 22 Aug 2018 14:55:29 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/HEC-Curl-Command-Not-Working/m-p/422685#M74242</guid>
      <dc:creator>thomastaylor</dc:creator>
      <dc:date>2018-08-22T14:55:29Z</dc:date>
    </item>
    <item>
      <title>Re: HEC Curl Command Not Working?</title>
      <link>https://community.splunk.com/t5/Getting-Data-In/HEC-Curl-Command-Not-Working/m-p/422686#M74243</link>
      <description>&lt;P&gt;@thomastaylor, glad to know it worked &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 23 Aug 2018 01:18:17 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Getting-Data-In/HEC-Curl-Command-Not-Working/m-p/422686#M74243</guid>
      <dc:creator>renjith_nair</dc:creator>
      <dc:date>2018-08-23T01:18:17Z</dc:date>
    </item>
  </channel>
</rss>

