Announcement Announcement Module
Collapse
No announcement yet.
problem while running hbase program Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • problem while running hbase program

    Hi Friends,
    I am having some problem while I tried to run HBase program using Spring. When I run the got the following problem.

    Code:
         ApplicationContext context = new ClassPathXmlApplicationContext("context.xml");
         FirstHbaseExample first = (FirstHbaseExample) context.getBean(FirstHbaseExample.class);
         byte[] name = Bytes.toBytes("table_12");
         Configuration config =  first.getConfiguration();
         HBaseAdmin admin = new HBaseAdmin(config);
         HTableDescriptor desc = new HTableDescriptor(name);
         HColumnDescriptor coldef1 = new HColumnDescriptor(Bytes.toBytes("colfam1"));
         desc.addFamily(coldef1);
         admin.createTable(desc);
    Code:
            <hdp:configuration>
                    fs.default.name=hdfs://paragsystem:8020
                    mapred.job.tracker=paragsystem:8021
                    hbase.rootdir=hdfs://paragsystem/hbase
            </hdp:configuration>
    
            <hdp:hbase-configuration configuration-ref="hadoopConfiguration"/>
    
            <bean id ="firstHbaseExample"   class="org.test.hbase.FirstHbaseExample">
                    <property name="configuration" ref="hbaseConfiguration"/>
            </bean>
    Code:
    2012-06-20 09:36:30,467 INFO [org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation] - <getMaster attempt 0 of 10 failed; retrying after sleep of 1000>
    java.io.IOException: Call to paragsystem/192.168.111.135:60000 failed on local exception: java.io.EOFException
            at org.apache.hadoop.hbase.ipc.HBaseClient.wrapException(HBaseClient.java:953)
            at org.apache.hadoop.hbase.ipc.HBaseClient.call(HBaseClient.java:922)
            at org.apache.hadoop.hbase.ipc.WritableRpcEngine$Invoker.invoke(WritableRpcEngine.java:150)
            at $Proxy10.getProtocolVersion(Unknown Source)
            at org.apache.hadoop.hbase.ipc.WritableRpcEngine.getProxy(WritableRpcEngine.java:183)
            at org.apache.hadoop.hbase.ipc.HBaseRPC.getProxy(HBaseRPC.java:303)
            at org.apache.hadoop.hbase.ipc.HBaseRPC.getProxy(HBaseRPC.java:280)
            at org.apache.hadoop.hbase.ipc.HBaseRPC.getProxy(HBaseRPC.java:332)
            at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.getMaster(HConnectionManager.java:642)
            at org.apache.hadoop.hbase.client.HBaseAdmin.<init>(HBaseAdmin.java:106)
            at org.springframework.data.hadoop.samples.hbase.HBaseAction.createTable(HBaseAction.java:88)
            at org.springframework.data.hadoop.samples.hbase.HBaseAction.run(HBaseAction.java:66)
            at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
            at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
            at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
            at java.lang.reflect.Method.invoke(Method.java:597)
            at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor$LifecycleElement.invoke(InitDestroyAnnotationBeanPostProcessor.java:340)
            at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor$LifecycleMetadata.invokeInitMethods(InitDestroyAnnotationBeanPostProcessor.java:293)
            at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor.postProcessBeforeInitialization(InitDestroyAnnotationBeanPostProcessor.java:130)
            atringframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyBeanPostProcessorsBeforeInitialization(AbstractAutowireCapableBeanFactory.java:393)
            at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1415)
            at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:518)
            at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:455)
            at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:293)
            at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)
            at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:290)
            at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:192)
            at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:585)
            at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:895)
            at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:425)
            at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:139)
            at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:93)
            at org.springframework.data.hadoop.samples.hbase.Main.main(Main.java:41)
    Caused by: java.io.EOFException
            at java.io.DataInputStream.readInt(DataInputStream.java:375)
            at org.apache.hadoop.hbase.ipc.HBaseClient$Connection.receiveResponse(HBaseClient.java:571)
            at org.apache.hadoop.hbase.ipc.HBaseClient$Connection.run(HBaseClient.java:505)
    2012-06-20 09:36:31,517 INFO [org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation] - <getMaster attempt 1 of 10 failed; retrying after sleep of 1000>
    java.io.IOException: Call to paragsystem/192.168.111.135:60000 failed on local exception: java.io.EOFException
            at org.apache.hadoop.hbase.ipc.HBaseClient.wrapException(HBaseClient.java:953)
            at org.apache.hadoop.hbase.ipc.HBaseClient.call(HBaseClient.java:922)
            at org.apache.hadoop.hbase.ipc.WritableRpcEngine$Invoker.invoke(WritableRpcEngine.java:150)
            at $Proxy10.getProtocolVersion(Unknown Source)
            at org.apache.hadoop.hbase.ipc.WritableRpcEngine.getProxy(WritableRpcEngine.java:183)
            at org.apache.hadoop.hbase.ipc.HBaseRPC.getProxy(HBaseRPC.java:303)
            at org.apache.hadoop.hbase.ipc.HBaseRPC.getProxy(HBaseRPC.java:280)
            at org.apache.hadoop.hbase.ipc.HBaseRPC.getProxy(HBaseRPC.java:332)
            at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.getMaster(HConnectionManager.java:642)
            at org.apache.hadoop.hbase.client.HBaseAdmin.<init>(HBaseAdmin.java:106)
            at org.springframework.data.hadoop.samples.hbase.HBaseAction.createTable(HBaseAction.java:88)
            at org.springframework.data.hadoop.samples.hbase.HBaseAction.run(HBaseAction.java:66)
            at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
            at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
            at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
            at java.lang.reflect.Method.invoke(Method.java:597)
            at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor$LifecycleElement.invoke(InitDestroyAnnotationBeanPostProcessor.java:340)
            at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor$LifecycleMetadata.invokeInitMethods(InitDestroyAnnotationBeanPostProcessor.java:293)
            at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor.postProcessBeforeInitialization(InitDestroyAnnotationBeanPostProcessor.java:130)
            atringframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyBeanPostProcessorsBeforeInitialization(AbstractAutowireCapableBeanFactory.java:393)
            at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1415)
            at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:518)
            at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:455)
            at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:293)
            at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)
            at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:290)
            at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:192)
            at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:585)
            at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:895)
            at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:425)
            at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:139)
            at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:93)
            at org.springframework.data.hadoop.samples.hbase.Main.main(Main.java:41)
    Caused by: java.io.EOFException
            at java.io.DataInputStream.readInt(DataInputStream.java:375)
            at org.apache.hadoop.hbase.ipc.HBaseClient$Connection.receiveResponse(HBaseClient.java:571)
            at org.apache.hadoop.hbase.ipc.HBaseClient$Connection.run(HBaseClient.java:505)
Working...
X