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

Mike Percy commented on FLUME-1027:
-----------------------------------

This is a one-line patch to include log4j in the runtime distribution. In 
trunk, due to the single line which is removed in the patch, log4j is only 
included during the test phase, which means that the flume-ng script is broken 
when run from the distribution. See the stack trace above for the error you get 
when you try to run the flume-ng script.

I didn't bother with review board due to how minimal this change is. Let me 
know if you want me to post this there.

This patch should be committed right away. Thanks!

Regards,
Mike
                
> Cannot run Flume NG from script
> -------------------------------
>
>                 Key: FLUME-1027
>                 URL: https://issues.apache.org/jira/browse/FLUME-1027
>             Project: Flume
>          Issue Type: Bug
>          Components: Node
>    Affects Versions: v1.1.0
>         Environment: [CentOS 6.2 64-bit]
>            Reporter: Will McQueen
>            Priority: Critical
>             Fix For: v1.1.0
>
>         Attachments: FLUME-1027.patch
>
>
> [will@localhost flume-1.1.0-incubating-SNAPSHOT]$ bin/flume-ng node --conf 
> conf --conf-file conf/flume-conf.properties --name foo
> Failed to instantiate SLF4J LoggerFactory
> Reported exception:
> java.lang.NoClassDefFoundError: org/apache/log4j/Level
>       at org.slf4j.LoggerFactory.bind(LoggerFactory.java:128)
>       at org.slf4j.LoggerFactory.performInitialization(LoggerFactory.java:108)
>       at org.slf4j.LoggerFactory.getILoggerFactory(LoggerFactory.java:279)
>       at org.slf4j.LoggerFactory.getLogger(LoggerFactory.java:252)
>       at org.slf4j.LoggerFactory.getLogger(LoggerFactory.java:265)
>       at org.apache.flume.node.Application.<clinit>(Application.java:52)
> Caused by: java.lang.ClassNotFoundException: org.apache.log4j.Level
>       at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
>       at java.security.AccessController.doPrivileged(Native Method)
>       at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
>       at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
>       at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
>       at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
>       ... 6 more
> Exception in thread "main" java.lang.NoClassDefFoundError: 
> org/apache/log4j/Level
>       at org.slf4j.LoggerFactory.bind(LoggerFactory.java:128)
>       at org.slf4j.LoggerFactory.performInitialization(LoggerFactory.java:108)
>       at org.slf4j.LoggerFactory.getILoggerFactory(LoggerFactory.java:279)
>       at org.slf4j.LoggerFactory.getLogger(LoggerFactory.java:252)
>       at org.slf4j.LoggerFactory.getLogger(LoggerFactory.java:265)
>       at org.apache.flume.node.Application.<clinit>(Application.java:52)
> Caused by: java.lang.ClassNotFoundException: org.apache.log4j.Level
>       at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
>       at java.security.AccessController.doPrivileged(Native Method)
>       at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
>       at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
>       at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
>       at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
>       ... 6 more
> Could not find the main class: org.apache.flume.node.Application.  Program 
> will exit.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to