You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@flume.apache.org by "lizhenmxcz@163.com" <li...@163.com> on 2015/10/15 05:21:17 UTC

flume use syslogudp source error

hi all:
i'm use flume to receive syslog that send by perl,but there are alway some errors.
Oct 15, 2015 11:11:13 AM org.jboss.netty.channel.SimpleChannelHandler
WARNING: EXCEPTION, please implement org.apache.flume.source.SyslogUDPSource$syslogHandler.exceptionCaught() for proper handling.
java.lang.NumberFormatException: For input string: ""
        at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65)
        at java.lang.Integer.parseInt(Integer.java:504)
        at java.lang.Integer.parseInt(Integer.java:527)
        at org.apache.flume.source.SyslogUtils.buildEvent(SyslogUtils.java:294)
        at org.apache.flume.source.SyslogUtils.extractEvent(SyslogUtils.java:476)
        at org.apache.flume.source.SyslogUDPSource$syslogHandler.messageReceived(SyslogUDPSource.java:78)
        at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:268)
        at org.jboss.netty.channel.socket.oio.OioDatagramWorker.process(OioDatagramWorker.java:54)
        at org.jboss.netty.channel.socket.oio.AbstractOioWorker.run(AbstractOioWorker.java:75)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
        at java.lang.Thread.run(Thread.java:745)
The following is the packet.
who can help me ,thanks.



lizhenmxcz@163.com

Re: Re: flume use syslogudp source error

Posted by "lizhenmxcz@163.com" <li...@163.com>.
thank to Gonzalo. But i see the priority in the packet.





lizhenmxcz@163.com
 
From: Gonzalo Herreros
Date: 2015-10-15 15:35
To: dev
Subject: Re: flume use syslogudp source error
The error is because your event doesn't conform to the syslog standard
https://tools.ietf.org/html/rfc5424
Are you building the message manually or are you calling the "logger"
command?
 
In your case is missing the priority, which is a number in the header,
enclosed in < >
 
Regards,
Gonzalo
 
On 15 October 2015 at 04:21, lizhenmxcz@163.com <li...@163.com> wrote:
 
>
> hi all:
> i'm use flume to receive syslog that send by perl,but there are alway some
> errors.
> Oct 15, 2015 11:11:13 AM org.jboss.netty.channel.SimpleChannelHandler
>
> WARNING: EXCEPTION, please implement org.apache.flume.source.SyslogUDPSource$syslogHandler.exceptionCaught() for proper handling.
> java.lang.NumberFormatException: For input string: ""
>
>         at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65)
>         at java.lang.Integer.parseInt(Integer.java:504)
>         at java.lang.Integer.parseInt(Integer.java:527)
>
>         at org.apache.flume.source.SyslogUtils.buildEvent(SyslogUtils.java:294)
>
>         at org.apache.flume.source.SyslogUtils.extractEvent(SyslogUtils.java:476)
>
>         at org.apache.flume.source.SyslogUDPSource$syslogHandler.messageReceived(SyslogUDPSource.java:78)
>
>         at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:268)
>
>         at org.jboss.netty.channel.socket.oio.OioDatagramWorker.process(OioDatagramWorker.java:54)
>
>         at org.jboss.netty.channel.socket.oio.AbstractOioWorker.run(AbstractOioWorker.java:75)
>
>         at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
>
>         at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
>         at java.lang.Thread.run(Thread.java:745)
> The following is the packet.
> who can help me ,thanks.
>
> ------------------------------
> lizhenmxcz@163.com
>

Re: flume use syslogudp source error

Posted by Gonzalo Herreros <gh...@gmail.com>.
The error is because your event doesn't conform to the syslog standard
https://tools.ietf.org/html/rfc5424
Are you building the message manually or are you calling the "logger"
command?

In your case is missing the priority, which is a number in the header,
enclosed in < >

Regards,
Gonzalo

On 15 October 2015 at 04:21, lizhenmxcz@163.com <li...@163.com> wrote:

>
> hi all:
> i'm use flume to receive syslog that send by perl,but there are alway some
> errors.
> Oct 15, 2015 11:11:13 AM org.jboss.netty.channel.SimpleChannelHandler
>
> WARNING: EXCEPTION, please implement org.apache.flume.source.SyslogUDPSource$syslogHandler.exceptionCaught() for proper handling.
> java.lang.NumberFormatException: For input string: ""
>
>         at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65)
>         at java.lang.Integer.parseInt(Integer.java:504)
>         at java.lang.Integer.parseInt(Integer.java:527)
>
>         at org.apache.flume.source.SyslogUtils.buildEvent(SyslogUtils.java:294)
>
>         at org.apache.flume.source.SyslogUtils.extractEvent(SyslogUtils.java:476)
>
>         at org.apache.flume.source.SyslogUDPSource$syslogHandler.messageReceived(SyslogUDPSource.java:78)
>
>         at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:268)
>
>         at org.jboss.netty.channel.socket.oio.OioDatagramWorker.process(OioDatagramWorker.java:54)
>
>         at org.jboss.netty.channel.socket.oio.AbstractOioWorker.run(AbstractOioWorker.java:75)
>
>         at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
>
>         at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
>         at java.lang.Thread.run(Thread.java:745)
> The following is the packet.
> who can help me ,thanks.
>
> ------------------------------
> lizhenmxcz@163.com
>