Hi Mark,
Some of the jars are missing in lib. now i am able to run the agent. I am
able to get time stamp buckets and host buckets get created in HDFS.
Config:
================
agent1Test1.sources.seqGenSrc.interceptors = hostInterceptor
agent1Test1.sources.seqGenSrc.interceptors.hostInterceptor.type =
org.apache.flume.interceptor.HostInterceptor$Builder
agent1Test1.sources.seqGenSrc.interceptors.hostInterceptor.hostHeader = *
host *
agent1Test1.sinks.loggerSink.hdfs.path = hdfs://host:8020/data/%Y/%m/%d/%{*
host*}/Logs
================
Thanks,
Khadar
On Fri, Jul 27, 2012 at 1:20 PM, Stern, Mark <[email protected]> wrote:
> I am not sure if this is the cause of your problem, but you seem to have a
> mismatch for the hostname header key
> between your interceptor (myhostname) and your sink (host).
> ________________________________________
> From: khadar basha [[email protected]]
> Sent: Friday, July 27, 2012 8:48 AM
> To: [email protected]
> Subject: Exception in thread "main" java.lang.NoClassDefFoundError:
> org/apache/flume/node/Application
>
> Hi,
>
> I am using flume1.2 version. Having the following configuration.
>
>
>
> agent1Test1.sources = seqGenSrc
> agent1Test1.channels = memoryChannel
> agent1Test1.sinks = loggerSink
>
> # For each one of the sources, the type is defined
> agent1Test1.sources.seqGenSrc.type = exec
> agent1Test1.sources.seqGenSrc.command= tail -f /tomcat/logs/catalina.out
> agent1Test1.sources.seqGenSrc.interceptors = hostInterceptor
> agent1Test1.sources.seqGenSrc.interceptors.hostInterceptor.type =
> org.apache.flume.interceptor.HostInterceptor$Builder
> agent1Test1.sources.seqGenSrc.interceptors.hostInterceptor.hostHeader =
> myhostname
>
> # The channel can be defined as follows.
> agent1Test1.sources.seqGenSrc.channels = memoryChannel
>
> # Each sink's type must be defined
> agent1Test1.sinks.loggerSink.type = hdfs
> agent1Test1.sinks.loggerSink.hdfs.path = hdfs://host:8020/data/%{host}/Logs
>
> agent1Test1.sinks.loggerSink.hdfs.fileType = DataStream
>
> #Specify the channel the sink should use
> agent1Test1.sinks.loggerSink.channel = memoryChannel
>
> # Each channel's type is defined.
> agent1Test1.channels.memoryChannel.type = memory
>
> # Other config values specific to each type of channel(sink or source)
> # can be defined as well
> # In this case, it specifies the capacity of the memory channel
> agent1Test1.channels.memoryChannel.capacity = 1000
>
>
> Gettting the following exception:
>
>
> Exception in thread "main" java.lang.NoClassDefFoundError:
> org/apache/flume/node/Application
> Caused by: java.lang.ClassNotFoundException:
> org.apache.flume.node.Application
> 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)
> Could not find the main class: org.apache.flume.node.Application. Program
> will exit.
> --
> Thanks,
> Khadar
>
>
--
Thanks,
Khadar