accumulo-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Josh Elser (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (ACCUMULO-3952) bin/accumulo should verify log4j.jar was found
Date Mon, 03 Aug 2015 22:03:05 GMT

    [ https://issues.apache.org/jira/browse/ACCUMULO-3952?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14652633#comment-14652633
] 

Josh Elser commented on ACCUMULO-3952:
--------------------------------------

bq. Should there be an error if the script is unable to check the well-known directory for
the jar in question, but it doesn't matter because all the necessary classes are in a jar
in CLASSPATH already when the script is launched?

I didn't think we supported users setting CLASSPATH and then calling Accumulo scripts. If
that does work, it's news to me and I would call it an undocumented/subject-to-change feature.

bq. How much of a problem is it that the jars aren't in the expected directory? Is it always
a "fail loudly" situation, or only if CLASSPATH is empty when the script starts?

Very much of a problem? It's a fail very poorly situation if the log4j jar can't be found.
I had to try very had to get a stacktrace.

bq. How much checking can we actually do to ensure the classpath is properly set up before
the JVM launches and it tries to load a class?

I think it's very trivial to check the "start" classpath (slf4j and log4j) which is all I
intended to check. Maybe accumulo-start too?

> bin/accumulo should verify log4j.jar was found
> ----------------------------------------------
>
>                 Key: ACCUMULO-3952
>                 URL: https://issues.apache.org/jira/browse/ACCUMULO-3952
>             Project: Accumulo
>          Issue Type: Improvement
>          Components: scripts
>    Affects Versions: 1.6.0, 1.6.1, 1.6.2, 1.6.3, 1.7.0
>            Reporter: Josh Elser
>            Assignee: Josh Elser
>             Fix For: 1.6.4, 1.7.1, 1.8.0
>
>
> Just spent a few hours trying to wrangle this one down. Ambari was failing to start all
Accumulo components. After digging in, I realized that when Ambari was invoking {{accumulo}},
it was failing to find the log4j jar.
> It turns out this was a deployment issue where the home directory for the {{accumulo}}
user was never created and the find command failed:
> {noformat}
> find: cannot stat current directory: Permission denied
> {noformat}
> Sadly, I couldn't find this error until I manually edited the accumulo script to remove
the {{2>/dev/null}} redirect. We should have been able to realize that we never found the
log4j jar and then clearly printed an error and exited instead of leading me on a goosechase
by silently proceeding.
> Same goes for the slf4j jars.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message