<?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 Why do writes to KV Store fail? in Knowledge Management</title>
    <link>https://community.splunk.com/t5/Knowledge-Management/Why-do-writes-to-KV-Store-fail/m-p/240884#M2117</link>
    <description>&lt;P&gt;I've been trying to write to about 900k records to a KV Store using the Splunk SPL and it only partially succeeds.  Looking at search.log for the attempted input, I get the following errors:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;11-19-2015 10:40:42.697 INFO  DispatchThread - Disk quota = 10485760000
11-19-2015 10:47:04.202 ERROR KVStorageProvider - An error occurred during the last operation ('saveBatchData', domain: '2', code: '4'):     Failed to read 4 bytes from socket within 300000 milliseconds.
11-19-2015 10:47:04.226 ERROR KVStoreLookup - KV Store output failed with code -1 and message '[ "{ \"ErrorMessage\" : \"Failed to read     4 bytes from socket within 300000 milliseconds.\" }" ]'
11-19-2015 10:47:04.226 ERROR SearchResults - An error occurred while saving to the KV Store. Look at search.log for more information.
11-19-2015 10:47:04.226 ERROR outputcsv - An error occurred during outputlookup, managed to write 598001 rows
11-19-2015 10:47:04.226 ERROR outputcsv - Error in 'outputlookup' command: Could not append to collection 'Incident_Collection': An error occurred while saving to the KV Store. Look at search.log for more information..
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;I've tried inputting from search results and tried inputting from a .csv file using &lt;CODE&gt;outputlookup&lt;/CODE&gt;, but both give these errors.  I've also restarted both Splunk and the server that Splunk runs on.  This is a standalone indexer/search head and there is no other search activity going on at the time.  The mongod.log file shows no errors.  &lt;/P&gt;

&lt;P&gt;Any ideas?&lt;/P&gt;</description>
    <pubDate>Thu, 19 Nov 2015 17:14:24 GMT</pubDate>
    <dc:creator>wpreston</dc:creator>
    <dc:date>2015-11-19T17:14:24Z</dc:date>
    <item>
      <title>Why do writes to KV Store fail?</title>
      <link>https://community.splunk.com/t5/Knowledge-Management/Why-do-writes-to-KV-Store-fail/m-p/240884#M2117</link>
      <description>&lt;P&gt;I've been trying to write to about 900k records to a KV Store using the Splunk SPL and it only partially succeeds.  Looking at search.log for the attempted input, I get the following errors:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;11-19-2015 10:40:42.697 INFO  DispatchThread - Disk quota = 10485760000
11-19-2015 10:47:04.202 ERROR KVStorageProvider - An error occurred during the last operation ('saveBatchData', domain: '2', code: '4'):     Failed to read 4 bytes from socket within 300000 milliseconds.
11-19-2015 10:47:04.226 ERROR KVStoreLookup - KV Store output failed with code -1 and message '[ "{ \"ErrorMessage\" : \"Failed to read     4 bytes from socket within 300000 milliseconds.\" }" ]'
11-19-2015 10:47:04.226 ERROR SearchResults - An error occurred while saving to the KV Store. Look at search.log for more information.
11-19-2015 10:47:04.226 ERROR outputcsv - An error occurred during outputlookup, managed to write 598001 rows
11-19-2015 10:47:04.226 ERROR outputcsv - Error in 'outputlookup' command: Could not append to collection 'Incident_Collection': An error occurred while saving to the KV Store. Look at search.log for more information..
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;I've tried inputting from search results and tried inputting from a .csv file using &lt;CODE&gt;outputlookup&lt;/CODE&gt;, but both give these errors.  I've also restarted both Splunk and the server that Splunk runs on.  This is a standalone indexer/search head and there is no other search activity going on at the time.  The mongod.log file shows no errors.  &lt;/P&gt;

&lt;P&gt;Any ideas?&lt;/P&gt;</description>
      <pubDate>Thu, 19 Nov 2015 17:14:24 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Knowledge-Management/Why-do-writes-to-KV-Store-fail/m-p/240884#M2117</guid>
      <dc:creator>wpreston</dc:creator>
      <dc:date>2015-11-19T17:14:24Z</dc:date>
    </item>
    <item>
      <title>Re: Why do writes to KV Store fail?</title>
      <link>https://community.splunk.com/t5/Knowledge-Management/Why-do-writes-to-KV-Store-fail/m-p/240885#M2118</link>
      <description>&lt;P&gt;I should mention that it does write some of the records to the kvstore.  The last time I attempted this, it wrote about 650k of the 900k records to the store.  I tried reducing the amount of records being input to about 150k and it failed after about 110k records.&lt;/P&gt;</description>
      <pubDate>Thu, 19 Nov 2015 17:47:24 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Knowledge-Management/Why-do-writes-to-KV-Store-fail/m-p/240885#M2118</guid>
      <dc:creator>wpreston</dc:creator>
      <dc:date>2015-11-19T17:47:24Z</dc:date>
    </item>
    <item>
      <title>Re: Why do writes to KV Store fail?</title>
      <link>https://community.splunk.com/t5/Knowledge-Management/Why-do-writes-to-KV-Store-fail/m-p/240886#M2119</link>
      <description>&lt;P&gt;For anyone interested, I got this working.  The disk that Splunk was writing to was extremely fragmented.  I cleaned the collection with a &lt;CODE&gt;splunk clean kvstore ...&lt;/CODE&gt; command, defragmented the disk and tried again.  This time it worked like a charm.&lt;/P&gt;</description>
      <pubDate>Thu, 19 Nov 2015 18:52:31 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Knowledge-Management/Why-do-writes-to-KV-Store-fail/m-p/240886#M2119</guid>
      <dc:creator>wpreston</dc:creator>
      <dc:date>2015-11-19T18:52:31Z</dc:date>
    </item>
  </channel>
</rss>

