<?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 Too many opened files in Talend Studio</title>
    <link>https://community.qlik.com/t5/Talend-Studio/Too-many-opened-files/m-p/2255221#M37987</link>
    <description>This is a schema of my job:
&lt;BR /&gt;tMySqlConnection_1 ----onComponentOk----&amp;gt;&amp;nbsp;tMysqlInput_1 --row1--&amp;gt; tFlowIterator_1 --X20--&amp;gt; tFileFetch_1 ----onComponentOk----&amp;gt;
&lt;BR /&gt;(continue) -&amp;gt; tFileInputXml_1 --row2--&amp;gt; tJavaRow_1 --row3--&amp;gt; tMap_1 --main (insert)--&amp;gt; tMysqlOutput_1
&lt;BR /&gt;To put in words:
&lt;BR /&gt;Connect to the db (tMySqlConnection_1), query from the db (tMysqlInput_1).
&lt;BR /&gt;For each row (tFlowIterator_1), fetch an XML file (tFileFetch_1) and save it.
&lt;BR /&gt;Open each file (tFileInputXml_1), do some logic (tJavaRow_1, tMap_1) and insert it to a table (tMysqlOutput_1).
&lt;BR /&gt;When the iterator's parallel value was 300, I would get "too many open files exception" after &amp;lt;3000 files. When I lowered it to 20, I get the exception after 155,000 files. I have a total of ~200,000 files I need to process.
&lt;BR /&gt;I changed the Xmx to 2048, didn't help.
&lt;BR /&gt;So my questions are:
&lt;BR /&gt;1. Is there a way to enforce closing the files or have a max opened files enforced?
&lt;BR /&gt;2. Another solution is to maybe have a master job that'll run this job several times for a different batch each time
&lt;BR /&gt;Please advise, I'm stuck on this for more than a week...
&lt;BR /&gt;Thanks!</description>
    <pubDate>Wed, 08 Feb 2017 16:19:44 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2017-02-08T16:19:44Z</dc:date>
    <item>
      <title>Too many opened files</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Too-many-opened-files/m-p/2255221#M37987</link>
      <description>This is a schema of my job:
&lt;BR /&gt;tMySqlConnection_1 ----onComponentOk----&amp;gt;&amp;nbsp;tMysqlInput_1 --row1--&amp;gt; tFlowIterator_1 --X20--&amp;gt; tFileFetch_1 ----onComponentOk----&amp;gt;
&lt;BR /&gt;(continue) -&amp;gt; tFileInputXml_1 --row2--&amp;gt; tJavaRow_1 --row3--&amp;gt; tMap_1 --main (insert)--&amp;gt; tMysqlOutput_1
&lt;BR /&gt;To put in words:
&lt;BR /&gt;Connect to the db (tMySqlConnection_1), query from the db (tMysqlInput_1).
&lt;BR /&gt;For each row (tFlowIterator_1), fetch an XML file (tFileFetch_1) and save it.
&lt;BR /&gt;Open each file (tFileInputXml_1), do some logic (tJavaRow_1, tMap_1) and insert it to a table (tMysqlOutput_1).
&lt;BR /&gt;When the iterator's parallel value was 300, I would get "too many open files exception" after &amp;lt;3000 files. When I lowered it to 20, I get the exception after 155,000 files. I have a total of ~200,000 files I need to process.
&lt;BR /&gt;I changed the Xmx to 2048, didn't help.
&lt;BR /&gt;So my questions are:
&lt;BR /&gt;1. Is there a way to enforce closing the files or have a max opened files enforced?
&lt;BR /&gt;2. Another solution is to maybe have a master job that'll run this job several times for a different batch each time
&lt;BR /&gt;Please advise, I'm stuck on this for more than a week...
&lt;BR /&gt;Thanks!</description>
      <pubDate>Wed, 08 Feb 2017 16:19:44 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Too-many-opened-files/m-p/2255221#M37987</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-02-08T16:19:44Z</dc:date>
    </item>
    <item>
      <title>Re: Too many opened files</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Too-many-opened-files/m-p/2255222#M37988</link>
      <description>Hi Leeransetton,
&lt;BR /&gt;If you are on linux and have control of the machine, you could try to change ulimit to "&amp;nbsp;
&lt;FONT color="#242729"&gt;&lt;FONT face="Consolas, Menlo, Monaco, " lucida="" console=""&gt;ulimit -n "&lt;/FONT&gt;&lt;/FONT&gt;
&lt;BR /&gt;You can find more information there as well 
&lt;A href="http://stackoverflow.com/questions/4289447/java-too-many-open-files" rel="nofollow noopener noreferrer"&gt;http://stackoverflow.com/questions/4289447/java-too-many-open-files&lt;/A&gt;
&lt;BR /&gt;Tell us if it has solved your issue.
&lt;BR /&gt;Thanks,</description>
      <pubDate>Thu, 09 Feb 2017 03:11:02 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Too-many-opened-files/m-p/2255222#M37988</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-02-09T03:11:02Z</dc:date>
    </item>
    <item>
      <title>Re: Too many opened files</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Too-many-opened-files/m-p/2255223#M37989</link>
      <description>Hey Adrien,
&lt;BR /&gt;Thanks for the reply!
&lt;BR /&gt;Raised the number to 4096, but the problem persists..</description>
      <pubDate>Thu, 09 Feb 2017 16:41:18 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Too-many-opened-files/m-p/2255223#M37989</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-02-09T16:41:18Z</dc:date>
    </item>
    <item>
      <title>Re: Too many opened files</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Too-many-opened-files/m-p/2255224#M37990</link>
      <description>UPDATE:
&lt;BR /&gt;Ended up writing the job in Java becasue nothing helped..</description>
      <pubDate>Sun, 12 Feb 2017 18:04:48 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Too-many-opened-files/m-p/2255224#M37990</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-02-12T18:04:48Z</dc:date>
    </item>
  </channel>
</rss>

