451 Commits

Author SHA1 Message Date
Rainer Gerhards
f771764fab Merge branch 'aaron' into v4-beta
Conflicts:
	runtime/rsyslog.h
2009-10-02 09:21:25 +02:00
Rainer Gerhards
6a69e47822 added $InputTCPServerNotifyOnConnectionClose config directive 2009-10-01 18:39:21 +02:00
Rainer Gerhards
176f773a2e Merge branch 'v4-stable' into v4-beta & BUGFIX
Conflicts:
	configure.ac
	doc/manual.html
	runtime/datetime.h
	runtime/parser.c
	runtime/rsyslog.h
	tools/syslogd.c

v4-stable had a bug with RFC5424-formatted structured data, which showed
was detected by the enhanced automatted testbench of v4-beta.
2009-10-01 16:30:32 +02:00
Rainer Gerhards
f45217e776 bugfix: zero-sized UDP messages are no longer processed
Until now, they were forwarded to processing, but this makes no sense
Also, it looks like the system seems to provide a zero return code
on a UDP recvfrom() from time to time for some internal reasons. These
"receives" are now silently ignored.
2009-09-29 14:37:33 +02:00
Rainer Gerhards
ea6570c993 Merge branch 'v4-stable' into v4-beta
Conflicts:
	ChangeLog
	configure.ac
	doc/manual.html
2009-09-03 15:52:24 +02:00
Rainer Gerhards
1e9febaf28 bugfix: reverse lookup reduction logic in imudp do DNS queries too often
A comparison was done between the current and the former source address.
However, this was done on the full sockaddr_storage structure and not
on the host address only. This has now been changed for IPv4 and IPv6.
The end result of this bug could be a higher UDP message loss rate than
necessary (note that UDP message loss can not totally be avoided due
to the UDP spec)
2009-09-03 15:48:57 +02:00
Rainer Gerhards
56b781e5bb added $InputTCPMaxListeners directive
permits to specify how many TCP servers shall be possible (default is 20).
2009-08-17 17:18:19 +02:00
Rainer Gerhards
9de685929e bugfix: message could be truncated after TAG, often when forwarding
This was a result of an internal processing error if maximum field
sizes had been specified in the property replacer.
Also did some testbench improvements, including omstdout.
2009-07-09 16:32:14 +02:00
Rainer Gerhards
da933a7e10 added $klogConsoleLogLevel directive
...which permits to set a new console log level while rsyslog is active
2009-07-03 11:57:21 +02:00
Rainer Gerhards
7bfa03bdc0 now put the new property-based methods to good use
... hopefully reducing the number of allocs/frees as well as overall
memory usage in a busy system (plus that these shared properties hopefully
remain in cache longer than its single-instance counterparts...)
2009-07-01 14:33:19 +02:00
Rainer Gerhards
d6faee67b4 RcvFromIP now also a property
This sets stage to enable use of the property-interface to speed
up things (mildly), the next step to be done. I have also fixed one
regression of yesterday's changes.
2009-07-01 13:28:17 +02:00
Rainer Gerhards
aaffc4281e introduced a new way of handling the RcvFrom property
... plus a fix for a long-time bug in obj-types.h. That lead to
the object pointer only then to become NULL when the object was
actually destructed, I discovered this issue during
introduction of the pRcvFrom property in msg_t, but it potentially had other
effects, too. I am not sure if some experienced instability resulted from this
bug OR if its fix will cause harm to so-far "correctly" running code. The later
may very well be. Thus I will change it only for the current branch and also
the beta, but not in all old builds. Let's see how things evolve.
2009-06-30 18:45:41 +02:00
Rainer Gerhards
e397c34d2a finished transition to using inputName property
... plus some celanup and adding minor missing functionality
(the rule debug info again tell the property name, not just number).
2009-06-30 15:21:15 +02:00
Rainer Gerhards
de84a12f8a introduced the idea of detached properties
some things inside the message can be used over a large number of
messages and need to to be allocated and re-written every time. I now
begin to implement this as a "prop_t" object, first use for the inputName.
Some input modules are already converted, some others to go. Will do
a little performance check on the new method before I go further.

