hive-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From shashwat shriparv <>
Subject Re: Hive error when running a count query.
Date Thu, 10 May 2012 17:39:01 GMT
When ever you execute any query except "select * from tablename" hive runs
mapreduce job in background for which it needs hadoop to be properly
configured and proper commication between hadoop and hive. the error you
specified happens when the hive not able to connect to hadoop properly

here is the solution you can try :

1. Chown of the hive folder
2. change permission of hive folder to 755
3. Set this to hive-site.xml

    <description>Scratch space for Hive jobs</description>

3. put


these file to hive lib folder

Define external jar in hive site xml file as follows :

IN change following:

# Set HADOOP_HOME to point to a specific hadoop install directory

#here instead of path what i have given you give your own path where
hadoop #is there
export HADOOP_HOME=/home/shashwat/Hadoop/hadoop-0.20.205

# Hive Configuration Directory can be controlled by:

#here you specify the conf directory path of hive
export HIVE_CONF_DIR=/home/shashwat/Hadoop/hive-0.7.1/conf

#Folder containing extra ibraries required for hive compilation/execution

#can be controlled by:

#here you specify the lib file directory, here you can specify the lib

#directory of hadoop lib folder too like follows:
export HIVE_AUX_JARS_PATH=/home/shashwat/Hadoop/hive-0.7.1/lib:/home/shashwat/Hadoop/hadoop-0.20.205/lib:/home/shashwat/Hadoop/hbase/lib

and also in hive-site.xml


by default if you have just downloaded the hive there will not be
hive-site.xml or by default in conf dir there will be
hive-site.xml.template and same for the so make a backupe
of both and rename hive-site.xml.template to hive-site.xml and to and make the changes what i

Note : when ever you download something and extract in linux dont
forget to change owner and change mode using chown and chmod for the
folder recursively

Hope this will help you..



Shashwat Shriparv

On Wed, May 9, 2012 at 12:49 AM, Kayla Schultz <>wrote:

> The query I'm trying to run is: select count(*) from customers;
> The table exists and there is data in it. However when I run this command
> I get the following: and the error log shows:
> Any idea what I'm doing wrong?
> Sorry about the logs being pictures, was the easiest way to copy from my
> vm.
> Kayla


Shashwat Shriparv

View raw message