incubator-hcatalog-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Timothy Potter <>
Subject Re: Rookie question
Date Tue, 29 Jan 2013 03:18:31 GMT
Hi Prashant,

I would cook up a shell script that sets the correct vars. Here's an
outline of what needs to be done:

export PIG_HOME to point to your Pig home directory, eg. /usr/lib/pig
export HIVE_HOME to point to your Hive home directory, eg. /usr/lib/hive
export HCAT_THRIFT_ADDRESS - should be your thrift:// metastore address

Add the HCatalog and Hive JARS to the pig.additional.jars system
property, something like this should do it:

for jar in $PIG_HOME/*.jar; do

if [ ! -e $PIG_JAR ]; then
    echo "Unable to locate Pig jar" >&2
    exit 1


# HCatalog support


export PIG_OPTS="$PIG_OPTS -Dhive.metastore.uris=$HCAT_THRIFT_ADDRESS
$PIG_HOME/bin/pig $*

Let me know if that works for you.

On Mon, Jan 28, 2013 at 7:21 PM, Prashant Kommireddi
<> wrote:
> Hi,
> I just started looking at Hcat code and had a question - how do you run a
> Pig job via command line in HCatalog? I am looking at TempletonControllerJob
> and am wondering what the args or command looks like for this Map job.
> Thanks,
> Prashant

View raw message