<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
<title></title>
</head>
<body bgcolor="#ffffff" text="#000000">
Hello<br>
<br>
It was my error,since I had a bug in regexp in a stored procedure in
PostgreSQL,so the procedure was not processing particular message from
syslog.<br>
By the way,is it possible for syslog-ng to call stored procedure
directly,instead of logging into file and then another script picking
up that data and storing them into database ?<br>
Basically,is it possible for a syslog-ng to do the following:<br>
<br>
1. Got message,filter satisfied,it will call destination 'sql' for
example.<br>
2. destination 'sql' will connect to database,and do the following :<br>
<br>
select * from syslog_procedure('$MSG');<br>
<br>
instead of the classic way of insert:<br>
<br>
insert into syslog_table (message) values ('$MSG');<br>
<br>
Sincerely<br>
<br>
Dragan Zubac<br>
<br>
Lance Laursen wrote:
<blockquote
cite="mid:AANLkTileEhf4VCgz9rs2eV9KaNobbBx59xv8zQdOYih_@mail.gmail.com"
type="cite">
<div class="gmail_quote">On Fri, Jun 4, 2010 at 3:41 AM, Balazs
Scheidler <span dir="ltr"><<a moz-do-not-send="true"
href="mailto:bazsi@balabit.hu">bazsi@balabit.hu</a>></span> wrote:<br>
<blockquote class="gmail_quote"
style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div class="im">On Wed, 2010-06-02 at 17:09 +0200, Dragan Zubac
wrote:<br>
> Hello<br>
><br>
> I'm using syslog-ng to log messages into PostgreSQL via file
logging.<br>
> I have a problem,because syslog-ng actually sends two messages
from log<br>
> file,instead one at a time.<br>
> In attachment,You may see two messages that has the same ID number
and<br>
> were sent together,as 'one' message into database procedure.<br>
> Is it possible to configure syslog-ng to send one message at a
time only ?<br>
<br>
</div>
I don't really understand your question. The messages you have marked in<br>
your original email use the same PID, but pids are in no way unique.<br>
</blockquote>
<div><br>
</div>
<div>Perhaps postfix is sending a log message to syslog with a
newline character in it - so syslog is printing it as two separate log
lines in the file, but sending to postgres as one message? I don't
understand the question either if this is not the case.</div>
<div><br>
</div>
<blockquote class="gmail_quote"
style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div class="im"><br>
<br>
--<br>
Bazsi<br>
<br>
______________________________________________________________________________<br>
Member info: <a moz-do-not-send="true"
href="https://lists.balabit.hu/mailman/listinfo/syslog-ng"
target="_blank">https://lists.balabit.hu/mailman/listinfo/syslog-ng</a><br>
Documentation: <a moz-do-not-send="true"
href="http://www.balabit.com/support/documentation/?product=syslog-ng"
target="_blank">http://www.balabit.com/support/documentation/?product=syslog-ng</a><br>
FAQ: <a moz-do-not-send="true"
href="http://www.campin.net/syslog-ng/faq.html" target="_blank">http://www.campin.net/syslog-ng/faq.html</a><br>
<br>
<br>
______________________________________________________________________<br>
</div>
<div>
<div class="h5">This email has been scanned by the MessageLabs
Email Security System.<br>
For more information please visit <a moz-do-not-send="true"
href="http://www.messagelabs.com/email" target="_blank">http://www.messagelabs.com/email</a><br>
______________________________________________________________________<br>
</div>
</div>
</blockquote>
</div>
<br>
<br clear="all">
<br>
-- <br>
Lance Laursen<br>
Demonware Systems Engineer<br>
<pre wrap="">
<hr size="4" width="90%">
______________________________________________________________________________
Member info: <a class="moz-txt-link-freetext" href="https://lists.balabit.hu/mailman/listinfo/syslog-ng">https://lists.balabit.hu/mailman/listinfo/syslog-ng</a>
Documentation: <a class="moz-txt-link-freetext" href="http://www.balabit.com/support/documentation/?product=syslog-ng">http://www.balabit.com/support/documentation/?product=syslog-ng</a>
FAQ: <a class="moz-txt-link-freetext" href="http://www.campin.net/syslog-ng/faq.html">http://www.campin.net/syslog-ng/faq.html</a>
</pre>
</blockquote>
</body>
</html>