Also, this commit has some cleanup and a few bug fixes that prevented
compiliation in debug mode (I overlooked this as I did not compile
for debug, what I normally do, and the automatted test also does not
do that)
2009-06-29 16:53:26 +02:00
Michael Terry
ba4806a704 add support for KLogPath 2009-06-29 10:58:38 +02:00
Rainer Gerhards
662ad3e4bf optimized hostname processing 2009-06-23 16:32:29 +02:00
Rainer Gerhards
2de4964aff optimized handling of MSG part in msg object
WARNING: currently, message repeation processing is disabled, must
be reenabled (but prefer to do some other tests first)
2009-06-18 16:51:40 +02:00
Rainer Gerhards
2f86678c57 optimized TAG handling in msg object 2009-06-18 14:30:21 +02:00
Rainer Gerhards
8628312396 cleaned up/optimized raw message handling in msg object 2009-06-18 13:22:21 +02:00
Rainer Gerhards
98348ae03d Merge branch 'master' into omfile
Conflicts:
	ChangeLog
	runtime/msg.h
	tcps_sess.c
	tcpsrv.c
	tools/syslogd.c
2009-06-16 12:59:55 +02:00
Rainer Gerhards
74b2b24f50 removed long-obsoleted property UxTradMsg
... as well as some cleanup (some commented-out code is left to
support UxTradMsg again is someone really complains ;)).
2009-06-16 12:31:27 +02:00
Rainer Gerhards
015d17ca70 some performance optimizations
- saved gettimeofday() calls in imtcp (and increased reception buffer)
- somewhat optimized stringbuf.c
- some other optimizations
2009-06-16 08:46:45 +02:00
Rainer Gerhards
b5ccdf0672 performance-enhanced imtcp
...by now using lowres time and thus saving many time() calls. This needs
some performance testing and must be made configurable if it works out.
2009-06-12 15:59:50 +02:00
Rainer Gerhards
ca0ddc30a3 completed multi-ruleset core support
... as well as added multi-ruleset support for imtcp
2009-06-12 15:31:08 +02:00
Rainer Gerhards
e3d9843c85 re-enabled pipe, tty and console in omfile
... by moving code to stream.c. Thanks to the new design, new cases are
not really needed, resulting in cleaner code.

I also did a cleanup of header file usage as a side-activity.
2009-06-12 11:47:00 +02:00
Rainer Gerhards
76da7f9f4e added $OMFileIOBufferSize config directive and plumbing 2009-06-04 15:59:37 +02:00
Rainer Gerhards
9e434f19a9 cleaned up stream class ...
... and also made it callable via an rsyslog interface rather then
relying on the OS loader (important if we go for using it inside
loadbale modules, which we soon possible will)
2009-06-04 12:15:59 +02:00
Rainer Gerhards
25daa04902 added support for custom modules
... this provides some basic support to integrate extensions that
are not direct parts of rsyslog to be built during its build
process.
2009-06-02 07:44:07 +02:00
Rainer Gerhards
eafafc6359 fix: import from beta accidently disable imdiag 2009-05-29 14:31:50 +02:00
Rainer Gerhards
53fc3b9af9 Merge branch 'beta' 2009-05-29 14:24:58 +02:00
Rainer Gerhards
2ed8e41b31 Merge branch 'v3-stable' into beta
Conflicts:
	ChangeLog
2009-05-29 13:52:55 +02:00
Rainer Gerhards
43c45bfebc fixed problem in syslog-protocol (now RFC5424) parser
... as well as some other minor issues.
2009-05-29 13:40:04 +02:00
Rainer Gerhards
d7c98e7a6e Merge branch 'beta' into master
Conflicts:
	tests/Makefile.am
2009-05-28 18:34:17 +02:00
Rainer Gerhards
8d8befaeca Merge branch 'v3-stable' into beta
Conflicts:
	tests/Makefile.am
