Home | About | Sematext search-lucene.com search-hadoop.com
NEW: Monitor These Apps!
elasticsearch, apache solr, apache hbase, hadoop, redis, casssandra, amazon cloudwatch, mysql, memcached, apache kafka, apache zookeeper, apache storm, ubuntu, centOS, red hat, debian, puppet labs, java, senseiDB
 Search Hadoop and all its subprojects:

Switch to Threaded View
Hive >> mail # user >> create table syntax in CLI


Copy link to this message
-
Re: create table syntax in CLI
I got pass that error when I use CLI from trunk.

I copied hbase-site.xml from hbase master machine to trunk/dist/conf.

When I issue the following command in CLI:
CREATE EXTERNAL TABLE ruletable(key string, exactmatch_cat string, lpm_cat
int)
    STORED BY 'org.apache.hadoop.hive.hbase.HBaseStorageHandler'
    WITH SERDEPROPERTIES (
    "hbase.key.type" = "string",
    "hbase.columns.mapping" = "exactmatch_1.0:category,lpm_1.0:category",
    "hbase.table.name" = "ruletable"
    );

I get:

2010-03-25 15:49:52,557 WARN  client.HConnectionManager$TableServers
(HConnectionManager.java:tableExists(411)) - Testing for table existence
threw exception
org.apache.hadoop.hbase.client.RetriesExhaustedException: Trying to contact
region server 10.10.31.143:60020 for region .META.,,1, row '', but failed
after 10 attempts.
Exceptions:
java.io.IOException: Call to /10.10.31.143:60020 failed on local exception:
java.io.EOFException
java.io.IOException: Call to /10.10.31.143:60020 failed on local exception:
java.io.EOFException
java.io.IOException: Call to /10.10.31.143:60020 failed on local exception:
java.io.EOFException
java.io.IOException: Call to /10.10.31.143:60020 failed on local exception:
java.io.EOFException
java.io.IOException: Call to /10.10.31.143:60020 failed on local exception:
java.io.EOFException
java.io.IOException: Call to /10.10.31.143:60020 failed on local exception:
java.io.EOFException
java.io.IOException: Call to /10.10.31.143:60020 failed on local exception:
java.io.EOFException
java.io.IOException: Call to /10.10.31.143:60020 failed on local exception:
java.io.EOFException
java.io.IOException: Call to /10.10.31.143:60020 failed on local exception:
java.io.EOFException
java.io.IOException: Call to /10.10.31.143:60020 failed on local exception:
java.io.EOFException

        at
org.apache.hadoop.hbase.client.HConnectionManager$TableServers.getRegionServerWithRetries(HConnectionManager.java:1048)
        at
org.apache.hadoop.hbase.client.MetaScanner.metaScan(MetaScanner.java:55)
        at
org.apache.hadoop.hbase.client.MetaScanner.metaScan(MetaScanner.java:28)
        at
org.apache.hadoop.hbase.client.HConnectionManager$TableServers.listTables(HConnectionManager.java:454)
        at
org.apache.hadoop.hbase.client.HConnectionManager$TableServers.tableExists(HConnectionManager.java:404)
        at
org.apache.hadoop.hbase.client.HBaseAdmin.tableExists(HBaseAdmin.java:113)
        at
org.apache.hadoop.hbase.client.HBaseAdmin.tableExists(HBaseAdmin.java:100)
        at
org.apache.hadoop.hive.hbase.HBaseStorageHandler.preCreateTable(HBaseStorageHandler.java:149)
        at
org.apache.hadoop.hive.metastore.HiveMetaStoreClient.createTable(HiveMetaStoreClient.java:280)

However, I don't see any exception in hbase-hbaseadmin-regionserver.log on
10.10.31.143 within the past 4 hours.
No exception in hbase-hbaseadmin-master.log on hbase master machine either.

Please comment.

On Thu, Mar 25, 2010 at 11:22 AM, Carl Steinbach <[EMAIL PROTECTED]> wrote:

> Hi Ted,
>
> It looks like your copy of Hive does not have the changes that implemented
> support for integration with HBase. HBase support was committed to trunk on
> March 12th, and currently it is only available on trunk. In order to use it
> you need to  checkout (or update) the source from the svn repository.
> Instructions describing how to do this are on the Hive wiki.
>
> Carl
>
>
> On Thu, Mar 25, 2010 at 9:29 AM, Ted Yu <[EMAIL PROTECTED]> wrote:
>
>> Hi,
>> I encountered Parse Error creating table in CLI:
>>
>> [root@tyu-linux hive-0.5.0-bin]# bin/hive
>> Hive history file=/tmp/root/hive_job_log_root_201003240832_1752130264.txt
>> hive> SHOW TABLES;
>> OK
>> Time taken: 8.09 seconds
>> hive> CREATE EXTERNAL TABLE users(key string, state string, country
>> string,
>> country_id int)
>>     > STORED BY 'org.apache.hadoop.hive.hbase.HBaseStorageHandler'
>>     >
>>     > WITH SERDEPROPERTIES (
>>     >
>>     > "hbase.key.type" = "string",
>>     >
>>     > "hbase.columns.mapping" = "info:state,info:country,info:country_id",
NEW: Monitor These Apps!
elasticsearch, apache solr, apache hbase, hadoop, redis, casssandra, amazon cloudwatch, mysql, memcached, apache kafka, apache zookeeper, apache storm, ubuntu, centOS, red hat, debian, puppet labs, java, senseiDB