How to allow sysklogd to receive more than 1024 chars?
Created 2003-05-06 by Michael Meckelein.
By default the sysklogd package can handle up to 1024 bytes maximum message size. The
MonitorWare Products support sending syslog messages with more than 1024 characters.
Of course, according to RFC3164 syslog messages have the limitation of 1024 bytes. But
in several environments there is a need to log oversize messages. To enable sysklogd
to receive these oversize messages, do the following (verified with sysklogd-1.4.1):
- Open syslogd.c from the sysklogd package
- Search the source code for the line:
#define MAXLINE 1024 /*
maximum line length */
- If you change the #define MAXLINE to e.g. 1502, it should give you up
to 1500 characters per message.
Note: The two missing characters, caused by the line
i = recv(fd, line, MAXLINE - 2, 0);
- Now you can recompile the package.
|