2009-05-28 18:23:53 +02:00
Rainer Gerhards
a900a7c34b greatly enhanced testbench
The imdiag module now can very effectively inject messages, which also
frees us from uncertainties of tcp reception and processing. All shell
script based tests have been modularized, what makes it far easier to
create new tests. Also, the test bench now executes more reliable and
much faster, because we can now rely on actual engine information where
we previously did just a dumb sleep.
2009-05-27 11:29:47 +02:00
Rainer Gerhards
eb1615068c added new testing module imdiag
which enables to talk to the rsyslog core at runtime. The current
implementation is only a beginning, but can be expanded over time
2009-05-25 10:47:22 +02:00
Rainer Gerhards
aba90e8248 added capability to run multiple tcp listeners (on different ports)
Well, actually this and a lot of related things. I improved the
testbench so that the new capabilities are automatically tested and
also did some general cleanup. The current multiple tcp listener
solution will probably receive some further cleanup, too, but looks
quite OK so far. I also reviewed the way tcpsrv et all work, in
preparation of using this code for imdiag. I need to document the
findings, especially as the code is rather complicated "thanks" to
the combination of plain tcp and gssapi transport modes.
2009-05-22 17:06:52 +02:00
Rainer Gerhards
2aca3c2d33 made imdiag *just* compile & some cleanup
imdiag was never finished (not even really begun), but now I need it.
I made the few things that are available compile, but more serious
work is required.
2009-05-20 17:35:21 +02:00
Rainer Gerhards
b47d95286b bugfix: potential segfault issue when multiple $UDPServerRun directives are specified.
Thanks to Michael Biebl for helping to debug this one.
2009-05-12 12:03:00 +02:00
Luis Fernando Muñoz Mejías
9823c73d1d Make it recover from errors on insertions.
If the database rejected some entry, making the statement fail on it,
the batch was not cleaned and the same values were retried over and
over, causing a cascade of failures and a denial of service.

We use now OCI_BATCH_ERRORS so that everything valid in the batch is
inserted, and rejected values can be discarded.
2009-04-29 17:10:19 +02:00
Luis Fernando Muñoz Mejías
c35ce31aed Replace get_db_statement by a template.
Instead of reading a complete line, we'll use a template and delegate
in the core to read such template. Then, all omoracle has to do is to
find that template and use it as the prepared statement.

I'm not sure if this is the correct approach, though. It has to dig
too much into rsyslog's structures...

txt_statement is stored in a private area, so that we don't mess too
much with rsyslog's internals (I still don't feel comfortable with
this much digging into template structures).
2009-04-29 17:10:00 +02:00
Luis Fernando Muñoz Mejías
65a69831e9 Add the $OmoracleBatchItemSize directive
This directive controls the amount of memory needed for properties in
the batch. Users should specify the largest value they expect in the
statement. As per Rainer's comment:

on MAX_BUFSIZE: I'd tend to make this configurable, because with
RFC5424 messages can be much longer and RFC5425 now recommends a
minimum maximum size of 8K.

So we let users to choose. Maybe we need a sensible default value to
make users' lifes easier?

Also, the old non-vector based interface is not supported anymore. I
broke it already when moving to this stage.
2009-04-29 17:09:20 +02:00
Luis Fernando Muñoz Mejías
e65a30ddaa Add licensing information.
I'm not sure if GPLv3 contemplates the ability to link to proprietary
software, if it was previous work. I explicitly allow linking to OCI.
2009-04-29 17:08:37 +02:00
Rainer Gerhards
f8d9aad082 bugfix: compile problems in im3195 2009-04-23 11:45:50 +02:00
Rainer Gerhards
889a0a1da8 some cleanup
... mostly removal of compile-time warnings (thanks to Michael
Biebl for suggesting to look after that)
2009-04-17 15:19:57 +02:00
Rainer Gerhards
09ca443377 update project status & cleanup
removed some warning in imklog compilation, but may not have
solved a lurking issue (but placed comment so that we know if
something surfaces)
2009-04-17 15:10:06 +02:00
Rainer Gerhards
3f6c6cff47 Merge branch 'master' into nextmaster 2009-04-17 14:21:52 +02:00
Rainer Gerhards
51d68bb9af Merge branch 'beta' 2009-04-17 14:21:02 +02:00
Rainer Gerhards
63d3982721 Merge branch 'v3-stable' into beta 2009-04-17 14:19:43 +02:00
Rainer Gerhards
53bff58625 Merge branch 'debian_lenny' into v3-stable 2009-04-17 14:19:22 +02:00