<?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>question Re: HBASE Caused by: java.io.IOException: Wrong number of partitions in keyset in Support Questions</title>
    <link>https://community.cloudera.com/t5/Support-Questions/HBASE-Caused-by-java-io-IOException-Wrong-number-of/m-p/127289#M90008</link>
    <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/627/asinghal.html" nodeid="627"&gt;@Ankit Singhal  I have updated my full driver code .Can you please have a look &lt;/A&gt; &lt;/P&gt;</description>
    <pubDate>Tue, 29 Nov 2016 17:12:01 GMT</pubDate>
    <dc:creator>sudarshankumar_</dc:creator>
    <dc:date>2016-11-29T17:12:01Z</dc:date>
    <item>
      <title>HBASE Caused by: java.io.IOException: Wrong number of partitions in keyset</title>
      <link>https://community.cloudera.com/t5/Support-Questions/HBASE-Caused-by-java-io-IOException-Wrong-number-of/m-p/127286#M90005</link>
      <description>&lt;P&gt;Hi when i create table in hbase  with pre split i get this error .
I am running this on my VM .&lt;/P&gt;&lt;P&gt;This is how i create table &lt;/P&gt;&lt;PRE&gt;  public static void main(String[] args) throws Exception {

    if (hbaseConf == null)
        hbaseConf = getHbaseConfiguration();
    String outputPath = args[2];
    hbaseConf.set("data.seperator", DATA_SEPERATOR);
    hbaseConf.set("hbase.table.name", args[0]);
    hbaseConf.setInt(MAX_FILES_PER_REGION_PER_FAMILY, 1024);

    Job job = new Job(hbaseConf);
    job.setJarByClass(HBaseBulkLoadDriver.class);
    job.setJobName("Bulk Loading HBase Table::" + args[0]);
    job.setInputFormatClass(TextInputFormat.class);
    job.setMapOutputKeyClass(ImmutableBytesWritable.class);
    job.setMapperClass(HBaseBulkLoadMapperUnzipped.class);
    job.getConfiguration().set("mapreduce.job.acl-view-job", " bigdata-project-fricadev");
    //if (HbaseBulkLoadMapperConstants.FUNDAMENTAL_ANALYTIC.equals(args[0])) {
        HTableDescriptor descriptor = new HTableDescriptor(Bytes.toBytes(args[0]));
        descriptor.addFamily(new HColumnDescriptor(COLUMN_FAMILY));
        HBaseAdmin admin = new HBaseAdmin(hbaseConf);
        byte[] startKey = new byte[16];
        Arrays.fill(startKey, (byte) 0);
        byte[] endKey = new byte[16];
        Arrays.fill(endKey, (byte) 255);
        admin.createTable(descriptor, startKey, endKey, REGIONS_COUNT);
        admin.close();
    
    FileInputFormat.setInputPaths(job, args[1]);
    FileOutputFormat.setOutputPath(job, new Path(outputPath));

    job.setMapOutputValueClass(Put.class);
    HFileOutputFormat.configureIncrementalLoad(job, new HTable(hbaseConf, args[0]));

    System.exit(job.waitForCompletion(true) ? 0 : -1);

    System.out.println("job is successfull..........");

    HBaseBulkLoad.doBulkLoad(outputPath, args[0]);

    }

