FAQ
Dear Buddies,

I am running a map reduce job in a jar file through the shell like the
following:

#! /bin/sh
export HADOOP_CLASSPATH=/home/xuwh/log-fetcher.jar
export CLASSPATH=/home/xuwh/:$CLASSPATH
/opt/hadoop/bin/hadoop
com.companyname.context.processor.log.preprocessor.LogCleaner

In the LogCleaner class, besides submitting the map-reduce job, I will wait
for the job completion and send the result to a server for further
processing.

I added some logs through log4j in the log uploading part and I wanted to
receive the error logs through an SMTP appender, and I created my own
log4j.properties file in the jar contains the LogCleaner but it didn't work.

I don't want to change the log configuration in the hadoop for I have to
change the configuration in all nodes. And different map-reduce jar might
have different configuration in log4j.

Is there any way I could make the log4j code in jar file using the
log4j.properties inside the jar? Not the code in the map-reduce job, but the
code to setup the job and the code to process after the job is completed.

Thanks.

Best wishes,
Stanley Xu

Search Discussions

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupcommon-user @
categorieshadoop
postedFeb 17, '11 at 6:55a
activeFeb 17, '11 at 6:55a
posts1
users1
websitehadoop.apache.org...
irc#hadoop

1 user in discussion

Stanley Xu: 1 post

People

Translate

site design / logo © 2022 Grokbase