&lt;/PRE&gt;&lt;P&gt;This is my exception &lt;/P&gt;&lt;PRE&gt;  java.lang.Exception: java.lang.IllegalArgumentException: Can't read partitions file
     at org.apache.hadoop.mapred.LocalJobRunner$Job.run(LocalJobRunner.java:406)
  Caused by: java.lang.IllegalArgumentException: Can't read partitions file
     at org.apache.hadoop.mapreduce.lib.partition.TotalOrderPartitioner.setConf(TotalOrderPartitioner.java:108)
     at org.apache.hadoop.util.ReflectionUtils.setConf(ReflectionUtils.java:73)
     at org.apache.hadoop.util.ReflectionUtils.newInstance(ReflectionUtils.java:133)
     at org.apache.hadoop.mapred.MapTask$NewOutputCollector.&amp;lt;init&amp;gt;(MapTask.java:587)
     at org.apache.hadoop.mapred.MapTask.runNewMapper(MapTask.java:656)
     at org.apache.hadoop.mapred.MapTask.run(MapTask.java:330)
     at org.apache.hadoop.mapred.LocalJobRunner$Job$MapTaskRunnable.run(LocalJobRunner.java:268)
     at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
     at java.util.concurrent.FutureTask.run(FutureTask.java:262)
     at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
     at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
     at java.lang.Thread.run(Thread.java:745)
  Caused by: java.io.IOException: Wrong number of partitions in keyset
     at org.apache.hadoop.mapreduce.lib.partition.TotalOrderPartitioner.setConf(TotalOrderPartitioner.java:82)
     ... 11 more
  16/11/28 22:13:41 INFO mapred.JobClient:  map 0% reduce 0%
  16/11/28 22:13:41 INFO mapred.JobClient: Job complete: job_local1390185166_0001
  16/11/28 22:13:41 INFO mapred.JobClient: Counters: 0
  Job failed...&lt;/PRE&gt;</description>
      <pubDate>Tue, 29 Nov 2016 16:31:33 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/HBASE-Caused-by-java-io-IOException-Wrong-number-of/m-p/127286#M90005</guid>
      <dc:creator>sudarshankumar_</dc:creator>
      <dc:date>2016-11-29T16:31:33Z</dc:date>
    </item>
    <item>
      <title>Re: HBASE Caused by: java.io.IOException: Wrong number of partitions in keyset</title>
      <link>https://community.cloudera.com/t5/Support-Questions/HBASE-Caused-by-java-io-IOException-Wrong-number-of/m-p/127287#M90006</link>
      <description>&lt;P&gt;Are you specifying number of reducers for the job not equal to the no. of regions in your table?&lt;/P&gt;</description>
      <pubDate>Tue, 29 Nov 2016 17:02:52 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/HBASE-Caused-by-java-io-IOException-Wrong-number-of/m-p/127287#M90006</guid>
      <dc:creator>asinghal</dc:creator>
      <dc:date>2016-11-29T17:02:52Z</dc:date>
    </item>
    <item>
      <title>Re: HBASE Caused by: java.io.IOException: Wrong number of partitions in keyset</title>
      <link>https://community.cloudera.com/t5/Support-Questions/HBASE-Caused-by-java-io-IOException-Wrong-number-of/m-p/127288#M90007</link>
      <description>&lt;P&gt;No i have not specified anywhere this .&lt;/P&gt;</description>
      <pubDate>Tue, 29 Nov 2016 17:07:48 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/HBASE-Caused-by-java-io-IOException-Wrong-number-of/m-p/127288#M90007</guid>
      <dc:creator>sudarshankumar_</dc:creator>
      <dc:date>2016-11-29T17:07:48Z</dc:date>
    </item>
    <item>
      <title>Re: HBASE Caused by: java.io.IOException: Wrong number of partitions in keyset</title>
      <link>https://community.cloudera.com/t5/Support-Questions/HBASE-Caused-by-java-io-IOException-Wrong-number-of/m-p/127289#M90008</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/627/asinghal.html" nodeid="627"&gt;@Ankit Singhal  I have updated my full driver code .Can you please have a look &lt;/A&gt; &lt;/P&gt;</description>
      <pubDate>Tue, 29 Nov 2016 17:12:01 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/HBASE-Caused-by-java-io-IOException-Wrong-number-of/m-p/127289#M90008</guid>
      <dc:creator>sudarshankumar_</dc:creator>
      <dc:date>2016-11-29T17:12:01Z</dc:date>
    </item>
    <item>
      <title>Re: HBASE Caused by: java.io.IOException: Wrong number of partitions in keyset</title>
      <link>https://community.cloudera.com/t5/Support-Questions/HBASE-Caused-by-java-io-IOException-Wrong-number-of/m-p/127290#M90009</link>
      <description>&lt;P&gt;I have 95 Live Nodes in my cluster and REGIONS_COUNT i am passing as 90&lt;/P&gt;</description>
      <pubDate>Tue, 29 Nov 2016 17:17:12 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/HBASE-Caused-by-java-io-IOException-Wrong-number-of/m-p/127290#M90009</guid>
      <dc:creator>sudarshankumar_</dc:creator>
      <dc:date>2016-11-29T17:17:12Z</dc:date>
    </item>
    <item>
      <title>Re: HBASE Caused by: java.io.IOException: Wrong number of partitions in keyset</title>
      <link>https://community.cloudera.com/t5/Support-Questions/HBASE-Caused-by-java-io-IOException-Wrong-number-of/m-p/127291#M90010</link>
      <description>&lt;P&gt;I don't see much problem with the code. can you try adding a debug point in TotalOrderPartitioner.setConf() // line 88 or something and see why split points are different while reading from partition file.&lt;/P&gt;</description>
      <pubDate>Tue, 29 Nov 2016 17:42:52 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/HBASE-Caused-by-java-io-IOException-Wrong-number-of/m-p/127291#M90010</guid>
      <dc:creator>asinghal</dc:creator>
      <dc:date>2016-11-29T17:42:52Z</dc:date>
    </item>
    <item>
      <title>Re: HBASE Caused by: java.io.IOException: Wrong number of partitions in keyset</title>
      <link>https://community.cloudera.com/t5/Support-Questions/HBASE-Caused-by-java-io-IOException-Wrong-number-of/m-p/127292#M90011</link>
      <description>&lt;P&gt;We got this exception after migrating one table from another cluster. Root cause was duplicate region created with the same start-key and end-key.&lt;/P&gt;</description>
      <pubDate>Sun, 01 Jan 2017 12:18:18 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/HBASE-Caused-by-java-io-IOException-Wrong-number-of/m-p/127292#M90011</guid>
      <dc:creator>ranjithap7576</dc:creator>
      <dc:date>2017-01-01T12:18:18Z</dc:date>
    </item>
    <item>
      <title>Re: HBASE Caused by: java.io.IOException: Wrong number of partitions in keyset</title>
      <link>https://community.cloudera.com/t5/Support-Questions/HBASE-Caused-by-java-io-IOException-Wrong-number-of/m-p/127293#M90012</link>
      <description>&lt;P&gt;&lt;A rel="user" href="https://community.cloudera.com/users/14847/ranjithap7576.html" nodeid="14847"&gt;@Ranjith Uthaman&lt;/A&gt; What did you do to solve the issue? I have exported the HBase table data from one cluster. I am creating hfiles from the exported data and getting this error. Please help.&lt;/P&gt;</description>
      <pubDate>Thu, 11 Apr 2019 20:28:36 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/HBASE-Caused-by-java-io-IOException-Wrong-number-of/m-p/127293#M90012</guid>
      <dc:creator>vijayinani</dc:creator>
      <dc:date>2019-04-11T20:28:36Z</dc:date>
    </item>
    <item>
      <title>Re: HBASE Caused by: java.io.IOException: Wrong number of partitions in keyset</title>
      <link>https://community.cloudera.com/t5/Support-Questions/HBASE-Caused-by-java-io-IOException-Wrong-number-of/m-p/284023#M210962</link>
      <description>&lt;P&gt;Hi Vijay.. did u solve this issue? I am having same exception . kindly share .&lt;/P&gt;</description>
      <pubDate>Tue, 26 Nov 2019 03:20:35 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Support-Questions/HBASE-Caused-by-java-io-IOException-Wrong-number-of/m-p/284023#M210962</guid>
      <dc:creator>anirban</dc:creator>
      <dc:date>2019-11-26T03:20:35Z</dc:date>
    </item>
  </channel>
</rss>

